dd0970ed7c
Three bugs fixed: - NVS img_id now written before epd_init/draw; new draw_needed flag in NVS survives power-loss mid-refresh so next boot re-draws from LittleFS instead of showing stale content - epd_sleep() now only called when display was initialized this cycle, preventing a 60 s wait_busy() timeout on every 304 poll - esp_task_wdt_reset() added to wait_busy() loop so the ~20 s 6-color refresh no longer triggers the task watchdog Also extracts normal_operation into operation.h template and adds a native PlatformIO test suite (16 tests) covering the full response matrix. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
19 lines
511 B
C
19 lines
511 B
C
#pragma once
|
|
#include "Arduino.h"
|
|
#define WIFI_STA 0
|
|
#define WIFI_AP 1
|
|
#define WL_CONNECTED 3
|
|
|
|
extern int g_wifi_status;
|
|
|
|
struct WiFiClass {
|
|
String macAddress() { return String("1C:C3:AB:D1:91:F8"); }
|
|
int status() { return g_wifi_status; }
|
|
void mode(int) {}
|
|
void begin(const char*, const char*) {}
|
|
void disconnect(bool) {}
|
|
bool softAP(const char*) { return true; }
|
|
String softAPIP() { return String("192.168.4.1"); }
|
|
String localIP() { return String("192.168.1.100"); }
|
|
} WiFi;
|