Car status dashboard: ROTA + POTA-to-validate + session-fallback rows - #730
Car status dashboard: ROTA + POTA-to-validate + session-fallback rows#730patrickrb wants to merge 2 commits into
Conversation
Extends the Android Auto status screen with the activation dashboard from
the CarPlay design exploration (Pane layout). Adds, beside the existing
POTA line:
- a ROTA (Roads On The Air) row — "ROTA <trip> · N QSOs" with mileage
- a POTA "N more to validate the activation" / "Activation validated"
secondary (POTA's 10-QSO program rule; no existing constant)
- a "N decodes last cycle" secondary on the band row
- a session-summary row ("Session · N QSOs" / "Last logged …") that takes
the slot when no POTA/ROTA activation is running — the design's
"activation rows drop out, session stats take the slot" behavior
The decision/format logic lives in pure, Android-free helpers in
CarQsoStatus.kt (buildCarActivationRows, potaValidateSpec, buildCarSessionRow,
formatMiles, minutesAgo, carDecodesSecondary), unit-tested in CarDashboardTest.
QsoStatusScreen maps the app singletons (PotaSessionManager, RotaTripManager,
GeneralVariables, FT8TransmitSignal) into those helpers.
Both render paths use the same builder: the PaneTemplate fallback (older
hosts) and the map Surface overlay (modern hosts) — CarSurfaceState.potaText
is generalized to activationLines so ROTA/session show on real devices too.
buildCarQsoStatus is left untouched, so the shared status/slot/band logic and
its tests are unaffected.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## dev #730 +/- ##
============================================
+ Coverage 35.89% 35.93% +0.03%
Complexity 289 289
============================================
Files 248 248
Lines 30512 30565 +53
Branches 4031 4046 +15
============================================
+ Hits 10952 10983 +31
- Misses 19208 19229 +21
- Partials 352 353 +1
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Pull request overview
Adds a pane-layout “activation dashboard” to the Android Auto/Car status UI so that POTA/ROTA activation rows appear while activating and collapse into a session-summary row when idle, and mirrors those activation lines onto the map surface overlay.
Changes:
- Introduces pure helper functions for activation/session row selection and formatting (POTA “to validate”, ROTA miles, session “last logged”, decode-count secondary), plus unit tests.
- Updates
QsoStatusScreento build activation/session rows (POTA + ROTA + session fallback) and to render them both in the PaneTemplate path and the Surface overlay. - Adds new string resources for the new dashboard rows.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 1 comment.
Show a summary per file
| File | Description |
|---|---|
| ft8af/app/src/test/kotlin/radio/ks3ckc/ft8af/car/CarDashboardTest.kt | New unit tests covering the pure dashboard helpers (activation/session selection + formatting). |
| ft8af/app/src/main/res/values/strings_compose.xml | Adds string resources for POTA validation, ROTA row/miles, session fallback, and decode-count secondary. |
| ft8af/app/src/main/kotlin/radio/ks3ckc/ft8af/car/QsoStatusScreen.kt | Wires new dashboard helpers into the pane rows and the surface overlay; adds decode-count secondary under band line. |
| ft8af/app/src/main/kotlin/radio/ks3ckc/ft8af/car/CarSurfaceState.kt | Generalizes surface overlay status from a single POTA line to a list of activation/session lines. |
| ft8af/app/src/main/kotlin/radio/ks3ckc/ft8af/car/CarQsoStatus.kt | Adds pure helpers: activation/session row builders, POTA validation spec, miles/minutes formatting, decode-count secondary. |
| ft8af/app/src/main/kotlin/radio/ks3ckc/ft8af/car/CarMapSurfaceRenderer.kt | Renders the new activationLines list on the surface overlay instead of only POTA text. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
carDecodesSecondary read mutableFt8MessageList.size, which accumulates across cycles when clearDecodesEveryCycle is off (the default) — the "N decodes last cycle" secondary would show a stale, growing count. Use vm.currentMessages (the per-cycle label overlay), which is refreshed each cycle and cleared on a silent slot, so the count reflects the latest cycle and drops to 0 correctly. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
|
Heads up: holding this PR rather than merging it right now. It conflicts structurally with #729 (Restore Android Auto — Play-approved IOT shape), which is merging first. #729 deletes The Copilot review comment here (per-cycle decode count) has been verified and fixed on this branch regardless. Next step (separate follow-up): rebase on the new |
What
Implements the Pane-layout status dashboard from the FT8AF CarPlay/Android Auto design exploration (Claude Design project). Extends the existing Android Auto status screen with the design's activation dashboard, whose defining behavior is "activation rows drop out, session stats take the slot."
Beside the existing POTA line, the pane now shows:
ROTA <trip> · N QSOswithX.X mi driven this activation, read fromRotaTripManager.state.N more to validate the activation→Activation validated(POTA's 10-QSO program rule; no existing constant, soPOTA_ACTIVATION_TARGET = 10is defined here).N decodes last cycle.Session · N QSOs/Last logged JA1XYZ · 20m · 41 min, shown only when neither POTA nor ROTA is active.How
Decision/format logic lives in pure, Android-free helpers in
CarQsoStatus.kt(buildCarActivationRows,potaValidateSpec,buildCarSessionRow,formatMiles,minutesAgo,carDecodesSecondary), unit-tested directly.QsoStatusScreenstays thin — it maps the app singletons (PotaSessionManager,RotaTripManager,GeneralVariables,FT8TransmitSignal.mutableQsoCompletedAt) into those helpers.Both render paths use the same builder: the
PaneTemplatefallback (older hosts) and the map Surface overlay (modern hosts) —CarSurfaceState.potaTextis generalized toactivationLinesso ROTA/session appear on real devices, not just old hosts. The sharedbuildCarQsoStatusis left untouched, so the existing status/slot/band logic and its tests are unaffected.Notes / judgment calls
QSL_Callsign_list_today) — the only cheap in-memory count; "last logged" is best-effort from the last partner + completion timestamp. Both documented at the call site.Testing
CarDashboardTest.kt— 17 new tests, 0 failures; existing car tests (incl. the manifest-wiring Robolectric test) still green:./gradlew testDebugUnitTest --tests 'radio.ks3ckc.ft8af.car.*'.assembleDebugpasses (validates the 9 new string resources + manifest merge).🤖 Generated with Claude Code