Skip to content

synthio: support running status in MidiTrack - #11659

Merged
dhalbert merged 1 commit into
mainfrom
synthio-miditrack-running-status
Oct 24, 2026
Merged

dhalbert merged 1 commit into
mainfrom
synthio-miditrack-running-status

Conversation

@tyeth

@tyeth tyeth commented Oct 23, 2026

Copy link
Copy Markdown
Member

Second of five stacked PRs; targets the branch of #11658, review that first.

A MIDI file may omit the status byte when it repeats the previous one, so a run of notes on the same channel is encoded as data bytes alone. The decoder read each of those as a status byte, took the invalid-event branch and ended the track.

Remember the last channel status byte and imply it when the next event begins with a data byte. System messages cancel it, as the specification requires.

Verification

Cross-checked against adafruit_midi_parser on a hand-built running-status file: the new decoder reproduces its note timeline exactly, the old one returned nothing. Builds clean on arm and xtensa.

Size

About +128 bytes of flash on nrf52840, plus one byte per MidiTrack object.

🤖 Generated with Claude Code

@tyeth
tyeth added this pull request to stack #11668 October 23, 2026 22:57
Base automatically changed from synthio-miditrack-meta-events to main October 24, 2026 12:29
A MIDI file may omit the status byte when it repeats the previous one, so
a run of notes on the same channel is encoded as data bytes alone. The
decoder read each of those as a status byte, took the invalid-event branch
and ended the track.

Remember the last channel status byte and imply it when the next event
begins with a data byte. System messages cancel it, as the specification
requires.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@dhalbert
dhalbert force-pushed the synthio-miditrack-running-status branch from 3d0ba77 to ff05e5b Compare October 24, 2026 12:29
@dhalbert
dhalbert merged commit bdef3c5 into main Oct 24, 2026
3 of 4 checks passed
@dhalbert
dhalbert deleted the synthio-miditrack-running-status branch October 24, 2026 12:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants