wifi-densepose/v2/crates/wifi-densepose-hardware/src
ruv 82be960de5 test(adr-110): cross-language wire-format conformance gate
Iter 21 — ultra-opt for protocol correctness across the two production
decoders. Pin the same 32-byte canonical hex in both Python and Rust
tests; if either decoder drifts from the wire, ONE of the tests starts
failing — and it's clear which side moved.

Canonical packet: COM9 sync-pkt #1 from §A0.12 live capture, expressed
as exact little-endian bytes:

  10a111c5 09 01 06 00                      magic + node + ver + flags + rsvd
  f26db70100000000                          local_us = 28_798_450
  c5aca50100000000                          epoch_us = 27_634_885
  1400000000000000                          sequence = 20 + reserved

Python test:
  archive/v1/tests/unit/test_esp32_binary_parser.py::TestSyncPacketParser
  ::test_canonical_wire_bytes_match_rust_decoder
  — decodes the pinned hex, asserts every field including the §A0.10
    1,163,565 µs offset.

Rust test:
  v2/crates/wifi-densepose-hardware/src/sync_packet.rs::tests
  ::canonical_wire_bytes_match_python_decoder
  — decodes the same bytes, asserts the same fields, then re-encodes
    via to_bytes() and asserts the round-trip produces the EXACT same
    32 bytes. So this also catches drift in the Rust encoder.

Test counts after this iter:
  Rust sync_packet: 15/15 green (was 14)
  Python SyncPacketParser: 7/7 green (was 6)

Branch contract: if a future PR changes the firmware wire format, BOTH
tests must be updated atomically with the new canonical hex. CI will
gate this naturally.

Co-Authored-By: claude-flow <ruv@ruv.net>
2026-05-23 13:52:44 -04:00
..
aggregator chore(repo): rename rust-port/wifi-densepose-rs → v2/ (flatten to one level) (#427) 2026-04-25 21:28:13 -04:00
bin fix(hardware): aggregator tolerates sibling RuView UDP packet magics (#517) 2026-05-11 10:48:00 -04:00
esp32 chore(repo): rename rust-port/wifi-densepose-rs → v2/ (flatten to one level) (#427) 2026-04-25 21:28:13 -04:00
bridge.rs feat(rust): host-side decode for ADR-018 byte 18-19 (ADR-110 closure) 2026-05-22 22:42:49 -04:00
csi_frame.rs feat(rust): host-side decode for ADR-018 byte 18-19 (ADR-110 closure) 2026-05-22 22:42:49 -04:00
error.rs fix(hardware): aggregator tolerates sibling RuView UDP packet magics (#517) 2026-05-11 10:48:00 -04:00
esp32_parser.rs feat(rust): host-side decode for ADR-018 byte 18-19 (ADR-110 closure) 2026-05-22 22:42:49 -04:00
lib.rs feat(hardware): Rust SyncPacket decoder + 7 unit tests (ADR-110 §A0.12) 2026-05-23 13:06:08 -04:00
radio_ops.rs chore(repo): rename rust-port/wifi-densepose-rs → v2/ (flatten to one level) (#427) 2026-04-25 21:28:13 -04:00
sync_packet.rs test(adr-110): cross-language wire-format conformance gate 2026-05-23 13:52:44 -04:00