Hi when I set the device in EM3 I need to wake it up on a release interrupt. Tested and works fine.
But what if that interrupt never comes? In this case I need the device to go to EM4S sleep to conserve power.
What I'd like to do is:
- Schedule an action "go to EM4S sleep" in 60 seconds
- Set up an interrupt to wake the system from EM3 sleep using a pin
- Enter EM3 sleep
This way if a button interrupt comes within 60 seconds it will wake up the chip. If it doesn't the device will go to EM4S and can be woken up by pulling the WAKE pin low.
It's like a "reverse watchdog" which turns the device to EM4S if not kicked periodically. How can I do this?
NOTE: EM3 sleep needs to use multiple pin interrupts to wake up, I can't use the WAKE pin for this.