Unable to receive UDP messages when thread is active.

Hi,

I built a Thread Network using two nRF52840-DKs with the OpenThread CLI sample written.
After making each thread active, we opened a UDP socket and sent a message to the multicast address (ff02::1).
At this time, no log indicating reception was displayed on the other nRF52840-DK.
I can confirm using Wireshark that the UDP message can be sent reliably.

Also, when sending the same message after inactivating Thread with "ot thread stop", a log showing receipt was displayed.
Is there a way to receive UDP messages with Thread active?

Below are the respective CLI logs.

<< commissioner size log >>

*** Booting Zephyr OS build v3.3.99-ncs1 ***


uart:~$ ot thread stop
Done
uart:~$ ot dataset init new
Done
uart:~$ ot dataset channel 11
Done
uart:~$ ot dataset panid 0x1234
Done
uart:~$ ot dataset commit active
Done
uart:~$ ot ifconfig up
Done
uart:~$ ot thread start
Done
uart:~$ ot dataset
Active Timestamp: 1
Channel: 11
Channel Mask: 0x07fff800
Ext PAN ID: de1372f2690746ac
Mesh Local Prefix: fd87:e652:47f:59ee::/64
Network Key: 8e70238e21f467005ca0f012a2f544f2
Network Name: OpenThread-158d
PAN ID: 0x1234
PSKc: b0164bbfe9e483a4c4a7d2b1b389db3d
Security Policy: 672 onrc
Done
uart:~$ ot commissioner start
Commissioner: petitioning
Done
Commissioner: active
uart:~$ ot commissioner joiner add f4ce364117e9f1a4 N0RD1C
Done
Commissioner: Joiner start 237c8fef269a5885
Commissioner: Joiner connect 237c8fef269a5885
Commissioner: Joiner finalize 237c8fef269a5885
Commissioner: Joiner end 237c8fef269a5885
Commissioner: Joiner remove 237c8fef269a5885
uart:~$ ot udp open
Done
uart:~$ ot udp linksecurity disable
Done
uart:~$ ot udp send ff02::1 test1
Error 7: InvalidArgs
uart:~$ ot udp send ff02::1 2378 test1
Done
uart:~$ ot udp send ff02::1 2378 test2
Done
uart:~$ ot udp send ff02::1 2378 test3
Done
uart:~$ ot udp bind :: 2378
Done
uart:~$ ot thread stop
Done
5 bytes from fe80:0:0:0:e0e0:a6a0:5e93:1294 2378 test3
uart:~$ ot thread start
Done
uart:~$ ot ipaddr
fd87:e652:47f:59ee:0:ff:fe00:7800
fd87:e652:47f:59ee:0:ff:fe00:fc35
fd87:e652:47f:59ee:df22:d48b:3815:3dfd
fe80:0:0:0:4c7c:380a:7beb:2442
Done
Commissioner: disabled
uart:~$
uart:~$ ot thread stop
Done
5 bytes from fe80:0:0:0:e0e0:a6a0:5e93:1294 2378 test4
uart:~$

<< joiner side log >>

*** Booting Zephyr OS build v3.3.99-ncs1 ***


uart:~$ ot thread stop
Done
uart:~$ ot dataset init new
Done
uart:~$ ot dataset channel 11
Done
uart:~$ ot dataset panid 0x1234
Done
uart:~$ ot dataset commit active
Done
uart:~$ ot ifconfig up
Done
uart:~$ ot eui64
f4ce364117e9f1a4
Done
uart:~$ ot joiner start N0RD1C
Done
Join success
uart:~$ ot thread start
Done
uart:~$ ot udp open
Done
uart:~$ ot udp linksecurity disable
Done
uart:~$ ot udp bind :: 2378
Done
uart:~$ ot thread stop
Done
5 bytes from fe80:0:0:0:4c7c:380a:7beb:2442 49156 test2
5 bytes from fe80:0:0:0:4c7c:380a:7beb:2442 49156 test3
uart:~$ ot udp send ff02::1 2378 test1
Done
uart:~$ ot udp send ff02::1 2378 test2
Done
uart:~$ ot udp send ff02::1 2378 test3
Done
uart:~$ ot thread start
Done
uart:~$ ot ipaddr
fd87:e652:47f:59ee:0:ff:fe00:5400
fd87:e652:47f:59ee:ca07:9c8:34c3:dd44
fe80:0:0:0:e0e0:a6a0:5e93:1294
Done
uart:~$ ot udp send ff02::1 2378 test3
Done
uart:~$ ot udp send fe80:0:0:0:4c7c:380a:7beb:2442 2378 test4
Done
uart:~$

Best regards,

Yuma

Parents Reply
  • Hello Maria,

    I tested with disable linksecurity and I have confirmed that we can successfully receive UDP messages addressed to ff04::3:0.
    Thank you for your support.

    However, there are two things I don't understand, so please let me know.

    1. What effect does the linksecurity setting have?
    2. When linksecurity is set to enabled, it is not possible to receive data unless the thread is inactive. Is this the expected behavior?

    Best regards,

    Yuma

Children
Related