samples: cc13x2_cc26x2: system_off: force soft off state
In the last step of the example, the system should go into soft off state in order to match the original intent in the example to go into the hardware's SHUTDOWN mode. Fixes #31727 Signed-off-by: Vincent Wan <vanti.coder@gmail.com>
This commit is contained in:
parent
66ed8d53e5
commit
41a726dac8
|
@ -64,11 +64,10 @@ void main(void)
|
|||
status = GPIO_getEventMultiDio(GPIO_DIO_ALL_MASK);
|
||||
GPIO_clearEventMultiDio(status);
|
||||
|
||||
/* Above we disabled entry to deep sleep based on duration of
|
||||
* controlled delay. Here we need to override that, then
|
||||
* force a sleep so that the deep sleep takes effect.
|
||||
/*
|
||||
* Force the SOFT_OFF state.
|
||||
*/
|
||||
pm_power_state_force((struct pm_state_info){PM_STATE_STANDBY, 0, 0});
|
||||
pm_power_state_force((struct pm_state_info){PM_STATE_SOFT_OFF, 0, 0});
|
||||
k_sleep(K_MSEC(1));
|
||||
|
||||
printk("ERROR: System off failed\n");
|
||||
|
|
Loading…
Reference in a new issue