Repository navigation
P3-H P0.1: encoder-produced deterministic SV WirePlan - #141
Merged
Merged
Conversation
Record ASDU field regions while BER is encoded, translate them to absolute Ethernet offsets, and consume those offsets directly in the ESP32-P4 publisher. Remove per-transmit smpSynch BER scanning and the duplicate transport-failure guard so the realtime path has one TX authority. Tracks #139.
6 tasks
Reject reintroduction of raw fixed-field scans, TX interception, smpSynch wire parsing, or a second transport-failure authority in the ESP32-P4 publication path. Tracks #139.
masarray
changed the base branch from
hardening/smv-p0-standards-invariants
to
main
October 6, 2026 12:43
masarray
marked this pull request as ready for review
October 6, 2026 12:44
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
This was referenced Oct 6, 2026
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #140. Tracks #139.
Base head expected:
a09e0312dd1257404669ddc2e6a2cf4264d072a6This PR must not merge before #140 is accepted; after #140 lands, retarget/re-evaluate against current
main.Why
The deterministic ESP32-P4 publisher still rediscovered
smpCnt,confRevandseqDataoffsets by scanning the fully encoded frame for tag/length byte patterns. Separately, the smpSynch TX interception shim structurally parsed BER on every transmitted SV frame and contained a second canonical transport-failure guard even thoughapp_main.cppalready owns that failure policy.That is correctable technical debt in the realtime path.
Architecture change
SampledValuesPduCodec::encode_into_with_layout()std::span<SampledValueAsduEncodeLayout>; no metadata heap allocation;SampledValuesFrameCodec::encode_into_with_layout()smpCnt,smpSynchandseqDatadirectly by bounded offsets.smp_synch_lab.cppis removed;app_main.cppremains the single canonical TX failure authority.wire_field_offsets.hpputility remains available for inspection of arbitrary/foreign frames; it is no longer part of deterministic publication.Runtime properties
No XML/SCL parsing, BER parsing, packet rescanning, dynamic re-encoding or new allocation is added to the steady-state publish loop.
Per published sample, synchronization policy resolves from atomics and the selected value is a direct one-byte patch. Canonical/mirror frames use the same decision for that sample.
Regression coverage
Non-goals
No IEC 61869-9 profile expansion, no arbitrary dataset activation, no multi-stream scheduler, no PTP conformance claim and no PRP/HSR work in this PR.
Next node after P0/P0.1: #139 P1 timing/profile semantic separation.