Architecture specific RTT functions for ESP32. More...
Architecture specific RTT functions for ESP32.
The RTT peripheral driver implements a 32-bit RTT counter with a frequency of 32.768 kHz. It uses either
For this purpose, a hardware abstraction layer is defined by a driver interface of the type rtt_hw_driver_t, which generally provides a 48-bit RTC counter with a frequency of 32.678 kHz. This way the RTT implementation always sees a 48-bit counter with a frequency of 32.768 kHz regardless of which hardware implementation is actually used.
esp_rtc_timer_32 is enabled by the board definition and the 32.768 kHz crystal is actually connected, the 48-bit RTC counter is used. Otherwise, the 64 bit microsecond system timer is used.
Since the 64-bit microsecond system timer does not work during light/deep or during a reboot, the status of the 64-bit microsecond system timer is saved in RTC memory before entering a sleep mode or reboot. When leaving the sleep mode or after a reboot, it will be updated from the RTC counter.
Definition in file rtt_arch.h.
|RTT hardware abstraction layer driver. More...|
|#define||RTT_HW_COUNTER_MAX ((1ULL << 48) - 1)|
|Maximum value of the 48-bit RTT hardware counter. More...|
|uint64_t||rtt_pm_sleep_enter (unsigned mode)|
|Called before the power management enters a light or deep sleep mode. More...|
|void||rtt_pm_sleep_exit (uint32_t cause)|
|Called after the power management left light sleep mode. More...|
|#define RTT_HW_COUNTER_MAX ((1ULL << 48) - 1)|
Called before the power management enters a light or deep sleep mode.
|mode||sleep mode that is entered|
Called after the power management left light sleep mode.