merge: an escaped checksum is the checksum, not data (#58)

S3FrameParser kept the 10 of a checksum sent as `10 02/03/04` as the reply's
last data byte.  It now takes the pair: 7,747 / 7,747 recorded replies check,
272 of them with an escaped checksum.  Fixes the 1C battery/memory misread
(419.84 V on 12 of 760 recorded status replies) and the 2C call-home read; the
5A file builder's own compensation is removed with it, and pre-fix .a5.pkl
frames are converted on load (A5_PICKLE_VERSION 2).  checksum_valid now sums
the unescaped payload.

Conflict: the reference's changelog table (dev's own 2026-11-06 row); #58's
row kept as 2026-11-06 (2).  Suite on the merge: 1,693 passed, 0 failed.

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-11-12 15:27:00 -05:00
commit ff705ebf87
8 files changed
+248 -82

No files matched your search

+1
View File
@@ -15,6 +15,7 @@
| 2026-11-09 | Appendix D.6.15 (NEW), D.6.6, D.6.11 | ✅ **Over range and the mic.** **D.6.15:** a peak past full scale (2,000 units = 32,000 counts; the mic in counts) is Blastware's `OORANGE`, per channel and per histogram interval, from the unit's own summary peaks. The vector sum is `OORANGE` exactly when a geophone is (43 / 43); never on its own (38 / 38 numeric), which retracts D.6.11's open "vector sum alone" case. The `<OORANGE>` line marks the mic over (18 / 18). **D.6.6:** the mic has its own range byte (label + 29): at 1 a count is an eighth, 7 DL2 events SFM read 8× high. The dB offset is **81.938216**: [81.9383, 81.9385] was too high, and every count Blastware printed leaves [81.9382058, 81.9382266]. Blastware's mic unit labels do not hold on every report; some mix dB and psi in one column. **80 of 88 report fields now match on every DL2 event.** |
| 2026-11-08 | Appendix D.6.14 (NEW), D.3.3, D.6.11 | ✅ **The monitor log is in the footer.** Every DL2 report prints one Monitor Log line: the footer's ts1 and ts2, then words for the footer's flag word `[18:20]` (`0x0001` Event Recorded, `0x0002` Keyboard Exit, `0x0004` Remote Exit, `0x0008` Selfcheck Passed, `0x0010` Timer Stop, `0x0020` Modem Exit, `0x0200` Battery Low Exit, `0x0800` Memory Full Exit; the higher session-end bit wins, from one file). Rebuilt, it equals Blastware's character for character on 69,983 / 69,983. **D.3.3:** footer `[20:22]` is the trigger source again, `[22:24]` is zero; `[24:26]` still unknown, and no common CRC-16 or sum fits. **72 of 88 report fields now match on every DL2 event.** |
| 2026-11-06 | Appendix D.6.13 (NEW), D.3.3, D.6.11, D.6.12 | ✅ **The record chain to the footer, and the sensor check.** Walked from the event record, the chain (event `0x05` → unit's summary `0x32`–`0x35` → sensor checks `0x3c`–`0x3f` → footer `0x0e`) ends exactly at the file's end on all 70,041 DL2 files. The footer is its last record: `00 1a` is its length, `0e` its id. **Each sensor-check record's header holds the unit's results:** channel type `[2]`, status `[4]` (0 = passed), frequency × 10 `[5:7]`, ratio × 10 `[7:9]` and amplitude mV `[9:11]`. Blastware prints them as they are: 209,943 / 209,943 geophone frequencies and ratios, 69,975 / 69,975 mic frequencies and amplitudes. The result is Passed / Check / Disabled by status and type. The status is the unit's own verdict, its bits not decoded. D.6.12's "`0x3c` / `0x3d`, before and after" retracted in place: one record per channel. **71 of 88 report fields now match on every DL2 event.** |
| 2026-11-06 (2) | §3 (replies), SUB 1C, 2C, 15, 5A file build | ✅ **An escaped checksum is the checksum, not data (#58, measured).** A reply whose checksum is 02, 03 or 04 sends it as `10 X`, and `S3FrameParser` kept that `10` as the frame's last data byte (first seen on BE9441's 1A read, 2026-11-04). **Across every recorded reply** (60 captures, March to October 2026, three units) SUM8 of the unescaped payload is the checksum on **7,747 / 7,747**, widening 2026-10-26 (4)'s 748 / 748. **272** checksums arrived escaped; every one checks as an escape pair, and no checksum ever arrived as a bare 02/03/04. **What the stray byte did:** **SUB 1C** battery and memory are counted from the end, so 12 of 760 recorded status replies read 419.84 V and 251,654,656 bytes (for 6.76 V and 983,026). A **SUB 2C** call-home read came out one byte long and was refused as "monitoring". The **SUB 15 probe reply** (`00 00 00 00 0a …`, the same on BE11529, BE18189 and BE9441) always has an escaped checksum: 230 of the 272, harmless, as nothing reads it. The **5A file builder** had compensated since 2026-04-21 (the "split pair" rule). With the parser fixed, that rule would drop a real `0x10` ending a chunk (one A5 chunk in ten ends in one; none recorded with an escaped checksum as well), so it is removed. The 1A and 09 reads' length trims (2026-11-04) stay as guards. `checksum_valid` now sums the unescaped payload, and every recorded reply checks. |
| 2026-11-05 | Appendix D.6.12 (NEW), D.6.11, §7.8.9 | ✅ **The unit's own event summary, in every event file.** The embedded event record is the first of a `[length][id][payload]` chain. It holds the vector-sum peak's sample (6,492 / 6,493). Then one 22-byte record per channel, ids `0x32` Tran … `0x35` MicL: min, max, peak sample, **half-period** and a **displacement integral**. Blastware prints them as they are. **ZC frequency** = (rate / 2) / half-period, with the interval rule's words: 25,966 / 25,966 waveform and 253,958 / 253,958 histogram channel values. **Peak displacement** = half the integral: 19,479 / 19,479. Recomputing from the samples had reached 46% and 84%: the unit works at full resolution. **Times of peak** follow the unit's peak sample. That differs from the samples only on **O117I1NK.R70W**, whose stored samples wrap at the trigger by 65,536 counts (Blastware's own table has the same values). Peak acceleration is Blastware's own computation from the stored samples (group D part 1, documented here too). The unit stores its own largest step at `[15:21]` (inferred), which Blastware does not print. §7.8.9's "constant, meaning ❓" bytes amended in place. 59 of 88 report fields now match on every DL2 event (47 before group D). |
| 2026-11-04 | SUB 1A / 09 reads, SUB 68–74 settings write, the keypad | **SFM's settings write, benched on BE9441 (Brian at the unit; ~12 writes, each with his go).** **Every write** -- trigger 0.04 ↔ 0.05, a note, several fields at once (Project, job number + its report flag, trigger), the alarm 1.0 ↔ 1.5, and a full restore -- was acknowledged on all nine steps (`97 8C 8E×5 8D 7D 7C 96 8B 8D`), read back as sent, and **confirmed on the unit's own screen**; the unit ended byte for byte as found. Moved bytes were exactly the field's: trigger f32 at each geophone channel +30 (`+31..+33` moved), **alarm f32 at channel +38** (`+39` moved; the first Series-3 alarm write), job number `[40:42]`, its report bit `[39]` `0x02`, a note's value window. **`[26:28]`** went `01 7f` → `00 00` on SFM's first write (Blastware's value) and the unit **set `01 7f` again during the next monitoring session**. The **two bytes after the block** went out as `00 00` (Blastware sends a per-unit constant) and were taken. **🔑 Escaped-checksum artifact:** when a reply's checksum byte is itself escaped (02 / 03 / 04, ~1 frame in 85), `S3FrameParser` keeps the escape's `0x10` and strips only the byte after it, so the frame's data gains one trailing `0x10`. It hit the first live 1A read (frame B 1,026 bytes after the header); the 12 recorded reads never had. SFM's settings read and waveform read now take exactly the length they asked for. **🔑 The keypad menu wins:** a write sent while the setup menu was open was acknowledged and read back, then **lost when the operator pressed Cancel or Save** -- the menu writes its own copy of the **whole** block back (both times the block returned byte for byte to its state when the menu was opened). A keypad Cancel with nothing pending leaves the block unchanged. **While monitoring**, the 1A read returns the device-info block (SFM refuses, nothing sent), and the opening poll was answered only intermittently (2 of 3 attempts timed out). Code: `minimateplus.protocol.read_compliance_content` / `read_waveform_data_raw`, `micromate.setup_fields`; notes `~/bench-logs/2026-11-04-sfm-settings/`. |
| 2026-11-03 (5) | SUB 1A / 71 / 69 (settings read and write) | **The settings block, read and written as content (measured, BE9441's 10-26 recording and BE11529's 2026-04-20 captures).** **Read:** unescape each 1A data frame and take `data[11:]`; every frame but the last starts with one `00` that is not content; dropped, the frames join into **2,090 bytes headed by N = 2090: Series IV's `0x1A` content layout** (12 / 12 reads, Blastware's 4 × 512 + 42 and SFM's 1024 + 1024 + 42). The old "stable anchor" `be 80 00 00 00 00` is content `[12:18]` (pre-trigger −0.25 + stop mode Fixed). **Round trip:** the read after each of Blastware's two 10-26 writes equals the image it had just written, all 2,090 bytes (2 / 2). While monitoring, the read returns the device-info block (`0e 'BE9441' …`, 5 / 5). **`[26:28]`:** Blastware writes `00 00` on all 11 writes; the unit reads `01 7f` after a monitoring session (BE9441 10-26, BE11529 4-20 15:19) and sets it by itself; meaning unknown. **The two bytes after the block** (`[2090:2092]` of the 0x71 image) are Blastware's own per-unit constant -- `7c ea` on all nine of BE11529's writes, `0c e9` on both of BE9441's -- not the block's CRC-16/AUG, and in no reply of BE9441's three-hour session; SFM sends `00 00`. **`0x09` `[200:202]`:** Blastware echoed the unit's `8c 76` on all nine April writes; on 10-26 it read `17 17` and wrote `78 76` (read back so); meaning unknown. **Blastware re-renders the mic trigger level:** on BE11529's first write (4-20 15:19) the unit read 0.005 and 0.01 psi in its two `MicL` channel blocks (3 and 7; Series 3 carries 8 channel blocks of 48 bytes from `[1708]`, the second four prefixed `0x32`) and Blastware wrote 0.004983 and 0.010058 -- the same levels to its 0.1 dB; every other write left them alone. **Every one of the 11 Blastware writes reproduces** from the block before it with only the fields Blastware changed (plus that re-render and, on 10-26, the mic bit of `[25]`). Code: `minimateplus.protocol.assemble_compliance_content`, `read_compliance_content`, `micromate.setup_fields`; tests `tests/test_s3_settings_read.py`, `tests/test_setup_fields.py`. |