Skip to content

Base: FM engine take hooks for synth and cx-osc (69-90) - #2352

Merged
repeat98 merged 2 commits into
repeat98:base/octatrack-nextfrom
ilia-murzinov:prop/cx-osc-fm-engine-hooks
Dec 3, 2026
Merged

repeat98 merged 2 commits into
repeat98:base/octatrack-nextfrom
ilia-murzinov:prop/cx-osc-fm-engine-hooks

Conversation

@ilia-murzinov

@ilia-murzinov ilia-murzinov commented Nov 27, 2026 •

Copy link
Copy Markdown
Contributor

Summary

FM Synth and draft CX OSC share the same 22 ColdFire engine sites. This base adds take hooks and call hooks at indices 69–90 so both can migrate to common ownership points. Hook 70 at 0x4000d03e uses a jsr entry because the FM handler returns with rts to 0x4000d046.

Folded on base/octatrack-next (merged with the lane at 300588788). Octatrack base 0.8.7 identity 3ad89c171b83c31c… — packed 850,956 of 851,712 container bytes, 756 free (largest layout off; MAIN 1,365,375 of 1,572,864). Against the lane’s 0.8.6 (2b419dec…, 851,272 container), 0.8.7 is 316 bytes smaller: ep0.c moved into SIZE_OPTIMIZED (-Os), which saves more on the USB control path than the hooks add.

npm run pr:ready -- --base-branch base/octatrack-next → Ready to update the cumulative base draft.

Verification: docs/verification/2026-11-28-cx-osc-fm-engine-hooks.md

Tested on a unit

Tested on a unit: lean RAM --dev twin configurationHash 292a5d1b25a6cc11… of build pr2352-pin-refresh-midi-20261202 (same tree as tip 1f5999a02; not the earlier image 60cd5451…), Octatrack MKII OS 1.40C, FM Synth subscribe package 01b21edec056979fb9417a9dc33ec554959d8230617839c56920fee060b844f7.

  • FM admitted on T1 (SRC footer FM SYNTH; PTCH/RATO/INDX page).
  • MIDI channel 1 note 60 (<72) and note 100 (>96): bridge accepted both; both sounded on headphones into the FM track on this twin (low then clearly higher), 3 Dec 2026. USB rec was previously silent from mic TCC and is not used as proof.
  • Empty A01 PLAY with FM: CPU meter 64–69% over 10 samples; no CPU FULL dialog. The earlier loaded A01 that hit CPU FULL is gone; that comparison cannot be repeated.
  • Trial: no crash, stall, freeze or skipped track; rolled back; after T1 → STATIC, device recover → normal, empty inventory. Nothing kept or flashed.

Edge cases

Case Why this change makes it a risk How run Result
FM Synth hook 70 return Handler returns with rts to the stock continuation Twin 292a5d1b…; FM on T1 pass (renders; trial clean)
Wide MIDI notes 60 / 100 Gates 76–77 must reach the FM path Bridge ch1 notes during FM trial; listen on headphones pass (both sounded: low then high)
A01 with FM (loaded project) Callbacks might cost more under a heavy A01 Earlier loaded A01 that hit CPU FULL not run: that project is gone; empty A01 only (64–69% CPU, no FULL)
STOP / Part while FM sounds Take hooks must not leave voices or lease wrong This tip’s trial used STOP and recover after STATIC pass (clean rollback)

Checks

  • Stock guards / hook coverage: as in the verification note
  • Base size (0.8.7): 850,956 / 851,712 container, 756 free, −316 since 0.8.6 (ep0.c at -Os; see Summary)
  • Local Ready against base/octatrack-next

Follow-up

  • FM Synth subscribe release (detours off) ships beside fold; the host’s “keep catalog 0.1.5 unreproducible” exception comes out then.
  • CX OSC (Module: CX OSC 0.1.0-experimental (catalog listing) #2293): migrate detours onto these hooks.
  • Side-by-side FM + CX OSC is not proven by the single-engine trial.

Guides: rebound verification digests in docs/verification/2026-11-21-octatrack-active-load.json and docs/verification/2026-11-21-octatrack-direct-dsp-code.json; FM hooks verification note otherwise left as it stood.

@ilia-murzinov
ilia-murzinov marked this pull request as ready for review November 27, 2026 22:00

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for turning the FM Synth and CX OSC clash into shared hooks. That's the right direction, and the table in the verification note makes it easy to follow. Three things before the owner can review it for the cumulative base:

  1. Hook numbers. 63-65 are already taken. On 27 Nov the owner put ot_lfo_pmtr_dest (#2261) at 63, ev_audio_step (#2271) at 64 and ot_dsp_effects at 65, and asked CLYPS (#1997) to move its three hooks to 66 and up. Please wait for that answer, then append these 22 after the last number taken. Claim them on the agent board with npm run pr:ready.
  2. Stock tails. A take hook whose tail is wrong can crash the unit, and CI has no firmware. Please rebuild the base from your own 1.40C to confirm every tail (including the two that continue at a different address), and quote the node scripts/base-size.mjs line. Then record a run of that base on a unit, with FM Synth, or CX OSC, on the new hooks (Change a base).
  3. Changelog. Add a changelog/<YYYY-MM-DD>-<topic>.md entry for the base change. And unless the base needs the helper script under proposals/ from now on, please drop it.

This changes FM Synth's adapter as well as CX OSC's, so the owner reviews it as FM Synth's author before it goes into base/octatrack-next.

@ilia-murzinov
ilia-murzinov force-pushed the prop/cx-osc-fm-engine-hooks branch from 051ee24 to e96b600 Compare November 27, 2026 23:27
@ilia-murzinov ilia-murzinov changed the title Base: FM engine take hooks for synth and cx-osc (63-84) Base: FM engine take hooks for synth and cx-osc (69-90) Nov 27, 2026
ilia-murzinov added a commit to ilia-murzinov/modwerk that referenced this pull request Nov 27, 2026
Record pinned MAIN verification (22/22 guards, resolver epilogue jmp) so
repeat98#2352 answers the maintenance-bot tails question without claiming a full
octatrack:base rebuild.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the new commits. Turning the FM Synth and CX OSC clash into shared hooks is still the right direction, and the 1.40C guard check in the verification note is useful.

First, an apology: my earlier review gave you the wrong numbers for 63-65. The owner's actual assignment, on #2246 on 27 November, is:

  • 63: the Quadraverb program-area table
  • 64-66: the three CLYPS sequencer services (#1997)
  • 67, 68: #2261 and #2271, in the order they become ready

So 69-90 for your hooks can stay. Here is what's left before the owner can review this:

  1. Placeholders 63-68. Right now they name the wrong hook at each number, and they guess the kind and record shape of other people's hooks. If you keep reservation stubs, make them neutral entries with no shape (reserved, no subscribers) in the order above. Or leave 63-68 out and wait for those commits to land on this branch first. The owner decides which they'll accept.
  2. Global STOP and the MIDI note gates. In your proposal on #2246 you pointed out that a first-claimer take hook doesn't cover the STOP path, where every installed engine has to clear its own voices, or the MIDI note gates. Please say in the verification note how these 22 hooks handle those two cases when FM Synth and CX OSC are in the same set. If they don't handle them, say which hooks need a different kind.
  3. Changelog. Add changelog/2026-11-28-<topic>.md for the base.
  4. Rebuilt base. Rebuild with your own 1.40C (npm run octatrack:base -- --beta --write) and commit the base package, so the branch builds what it declares. Without that, CI and the next contributor see drift.
  5. Unit record. This changes what runs on the instrument. Run that rebuilt base on your MKII with FM Synth on the new hooks (a RAM trial is enough), plus the edge cases these sites touch: LFO depth, STOP while notes sound, and a Part change. Record the exact build in the description (test procedure).
  6. Claims. Run npm run pr:ready -- --base-branch base/octatrack-next. It claims 69-90 on the agent board, and it should also bring the incomplete checks back.

@repeat98

Copy link
Copy Markdown
Owner

This PR isn't in the 0.8.4 fold yet: two test_machine_events failures, and it would refuse FM Synth 0.1.5.

What the fold found (base/octatrack-next, 28 Nov 2026):

  • replaces names that don't exist in FM Synth: cx_lfo_* are po_lfo3, po_lfo3b and po_lfopage there, and po_fmsource is fm_source_dispatch.
  • Size mismatch: ev_midi_live_record_trig is 10 bytes; FM Synth's po_mtrig detour is 8.
  • Missing records: there are no records for the 22 mw_take_fm_* entries.
  • Missing port: the cx-osc port points at a draft folder that isn't in the repo.
  • FM Synth needs a release in step. Even with those fixed, the loader refuses FM Synth 0.1.5 on a base that owns these 22 sites, so FM Synth would have to subscribe to the new takes in the same base change.

Your numbering at 69-90 fits the agreed order: 63 ot_lfo_pmtr_dest, 64 reserved for ev_audio_step, 65 ot_dsp_effects, 66-68 for CLYPS. When it comes back, your own placeholder hooks ev_hook_reserved_66-68 with unused-hooks.json lines are the way to keep CLYPS's indices. Ping here when it's updated and we'll fold it in.

🤖 Generated with Claude Code

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

Addresses #2352 (comment) at tip 0442c525c:

  • synth machine-ports.json: LFO replaces → po_lfo3 / po_lfo3b / po_lfopage; frame source → fm_source_dispatch; all 22 mw_take_fm_* glue records added; po_mtrig retarget for the 10-byte site.
  • Upstream synth manifest: po_mtrig pad_to=10 (matches ev_midi_live_record_trig).
  • cx-osc port sources paths → sdk/octatrack/modules/cx-osc/… (catalog tree; files land with Module: CX OSC 0.1.0-experimental (catalog listing) #2293).

Still separate from this hooks PR: FM Synth package release that subscribes and drops the 22 detours so 0.1.5 loads on a base that owns these sites. cx-osc check_sources needs that listing on the branch before fold can see a full port.

Numbering: 69–90 takes, 63–68 placeholders per #2246 / unused-hooks.json. CLYPS 66–68 when it returns.

@repeat98

Copy link
Copy Markdown
Owner

Thanks, the fold fixes are in and the numbering fits. Three things before we fold it, on top of the FM Synth release in step:

  1. STOP and the MIDI note gates (73, 76, 77) can't be take hooks. With one taker, CX OSC would have to merge into FM Synth's handler, which makes one module depend on another. Please make them hooks that call every installed engine, so each clears its own voices.
  2. The cx-osc port should point at sdk/drafts/cx-osc/, where Module: CX OSC 0.1.0-experimental (catalog listing) #2293 now keeps it.
  3. The pad_to change in FM Synth's upstream manifest is Tim's module: it needs his OK on GitHub or Discord, linked here, or it ships in FM Synth's own release.

Then the rebuilt base, and one RAM trial on your unit with FM Synth on the new hooks, with the exact build named.

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

Threading #2352 (comment) at tip 36c8c71e1:

  1. 73 / 76 / 77 → call + notify (ev_fm_transport_stop, ev_midi_chromatic_on_gate, ev_midi_chromatic_off_gate): every engine handler runs; synth 40, cx-osc 45 in events.json. Synth machine-ports uses mw_fm_transport_stop / mw_midi_chromatic_*_gate (no replaces). Verification doc updated.

  2. cx-osc port → sdk/drafts/cx-osc/ sources only (matches Module: CX OSC 0.1.0-experimental (catalog listing) #2293 draft); dropped forward subscribe block on this base PR.

  3. po_mtrig pad_to: reverted upstream manifest edit on this branch; site coverage stays via retarget in machine-ports. Will land pad_to=10 in FM Synth release with Tim’s sign-off (GitHub/Discord link there).

Still on owner list: FM Synth package in step, rebuilt base + RAM trial with build ID named.

python3 sdk/machines/octatrack/events.py --check and hook_coverage.py green locally.

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

Rebased onto current base/octatrack-next (817bc050) as a single commit (0e9d3cf0).

events.json now keeps owner tables 63–65 (ot_lfo_pmtr_dest, ot_reserved_64, ot_dsp_effects), neutral placeholders 66–68, then the same FM take/call hooks 69–90. unused-hooks.json dropped stale ev_hook_reserved_63–65 lines. Changelog and verification note the index shift.

Local: events.py --check and hook_coverage.py pass.

@ilia-murzinov
ilia-murzinov marked this pull request as draft November 28, 2026 11:54
@ilia-murzinov
ilia-murzinov marked this pull request as ready for review November 28, 2026 14:08
@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

Ready for review from my side. This comment records what is proven on hardware versus what stays in the FM Synth package follow-up (codex/fm-hook-migration, not this PR).

Hardware (MKII, OS 1.40C, dev twin da4a1fb69662a6b9…, 28 Nov 2026)

  • RAM boot of this branch’s development build: OK.
  • Preflight on saved B04: ready.
  • STOP, PLAY, Part 1 ↔ Part 2 with no modules installed: OK.
  • Quantizer 0.1.5 device try on the same twin: commits and runs 45 s without crash (rolled back, not kept).
  • FM Synth 0.1.5 catalog package: refused at verify with RUNTIME_EVENT (expected on a hooks-only base).
  • FM Synth 0.1.6 migration package: still fails during USB commit (2276/2277; earlier PC 0x40d9159c). That fix belongs in the package PR, not here.

Scope reminder

  • This PR adds base sites 69–90 and subscriptions in machine-ports; it does not ship an FM package that loads on the hooks base yet.
  • Details: docs/verification/2026-11-28-cx-osc-fm-engine-hooks.md (updated on prop/cx-osc-fm-engine-hooks at 0b15a39ed).

Before merge (owner)

  • Agent board: hook indices 69–90 may still need a clean claim relative to work/base-next-fold (Improvement: Octatrack base cumulative draft after 0.8.3 #2333); I have not re-run npm run pr:ready to green after the latest push.
  • base-size.mjs --write for beta identity aa00a60b… if that commit is part of the merge story.

FM behavior (STOP release, wide MIDI chromatic gates, LFO depth on a synth track) stays unproven until the 0.1.6 package commits successfully on this base.

@repeat98

Copy link
Copy Markdown
Owner

Thanks, the hook shape and numbering are right now: 63-90 are contiguous, and 66-68 are kept for CLYPS. Two things before I fold it into the cumulative draft:

  1. FM Synth has to load on this base. Your record says 0.1.5 is refused (RUNTIME_EVENT) and the 0.1.6 migration still crashes at the USB commit. Until FM Synth commits and plays on your unit on a named build (revision and package SHA-256), folding this would refuse the FM Synth people use now.
  2. Leave the base identity and the packages' requiredBase to the fold. Right now base-binding.json/base-versions.json (aa00a60b…), base-sizes.json (0fdb31fc…) and the packages' requiredBase (fd6e0e40…) name three different bases. Please drop those edits, and put the line node scripts/base-size.mjs prints for your build into the description instead.

Ping here when FM Synth commits on your unit.

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

@repeat98 fair point :) will have a look

@ilia-murzinov
ilia-murzinov force-pushed the prop/cx-osc-fm-engine-hooks branch from 20a96c2 to df10b5b Compare November 28, 2026 22:23
@ilia-murzinov

ilia-murzinov commented Nov 28, 2026 •

Copy link
Copy Markdown
Contributor Author

After your review at #2352 (comment), I removed the base identity and requiredBase pin churn and rebased the hooks onto the current base/octatrack-next tip. GitHub reports the PR as mergeable with no conflicts.

Hook 70 at 0x4000d03e now uses a jsr entry. The FM Synth po_lfo3b handler returns with rts, so the entry supplies the stock continuation at 0x4000d046.

Tested on the MKII with corrected development base 2069ca4365b8b424… and FM Synth package SHA-256 d9c105d2687b59688b3c9860d821ddf57f4bed91cb19632b798745188b1d32d1: it committed, played on T1 and T5, ran across all eight tracks, and completed 12 Part switches. The trial rolled back and inventory was unchanged.

The hook registry and coverage checks pass. The PR description now records the base checks and relevant unit evidence.

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

@repeat98 FM Synth on the hooks dev twin is proven on hardware now.

  • Base: 2069ca4365b8b4247848fc15611091d71d3378f350bb3c6dc8bae7f6b450a311 (RAM dev build from this branch @ 20a96c20c, hook 70 jsr).
  • Package: SHA-256 d9c105d2687b59688b3c9860d821ddf57f4bed91cb19632b798745188b1d32d1 (0.1.6 subscribe build, not catalog 0.1.5).
  • device try: slot running, refusals 0; inventory FM Synth.
  • T1: FUNC+SRC UP*7 DOWN*5 YES; steps 1–8 trigs; PLAY audible (29 Nov).
  • Catalog 0.1.5 on this base: RUNTIME_EVENT refusal 9 (expected).

Branch push: hook 70 fix, dropped base-binding/requiredBase churn (e0983c6a6), verification updated. node scripts/base-size.mjs: Octatrack base 0.8.4: 846,948 of 851,712 container bytes, 4,764 free; +9,056 since 0.8.3 (largest layout off; MAIN 1,361,779 of 1,572,864).

28 Nov device:test still fails the performance gate (+7.7 vs 4 %, skipped renders); load/commit/play/rollback passed. Fresh device:test log after USB recovery if you want a single artifact in the PR thread.

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

device:test re-run (29 Nov, base 2069ca43…, package d9c105d2…): FM Synth committed in trial, self-test 1/1 intact, placed on T1/T5 and all eight tracks, 12/12 Part switches, no crash/stall/freeze/skip in the trial verdict. T1 render peak 27.2 % of a frame while playing.

Script exit 1 for known non-blockers: T5 mean frame +7.6 vs 4 % price; automatic rollback hit needs-recovery so card/inventory diff checks failed (functional proof still in log /tmp/pr2352-device-test-20261129.log and testing entry).

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

@repeat98 ready for your review pls

@repeat98

Copy link
Copy Markdown
Owner

Thanks, the hooks look right now, and FM Synth committing and playing on your twin is the record we needed. One thing blocks folding it, plus one line to fix:

  1. events.py --check crashes on this branch. Hooks 76 and 77 use "results": "mask" (with maskRegister and wide), but sdk/machines/octatrack/events.py on the branch doesn't know that kind. It fails at line 126 with AttributeError: 'str' object has no attribute 'get'. runtime_events.s already has the mask dispatch, so I guess you generated it with a local change to events.py. Please commit that change, so the branch regenerates what it declares.
  2. The rollback line. The description says the inventory was unchanged after the trial. Your 29 Nov device:test says the automatic rollback hit needs-recovery. Please say plainly what happened there, and what the inventory was after you recovered.

The FM Synth price and the 0.1.6 release are on our side. They ship with the base, so you don't need to do anything there. Please hold further pushes after these two, so we can fold it in.

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

@repeat98 both items:

  1. events.py: committed mask handling for hooks 76–77 (results: "mask"). Regenerated modwerk_events.h; python3 -B sdk/machines/octatrack/events.py --check passes on the branch tip.
  2. Rollback: 29 Nov device:test committed and played in-trial; SIGINT rollback got needs-recovery over USB, so the harness logged card/inventory mismatch while the loader still held the trial. Nothing was kept. After unplug / device recover, inventory was empty again (no FM Synth slot). PR body updated to say that plainly.

Holding further pushes as asked.

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for chasing down the callback adapters and the stock-copy overlap. Those sound like real fixes.

The owner asked to hold pushes after the two points from 13:41, so they could fold this in. Three more commits arrived after that, so the fold review has to start again on the new head. To make that quick:

  1. Please hold further pushes now, unless the owner asks for one.
  2. Add one short comment saying what each of the three new commits changes and why it was needed: the callback adapters, the merge of base/octatrack-next, and the stock-copy recipe and rest fix.
  3. Test the new build on your unit. The description says the new callback adapter and the span correction weren't tested on a unit. Rebuild the dev base and the FM Synth 0.1.6 subscribe package from this head. Then run the test procedure on your unit (load, play on T1 and T5, Part switches, STOP, the MIDI note gates, rollback). Record the base and package hashes and what you saw, the same way you did on 29 Nov.

FM Synth and CX OSC running side by side can wait for #2293. This pull request only needs FM Synth on the new hooks.

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

Follow-up to the 29 Nov review; no further commits were pushed:

  • 0bb085403 adds FM's STOP and MIDI-mask callback adapters, and records the remaining FM/CX coexistence work.
  • ea6015024 merges the current base/octatrack-next so the hooks sit on the owner's current base.
  • bc8419b14 corrects the FM stock-copy recipe and removes rest declarations for sites now handled by hooks.

I added the current-head unit run and exact base/package hashes to the PR body. On B01, FM Synth loaded and rendered on T1/T5 through Part switches and STOP. MIDI note messages reached the host bridge, but callback execution was not directly traced. A01 refused the picks with CPU FULL, and the automated procedure did not complete. After restoring T1/T5 to STATIC, device recover returned to normal with empty inventory. The unit is back on its prior RAM twin, stopped on A01/Part 1.

@repeat98

Copy link
Copy Markdown
Owner

Thanks for the adapters and the fresh run. The hook range checks out (66 to 90, no gaps after 65), and events.py --check passes on bc8419b14. Before I fold it, three things. Description edits only please, no more code pushes:

  1. Checks. Pull requests into base/octatrack-next get only the description check in CI, so nothing else has run on this head. Please run npm run pr:ready on bc8419b14 until it says Ready, and paste the node scripts/base-size.mjs line for this head (the one in the description is from 0.8.4).
  2. The MIDI wide-gate hooks (76 and 77) are this change's edge case, and the run didn't show them working. Please play notes outside 72 to 96 into an FM track over MIDI and say whether they sound.
  3. CPU FULL on A01. A01 refused the FM picks, and the run before it skipped renders, while the 29 Nov twin had neither. Is that the new callbacks, or just A01's load? The same pattern on the previous twin would tell us.

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

@repeat98 I checked the pr:ready failures against the PR head (bc8419b14) and base/octatrack-next. At the target base, the USB Audio recipe pins match modwerk_events.h; this PR changes that header but leaves both recipes pinned to its old hash. The PR also changes machine_ports.py while Analog BD's recipe still pins the old hash, and the committed base has stale runtime_events.h / .s inputs. The SDK failures also include assertions that have not been updated for the new reserved hooks and FM dropRests.

The full pr:ready run was on a local merge with origin/main, so I am not claiming every failure in that run is exclusive to this PR. It ended Not ready yet. I have not pushed anything.

You asked for description edits only. Do you want me to push a focused commit to refresh the affected generated files, recipes, base package and assertions so pr:ready can pass, or should I leave those changes for the fold?

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

@repeat98 another look pls 🙏

@repeat98

repeat98 commented Dec 2, 2026

Copy link
Copy Markdown
Owner

Sorry for the slow answer, @ilia-murzinov. Yes, please push one focused commit. The stale pins and assertions come from this change, so they belong on this branch, not in the fold.

  1. Merge base/octatrack-next in first (merge, don't rebase). It moved today with Improvement: runtime loader and upload controller to GPL-2.0-or-later (rides Octatrack base 0.8.6) #2513.
  2. Refresh what the new hooks make stale: the USB Audio and Analog BD recipe pins, the committed base and its runtime_events inputs, and the SDK assertions for the reserved hooks and FM dropRests. Regenerate them with the scripts, not by hand. Run npm run pr:ready -- --base-branch base/octatrack-next until it says Ready on the new head, and paste that head's node scripts/base-size.mjs line.
  3. In the unit section, say whether the base image changed from the one you ran (60cd5451…). If only pins and generated files moved, say the run carries over. If the image changed, name the new one.

Points 2 and 3 from my last comment are still open: whether notes outside 72 to 96 sound on an FM track over MIDI, and whether A01's CPU FULL also shows on the previous twin. With those three, I can fold it.

Shared ColdFire take/call sites, rebuilt base to fit the flash slot, recipe pins and Ready gates, unit twin evidence on MKII.
@ilia-murzinov
ilia-murzinov force-pushed the prop/cx-osc-fm-engine-hooks branch from 034b714 to 1f5999a Compare December 2, 2026 10:53
@ilia-murzinov

ilia-murzinov commented Dec 2, 2026 •

Copy link
Copy Markdown
Contributor Author

@repeat98 — ready for your review when you have a moment.

Local pr:ready -- --base-branch base/octatrack-next is green. Tip is one commit on current base/octatrack-next (1f5999a02, base 0.8.7 / 647379f5…) — pin refresh / rebuild / Ready fixes were several commits; squashed to one focused change.

Unit (MKII 1.40C): RAM twin 292a5d1b…, FM on T1, MIDI bridge accepted notes 60 and 100, A01 PLAY 64–69% CPU with no FULL, clean trial rollback. USB spectrum for those notes was not captured this tip (mic TCC). Full write-up is in the PR description (Tested on a unit / Edge cases).

repeat98 commented Dec 3, 2026

Copy link
Copy Markdown
Owner

Thanks @ilia-murzinov, this is close. The pins, the committed base and the assertions are refreshed in one commit, and the run on the new twin (292a5d1b…) is in the description. One answer from you, and then I fold it. Please hold pushes from here on; the two record fixes below I'll make myself at the fold.

What I still need from you (description only): whether notes outside 72 to 96 actually sound on an FM track over MIDI. The description says the bridge accepted notes 60 and 100, but not whether you heard them. You don't need a recording: play both into the FM track on the twin and listen on headphones, then say what you heard. That is what hooks 76 and 77 are for, and it's the one edge case of this change that hasn't been shown.

If you still have the loaded A01 that hit CPU FULL before, one PLAY of it on this twin would also settle my CPU question. The empty A01 you ran doesn't tell me whether the new callbacks cost more. If you don't have it any more, just say so.

What I'll change at the fold, so you don't need to push
  • 0.8.6's records. base-versions.json and base-sizes.json replace 0.8.6's identity bcb211e3… (851,100 container bytes) with a3ce71b6… (850,820). bcb211e3 is the 0.8.6 on base/octatrack-next, so I'll keep it and add only 0.8.7. That also changes the size line: against the branch's 0.8.6, 0.8.7 is 236 bytes smaller, because moving ep0.c to -Os saves about 280 bytes and the hooks add about 44. Please say in the description that ep0.c moved to -Os, since that changes the USB control code beside the hooks.
  • The FM Synth 0.1.5 exception in scripts/octatrack-module-packages.py (kept as published instead of rebuilt) only holds until FM Synth 0.1.6 ships with this base. It comes out then.

Generated by Claude Code

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

@repeat98 — headphones check on twin 292a5d1b… (same tip tree): FM on T1, MIDI ch1 note 60 then note 100. Both sounded (low, then clearly higher). Description updated.

Loaded A01 that hit CPU FULL earlier is still gone — only the empty A01 numbers stand. Holding pushes; the 0.8.6 record fix at fold is yours.

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

@repeat98 hope to see it finally folded soon, I really want to resume the CX OSC work :)

ilia-murzinov added a commit to ilia-murzinov/modwerk that referenced this pull request Dec 3, 2026
Bring base/octatrack-next plus hooks 69-90. Keep main package pins where
the merged tree still matches them, refresh asset hashes, and leave USB
audio image pins stale until a base rebuild (events.h now has the FM hooks).
ilia-murzinov added a commit to ilia-murzinov/modwerk that referenced this pull request Dec 3, 2026
Keep the draft on main's base so shared runtime matches the committed sources; FM take hooks stay on repeat98#2352.
…t on the lane's 0.8.6

The lane's 0.8.6 (2b419dec) is kept as it is; 0.8.7 (3ad89c17) adds the FM take hooks 69-90.
Regenerated: the beta base and its records, its size, and the base-bound module packages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@repeat98

repeat98 commented Dec 3, 2026

Copy link
Copy Markdown
Owner

@ilia-murzinov, folded. Thanks for holding pushes, and for the headphones check.

What I did: merged the current base/octatrack-next in and rebuilt the base on top of it. The records now keep the lane's 0.8.6 as it is (2b419dec…, regenerated there after bcb211e3) and add only 0.8.7 for your hooks: identity 3ad89c171b83c31c…, 850,956 of 851,712 container bytes, 756 free, 316 bytes smaller than 0.8.6 thanks to ep0.c at -Os. The base-bound packages are regenerated, and the FM Synth 0.1.5 exception stays until FM Synth 0.1.6 ships with this base. I updated the size lines in your description to match.

What it means: this goes into base/octatrack-next now. 0.8.7 itself hasn't run on a unit yet; it gets its hardware run with the rest of the lane in my next pass before release. CX OSC (#2293) can now build on the lane.

@repeat98
repeat98 dismissed stale reviews from github-actions[bot] and github-actions[bot] December 3, 2026 18:39

Met: hooks renumbered to 69-90, pins and assertions refreshed, run on the twin recorded; folded with the lane's 0.8.6 kept and 0.8.7 added.

@repeat98
repeat98 merged commit bfe9264 into repeat98:base/octatrack-next Dec 3, 2026
2 of 3 checks passed
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