Skip to content

fix: fail the build if the SDK renumbers a probed display controller - #623

Merged
prokrypt merged 1 commit into
mainfrom
fix/panel-probe-enum-guard
Nov 11, 2026
Merged

prokrypt merged 1 commit into
mainfrom
fix/panel-probe-enum-guard

Conversation

@prokrypt

Copy link
Copy Markdown
Owner

Requested by Clankmaster · project thread

Review finding: src/platform/PanelProbe.cpp stores BoardConfig::DisplayController in NVS as a raw value. An SDK renumber would load a stale record into the wrong driver until the recovery chord.

Fix: a static_assert pins the values the probe can store (SSD1677 0, UC8253 2, UC8279 6, UC8179 7). A renumber now breaks the build with "bump RECORD_VERSION", which forces one re-probe. Zero runtime cost, no NVS format change.

Not needed: board and defaultController are compared, not trusted, so a renumber there only re-probes; the diag blob is size-checked and diagnostics only.

Hardware check: none needed (compile-time only); X4 Pro boot log still shows the panel from "saved probe (NVS)".

No changelog: compile-time guard, no user-visible change.


Generated by Claude Code

The panel probe record in NVS keeps DisplayController as raw values. An SDK
renumber would load a stale record into the wrong driver until the recovery
chord. A static_assert pins the values the probe can store, so a renumber
breaks the build and the fix is a RECORD_VERSION bump.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QrEdpxLkuVrifx7ahhZV13
@prokrypt
prokrypt enabled auto-merge (squash) November 11, 2026 17:18
@prokrypt prokrypt self-assigned this Nov 11, 2026
@prokrypt
prokrypt merged commit 248b627 into main Nov 11, 2026
17 checks passed
@prokrypt
prokrypt deleted the fix/panel-probe-enum-guard branch November 11, 2026 17:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants