mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 11:10:54 +03:00
change(soc): move _RTC_GPIO_EDGE_WAKEUP_SUPPORTED to soc_caps.h
This commit is contained in:
@@ -16,9 +16,6 @@
|
||||
#include "hal/rtc_io_hal.h"
|
||||
#include "hal/rtc_io_periph.h"
|
||||
#include "soc/soc_caps.h"
|
||||
#if SOC_RTCIO_PIN_COUNT > 0
|
||||
#include "hal/rtc_gpio_caps.h"
|
||||
#endif
|
||||
#if SOC_LP_GPIO_MATRIX_SUPPORTED
|
||||
#include "soc/lp_gpio_pins.h"
|
||||
#endif
|
||||
@@ -320,11 +317,11 @@ esp_err_t rtc_gpio_isolate(gpio_num_t gpio_num)
|
||||
esp_err_t rtc_gpio_wakeup_enable(gpio_num_t gpio_num, gpio_int_type_t intr_type)
|
||||
{
|
||||
ESP_RETURN_ON_FALSE(rtc_gpio_is_valid_gpio(gpio_num), ESP_ERR_INVALID_ARG, RTCIO_TAG, "RTCIO number error");
|
||||
#if !RTC_GPIO_CAPS_GET(EDGE_WAKEUP_SUPPORTED)
|
||||
#if !SOC_RTC_GPIO_EDGE_WAKEUP_SUPPORTED
|
||||
if (intr_type == GPIO_INTR_POSEDGE || intr_type == GPIO_INTR_NEGEDGE || intr_type == GPIO_INTR_ANYEDGE) {
|
||||
return ESP_ERR_INVALID_ARG; // Dont support this mode.
|
||||
}
|
||||
#endif //!RTC_GPIO_CAPS_GET(EDGE_WAKEUP_SUPPORTED)
|
||||
#endif //!SOC_RTC_GPIO_EDGE_WAKEUP_SUPPORTED
|
||||
RTCIO_ENTER_CRITICAL();
|
||||
rtcio_hal_wakeup_enable(rtc_io_number_get(gpio_num), intr_type);
|
||||
RTCIO_EXIT_CRITICAL();
|
||||
|
||||
Reference in New Issue
Block a user