Pārlūkot izejas kodu

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

cube 8 mēnešus atpakaļ
vecāks
revīzija
bf7c954510
1 mainītis faili ar 3 papildinājumiem un 0 dzēšanām
  1. 3
    0
      Seeed Wio Terminal/projects/m5-gps.ino

+ 3
- 0
Seeed Wio Terminal/projects/m5-gps.ino Parādīt failu

40
   pinPeripheral(PIN_WIRE_SCL, PIO_SERCOM_ALT);
40
   pinPeripheral(PIN_WIRE_SCL, PIO_SERCOM_ALT);
41
   pinPeripheral(PIN_WIRE_SCL, PIO_SERCOM_ALT);
41
   pinPeripheral(PIN_WIRE_SCL, PIO_SERCOM_ALT);
42
 
42
 
43
+  tft.drawString("Not using WiFi", 10, 10);
43
   WiFi.begin(ssid, pw);
44
   WiFi.begin(ssid, pw);
44
 }
45
 }
45
  
46
  
103
       if((WiFi.status() == WL_CONNECTED))
104
       if((WiFi.status() == WL_CONNECTED))
104
       {
105
       {
105
         String wifi_text = "Connected to WiFi: " + String(ssid);
106
         String wifi_text = "Connected to WiFi: " + String(ssid);
107
+        tft.fillRect(10, 10, 250, 20, TFT_BLACK);
106
         tft.drawString(wifi_text, 10, 10);
108
         tft.drawString(wifi_text, 10, 10);
107
         api_lookup();
109
         api_lookup();
108
       }
110
       }
132
       String name = doc["name"];
134
       String name = doc["name"];
133
       String state = doc["state"];
135
       String state = doc["state"];
134
       String loc_text = name + ", " + state;
136
       String loc_text = name + ", " + state;
137
+      tft.fillRect(10, 80, 200, 20, TFT_BLACK);
135
       tft.drawString(loc_text, 10, 80);
138
       tft.drawString(loc_text, 10, 80);
136
     }
139
     }
137
   }
140
   }