Repository navigation
Conversation
A card build has no base events. sdk/machines/octatrack/card/trig_muted.inc names one meeting point, modwerk_card_ev_trig_muted: a mute module answers it from a DRAM unit, a machine asks it from a DRAM unit (a weak reference), and with either one missing the ask is 0 and nothing changes in what plays. Bits 0-7 are ev_trig_muted's answer; bits 8-15 name the tracks whose sounding note the mute ends (OTFX-T's note-off), which an engine that keeps its own notes needs. Host tests: the native DRAM link and the configurator's linker give the same bytes for every combination and refuse a second answer.
This branch has not been deployed
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.
SDK: a card-build counterpart of ev_trig_muted (#777)
@repeat98 @Zac-Kyoti, this is the SDK part of option 2 on #777: a meeting point where Mute Modes can answer and FM Synth can ask on a card build, with neither module reading the other's code or data. It changes no module and no card image.
What is in
sdk/machines/octatrack/card/trig_muted.inc(GNU as) defines one symbol,modwerk_card_ev_trig_muted.unsigned f(void)in the C convention and writes nothing. Bits 0-7 have the same meaning as inev_trig_muted: bit t means track t+1's new trigs are dropped now.MODWERK_CARD_ASK_TRIG_MUTED. It makes a weak reference to the answer and returns 0 when no module answers, so the machine plays every trig, as stock does.remix/platform_build.pyand in the configurator incoldfire-link.ts, so the two meet whatever the module order. ROM units can't take part: the native builder links them one at a time before the DRAM link, and the configurator links them after it.card/README.md, a line insdk/machines/octatrack/README.md, the muted-trigs item indocs/module-guides/machines.md, and the changelog entry.Tests
sdk/tests/test_card_trig_muted.pylinks an asking unit, an answering unit and a bystander unit with the native DRAM link (platform_build.link_runtime). It covers neither unit, asker only, answerer only, both, and both in the other order.events.json.src/engine/card-trig-muted.test.tslinks the same objects with the configurator's linker. It gives GNU's bytes and symbols in all five cases and refuses a second answer.npm run sdk:check: 568 tests OK.modules:generateleaves the tree unchanged.modules:check -- --base origin/mainandsdk:imports:checkpass. Innpm run pr:readyon f577d62 every stage passes except vitest, whose failures were timeouts on a loaded machine. Those test files pass when re-run under Node 24 with a long timeout (122 files, 1,115 tests).End to end, on prototypes that are not in this PR
I wrote local prototypes of both sides to check that the contract does the job:
I built them with the native exporter and ran them on ot_emu (MKI, DSP lockstep). T1 was FM SYNTH and T2 a FLEX sine with the same trigs, both muted mid-pattern:
T2, the plain sample, behaved the same in both images.
The image with both prototypes differs from the 0.1.4 + Mute Modes image in 3 ROM bytes (one detour target) plus the runtime. FM Synth alone with the ask differs from #1146's image in the same 3 bytes, and its ask loads 0.
One question before anyone builds on it
A DRAM unit reserves 1,707 pages (10,487,808 B) of the sample arena (
coldfire-runtime.ts:28). So a card build with Mute Modes but no other DRAM unit loses that much sample memory just to carry an answer nobody asks. Beside FM Synth, which already has a DRAM unit, the answer adds only its own bytes. Jannik, which would you prefer?Zac, thanks for agreeing on #777. Are you OK with the meaning of bits 8-15? On your STOP point: with both prototypes, a muted FM note at HOLD INF ends at STOP (the DT-T row above). FM Synth's ask comes as its own release after this lands, and nothing here changes 0.1.4.