S2 wake on external pin ? #13374
-
Hi, I'm using an esp32-S2 (S2 mini) and I can't wake it up with an external signal (low level or high level). The code works fine on an ESP32-WROOM-32D but not on the S2. I'm using the latest version 1.22.1 (LOLIN_S2_MINI-20240105-v1.22.1.bin). I've tried other versions but it's the same. I've also tried other pins. With the WAKEUP_ANY_HIGH option, ESP never wakes up wake = Pin(3,Pin.IN) and with the WAKEUP_ALL_LOW option, ESP wakes up immediately after the deepsleep call. Is this a bug or is it not possible to do this type of wake-up with S2? This message is an opportunity to thank all those who worked on this brilliant micropython project! |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments
-
I did this on wemos s2 mini >>> from machine import Pin, deepsleep
>>> import esp32
>>> wake = Pin(21, Pin.IN, Pin.PULL_DOWN)
>>> esp32.wake_on_ext0(pin = wake, level = esp32.WAKEUP_ANY_HIGH)
>>> deepsleep()
[tio 00:07:29] Disconnected
Touch GPIO21 to 3V3
[tio 00:10:04] Connected According to espressif there are only two GPIOs dedicated to RTC_GPIO: RTC_GPIO0, RTC_GPIO21. GPIO1 to GPIO20 are also used for ADC1 and ADC2, and do not seem to work for the wake pin. Therefore, GPIO21 is the only viable GPIO. |
Beta Was this translation helpful? Give feedback.
-
hello, Thank you very much, it works very well with with GPIO21. It's a bit silly, this hardware limitation on the S2. |
Beta Was this translation helpful? Give feedback.
I did this on wemos s2 mini
According to espressif there are only two GPIOs dedicated to RTC_GPIO: RTC_GPIO0, RTC_GPIO21.
GPIO1 to GPIO20 are also used for ADC1 and ADC2, and do not seem to work for the wake pin. Therefore, GPIO21 is the only viable GPIO.