You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 23, 2026. It is now read-only.
Repository navigation
Commit d4dfdd5
Browse filesBrowse the repository at this point in the historyBrowse files
Version and feedback in the app, longer console history with Save, USBTMC stall recovery, Metrics under Instruments, kit styles in drawers
- Top bar shows the running version; Feedback drawer (version, copy, GitHub issues links opened in the system browser via the open_page command)
- Instrument console: 50 000 entries / 8 MiB per instrument, first fetch limited, Save writes the full log; GET /devices/{id}/wire takes limit
- USBTMC (Linux kernel driver and nusb): a stalled bulk-out is aborted and cleared once and the write retried; recovery steps logged in the console
- Metrics moved to an Instruments tab, judged against limits in the bench page style
- Drawer pages share .bench-page / .bench-group; e2e edge guard; Instruments form buttons and fields use the kit styles
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: CLAUDE.md
+17-5Lines changed: 17 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -164,9 +164,10 @@ code; the definitions' `ui_component` is not used by the UI.
164
164
| `bench/panels/` | class panels (`PsuPanel`, `DmmPanel`, `EllPanel` - modes without a setpoint, Short (two presses); `AwgChannel` - frequency or period, amplitude as Vpp / Vrms / dBm / high-low levels, phase, ramp symmetry, load, pulse duty/width/edges, mode CW / MOD (AM/FM/PM: modulating wave, frequency, depth or deviation) / SWEEP (start, stop, time, spacing, trigger) / BURST (N cycles or infinite, period, trigger), each control only when the definition binds it: conversions in `bench/awgMath.ts`, values the instrument does not report tagged CALC; `OscPanel` - one screen for all channels, `LcrPanel` - primary/secondary readouts, function keys L/C/R/Z/DCR → secondary → SER/PAR, frequency/level, range/speed, open/short correction with a prompt, bias; `SalPanel` - spectrum screen (`kit/SpectrumScreen`: dB graticule, max-hold ghost, marker diamond, click to place), marker readout, annotation bar, soft-key groups FREQ/BW/AMPT/SWEEP/TRACE/MKR/TG; `GenericPanel`) |
165
165
| `bench/layout.ts`, `Rack.tsx` | panel order / width (S, M, L, W) / hidden / channel layout of multi-channel panels (side by side or stacked), persisted in `localStorage` (`benchmesh:bench-layout`); columns follow the window width (300 px units) |
| `drawers/` | Instruments drawer tabs: configuration (incl. **Detect**: `DetectView.tsx`, `detect.ts`), Supported, Miscellaneous, **Metrics** (`MetricsView.tsx` + `metrics.ts`: per instrument link busy, exchanges/s, API latency from `/ws/metrics`, judged against limits), Remote access; request log |
168
168
| `recording/` | recordings v2 (`ai_context/migration/RECORDINGS.md`): `RecordingsProvider`(REST + `/ws/recordings`, live sample buffers; main and panel windows), recordable readings (`signal.tsx`: `SignalScope` + `Recordable`, kit `ContextMenu` on right-click / context-menu key, red dot when recorded), recorder dock (bottom of the main window, `benchmesh:recorder-dock`), recordings drawer (history, zoomable chart, rename, CSV export, delete). Chart: `chartModel.ts` (one y-axis per series, colours `--kit-series-1..8`), ECharts core loaded lazily in `RecordingChart.tsx` |
169
169
| `kit/brand.ts`, `kit/BrandMark.tsx` | the logo ("Readout": seven-segment b, ghost segments, amber decimal point): one geometry, colours on dark / on light; `BrandMark` follows the skin (`--kit-brand-*`) or takes fixed colours (website). `node scripts/logo/build.mjs` writes `docs/static/logo/*.svg`, `frontend/public/favicon.svg` and the app icons (`crates/benchmesh-app/icons`, via Inkscape + `cargo tauri icon`); a test fails when they are stale |
170
+
| `about/` | top-bar version (`GET /version`, `version.ts`) and the **Feedback** drawer (`AboutView.tsx`: version, Copy version, GitHub issues links). External pages open by name (`links.tsx`): in the desktop app the system browser via the `open_page` command (fixed list, `crates/benchmesh-app/src/links.rs`, capability `links.json`), in a browser a new tab |
170
171
| `automation/` | Automation drawer (top bar **Automation**, contract `ai_context/AUTOMATION.md`): saved flows (new, duplicate, delete, import/export JSON), flow editor (parameter form, Setup / Steps / Cleanup step cards with vocabulary pickers, live validation shown at each step's path, JSON view; pure document model `flowModel.ts`), run panel (arm dialog for energising flows, live log, variables, prompt Continue, Abort / Escape), assistant (user's own LLM key, result loaded as unsaved), settings tab (provider, key - only its hint is ever shown, model, base URL; MCP access + connection snippets). `RunProvider.tsx` polls `/automation/run` for the whole UI: top-bar `▶ flow - state` + red **Stop** while a run is active |
171
172
172
173
Panel **window controls** (header, top right): fold to the header line (saved with the layout;
**Instrument console** (panel header, console icon): an optional pane at the bottom of the panel
184
185
showing what is sent to (→) and received from (←) the instrument, plus port events (•), from
185
-
`GET /devices/{id}/wire?after=<seq>`(per-device ring of 2000 entries, `bm_driver::wirelog`;
186
-
reply chunks joined in the UI). Auto / Text / Hex view, pause, clear, and **Copy**: paste-ready
187
-
evidence with instrument, model, identify reply, link and app version (`bench/wire.ts`,
188
-
`bench/WireConsole.tsx`). Open state per panel in `localStorage` `benchmesh:consoles`.
186
+
`GET /devices/{id}/wire?after=<seq>&limit=<n>`(per-device ring of 50 000 entries / 8 MiB, about
187
+
19 minutes of a polled oscilloscope and longer for meters, `bm_driver::wirelog`; reply chunks
188
+
joined in the UI, which shows the last 5000 lines). Auto / Text / Hex view, pause, clear, **Copy**:
189
+
paste-ready evidence with instrument, model, identify reply, link and app version, and **Save**:
190
+
the same for everything the server kept, as a text file (`bench/wire.ts`, `bench/WireConsole.tsx`).
191
+
Transports add their own events as info lines (`Transport::take_notes`), e.g. a USBTMC recovery:
192
+
a write that times out or stalls gets abort bulk-out/in, clear halts and a device clear, then one
193
+
more try, else an error telling the user to replug (`bm-transport` usbtmc.rs, usbtmc_proto.rs). Open state per panel in `localStorage` `benchmesh:consoles`.
189
194
190
195
Every control that changes the instrument waits for **confirmation**: after the request is sent it
191
196
pulses discreetly until the instrument's reported value (registry status, or a read-back for
192
197
setpoints) equals the requested one, and shows a small red dot if that does not happen within 6 s
193
198
(`kit/confirm.ts`). Pass the reported value, never a locally assumed one.
194
199
200
+
Drawer pages of text and controls use the shared page standard in `bench/bench.css`: content in
201
+
`.bench-page`(16 px inset, 14 px rhythm, `.bench-hint` text), boxes in `.bench-group`, rows in
202
+
`.bench-group__row`(About and feedback, Metrics, Remote access); `e2e/about-feedback.spec.ts` fails when a
203
+
drawer's content comes closer than 8 px to the drawer's sides. Buttons are kit buttons (`bench-btn`, `--primary` for
204
+
the main action, `--danger` for removal, `--icon` for a glyph), fields the kit field (`kit-field`, `kit-label`,
205
+
`kit-input`); the Instruments form styles its fields with the same tokens.
206
+
195
207
Adding a class panel: write `bench/panels/<Cls>Panel.tsx` from kit components, a `<cls>Profile()`
196
208
in `profiles.ts` (with tests against `bench/__tests__/bench-fixtures.json`, captured from the
197
209
simulated bench), and dispatch it in `InstrumentPanel.tsx`.
"description": "The UI (served by the embedded server on 127.0.0.1) opens the feedback and releases pages in the system browser by name (src/links.rs).",
0 commit comments