tickwave
Web viewer for mixed-signal captures
tickwave shows a logic or mixed-signal capture inside a web page, beside the text that cites it.
It draws digital channels from their edges and analog channels from their samples, on one time axis. A phrase in the text can name a stretch of the capture: point at it to see that stretch, or click it to open the whole capture there. The Escapement Project's pages show their bench's recordings with it.
Reading a capture
Zoom, measure and place cursors, on one time axis
Move and zoom
Ctrl or Cmd with the wheel, or a pinch, zooms about the pointer. A drag or a sideways swipe moves along the capture. Over an analog channel's scale, the same zooms and moves its values.
Read a pulse
Point at a digital channel for the pulse's width, period, duty and frequency, or at an analog channel for its value.
Cursors and spans
Two clicks place cursors and give the interval between them. A drag selects a span and measures a channel's clock in it.
Annotations
A sidecar names spans and points, shown above the channels. Step through one kind of them, such as every WAIT.
Try them on this capture of an SWD bus, from a mixed-signal analyser's two analog inputs at a billion samples a second. The analyser read each sample as an integer code, and the recording stores those codes. One code step is about 2.5 mV, so a readout stops at the millivolt.
Convert
From a Saleae Logic 2 export, a sigrok session or a VCD file
Get the converter
cargo build --release -p escapement-tickwave-cliFrom tickwave's repository, with a current Rust toolchain. Or convert on the Open page, in your browser, on the same code.
Convert
tickwave convert sigrok session.sr -o session.tickwaveA Saleae export and a VCD file convert the same way. It checks what it wrote against the capture, edge by edge.
Describe
tickwave info session.tickwaveThe recording's length and resolution, its channels and their edges.
Each time is counted in the capture's own ticks, so a recording never shows more resolution than its source had. The converter's doc has every option.
In your page
A capture cited the way a page cites a figure
Each underlined phrase below names a stretch of a real capture. Point at one, or reach it with Tab, to see that stretch. Click it to open the whole capture there.
A logic analyser recorded a debug probe opening an SWD session, at a billion samples a second, so one tick is one nanosecond. The probe starts with a
Its first transfer
Here is the whole capture, closed. It says what it holds before any of its data downloads.
How this page does it
The page includes one script, and a stylesheet that lays out the closed capture before the script has loaded. The capture and its sidecar of annotations sit beside them as files.
<script type="module" src="tickwave.js">
</script>
<link rel="stylesheet" href="tickwave.css">
<p>Its first transfer
<tickwave-ref for="capture"
annotation="dpidr-read">reads
the ID register</tickwave-ref>.</p>
<tickwave-view id="capture"
src="identify-swd.tickwave"
annotations="identify-swd.annotations.toml">
<span slot="title">identify-swd.tickwave</span>
<span slot="facts">524 ms; 2 channels:
SWCLK, SWDIO; 4.6 KiB</span>
</tickwave-view>
The sidecar is a short TOML file. This entry names a transfer an SWD decoder found, and asks for the clock's rate over it:
[[annotation]]
id = "dpidr-read"
ref = "swd/read/377094557"
label = "Reading the debug port's ID register"
measure = { channel = "SWCLK", what = "rate" }
tickwave-view- A whole recording, shown as its title and a summary until the reader opens it.
tickwave-inset- One annotation's span, magnified, with a reading under it. Point at a part to read it.
tickwave-ref- A phrase that cites an annotation. Pointing at it opens an inset.
tickwave-chart- Measurements against a setting. A point can open the recording behind it.
A reference loads nothing until it scrolls into view. Then it fetches the recording's head and the sidecar, and the data for a stretch arrives when someone points at it. The sidecar's doc lists its fields.
Docs
Written beside the code, in tickwave's repository
- Using it
- Reading a recording in the viewer, and converting a capture into one, in the browser or on the command line.
- In your page
- The elements that put a capture in a page's text, and the charts that draw measurements.
- The files
- The recording format, and the sidecar of annotations that sits beside a recording.