Deep Sleep Wakeup and Interrupt

Posts: 1
Joined: Mon May 21, 2018 6:13 pm

Deep Sleep Wakeup and Interrupt

Postby jvanderstelt » Mon May 21, 2018 6:35 pm

I wanted to use deep sleep and respond to a user pressing a button and use a timer for a heartbeat. My question is:

With deep sleep I can set up the esp32 to wake up from deep sleep with the button press. When the CPU is running I can set up an interrupt to handle the button press.

If the deep sleep wakes up because of a timer, and the user presses the button before the code registers the interrupt handler, what happens?

Posts: 1
Joined: Tue Sep 04, 2018 2:31 pm

Re: Deep Sleep Wakeup and Interrupt

Postby Hr.Mitrev » Tue Feb 05, 2019 10:15 am

I don't have an answer, but I have similar question - can I configure GPIO as both wake up stub and interrupt while the CPU is running, or I should configure the interrupt first and then change it to wake up stub before going to sleep? Also what happens if you have configured wake up source and it kicks in while the cpu is running? Also it seems that as jvanderstelt mentioned it takes quite a bit of time to setup peripherals after deep-sleep how we can counteract that?

Who is online

Users browsing this forum: Baidu [Spider] and 17 guests