nrf52833 failed to wake up from SOFT_OFF

Dear all,

I am developing a device that base on nrf52833, nrf connect sdk ver 2.0.0

The device run bluetooth mesh. And becase it was powered  by battery, so it must go into sleep mode, and wake up by GPIOs in specific scenarios.

This is the function that put the device into sleep mode

void app_system_sleep(struct k_work *work_tem) {
	nrf_gpio_cfg_sense_input(wake_pin_1, NRF_GPIO_PIN_NOPULL, NRF_GPIO_PIN_SENSE_LOW);
	nrf_gpio_cfg_sense_input(wake_pin_2, NRF_GPIO_PIN_NOPULL, NRF_GPIO_PIN_SENSE_LOW);
	
	LREP(__func__,"Entering system off");
	bt_mesh_suspend();
	
	const struct pm_state_info si = {PM_STATE_SOFT_OFF, 0, 0};
	pm_state_force(0, &si);

	k_sleep(K_MSEC(100));
	
	LREP(__func__, "Exit sleep mode");
	NVIC_SystemReset();
}

After the deviced run for about 1-2 days, It failed to wake up via wake_pin_1 and wake_pin_2. And I must re-power it.
One thing I am not sure, when the device went into this error, Its current consumsion is about 500uA.
Please help me.
Best regards.
  • Hi

    It seems like you're trying to set a timer as the wake up source after going to system OFF. When the nRF52 series devices are in system OFF, the CPU and all peripherals like timers, etc. are disabled entirely. Also, is this LREP a custom define you have made, because it seems a bit out of place here. I would strongly recommend checking out the nRF5x System OFF demo in NCS here, that shows a good way of going to system OFF.

    Best regards,

    Simon

  • Dears,

    Thank you for your prompt response.

    It seems like you're trying to set a timer as the wake up source after going to system OFF

    I am not tryting to wake up by a timer. I only have two GPIO working as wakeup source (GPIO inputs).

    Also, is this LREP a custom define you have made, because it seems a bit out of place here.

    This is my debug function via RTT. I have tested when enable or disable CONFIG_CONSOLE and CONFIG_RTT_CONSOLE.

    I would strongly recommend checking out the nRF5x System OFF demo in NCS here, that shows a good way of going to system OFF.

    Yes I already checked the demo.

    I think problem might because of the bluetooth mesh. 

    When my device is not provisioned, it is working fine. The issue was only after the device is provisioned.

    I am trying to locate the problem.

    Do you have any idea? 

    Best regards.

  • Hi

    Okay, you're using the Bluetooth Mesh. Mesh is in general a very power hungry as provisioned nodes need to continuously keep their radio in listening mode, which will indeed draw additional current. In order to enable low power devices (LPN) to take part in a Mesh network, you need to implement the Friendship feature. This lets low power devices establish a relationship with regular Mesh devices, which will then cache and forward messages to the low power device at regular intervals. 

    In the nRF Connect SDK we don't have sample projects using LPNs and Friend nodes, but you can enable a friend node by setting this config CONFIG_BT_MESH_FRIEND. You can also add the LPN feature with the configs you can find by searching for CONFIG_BT_MESH_LPN in the KConfig search.

    Best regards,

    Simon

  • Dears,

    In order to enable low power devices (LPN) to take part in a Mesh network, you need to implement the Friendship feature. This lets low power devices establish a relationship with regular Mesh devices, which will then cache and forward messages to the low power device at regular intervals. 

    Yes, this is a different approach for the bluetooth mesh.

    What is the lowest current consumption of the nrf52833 from this LPN mode?

    Best regards.

  • Hi

    Please check out this case, and the other tickets that are linked in it, which explains how low you should be able to go with a low power node (LPN) in Bluetooth Mesh. While still having the Mesh stack enabled you should be able to get down to ~14µA with the nRF52833, but as Hung suggests in this ticket, you can disable the Mesh stack entirely and go to deep sleep mode, only waking up when you want to transmit something (must be at least every 96 hours) to get down to ~4µA in sleep mode. Please note that the wake up and mesh stack enable will take some time and current, so this method is only "worth it" if the device wakes up very rarely.

    Best regards,

    Simon

Related