From 1cf9fbed207e7099301d38ad44bbec76ea6668e2 Mon Sep 17 00:00:00 2001 From: Jin Chen Date: Tue, 30 Jun 2026 19:04:29 +0800 Subject: [PATCH] fix(ble): change min freq in ble power save (cherry picked from commit 958c28c41d87ed7c994ea1731b3c759e1122a482) Co-authored-by: cjin --- examples/bluetooth/nimble/power_save/main/main.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/examples/bluetooth/nimble/power_save/main/main.c b/examples/bluetooth/nimble/power_save/main/main.c index 331db9171e8..1f85cb4bf83 100644 --- a/examples/bluetooth/nimble/power_save/main/main.c +++ b/examples/bluetooth/nimble/power_save/main/main.c @@ -16,6 +16,7 @@ #include "console/console.h" #include "services/gap/ble_svc_gap.h" #include "bleprph.h" +#include "soc/rtc.h" #if CONFIG_EXAMPLE_EXTENDED_ADV static uint8_t ext_adv_pattern_1[] = { @@ -574,7 +575,7 @@ app_main(void) // automatic light sleep is enabled if tickless idle support is enabled. esp_pm_config_t pm_config = { .max_freq_mhz = CONFIG_ESP_DEFAULT_CPU_FREQ_MHZ, - .min_freq_mhz = CONFIG_XTAL_FREQ, + .min_freq_mhz = rtc_clk_xtal_freq_get(), #if CONFIG_FREERTOS_USE_TICKLESS_IDLE .light_sleep_enable = true #endif