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

App_timer with Soft device and sd_app_evt_wait

My application is using multiple features such as BLE UART, Proximity and TWI.

I've two twi sensors triggered when needed. and one of them generate an int to wake up the device. (this is working perfectly today). 

My project also integrate Serial UART And I managed to exchange with the toolbox software using the uart app. 

logic is as follow:

Init all and advertise to check if the mobile app wants to connect. If not sleep by using  nrf_pwr_mgmt_run which trigger sd_app_evt_wait.

device looks to go to sleep mode and wake up when event on IO (interrupt of the twi sensor) occurs. 

I need also to wake up my device every 4h to send information to a server (I'm sending to a modem thru serial) 

For this I setup an App_timer to wake up the device.

For testing I setup the period to few 12sec and the timer occurs while the advertising is running. when device go to sd_app_evt_wait timer never wake up my device

I'm feeling I may miss something that most of you already master. Thanks for your time helping me on this

Didier

Parents
  • Hi DidT, 

    I suspect that your device entered deep sleep mode (SYSTEM OFF) when the advertising is timed out. Could you let me know which SDK you are working on ? 


    For example in SDK v15.3, proximity example you can find in on_adv_evt() in main.c when the advertising state enter IDLE mode it will put the chip to system off mode and in that mode you can only wake up either using a GPIO interrupt or a pin reset. 

  • Ok thank you.

    I'll trace and verify. I effectively started from the advertising example and use SDK 15.3. And effectively I missed this one Slight smile

    Thanks again

    Didier

Reply
  • Ok thank you.

    I'll trace and verify. I effectively started from the advertising example and use SDK 15.3. And effectively I missed this one Slight smile

    Thanks again

    Didier

Children
No Data