| 59 | } |
| 60 | |
| 61 | void drawTime() { |
| 62 | tft.drawPixel(0, 0, 0); |
| 63 | tft.fillRect(80, 0, display_w, canvas_top_h - 3, bruceConfig.bgColor); |
| 64 | tft.setTextDatum(TR_DATUM); |
| 65 | unsigned long ellapsed = millis() / 1000; |
| 66 | int8_t h = ellapsed / 3600; |
| 67 | int sr = ellapsed % 3600; |
| 68 | int8_t m = sr / 60; |
| 69 | int8_t s = sr % 60; |
| 70 | char right_str[50] = "UPS 0% UP 00:00:00"; |
| 71 | sprintf(right_str, "UPS %i%% UP %02d:%02d:%02d", getBattery(), h, m, s); |
| 72 | tft.drawString(right_str, display_w, 3); |
| 73 | } |
| 74 | |
| 75 | void drawFooterData(uint8_t friends_run, uint8_t friends_tot, String last_friend_name, signed int rssi) { |
| 76 | tft.drawPixel(0, 0, 0); |
no test coverage detected