Created
December 12, 2022 01:41
-
-
Save reefwing/5d73a24f0b5c0ca8b2c6e10fd6c0360f to your computer and use it in GitHub Desktop.
TWatch-2020 Charge Icon Example
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| int chargeOffset = map(batSOC, 0, 100, 0, 17); | |
| // Draw Battery Charged Icon | |
| ttgo->tft->fillRect(150, 0, 20, 10, TFT_GREEN); | |
| ttgo->tft->fillRect(146, 3, 4, 4, TFT_GREEN); | |
| ttgo->tft->fillRect(152, 2, 16 - chargeOffset, 6, TFT_BLACK); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment