Skip to content

Improvement: the Digitone II link client in the site's engine (read-only) - #1823

Merged
prodbysmolec merged 4 commits into
repeat98:mainfrom
prodbysmolec:improve/digitone-ii-link-client
Nov 20, 2026
Merged

prodbysmolec merged 4 commits into
repeat98:mainfrom
prodbysmolec:improve/digitone-ii-link-client

Conversation

@prodbysmolec

@prodbysmolec prodbysmolec commented Nov 20, 2026 •

Copy link
Copy Markdown
Collaborator
  • What was wrong or hard: The Digitone II development link answers on a unit (Machine: Digitone II development link, stage one (read-only diagnostics over USB MIDI) #1763, Machine: Digitone II diagnostics log, the Octatrack's layout, over the development link #1820), but only a Python host could talk to it. The machine page, the diagnostics upload and the device tools (pieces 4 and 7 of the Digitone II goal) need it in the site's engine.
  • What this changes: src/engine/elektron/dn2-link.ts, read-only: the link's requests and replies in the Analog Rytm MKII link's wire format over any SysEx line (LinkLine, as os-upgrade.ts's), ident, mem, screen (stock's frame pointer, then the 128x64 frame in eight reads) and readLog, which reads the diagnostics log through diag and mem and parses it with the site's parseDeviceLog. No keys, turns or RAM boot from the site. Tests run it against a simulated unit that answers as link.c does, with a log laid out as the unit kept it on 19 November (a START, then a FREEZE of 9,050 frames after FLTR). A changelog entry. No page uses it yet.
  • How I checked it: npm run pr:ready (Ready, after merging current main); the tests above; the run on a unit below. The wire format and the reads are the ones dn2_link.py used on my unit (Machine: Digitone II development link, stage one (read-only diagnostics over USB MIDI) #1763, Machine: Digitone II diagnostics log, the Octatrack's layout, over the development link #1820's records).
  • Tested on a unit: 20 November 2026, my Digitone II on a development base with the link (RAM-booted research build, link version 1), over USB MIDI from Node (@julusian/midi through scripts/zoom-device.ts's nodeMidiAccess), with this PR's dn2-link.ts byte for byte: ident (version 1, armed, no person, boot status 1, no drops), mem of SRAM 0x800053a4 (8 bytes), screen (64 rows of 128 pixels, the page header readable as text) and readLog (6,148 bytes, parsed: version 2, boot 1, load records every 5 minutes). No page calls it yet.
    Edge cases: none, because this adds read-only TypeScript to the site's engine; nothing that runs on a unit changes.
  • What the guides lacked or got wrong, and where I fixed it: nothing.

🤖 Generated with Claude Code

ident, mem, the screen and the diagnostics log over any SysEx line, in the Rytm link's wire format; the log reads
with parseDeviceLog. Tested against a simulated unit answering as link.c does.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added the enhancement New feature or request label Nov 20, 2026
@repeat98

Copy link
Copy Markdown
Owner

Please reject incomplete replies before returning screen or diagnostics data. mem() drops the echoed address and accepts any number of decoded bytes. The read loop advances by the requested length, so a short reply leaves zeroes in the returned log or screen. A short identity reply can likewise resolve with missing fields.

Please check the echoed address, the exact requested byte count, and the mandatory identity fields. Tests for a short chunk and a reply for the wrong address would cover the cases the simulated unit currently misses.

@prodbysmolec
prodbysmolec merged commit 6bbb950 into repeat98:main Nov 20, 2026
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants