Hi! this is my first post, I’m trying to get my ESP32S2 Saola kit into Automatic Light Sleep, I used a code in an ESP32 and it get into the ALS without a problem, so I tried to implement that code in the ESP32S2, changing the:
esp_pm_config_esp32s2_t pm_config = {
.max_freq_mhz = 240,
.min_freq_mhz = 80,
#if CONFIG_FREERTOS_USE_TICKLESS_IDLE
.light_sleep_enable = true
#endif
};
ESP_ERROR_CHECK( esp_pm_configure(&pm_config) );
I’ve used this build flags:
[env]
platform = espressif32
framework = espidf
monitor_speed = 115200
[env:esp32-s2-saola-1]
platform = espressif32
board = esp32-s2-saola-1
build_flags =
-D CORE_DEBUG_LEVEL=1
-D CONFIG_ESP32S2_DEFAULT_CPU_FREQ_80
-D CONFIG_PM_ENABLE
-D CONFIG_FREERTOS_USE_TICKLESS_IDLE
-D CONFIG_PM_USE_RTC_TIMER_REF
And the sdk shows this:
#
# Power Management
#
CONFIG_PM_ENABLE=y
CONFIG_PM_DFS_INIT_AUTO=y
# CONFIG_PM_PROFILING is not set
# CONFIG_PM_TRACE is not set
CONFIG_PM_SLP_IRAM_OPT=y
# CONFIG_PM_RTOS_IDLE_OPT is not set
CONFIG_PM_SLP_DISABLE_GPIO=y
# end of Power Management
But it nevers get into Light sleep. Any help will be welcome.