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

nrf51 not waking up if sleep time exceed (5 hours)

I configured nrf to go to sleep after 5 minutes of inactivity and then wake up by external signal (by accelerometer interrupt if any movement detected). what struck me is, when it goes to sleep and shake it, it wake up (if the time sleep is less then 5 hours), but if I let it sleep for more then 5 hours, it doenst wake up. the accelerometer is always powered. here my configuration before going to sleep. the wake up pin is connected to accelerometer interrupt pin. notice that im using a watchdog (I think but im not sure that the issue start to happen after setting the watchdog)

APP_ERROR_CHECK(acc_config_motion_detector());
NRF_GPIOTE->EVENTS_PORT = 0;
nrf_gpio_cfg_sense_input(WAKE_UP, NRF_GPIO_PIN_NOPULL, NRF_GPIO_PIN_SENSE_HIGH);
err_code = sd_power_system_off();
Related