diagnose_frame
Diagnose a raw frame without hardware by verifying checksum/encoding combinations and testing expected command parsing at nearby offsets to expose off-by-N framing.
Instructions
Diagnose one raw frame, pure computation — no hardware, no audit entry. Every checksum algorithm x value encoding is verified at the default tail position (checksum_matrix); each row's at is the byte offset where the stored checksum starts (frame_len - stored_len; stored_len is the algorithm's byte count for raw, twice that for ascii_hex), and a row whose algorithm cannot apply to this frame carries only kind/encoding/error, no at. With expected:{device,command} the command's response.parse is also attempted at byte offsets -2..=+2 (parse_attempts) to expose off-by-N framing — parsed: true only means the bytes are structurally decodable at that offset; the offsets are mutually exclusive hypotheses, so judge which (if any) is the real alignment yourself. The result declares view:{kind:"diagnostics"} for show_result.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| hex | Yes | The frame bytes, e.g. "01 04 02 08 9B FA 8D" | |
| expected | No | {device, command}: the workspace command whose response.parse the frame was expected to satisfy |