test+docs: SFM's MiniMate downloads are byte-identical to Blastware's; the 64 KB bug narrowed

Brian's Blastware downloads of BE9441's 20 events give ground truth.  SFM's
re-run downloads of events 0, 1, 3, 4 and 10 are byte-identical to Blastware's
own files; imported first through the watcher route, the same events download
as already_stored (no duplicate rows -- the unit's 0C and Blastware's file agree
on serial + timestamp).  Fixtures: Blastware's P00/Q10 (now asserted equal to
SFM's builds) and QZ0/T80, the two page-crossing events, as byte-exact targets.

The 64 KB page bug, narrowed by a read-only test walk: carrying the page byte
addresses the first chunk in page 0x12 (answered), but the next request carries
a raw 0x03 inside its params (counter 0x032c) and gets no reply.  Pages after
0x11 have such counters; 0x11 does not (event 1 skips 0x0000-0x05FF).  Needs a
Blastware wire capture of event 2 or 19 (recorded in CLAUDE.md, the Series-III
reference and the spec).  No code change.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SyJ2ip3Krb6dtdv2cXua44
This commit is contained in:
serversdownandClaude Opus 5.5 committed 2026-10-26 12:15:50 -04:00
1 parent 1ded70fcd9
commit 465bc704dd
9 files changed
+49 -1

No files matched your search

+16
View File
@@ -13,3 +13,19 @@ the `0xA5` frames.
Both events: single shot, 4096 sps, 5 s record + 0.25 s pre-trigger = 5.25 s = 21,504 samples per channel.
Event 1 is the case that showed the body builder skipping 13 bytes on its second and third
frames as if they were metadata pages (2 bytes lost, decode truncated at 1,024 / 2,782 / 512).
## `blastware/`: Blastware's own downloads of the same events (Brian, 2026-10-25)
| file | event | key | note |
|---|---|---|---|
| `K441LTMK.P00` | 0 | `01110000` | byte-identical to SFM's build (sha `589073a0…`) |
| `K441LTMK.Q10` | 1 | `0111646a` | byte-identical to SFM's build after the metadata-page fix (sha `e74c664d…`) |
| `K441LTMK.QZ0` | 2 | `0111c92c` | **crosses the 64 KB page boundary**: STRT end key `01122f06` |
| `K441LTML.T80` | 19 | `0118a4ca` | **crosses the 64 KB page boundary**: STRT end key `01190824` |
On the 2026-10-26 re-run, SFM's own downloads of events 0, 1, 3, 4 and 10 were byte-identical to
Blastware's files, all five. QZ0 and T80 are the byte-exact target for a fix of the
page bug. Carrying the page byte is enough to address the first chunk in the next page
(0x0112012C answered). The second chunk (0x0112032C) puts a raw 0x03 in the request's
params, and the unit does not answer. How Blastware encodes 02/03/04 inside params is
unknown; it needs a wire capture of Blastware downloading one of these two events.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
+11
View File
@@ -77,6 +77,8 @@ def test_a_sample_chunk_at_0x1002_is_not_mistaken_for_a_header_byte():
GOLDEN = { # sha256 of STRT + body + footer, and of the written file
# Both written files are byte-identical to Blastware's own downloads of the same
# events (fixtures/minimate-bench-10-25-26/blastware/, compared below).
# event 0's file is byte-identical to the one SFM stored at the bench before any fix
"event0": ("29beabfe46a858587b8cdc6ee3f484473c07f96485e404f68c42c6aa1e298aa7",
"589073a096d4f867c5ab8c697c82c4b635c7757fcfdd618b460f3b647c32ed7f"),
@@ -112,3 +114,12 @@ def test_a_term_at_0x1002_is_not_mistaken_for_a_header_byte():
moved = type(term)(**{**vars(term), "data": d[:3] + b"\x10\x02" + b"\x00" + d[5:]})
_s, got, _f = extract_body_bytes(frames[:-1] + [moved])
assert got == want
@pytest.mark.parametrize("which,bw", [("event0", "K441LTMK.P00"), ("event1", "K441LTMK.Q10")])
def test_the_written_file_is_blastwares_own(which, bw, tmp_path):
ev = Event(index=0)
ev.timestamp = None
path = tmp_path / "x"
write_blastware_file(ev, a5_frames(which), path)
assert path.read_bytes() == (FIX / "blastware" / bw).read_bytes()