ESP32 - EN pin when in Deep Sleep State
When my board is in deep sleep state ( machine.deepsleep() ), when I press the EN button the machine.reset_cause() returns the machine.PWRON_RESET instead of the machine.DEEPSLEEP_RESET. Is this supposed to happen? How can I get the machine.DEEPSLEEP_RESET by pressing a button?
I tried the embedded EN button and connecting a physical button to the EN pin.
esp32 : fix for #7158 - machine.deepsleep() not behaving as expected
This PR fixes machine.deepsleep() waking up the board after a delay d, for example when a machine.lightsleep(d) call was issued previously. This is because previous wake-sources remain active, whereas machine.deepsleep() shall put the board to sleep forever as per the
machine.deepsleep documentation
See #7158 for more details on : issue description, reproduction steps and fix implementation.