Repository navigation
Octatrack base 0.8.5: IN USE, where a sync would be refused as in use, before it is sent - #2463
Merged
Merged
Conversation
…se, before it is sent A new read-only vendor request (0xC1, bRequest 44, wValue entry | how << 8, wLength 24; capability feature bit 14, in_use.h) asks, for one installed module and a removal or a same-module update, what the unit's own admission would refuse as RUNTIME_IN_USE (or RUNTIME_UI_OPEN): the effect's slots in the current Part, a removed contributed machine's Part copies (working and saved, per track), an open page, or a hold with no place to name (a resident controller, a table owner's consumer, a retirement that cannot plan, an unreadable Part copy). The ISR only notes the question and wakes the engine, which answers under the stable lock with the prepare's paused-task context; the host asks again until the reply is no longer PENDING, and BUSY while a transaction, trial, journal or export holds the loader. The answer calls the refusal's own predicates, now shared: dsp.c held_slots (modwerk_dsp_in_use), machine_contributor_held over machine_part_signature_where, table_metadata_held over consumers(), controller_board.c outgoing_held (modwerk_controller_in_use) and machine_admission_runtime.c ui_open; modwerk_machine_holds walks them in the admission's order. Host tests check the answer against the admission in each case. The resident dsp.c patch follows the new line numbers. The base is not regenerated here. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…r Part
On a base with capability feature bit 14 (0.8.5 on), a sync first reads INVENTORY and asks IN USE for
each module it removes or replaces (packageTarget reads the module and removal from the package
header). A finding stops the sync before any session opens, with what to do in the musician's words
("Track 3 runs Tape Echo as its FX2 effect, and this sync removes it. Pick another effect for FX2 on
Track 3, then sync again.", or the Part, its saved copy and track keeping a machine, or an open page).
No capability, BUSY, no answer or a failed read and the sync goes ahead exactly as before; the
post-refusal texts are untouched. OctatrackLink.whereInUse asks outside a sync, the pretend unit
answers request 44 (PENDING once, then its answer), and `npm run device -- inuse` (also a `do` step and
a read for the unit queue) prints each installed module's answer for a removal and an update.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The README says where the request is documented and which vendor numbers are taken; to keep it from growing, two paragraphs of the USB profile section drop history their linked evidence records keep. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…stion; the reply buffer is off the scanned stack Review fixes: the site asks again when the first reply is already ANSWERED (a question asked earlier and never read), and ep0.c keeps the 24-byte reply static so the machine checks' stack scan cannot read stale bytes as a hold. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
With IN USE the base packed to 851,872 bytes, 160 more than a flash slot holds. Both units run on the UI task only: part_menu.c from stock's three Part Edit openers and ev_key/ev_enc/ev_tick/ev_draw, midi_generators.c from its four UI sites (events.json ot_midi_generators), its key layers and the UI tick (mw_tick_hook -> mw_ui_tick -> mg_tick). Nothing from ep0, vendor, transfer, manager, status or the frame calls into them, and no caller holds the machine lock or mask. Their one masked stretch is a copy of a table of at most 7 or 16 rows (pm_entries, mg_generators), a loop no longer at -Os than at -O2. SIZE_OPTIMIZED's comment names the rule for them and the units that stay at -O2 (settings, diag, the sample editor, the LFO PMTR table). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…he base with IN USE IN USE and the size-built UI units moved the base symbols Analog BD's package links against (the controller write lease, cue_cfg_clamp, raise_ev_mute_keep), so its image changed and the reviewed recipe refused it. Captured with build.py --capture-stock-recipe against the empty-row build's symbols: only imageSha256 changes (0b8421fe -> 48ba77e8); its stock copies and source pins are the same. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
base ddb56b72d1ac0b60…, browser .bin 16126056… (849,940 bytes; 1,788 container bytes free, +1,472 since 0.8.4), with IN USE and part_menu.c and midi_generators.c built for size. The lease entries moved, so Sidechain 0.2.2, Output Matrix 0.1.1 and Analog BD 0.1.7 are rebound: they differ from a14144f5's packages only in their words for the four base symbols, and their trust rows follow. CC Map, Recorder Loop fix and USB Audio keep their bytes; every base-bound package takes the new requiredBase. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…packages Output Matrix, Analog BD and Sidechain Compressor are a14144f5's packages with only the base symbol words substituted (the controller write lease, cue_cfg_clamp, raise_ev_mute_keep), checked byte for byte, so their active-load readings are rebound to the new digests (resource-indicators.test.ts passes). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…ound package Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What was wrong or hard: 83 USB syncs on 42 units (31 Oct–30 Nov 2026) were refused because a track was using a module the sync changes or removes. The site could only explain the refusal afterwards, and people retried while hunting for the track.
What this changes:
modwerk_dsp_in_use,machine_contributor_held,machine_part_signature_where,table_metadata_held,modwerk_controller_in_use,ui_open,modwerk_machine_holds), so it cannot disagree with a refusal.npm run device -- inusereads it.part_menu.candmidi_generators.care built for size: UI-task only. Each holds the machine mask once for a table copy of at most 16 rows, the same length at -Os, andSIZE_OPTIMIZED's comment names this exception. Base 0.8.5 is 849,924 of 851,712 bytes (1,788 free).ddb56b72. Analog BD's reviewed recipe was recaptured. Sidechain, Output Matrix and Analog BD were rebound, with only the four moved base symbols changed. Other base-bound packages take the newrequiredBase.How I checked it:
npm run pr:ready -- --base-branch base/octatrack-next. Host tests check that the query and the admission agree for each refusal path (effects FX1/FX2, Part copies in RAM and SRAM mirrors, open pages, Analog BD, controllers), plus the wire format (malformed, pending, answer once, stale answers). There is an m68k compile under -Werror and the sdk recipe, base-bound, runtime-loader and codegen suites. A separate safety review found every refusal path unchanged; its two findings (a leftover answer taken for a new question, the reply buffer on the scanned stack) are fixed with a test.Tested on a unit: owner's MKII, 30 Nov 2026, development twin
ad5835d6(the--devbuild ofddb56b72, without--stream-channel), with Tape Echo 0.1.9 and FM Synth 0.1.5 kept on the twin, on a scrap project. The site was driven through the developer tool service with this branch'sOctatrackLink. The twin advertises feature bit 14 (features 32647). Since this start: 0 DSP stalls, 0 loader errors.freefor both modules, removed and updated.{refusal 7, slots [T3 FX2]}for removed and updated. The sync stopped before sending: "Track 3 runs Tape Echo as its FX2 effect, and this sync removes it. Pick another effect for FX2 on Track 3, then sync again. Nothing was sent." The set was unchanged.{refusal 7, parts [PART 2 T5]}, updatedfree. The sync stopped: "FM Synth is still the machine on Track 5 in Part 2 of this bank, and this sync removes it. Give that track another machine and save Part 2, then sync again. Nothing was sent."free, the same sync goes through to a trial, and Undo verified it ("back to how it was").Edge cases:
SIZE_OPTIMIZED's comment states the masked-copy exception.🤖 Generated with Claude Code