debug: test LilyGO firmware in simple AP-only mode
This commit is contained in:
@@ -33,3 +33,6 @@
|
|||||||
|
|
||||||
// LilyGO bring-up isolation: disable BLE/BMS to test WiFi AP stability.
|
// LilyGO bring-up isolation: disable BLE/BMS to test WiFi AP stability.
|
||||||
#define BMS_COMPILE_ENABLED 0
|
#define BMS_COMPILE_ENABLED 0
|
||||||
|
|
||||||
|
// LilyGO S3 WiFi isolation: use AP-only mode, no STA.
|
||||||
|
#define LILYGO_SIMPLE_AP_ONLY_DEBUG 1
|
||||||
|
|||||||
@@ -2067,6 +2067,10 @@ int findNextWifiIndexByPriority(bool tried[]) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void connectStaWifi() {
|
void connectStaWifi() {
|
||||||
|
#if LILYGO_SIMPLE_AP_ONLY_DEBUG
|
||||||
|
Serial.println("STA WiFi disabled for LilyGO AP-only debug.");
|
||||||
|
return;
|
||||||
|
#endif
|
||||||
if (wifiNetworkCount <= 0) {
|
if (wifiNetworkCount <= 0) {
|
||||||
Serial.println("STA WiFi not configured.");
|
Serial.println("STA WiFi not configured.");
|
||||||
return;
|
return;
|
||||||
@@ -4152,7 +4156,13 @@ void setup() {
|
|||||||
loadApConfig();
|
loadApConfig();
|
||||||
heapCheckpoint("after:loadApConfig");
|
heapCheckpoint("after:loadApConfig");
|
||||||
|
|
||||||
|
#if LILYGO_SIMPLE_AP_ONLY_DEBUG
|
||||||
|
WiFi.persistent(false);
|
||||||
|
WiFi.setSleep(false);
|
||||||
|
WiFi.mode(WIFI_AP);
|
||||||
|
#else
|
||||||
WiFi.mode(WIFI_AP_STA);
|
WiFi.mode(WIFI_AP_STA);
|
||||||
|
#endif
|
||||||
startAccessPoint();
|
startAccessPoint();
|
||||||
oledShowSetupPage();
|
oledShowSetupPage();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user