Skip to content

Commit 6602cf0

Browse files
committed
AGPS data download should not happen in AP mode #231
Fixes #231
1 parent efb50b3 commit 6602cf0

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

src/configServer.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -616,9 +616,9 @@ bool CreateWifiSoftAP(String chipID) {
616616
IPAddress apIP(172, 20, 0, 1);
617617
IPAddress netMsk(255, 255, 255, 0);
618618

619-
displayTest->showTextOnGrid(0, 2, "AP:");
620-
displayTest->showTextOnGrid(1, 2, "");
621-
displayTest->showTextOnGrid(0, 3, APName.c_str());
619+
displayTest->showTextOnGrid(0, 1, "AP:");
620+
displayTest->showTextOnGrid(1, 1, "");
621+
displayTest->showTextOnGrid(0, 2, APName.c_str());
622622

623623

624624
WiFi.softAPConfig(apIP, apIP, netMsk);
@@ -629,11 +629,11 @@ bool CreateWifiSoftAP(String chipID) {
629629

630630
Serial.println(F("AP successful."));
631631

632-
displayTest->showTextOnGrid(0, 4, "Pass:");
633-
displayTest->showTextOnGrid(1, 4, APPassword);
632+
displayTest->showTextOnGrid(0, 3, "Pass:");
633+
displayTest->showTextOnGrid(1, 3, APPassword);
634634

635-
displayTest->showTextOnGrid(0, 5, "IP:");
636-
displayTest->showTextOnGrid(1, 5, WiFi.softAPIP().toString());
635+
displayTest->showTextOnGrid(0, 4, "IP:");
636+
displayTest->showTextOnGrid(1, 4, WiFi.softAPIP().toString());
637637
} else {
638638
Serial.println(F("Soft AP Error."));
639639
Serial.println(APName.c_str());
@@ -689,7 +689,7 @@ void startServer(ObsConfig *obsConfig) {
689689
voltageMeter = new VoltageMeter();
690690
}
691691

692-
if (SD.begin()) {
692+
if (SD.begin() && WiFiClass::status() == WL_CONNECTED) {
693693
AlpData::update(displayTest);
694694
}
695695

0 commit comments

Comments
 (0)