From ecd67f0a859fc6932b667637c3c6d84b6aca5aad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20G=C3=B6ttgens?= Date: Fri, 24 Feb 2023 09:32:31 +0100 Subject: [PATCH] disable the frequency switcher for the C3 CPU... --- src/sleep.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/sleep.cpp b/src/sleep.cpp index 72d4974a..9bdd52cb 100644 --- a/src/sleep.cpp +++ b/src/sleep.cpp @@ -61,13 +61,15 @@ void setCPUFast(bool on) * all WiFi use cases. * (Added: Dec 23, 2021 by Jm Casler) */ +#ifndef CONFIG_IDF_TARGET_ESP32C3 LOG_DEBUG("Setting CPU to 240mhz because WiFi is in use.\n"); setCpuFrequencyMhz(240); +#endif return; } // The Heltec LORA32 V1 runs at 26 MHz base frequency and doesn't react well to switching to 80 MHz... -#ifndef ARDUINO_HELTEC_WIFI_LORA_32 +#if !defined(ARDUINO_HELTEC_WIFI_LORA_32) && !defined(CONFIG_IDF_TARGET_ESP32C3) setCpuFrequencyMhz(on ? 240 : 80); #endif