mirror of
https://github.com/espressif/esp-idf.git
synced 2025-09-25 01:37:22 +00:00
Merge branch 'docs/rewrite_all_low_to_any_low_when_not_esp32' into 'master'
Docs: rewrite_all_low_to_any_low_when_not_esp32 See merge request espressif/esp-idf!24997
This commit is contained in:
@@ -84,7 +84,7 @@ RTC peripherals or RTC memories don't need to be powered on during sleep in this
|
||||
|
||||
:cpp:func:`esp_sleep_enable_touchpad_wakeup` function can be used to enable this wakeup source.
|
||||
|
||||
.. only:: SOC_PM_SUPPORT_EXT0_WAKEUP or SOC_PM_SUPPORT_EXT1_WAKEUP
|
||||
.. only:: SOC_PM_SUPPORT_EXT0_WAKEUP
|
||||
|
||||
External Wakeup (ext0)
|
||||
^^^^^^^^^^^^^^^^^^^^^^
|
||||
@@ -101,20 +101,39 @@ RTC peripherals or RTC memories don't need to be powered on during sleep in this
|
||||
|
||||
.. warning:: After waking up from sleep, the IO pad used for wakeup will be configured as RTC IO. Therefore, before using this pad as digital GPIO, users need to reconfigure it using :cpp:func:`rtc_gpio_deinit` function.
|
||||
|
||||
.. only:: SOC_PM_SUPPORT_EXT1_WAKEUP
|
||||
|
||||
External Wakeup (ext1)
|
||||
^^^^^^^^^^^^^^^^^^^^^^
|
||||
|
||||
The RTC controller contains the logic to trigger wakeup using multiple RTC GPIOs. One of the following two logic functions can be used to trigger wakeup:
|
||||
|
||||
.. only:: esp32
|
||||
|
||||
- wake up if any of the selected pins is high (``ESP_EXT1_WAKEUP_ANY_HIGH``)
|
||||
- wake up if all the selected pins are low (``ESP_EXT1_WAKEUP_ALL_LOW``)
|
||||
|
||||
This wakeup source is implemented by the RTC controller. As such, RTC peripherals and RTC memories can be powered down in this mode. However, if RTC peripherals are powered down, internal pullup and pulldown resistors will be disabled. To use internal pullup or pulldown resistors, request the RTC peripherals power domain to be kept on during sleep, and configure pullup/pulldown resistors using ``rtc_gpio_`` functions before entering sleep::
|
||||
.. only:: esp32s2 or esp32s3 or esp32c6 or esp32h2
|
||||
|
||||
- wake up if any of the selected pins is high (``ESP_EXT1_WAKEUP_ANY_HIGH``)
|
||||
- wake up if any of the selected pins is low (``ESP_EXT1_WAKEUP_ANY_LOW``)
|
||||
|
||||
This wakeup source is implemented by the RTC controller. As such, RTC peripherals and RTC memories can be powered down in this mode. However, if RTC peripherals are powered down, internal pullup and pulldown resistors will be disabled if we don't use the HOLD feature. To use internal pullup or pulldown resistors, request the RTC peripherals power domain to be kept on during sleep, and configure pullup/pulldown resistors using ``rtc_gpio_`` functions before entering sleep::
|
||||
|
||||
esp_sleep_pd_config(ESP_PD_DOMAIN_RTC_PERIPH, ESP_PD_OPTION_ON);
|
||||
rtc_gpio_pullup_dis(gpio_num);
|
||||
rtc_gpio_pulldown_en(gpio_num);
|
||||
|
||||
If we turn off the ``RTC_PERIPH`` domain, we will use the HOLD feature to maintain the pull-up and pull-down on the pins during sleep. HOLD feature will be acted on the pin internally before the system entering sleep, and this can further reduce power consumption::
|
||||
|
||||
rtc_gpio_pullup_dis(gpio_num);
|
||||
rtc_gpio_pulldown_en(gpio_num);
|
||||
|
||||
If certain chips lack the ``RTC_PERIPH`` domain, we can only use the HOLD feature to maintain the pull-up and pull-down on the pins during sleep::
|
||||
|
||||
gpio_pullup_dis(gpio_num);
|
||||
gpio_pulldown_en(gpio_num);
|
||||
|
||||
.. warning::
|
||||
- To use the EXT1 wakeup, the IO pad(s) are configured as RTC IO. Therefore, before using these pads as digital GPIOs, users need to reconfigure them by calling the :cpp:func:`rtc_gpio_deinit` function.
|
||||
|
||||
|
Reference in New Issue
Block a user