Hello,
I am configuring 2 pins (GPIO32,33) as ext1 wakeup source from deep sleep with mode = ALL_LOW (i.e wakeup when both pins are LOW), the chip wakes up as expected when the configured pins are both LOW, but I have a problem I always get 0 as a return from esp_ext1_wakeup_status() trying to know which one caused the wakeup or even if both did.
I know that this function returns 0 when the wakeup reason is any thing other than DeepSleep , but I always have the wakeup cause as ESP_SLEEP_WAKEUP_EXT1 as returned by this function esp_sleep_get_wakeup_cause and DEEPSLEEP_RESET as return from this function rtc_get_reset_reason(0)
I am setting the "Delay for deep sleep stub" option = 2000, I even increased it to 5000
I don't have this problem when setting wakeup mode to "ANY_HIGH".
Always get 0 pins as ext1 wakeup source from deep sleep.
Always get 0 pins as ext1 wakeup source from deep sleep.
Last edited by borai7588 on Mon Jul 16, 2018 8:27 am, edited 1 time in total.
Re: Always get 0 from as ext1 wakeup source from deep sleep.
If the mode is ESP_EXT1_WAKEUP_ALL_LOW then don't you already know that they are ALL LOW?
Re: Always get 0 from as ext1 wakeup source from deep sleep.
Well, I need to Know which pin cased the wakeup when going LOW. I know I can do it the other way around using "ANY_HIGH" but that's the way the hardware is setup... and esp32 documentation does not mention that it is not possible.WiFive wrote:If the mode is ESP_EXT1_WAKEUP_ALL_LOW then don't you already know that they are ALL LOW?
Re: Always get 0 pins as ext1 wakeup source from deep sleep.
Since they all have to be low to wake up do you mean the last pin to go low? I don't think that would be stored in any registers.
Re: Always get 0 pins as ext1 wakeup source from deep sleep.
Ok, well it sounds logical what you say, but I find it strange that this is not mentioned in the description of API esp_sleep_get_ext1_wakeup_statusWiFive wrote:Since they all have to be low to wake up do you mean the last pin to go low? I don't think that would be stored in any registers.
it mentions that it will return 0 only in case the wakeup source is not DeepSleep. or at least that what I understood.
Thanks
Who is online
Users browsing this forum: No registered users and 37 guests