What function should be used instead of pm_state_force(0u, &(const struct pm_state_info){PM_STATE_STANDBY, 0, 0}); in SDK 2.5.0

SDK 2.5.0 does not support CONFIG_PM feature for nrf5340 because nrf5340 does not HAS_PM in SDK2.5.0

So pm_state_force(0u, &(const struct pm_state_info){PM_STATE_STANDBY, 0, 0}); function is changed to sys_poweroff();

But I don't know how can be changed following function.

(this function is for keep System on sleep mode  and wakeup after deginaged time.

pm_state_force(0u, &(const struct pm_state_info){PM_STATE_STANDBY, 0, 0});

g_current_tid = k_current_get();
k_msleep(sleep_time_ms);

..

other interrupt routine has following function and make it wake up.

  if(g_current_tid){
      k_wakeup(g_current_tid);

pm_state_force(0u, &(const struct pm_state_info){PM_STATE_STANDBY, 0, 0}); function make all peheriperial go to suspense mode

with calling pm_suspend_devices() function.

But pm_state_force(0u, &(const struct pm_state_info){PM_STATE_STANDBY, 0, 0}) and

pm_suspend_devices() functions can not be used any more in SDK 2.5.0.

How can I make all peheriperial go to suspense mode instead of above functions.

Please guide me resolving this issue.

Best Regards

KIM

Related