gpio_wakeup_disable has no impact, with test case

kuhatovuk
Posts: 21
Joined: Thu Aug 01, 2019 8:46 pm

gpio_wakeup_disable has no impact, with test case

Postby kuhatovuk » Wed Mar 11, 2020 2:56 pm

Hello, any idea why gpio_wakeup_disable has no impact here ? ESP32 (IDF4) keeps on waking up if I put pin 25 to GND.

Code: Select all

void app_main()
{
    gpio_set_pull_mode(GPIO_NUM_25, GPIO_PULLUP_ONLY);
    gpio_set_direction(GPIO_NUM_25, GPIO_MODE_INPUT);
    gpio_wakeup_enable(GPIO_NUM_25, GPIO_INTR_LOW_LEVEL);
    esp_sleep_enable_gpio_wakeup();

    esp_light_sleep_start();

    // Put pin 25 to GND
    ESP_LOGE("Test", "Wakes as expected");

    gpio_wakeup_disable(GPIO_NUM_25); // <---- has no impact

    while(1) {
        esp_light_sleep_start();

        // Put pin 25 to GND
        ESP_LOGE("Test", "Wakes but shouldn't");
    }
}
Thank you!

kuhatovuk
Posts: 21
Joined: Thu Aug 01, 2019 8:46 pm

Re: gpio_wakeup_disable has no impact, with test case

Postby kuhatovuk » Wed Mar 11, 2020 3:40 pm

It's a 4.0 bug where gpio enable calls the RTC function but not disable :

https://github.com/espressif/esp-idf/bl ... pio.c#L470

ESP_houwenxiang
Posts: 118
Joined: Tue Jun 26, 2018 3:09 am

Re: gpio_wakeup_disable has no impact, with test case

Postby ESP_houwenxiang » Tue Mar 17, 2020 5:10 am

Hi, kuhatovuk

Thanks for reporting this issue. We will fix it soon.
wookooho

Who is online

Users browsing this forum: No registered users and 345 guests