Remove the deep-sleep feature entirely (user decision): power manager, Settings switch, NVS key, sleep bit in the shared header, docs
Firmware / build (push) Successful in 2m58s

This commit is contained in:
2026-09-28 17:20:35 +02:00
parent 6854aa1c46
commit a41800acc2
8 changed files with 7 additions and 168 deletions
+2 -9
View File
@@ -8,7 +8,6 @@
#include <Arduino.h>
#include <lvgl.h>
#include <esp_sleep.h>
#include "modules/display_init.h"
#include "modules/uart_receiver.h"
#include "modules/espnow_receiver.h"
@@ -18,7 +17,6 @@
#include "modules/link_peer.h"
#include "modules/console.h"
#include "modules/ota_update.h"
#include "modules/power_manager.h"
#include "config/ota_config.h"
// FreeRTOS task handles
@@ -44,13 +42,11 @@ void setup() {
Serial.println("\n[BOOT] ESP32-S3-LCD-1.3 starting...");
// A timer-wake probe boot (see PowerManager) must be quick: no serial waits.
bool probe = esp_sleep_get_wakeup_cause() == ESP_SLEEP_WAKEUP_TIMER;
unsigned long start_wait = millis();
while (!probe && !Serial && (millis() - start_wait < 3000)) {
while (!Serial && (millis() - start_wait < 3000)) {
delay(100);
}
if (!probe) delay(500);
delay(500);
Serial.println("[BOOT] Serial communication ready!");
Serial.println("\n\n=================================");
@@ -71,7 +67,6 @@ void setup() {
}
GaugeScreen::init(); // hand-coded screen, built once, loaded
PowerManager::init(); // probe boot? keep the panel dark until the Main CTRL is heard
xTaskCreatePinnedToCore(lvglTask, "LVGL_Task", 8192, NULL, 2, &lvglTaskHandle, 1);
@@ -88,7 +83,6 @@ void setup() {
Ota::init(); // version + slot; hooks A's OTA commands
Console::addHandler(LinkPeer::handleCommand);
Console::addHandler(Ota::handleCommand);
Console::addHandler(PowerManager::handleCommand);
Serial.println("\n[UART] Initializing link receiver...");
if (!UARTReceiver::init()) {
@@ -119,7 +113,6 @@ void loop() {
// STATUS to A, PAIR/SECURE frames from A, serial console
LinkPeer::tick();
Ota::tick(); // runs a queued check/install (blocks the loop while it does)
PowerManager::tick(); // deep sleep when the Main CTRL has been silent for a minute
Console::tick();
// Apply a new CONFIG from A. Overrides are a bench tool: applied but not