CPU does not return from power_manage from BLE advertisement events (SDK V13 , S132, NRF52832)

Hi Everyone,

I am currently developing a BLE application.

I have noticed that advertisement events do not cause the CPU to return from sd_app_evt_wait(), is this the expected beheviour?

I have a watchdog timer set up ( pause on CPU system on idle ) and it is fed in the main thread whereby the CPU also sleeps after processing all the flags.

If I don't have any other interrupts running then I have found that the watchdog timer eventually triggers, I am guessing this is from the CPU waking up to process

the BLE advertisement event internally and then returning back to sleep  without running the main thread. Due to this eventually the watchdog timer eventually

expires from the accumulated time taken to handle each advertisement. 

If I enable an application interrupt ( such as a timer that expires every 1s ) then the watchdog timer does not expire. 

I have also tested this by adding a log message after the power_manage() function. 

Without other interrupts this message doesnt get printed ever if the device is just advertising indefinitely, but as soon as I add another interrupt or if

I connect to the device, then the message gets printed.

I am assuming the MCU only wakes up and return to main thread from user application events or interrupts but not internal ones?

Thanks.

Parents Reply Children
No Data
Related