This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

NRF52840 Thread example power down 10 mins after USB disconnect

Hello,

I am trying the Thread Cloud COAP Client

<InstallFolder>\examples\thread\experimental\cloud_coap_client

on a NRF52840 PDK. I'm using Thread SDK v0.10.0. The example works as described.

However, when I unplug the board from USB, it goes into some kind of power down mode in approx. 10 minutes and loses connection to the Thread network. I can see LED1 is still on, but it is extremely faint. It is flickering, so trying to connect to the network, but it cannot do so. After a further 5-6 minutes of this, LED1 goes completely off.

I had a few questions about this behaviour:

  1. Where in the code can I set the time between USB disconnect and going in power-down mode?
  2. I know that the NRF52840 has System ON and System OFF power modes. Where in the code can I set which mode it should go in?
  3. Is the behaviour of it not being able to connect to the Thread network when in low power mode expected? If so, can I change this behaviour or is there a fix planned?

Thanks in advance!

Regards

Andy

Parents
  • Thanks for checking. An update from my side - I managed to get a bit further in receiving value on the NRF52840. Basically I use otCoapHeaderInit(&header, OT_COAP_TYPE_NON_CONFIRMABLE, OT_COAP_CODE_GET); to create a message and send that using otCoapSendRequest(p_instance, p_request, &message_info, cloud_data_request_callback, p_instance);. Here, cloud_data_request_callback is the callback function that is executed when the cloud responds with data. I execute this on Button press 3, which works, the cloud returns the JSON string for the requested resource. However, this is the NRF52 kind of polling. Instead, I would like the callback function to be executed when the value on the cloud is changed. For that, I checked and saw there is an "observor" option that can be set using otCoapHeaderAppendObserveOption. In this function, I don't understand the second parameter aObserve Observe field value. I tried various values but they don't work. So it would be great if you could check with the developers about this issue!

Reply
  • Thanks for checking. An update from my side - I managed to get a bit further in receiving value on the NRF52840. Basically I use otCoapHeaderInit(&header, OT_COAP_TYPE_NON_CONFIRMABLE, OT_COAP_CODE_GET); to create a message and send that using otCoapSendRequest(p_instance, p_request, &message_info, cloud_data_request_callback, p_instance);. Here, cloud_data_request_callback is the callback function that is executed when the cloud responds with data. I execute this on Button press 3, which works, the cloud returns the JSON string for the requested resource. However, this is the NRF52 kind of polling. Instead, I would like the callback function to be executed when the value on the cloud is changed. For that, I checked and saw there is an "observor" option that can be set using otCoapHeaderAppendObserveOption. In this function, I don't understand the second parameter aObserve Observe field value. I tried various values but they don't work. So it would be great if you could check with the developers about this issue!

Children
No Data
Related