added black boxes for the connection and location strings when they update

This commit is contained in:
2025-03-24 22:49:02 +00:00
parent 1939bef402
commit bf7c954510

View File

@@ -40,6 +40,7 @@ void setup()
pinPeripheral(PIN_WIRE_SCL, PIO_SERCOM_ALT);
pinPeripheral(PIN_WIRE_SCL, PIO_SERCOM_ALT);
tft.drawString("Not using WiFi", 10, 10);
WiFi.begin(ssid, pw);
}
@@ -103,6 +104,7 @@ void displayInfo()
if((WiFi.status() == WL_CONNECTED))
{
String wifi_text = "Connected to WiFi: " + String(ssid);
tft.fillRect(10, 10, 250, 20, TFT_BLACK);
tft.drawString(wifi_text, 10, 10);
api_lookup();
}
@@ -132,6 +134,7 @@ void api_lookup()
String name = doc["name"];
String state = doc["state"];
String loc_text = name + ", " + state;
tft.fillRect(10, 80, 200, 20, TFT_BLACK);
tft.drawString(loc_text, 10, 80);
}
}