Candidate 228 — manual saved-record sequence

Scope and prerequisites
-----------------------
This is a planning and evidence worksheet for a future qualified read.
The packaged checker supports generated synthetic files only. An actual
instrument transfer requires an already configured, documented link and
a terminal that can save one complete response at a time. Use a dated,
independently reviewed profile that binds the terminal/backend, model and
actual firmware replies, frame extraction, exact suffix bytes (including
whether there is a suffix), end-of-message evidence and timeout semantics.
The current package has no such actual profile. If the existing link or
the required evidence is unavailable, leave actual qualification pending.
A socket port, firmware list, line ending and end byte all require evidence
from the applicable interface. The checker installs nothing and operates
only on already saved files.

Before the future qualified read, copy observations-blank.csv for the
operator log. Use a separate evidence directory for the manifest and
response files. Record actual observations as made. Leave unknown
worksheet values blank and encode unknown observation leaves as null
under record-format.md. Use actual files only with synthetic set to false.
The tests' generated values and synthetic transport profile are a
separate software exercise.

Fixture, then manual Single
---------------------------
Use the RIGOL DHO804 and Tektronix AFG1022 low-voltage fixture. Before
connecting any scope input or output terminal, connect the scope's rear
Ground Terminal to earth with its supplied ground cable. This earth
connection must precede both the signal cable and the control link.
Use the supplied scope power adapter and keep the generator's protective
earth intact.

With the generator outputs off and the scope earthed, attach the
documented control link. On the qualified link, save an initial *IDN?
reply and confirm the applicable model and firmware before using
DHO804-specific readout behavior. Still save the identity query at every
required boundary below.

With generator output off, connect generator CH1 to scope CH1
with the existing short 50 ohm BNC coax. Use the scope's 1 megohm input,
CH1 on, all other scope channels off, DC coupling and 1x display ratio.
With generator CH2 off, set CH1 to High Z display load, a continuous
100 Hz sine, 2.00 V peak-to-peak and zero offset. Start near 0.5 V/div
and 20 ms/div in the scope's main timebase. Once hookup and configuration
are complete, enable generator CH1 output. Before arming the first
manual Single, verify that the intended sine is visible on scope CH1
and that the scope triggers steadily from CH1. Log the observations.
Leave optional meter fields blank unless separate readings were made.
Keep the generator output on and retain the fixture, generator settings
and trigger settings through A, B and C.

Choose Normal acquisition and Single trigger sweep on the front panel.
Make one manual Single acquisition at each specified depth and wait for
the STOP indication. Save before/after panel observations and capture
snapshots around all the reads of that capture. While reading, leave
acquisition and panel settings unchanged, allow only the readout selector
changes below, and keep concurrent operation off the instrument. Retain
the operator's actual reports for each capture. STOP at two boundaries,
stable settings and hashes establish saved observations, with acquisition
freshness and atomicity still unverified.

    Capture   Selected depth   Record roles in order
    A         100,000          A_SCREEN (NORMal), then A_RAW (RAW)
    B           1,000          B_RAW (RAW), after a new manual Single
    C         100,000          C_RAW (RAW), after restoring depth and
                               making a new manual Single

A's two roles share the same stopped acquisition and capture boundaries.
Leave the fixture, generator and timebase settings in place between
captures. Check that C restores A's depth, reported rate, main timebase
scale, RAW increment, instrument identity and panel observations. Record
B's own queried settings and grid. Record C's actual observations even
when they differ from A.

Capture snapshots
-----------------
For each capture and both full boundaries of each record, save the
individual, complete replies to these acquisition queries in their
corresponding snapshot fields. Send one query at a time and retain the
exact spelling.

    idn                  *IDN?
    trigger_status       :TRIGger:STATus?
    trigger_sweep        :TRIGger:SWEep?
    acquisition_type     :ACQuire:TYPE?
    memory_depth         :ACQuire:MDEPth?
    sample_rate          :ACQuire:SRATe?
    main_timebase_scale  :TIMebase:MAIN:SCALe?

Save the identity reply with its vendor, model, serial and firmware.
The compatible stopped settings are DHO804, STOP, SING and NORM. Record
the numeric depth, sample rate and timebase the instrument reports.
Source selection below controls waveform readout. Channel enables
belong in the separate panel report.

Full record and window reads
----------------------------
For the current role select the documented readout settings manually.
Use the NORMal mode command for A_SCREEN and the RAW mode command for
A_RAW, B_RAW and C_RAW. Send only the mode command for the current role.
Each line below is its own terminal command. Replace placeholders
with the intended positive integer.

    :WAVeform:SOURce CHANnel1
    :WAVeform:MODE NORMal
    :WAVeform:MODE RAW
    :WAVeform:FORMat ASCii
    :WAVeform:POINts <n>
    :WAVeform:STARt 1
    :WAVeform:STOP <n>

Request the role's supported full point count. A_SCREEN uses up to
1,000 points. RAW is intended to match the stopped capture's queried
depth. Verify the full start, stop, points and preamble against the
schema before treating any count as the full record. A setting command
alone is intent. Readbacks supply the observed settings. The selected
reply tokens are CHAN1 and ASC, with NORM for the NORMal selector and
RAW for the RAW selector. The waveform STOP selector sets the
inclusive read endpoint. The trigger status query separately reports
whether acquisition is stopped.

At the full before boundary, save the acquisition snapshot above and
separate complete replies to the seven waveform queries below. The
full before and restored full after boundaries each require all
fourteen replies, including each full preamble's ten fields.

    source       :WAVeform:SOURce?
    mode         :WAVeform:MODE?
    format       :WAVeform:FORMat?
    points       :WAVeform:POINts?
    start        :WAVeform:STARt?
    stop         :WAVeform:STOP?
    preamble     :WAVeform:PREamble?

For each consecutive window [i, j], use the documented
:WAVeform:STARt <i> and :WAVeform:STOP <j> selectors. Set the new
stop before advancing the start on forward windows. Indices are
one-based and inclusive. Start at 1, use at most 10,000 points per
window, begin each next window at the previous stop plus 1, and
end at the reported full count. The 100,000-point plan uses ten
windows, 1–10,000 through 90,001–100,000. These indices are
requests, with queried endpoints logged separately.

For each window, save the first six waveform replies above in
the window's before snapshot. Verify source, mode, format, full
points and the requested endpoints. Save the complete
:WAVeform:DATA? reply, then save those six separate queries again in
the window's after snapshot. Keep each window's requested indices
and both queried snapshots. The qualified ASC payload must contain
exactly j minus i plus 1 finite voltage values in reply order. Use
null in the window preamble slot
when it was not queried. A separately saved window preamble follows
the schema's optional consistency rule; full preambles give the
count authority. Unsupported or inconsistent replies stop the
qualification. Retain the files and the observed failure.

After the final window, restore the full read window with start 1
and stop equal to the full count. Save the full after snapshot with
all acquisition and waveform queries again. After the last role,
save the capture after snapshot and panel observations. Then move
to the next depth/control with a new manual Single as specified.
After saving C's final observations, switch generator CH1 output
off before disconnecting the coax.
A_SCREEN's intended digital negative is the readout mode, and
B_RAW's is the high-depth count. Both require a valid complete
saved record and retain their separate fixture and digital verdicts.

Terminal limits and evidence
----------------------------
Use a finite per-response deadline and byte limits configured in
the already qualified terminal/backend. Save its actual deadline
configuration and any timeout telemetry separately. The checker
reports saved timeout/EOM observations. It cannot enforce instrument
I/O deadlines. If an end-of-message (EOM) observation or timeout
status is unknown, leave the worksheet value blank and follow the
schema's unknown/null conventions. A file ending records
only the end of that file. Use an EOM basis that truthfully reflects
the reported observation. A physical operator statement is separate
from a qualified backend event.

Keep the original, complete response bytes for each scalar, preamble
or data reply. Preserve failures, including a partial response after
timeout, as evidence. Follow the reviewed frame profile for extraction.
Retain the original frame, including any suffix that was actually
received. Avoid screen copies, re-encoding, line ending conversion,
editing a numeric cell, trimming extra bytes and padding missing
values. Save one response per referenced file, with its relative
path, byte count and SHA-256 digest. Preserve any shared FileRef as a
reused observation. Equal data can arise from periodic signals.
For each reply, bind the exact command, profile, framing evidence and
reported transport status to that file. Save referenced telemetry and
framing evidence with the same file length and digest discipline.

These are software limits. The schema bounds scalar, identity and
preamble frames to 4 KiB, a complete data frame or an evidence file
to 1 MiB, each record to 100,000 values, 100 windows and 16 MiB of
referenced frame bytes, the combined capture snapshots to 1 MiB,
the whole input to 65 MiB and the manifest to 512 KiB. See
record-format.md for the remaining structure, path and numeric limits.

Offline check
-------------
From this directory run with Python 3.9 or later on a supported host:

    python3 check_records.py manifest.json --output new-report.json

Point to the saved manifest and a fresh output path in a local
directory that supports hard links. The report retains separate
protocol, digital contract, fixture sanity and operator scope
verdicts and the available issue locations. Transport observations
are saved reports; their telemetry files remain separate evidence.
Overall exit 2 is malformed input or command/output usage error,
3 is unsupported or physical control pending, 1 is a valid failed
comparison and 0 is the expected comparison. Malformed findings
take precedence, followed by unsupported/pending and then failure.
An exit 0 with this package is a synthetic, non-bench result.
It leaves physical accuracy, calibrated time, aliasing,
continuous-waveform completeness and integration unverified.

Command reference
-----------------
RIGOL DHO800/DHO900 Programming Guide, sections 3.3, 3.12.1,
3.26.5, 3.27, 3.28 and 4.3. The documented stopped RAW ASCII
100,000-point example supports the planned readout mode, with
actual transport and firmware behavior still awaiting qualification.
