cancel
Showing results for 
Search instead for 
Did you mean: 

[OpenThread] Sending CoAP to Thread SED from leader

shreyask21
Associate

I have used the Cube examples "Thread_FTD_Coap_Multicast" and "Thread_SED_Coap_FreeRTOS" and I was able to receive CoAP multicast from SED to the thread leader however I am not able to send messages to the SED in any way at all when I pressed SW1 on the Nucleo board.

 

I also tried the Thread CLI as a leader with the following commands:

panid 0x2222
channel 12
networkkey 00112233445566778899aabbccddeeff
ifconfig up
thread start
coap start

And I saw that the Thread CLI was in Leader state and SED was connected to the thread CLI but I was not getting any CoAP messages from SED and I was not able to send any messages to SED either through CoAP (GET, PUT, POST) (CON/NON-CON).

 

I would appreciate any pointers on how to achieve the Leader->SED communication through CoAP, or if any modifications necessary as I am quite new to OT devel.

Thanks in advance

 

Some boilerplate info:

STM32CubeIDE V1.13.2
STM32CubeWB V1.17.3

Thread SED:
P-NucleoWB55 // STM32WB55RG
M0 Copro FW: stm32wb5x_Thread_MTD_fw.bin V1.17.1
CFG_FULL_LOW_POWER set to DISABLED

Thread Leader:
P-NucleoWB55 // STM32WB55RG
M0 Copro FW: stm32wb5x_Thread_FTD_fw.bin V1.17.1

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

Thank you for the warm welcome @STTwo-32 !

I have already tried the example you suggested (FTD Multicast) on two boards. it works as expected.

But as I am developing a battery powered device (which will involve a Thread SED), I wish to know how to receive CoAP on the SED.

It would be amazing if you could help me out on how to achieve it.

 

Regarding the Thread CLI, I was able to fix it by creating the resource manually after starting CoAP with the command:

coap resource light

This fixed the issue and I was able to receive the CoAP from SED->Leader. I am posting this as it may be useful for someone in the future looking for the fix.

 

View solution in original post

2 REPLIES 2
STTwo-32
ST Employee

Hello @shreyask21 and welcome to the ST Community 😊

As I understand, you are looking to have a bidirectional communication between 2 STM32WB55RG_Nucleo in a thread network. For that, I suggest you use the Thread_FTD_Coap_Multicast example on both boards.

best regards.

STTwo-32

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Thank you for the warm welcome @STTwo-32 !

I have already tried the example you suggested (FTD Multicast) on two boards. it works as expected.

But as I am developing a battery powered device (which will involve a Thread SED), I wish to know how to receive CoAP on the SED.

It would be amazing if you could help me out on how to achieve it.

 

Regarding the Thread CLI, I was able to fix it by creating the resource manually after starting CoAP with the command:

coap resource light

This fixed the issue and I was able to receive the CoAP from SED->Leader. I am posting this as it may be useful for someone in the future looking for the fix.