C
release: publish version 1.7.3
YU CHIH CHANG000aee10705f
diff --git a/VERSION b/VERSIONindex f8a696c..661e7ae 100644--- a/VERSION+++ b/VERSION@@ -1 +1 @@-1.7.2+1.7.3diff --git a/include/version.h b/include/version.hindex 1b581d3..bb4e3fb 100644--- a/include/version.h+++ b/include/version.h@@ -1,3 +1,3 @@#pragma once-inline constexpr char GT7_DASH_VERSION[] = "1.7.2";+inline constexpr char GT7_DASH_VERSION[] = "1.7.3";diff --git a/installer/firmware/firmware-ili9341.bin b/installer/firmware/firmware-ili9341.binindex 000e2fa..307d64d 100644Binary files a/installer/firmware/firmware-ili9341.bin and b/installer/firmware/firmware-ili9341.bin differdiff --git a/installer/firmware/firmware-st7789.bin b/installer/firmware/firmware-st7789.binindex faa0357..f5285b2 100644Binary files a/installer/firmware/firmware-st7789.bin and b/installer/firmware/firmware-st7789.bin differdiff --git a/installer/manifest-st7789.json b/installer/manifest-st7789.jsonindex cba49e5..08b4238 100644--- a/installer/manifest-st7789.json+++ b/installer/manifest-st7789.json@@ -1,6 +1,6 @@{"name": "ESP32 GT7 Dashboard (ST7789)",- "version": "1.7.2",+ "version": "1.7.3","new_install_prompt_erase": true,"builds": [{diff --git a/installer/manifest.json b/installer/manifest.jsonindex 42a4eb0..15dde49 100644--- a/installer/manifest.json+++ b/installer/manifest.json@@ -1,6 +1,6 @@{"name": "ESP32 GT7 Dashboard (ILI9341)",- "version": "1.7.2",+ "version": "1.7.3","new_install_prompt_erase": true,"builds": [{diff --git a/installer/release-notes.json b/installer/release-notes.jsonindex 0017af1..71d4572 100644--- a/installer/release-notes.json+++ b/installer/release-notes.json@@ -1,4 +1,9 @@{+ "1.7.3": [+ "Improved Pocket fuel-level updates to reduce flicker and extracted reusable fuel, ABS and TCS dashboard icons.",+ "Kept Pocket ABS and TCS indicators stable while distinguishing inactive and active telemetry states.",+ "Refined fuel-pump icon placement in the GT3 and Mono themes."+ ],"1.7.2": ["Added an idle-screen Touch Setup flow that detects and saves 0, 90, 180 or 270 degree touch orientation corrections.","Added double-tap entry, verification and dual-orientation Cancel handling so accidental or incorrect calibration remains recoverable.",diff --git a/installer/releases.json b/installer/releases.jsonindex 6827a6b..70fa246 100644--- a/installer/releases.json+++ b/installer/releases.json@@ -1,15 +1,15 @@{"versions": [{- "version": "1.7.2",+ "version": "1.7.3","notes": [- "Added an idle-screen Touch Setup flow that detects and saves 0, 90, 180 or 270 degree touch orientation corrections.",- "Added double-tap entry, verification and dual-orientation Cancel handling so accidental or incorrect calibration remains recoverable.",- "Touch Setup now exits immediately when GT7 telemetry resumes and never blocks heartbeat, UDP or dashboard rendering."+ "Improved Pocket fuel-level updates to reduce flicker and extracted reusable fuel, ABS and TCS dashboard icons.",+ "Kept Pocket ABS and TCS indicators stable while distinguishing inactive and active telemetry states.",+ "Refined fuel-pump icon placement in the GT3 and Mono themes."],"manifests": {- "ili9341": "versions/1.7.2/manifest-ili9341.json",- "st7789": "versions/1.7.2/manifest-st7789.json"+ "ili9341": "versions/1.7.3/manifest-ili9341.json",+ "st7789": "versions/1.7.3/manifest-st7789.json"}},{diff --git a/installer/versions/1.7.2/boot_app0.bin b/installer/versions/1.7.3/boot_app0.binsimilarity index 100%rename from installer/versions/1.7.2/boot_app0.binrename to installer/versions/1.7.3/boot_app0.bindiff --git a/installer/versions/1.7.2/bootloader.bin b/installer/versions/1.7.3/bootloader.binsimilarity index 100%rename from installer/versions/1.7.2/bootloader.binrename to installer/versions/1.7.3/bootloader.bindiff --git a/installer/versions/1.7.2/firmware-ili9341.bin b/installer/versions/1.7.3/firmware-ili9341.binsimilarity index 65%rename from installer/versions/1.7.2/firmware-ili9341.binrename to installer/versions/1.7.3/firmware-ili9341.binindex 000e2fa..307d64d 100644Binary files a/installer/versions/1.7.2/firmware-ili9341.bin and b/installer/versions/1.7.3/firmware-ili9341.bin differdiff --git a/installer/versions/1.7.2/firmware-st7789.bin b/installer/versions/1.7.3/firmware-st7789.binsimilarity index 65%rename from installer/versions/1.7.2/firmware-st7789.binrename to installer/versions/1.7.3/firmware-st7789.binindex faa0357..f5285b2 100644Binary files a/installer/versions/1.7.2/firmware-st7789.bin and b/installer/versions/1.7.3/firmware-st7789.bin differdiff --git a/installer/versions/1.7.2/manifest-ili9341.json b/installer/versions/1.7.3/manifest-ili9341.jsonsimilarity index 95%rename from installer/versions/1.7.2/manifest-ili9341.jsonrename to installer/versions/1.7.3/manifest-ili9341.jsonindex 392daab..4193cd8 100644--- a/installer/versions/1.7.2/manifest-ili9341.json+++ b/installer/versions/1.7.3/manifest-ili9341.json@@ -1,6 +1,6 @@{"name": "ESP32 GT7 Dashboard (ILI9341)",- "version": "1.7.2",+ "version": "1.7.3","new_install_prompt_erase": true,"builds": [{diff --git a/installer/versions/1.7.2/manifest-st7789.json b/installer/versions/1.7.3/manifest-st7789.jsonsimilarity index 95%rename from installer/versions/1.7.2/manifest-st7789.jsonrename to installer/versions/1.7.3/manifest-st7789.jsonindex 351d519..55af9cb 100644--- a/installer/versions/1.7.2/manifest-st7789.json+++ b/installer/versions/1.7.3/manifest-st7789.json@@ -1,6 +1,6 @@{"name": "ESP32 GT7 Dashboard (ST7789)",- "version": "1.7.2",+ "version": "1.7.3","new_install_prompt_erase": true,"builds": [{diff --git a/installer/versions/1.7.2/partitions.bin b/installer/versions/1.7.3/partitions.binsimilarity index 100%rename from installer/versions/1.7.2/partitions.binrename to installer/versions/1.7.3/partitions.bindiff --git a/src/SHCustomProtocol.h b/src/SHCustomProtocol.hindex 436e90a..f182a59 100644--- a/src/SHCustomProtocol.h+++ b/src/SHCustomProtocol.h@@ -1269,6 +1269,8 @@ public:created = false;}+#include "dashboard/DashboardIcons.inc"+#include "dashboard/themes/RetroTheme.inc"#include "dashboard/themes/RadarTheme.inc"diff --git a/src/dashboard/DashboardIcons.inc b/src/dashboard/DashboardIcons.incnew file mode 100644index 0000000..cce6f0a--- /dev/null+++ b/src/dashboard/DashboardIcons.inc@@ -0,0 +1,96 @@+ void drawDashboardFuelPumpIcon(int x, int y, int fuelPercent,+ uint16_t fullColor, uint16_t emptyColor, uint16_t background)+ {+ constexpr int height = 24;+ const int darkRows = (constrain(fuelPercent, 0, 100) * height + 50) / 100;+ const int liquidTop = height - darkRows;+ for (int row = 0; row < height; ++row)+ {+ const uint16_t color = row >= liquidTop ? fullColor : emptyColor;+ if (row <= 20) tft.drawFastHLine(x, y + row, 13, color);+ if (row >= 21) tft.drawFastHLine(x - 3, y + row, 19, color);+ if (row >= 1 && row <= 5)+ {+ const int nozzleX = x + 13 + (row - 1);+ tft.drawFastHLine(nozzleX + (row == 1 ? 1 : 0), y + row,+ row == 1 ? 2 : 3, color);+ }+ if (row >= 6 && row <= 20)+ tft.drawFastHLine(x + 16, y + row, 2, color);+ if (row >= 6 && row <= 13)+ tft.drawFastHLine(x + 17, y + row, 3, color);+ }+ // The pump window remains transparent at every fuel level.+ tft.fillRect(x + 3, y + 3, 7, 6, background);+ }++ void drawDashboardAbsIcon(int centerX, int centerY, bool active,+ uint16_t activeColor, uint16_t inactiveColor, uint16_t background)+ {+ const uint16_t color = active ? activeColor : inactiveColor;+ if (active)+ tft.fillCircle(centerX, centerY, 11, color);+ else+ {+ tft.drawCircle(centerX, centerY, 11, color);+ tft.drawCircle(centerX, centerY, 10, color);+ }+ for (int angle = 132; angle <= 228; angle += 3)+ {+ const float radians = angle * DEG_TO_RAD;+ const int arcX = centerX + lroundf(cosf(radians) * 14.0f);+ const int arcY = centerY + lroundf(sinf(radians) * 14.0f);+ tft.drawPixel(arcX, arcY, color);+ tft.drawPixel(arcX - 1, arcY, color);+ }+ for (int angle = -48; angle <= 48; angle += 3)+ {+ const float radians = angle * DEG_TO_RAD;+ const int arcX = centerX + lroundf(cosf(radians) * 14.0f);+ const int arcY = centerY + lroundf(sinf(radians) * 14.0f);+ tft.drawPixel(arcX, arcY, color);+ tft.drawPixel(arcX + 1, arcY, color);+ }+ tft.setTextColor(active ? background : color,+ active ? color : background);+ tft.setTextDatum(TL_DATUM);+ constexpr int textWidth = 18;+ constexpr int textHeight = 8;+ tft.drawString("ABS", centerX + 1 - textWidth / 2,+ centerY + 1 - textHeight / 2, 1);+ }++ void drawDashboardTcsIcon(int x, int y, uint16_t color,+ uint16_t background)+ {+ // Rear-view car: symmetric trapezoid roof with an inset rear window.+ tft.fillTriangle(x + 5, y, x + 15, y, x, y + 8, color);+ tft.fillTriangle(x + 16, y, x + 21, y + 8, x, y + 8, color);+ tft.fillTriangle(x + 6, y + 2, x + 14, y + 2, x + 3, y + 7,+ background);+ tft.fillTriangle(x + 15, y + 2, x + 18, y + 7, x + 3, y + 7,+ background);++ tft.fillRect(x, y + 8, 22, 10, color);+ tft.fillRect(x + 3, y + 10, 4, 3, background);+ tft.fillRect(x + 15, y + 10, 4, 3, background);+ tft.fillRect(x + 2, y + 18, 5, 3, color);+ tft.fillRect(x + 15, y + 18, 5, 3, color);++ static constexpr int8_t skid[][2] = {+ {3, 0}, {4, 1}, {3, 2}, {1, 3}, {-1, 4},+ {-2, 5}, {-1, 6}, {1, 7}, {4, 7}};+ for (int trail = 0; trail < 2; ++trail)+ {+ const int originX = x + 1 + trail * 13;+ for (size_t i = 0; i < sizeof(skid) / sizeof(skid[0]); ++i)+ {+ const int pointX = originX + skid[i][0];+ const int pointY = y + 21 + skid[i][1];+ tft.fillCircle(pointX, pointY, 1, color);+ if (i > 0)+ tft.drawLine(originX + skid[i - 1][0],+ y + 21 + skid[i - 1][1], pointX, pointY, color);+ }+ }+ }diff --git a/src/dashboard/themes/GT3Theme.inc b/src/dashboard/themes/GT3Theme.incindex 576ed3f..b38f60a 100644--- a/src/dashboard/themes/GT3Theme.inc+++ b/src/dashboard/themes/GT3Theme.inc@@ -403,9 +403,9 @@if (!forceUpdate && prevData[id] == state) return;tft.fillRect(x, y, width, height, TFT_BLACK);- const int32_t pumpX = x + 2;+ const int32_t pumpX = x + 4;const int32_t pumpHeight = 18;- const int32_t pumpY = y + (height - pumpHeight) / 2 - 1;+ const int32_t pumpY = y + (height - pumpHeight) / 2 - 2;// Allocation-free monochrome fuel pump: body, window, base and hose.tft.drawRect(pumpX, pumpY, 8, 13, color);diff --git a/src/dashboard/themes/MonoTheme.inc b/src/dashboard/themes/MonoTheme.incindex 3aa0f9b..ef2f5cc 100644--- a/src/dashboard/themes/MonoTheme.inc+++ b/src/dashboard/themes/MonoTheme.inc@@ -365,11 +365,11 @@tft.drawString("LAST", 225, 145, 1);// Balanced status row: driving aids, centred fuel gauge, fuel and REM.- tft.drawRect(110, 197, 9, 13, muted);- tft.drawRect(112, 199, 5, 4, muted);- tft.drawFastHLine(109, 212, 12, muted);- tft.drawFastVLine(120, 201, 8, muted);- tft.drawLine(118, 199, 121, 202, muted);+ tft.drawRect(110, 196, 9, 13, muted);+ tft.drawRect(112, 198, 5, 4, muted);+ tft.drawFastHLine(109, 211, 12, muted);+ tft.drawFastVLine(120, 200, 8, muted);+ tft.drawLine(118, 198, 121, 201, muted);tft.setTextDatum(ML_DATUM);tft.drawString("ABS", 6, 203, 1);tft.drawString("TCS", 51, 203, 1);diff --git a/src/dashboard/themes/PocketTheme.inc b/src/dashboard/themes/PocketTheme.incindex dafa59c..7ed59c8 100644--- a/src/dashboard/themes/PocketTheme.inc+++ b/src/dashboard/themes/PocketTheme.inc@@ -203,6 +203,8 @@void drawPocketFuelAids(const DashboardState &state, bool forceUpdate){+ const bool absOn = isActiveValue(state.absActive);+ const bool tcsOn = isActiveValue(state.tcActive);const bool fuelChanged = forceUpdate ||prevData["pocketFuel"] != state.brakeBias;const bool absChanged = forceUpdate ||@@ -219,7 +221,10 @@const bool validFuel = state.brakeBias != "--" && state.brakeBias.length();if (fuelChanged){- tft.fillRect(176, 165, 44, 60, pale);+ if (forceUpdate)+ tft.fillRect(176, 165, 44, 60, pale);+ else+ tft.fillRect(176, 165, 44, 18, pale);tft.setTextSize(1.0f);tft.drawString(validFuel ? state.brakeBias + "%" : "--", 198, 174, 2);// The pump doubles as a coarse pixel fuel gauge. Its color boundary@@ -228,113 +233,39 @@const int fuelPercent = validFuel? constrain(state.brakeBias.toInt(), 0, 100): 100;- constexpr int pumpTop = 184;- constexpr int pumpBottom = 207;- constexpr int pumpHeight = pumpBottom - pumpTop + 1;- const int darkRows = (fuelPercent * pumpHeight + 50) / 100;- const int liquidTop = pumpBottom - darkRows + 1;- for (int y = pumpTop; y <= pumpBottom; ++y)- {- const uint16_t rowColor = y >= liquidTop ? darkest : light;- if (y <= 204) tft.drawFastHLine(191, y, 13, rowColor);- if (y >= 205) tft.drawFastHLine(188, y, 19, rowColor);- // Three-pixel diagonal nozzle flowing into a slim vertical hose.- if (y >= 185 && y <= 189)- {- const int nozzleX = 204 + (y - 185);- tft.drawFastHLine(nozzleX + (y == 185 ? 1 : 0), y,- y == 185 ? 2 : 3, rowColor);- }- if (y >= 190 && y <= 204)- tft.drawFastHLine(207, y, 2, rowColor);- if (y >= 190 && y <= 197)- tft.drawFastHLine(208, y, 3, rowColor);- }- // Keep the pump window cut out regardless of the displayed level.- tft.fillRect(194, 187, 7, 6, pale);- tft.drawString("FUEL", 198, 220, 1);+ drawDashboardFuelPumpIcon(191, 184, fuelPercent,+ darkest, light, pale);+ if (forceUpdate)+ tft.drawString("FUEL", 198, 220, 1);}- const bool absOn = isActiveValue(state.absActive);- const bool tcsOn = isActiveValue(state.tcActive);// Match the RPM bar: inactive is pale, active is the solid dark tone.- const uint16_t absColor = absOn ? darkest : light;const uint16_t tcsColor = tcsOn ? darkest : light;if (absChanged){- tft.fillRect(222, 165, 44, 60, pale);- // Compact circular ABS badge: active state is solid with reversed lettering.- if (absOn)- tft.fillCircle(244, 194, 11, absColor);+ if (forceUpdate)+ tft.fillRect(222, 165, 44, 60, pale);else- {- tft.drawCircle(244, 194, 11, absColor);- tft.drawCircle(244, 194, 10, absColor);- }- for (int angle = 132; angle <= 228; angle += 3)- {- const float radians = angle * DEG_TO_RAD;- const int arcX = 244 + lroundf(cosf(radians) * 14.0f);- const int arcY = 194 + lroundf(sinf(radians) * 14.0f);- tft.drawPixel(arcX, arcY, absColor);- tft.drawPixel(arcX - 1, arcY, absColor);- }- for (int angle = -48; angle <= 48; angle += 3)- {- const float radians = angle * DEG_TO_RAD;- const int arcX = 244 + lroundf(cosf(radians) * 14.0f);- const int arcY = 194 + lroundf(sinf(radians) * 14.0f);- tft.drawPixel(arcX, arcY, absColor);- tft.drawPixel(arcX + 1, arcY, absColor);- }- tft.setTextColor(absOn ? pale : absColor, absOn ? absColor : pale);- tft.setTextDatum(TL_DATUM);- static constexpr int absTextWidth = 18;- static constexpr int absTextHeight = 8;- tft.drawString("ABS", 245 - absTextWidth / 2,- 195 - absTextHeight / 2, 1);+ tft.fillRect(228, 179, 33, 31, pale);+ drawDashboardAbsIcon(244, 194, absOn,+ darkest, light, pale);tft.setTextDatum(MC_DATUM);tft.setTextColor(darkest, pale);- tft.drawString("ABS", 244, 220, 1);+ if (forceUpdate)+ tft.drawString("ABS", 244, 220, 1);}if (tcsChanged){- tft.fillRect(268, 165, 38, 60, pale);+ if (forceUpdate)+ tft.fillRect(268, 165, 38, 60, pale);+ else+ tft.fillRect(278, 180, 25, 31, pale);tft.setTextColor(darkest, pale);- // Chunky rear-view slipping-car glyph, drawn for this 42 px status cell.- // Crisp symmetrical trapezoid roof; the inset trapezoid is the rear window.- tft.fillTriangle(284, 181, 294, 181, 279, 189, tcsColor);- tft.fillTriangle(295, 181, 300, 189, 279, 189, tcsColor);- tft.fillTriangle(285, 183, 293, 183, 282, 188, pale);- tft.fillTriangle(294, 183, 297, 188, 282, 188, pale);-- // Solid rear body with two square, background-colour lamps.- tft.fillRect(279, 189, 22, 10, tcsColor);- tft.fillRect(282, 191, 4, 3, pale);- tft.fillRect(294, 191, 4, 3, pale);- tft.fillRect(281, 199, 5, 3, tcsColor);- tft.fillRect(294, 199, 5, 3, tcsColor);-- // Rounded pixel S trails: more intermediate points remove sharp elbows.- static constexpr int8_t SKID[][2] = {- {3, 0}, {4, 1}, {3, 2}, {1, 3}, {-1, 4},- {-2, 5}, {-1, 6}, {1, 7}, {4, 7}};- for (int trail = 0; trail < 2; ++trail)- {- const int originX = 280 + trail * 13;- for (size_t i = 0; i < sizeof(SKID) / sizeof(SKID[0]); ++i)- {- const int x = originX + SKID[i][0];- const int y = 202 + SKID[i][1];- tft.fillCircle(x, y, 1, tcsColor);- if (i > 0)- tft.drawLine(originX + SKID[i - 1][0], 202 + SKID[i - 1][1],- x, y, tcsColor);- }- }- tft.drawString("TCS", 290, 220, 1);+ drawDashboardTcsIcon(279, 181, tcsColor, pale);+ if (forceUpdate)+ tft.drawString("TCS", 290, 220, 1);}// Three equal status columns.