Skip to content

Base: rest unused FM take hooks on the frame path - #2603

Merged
repeat98 merged 6 commits into
repeat98:base/octatrack-nextfrom
ilia-murzinov:fix/fm-take-events-rest
Dec 4, 2026
Merged

repeat98 merged 6 commits into
repeat98:base/octatrack-nextfrom
ilia-murzinov:fix/fm-take-events-rest

Conversation

@ilia-murzinov

@ilia-murzinov ilia-murzinov commented Dec 4, 2026 •

Copy link
Copy Markdown
Contributor

Summary

  • Allow call or take hooks to declare rests in events.json (loader already drops resting modules from those rows; empty take sites run stock).
  • Mark the seven FM frame-path hooks rests: true (LFO depth / frame LFO, release, STOP, retrig, kill, frame source) so an unused take-only machine such as CX OSC leaves them.
  • Regenerated HOOKS.md, runtime_events.h, modwerk_events.h; updated the site-event rest test.

What was wrong or hard

On twin 292a5d1b, CX OSC installed and unused added +20.4 frame points on a medium pattern (stock 82.5% to 105%). Take hooks could not declare rests; only Detours could, so a subscribe-only machine stayed in the frame rows.

What this changes

Take hooks may rest. The seven FM frame-path takes do. UI/MIDI/page takes stay awake.

How I checked it

  • python3 -B sdk/machines/octatrack/events.py --check
  • SiteEventTests.test_modules_rest_out_of_the_per_frame_events_only
  • Twin fm-take-rest-midi-20261204 from tip 7c329fd6f, RAM identity 3dfbce8a…
  • CX OSC 24712ac8… device:price --write --curve T1,T3,T6,T7 on MKII OS 1.40C bank A A01 medium / A02 empty (at rest +0)
  • FM Synth subscribe 01b21ede… at-rest on the same twin (+14.7; see edge case)
  • npm run pr:ready against base/octatrack-next

Tested on a unit: base 3dfbce8a59b70570, MKII OS 1.40C, RAM twin of tip 7c329fd (fm-take-rest-midi-20261204; same rests as committed base 23b620d59b5e1566). CX OSC 24712ac8509ece68 at rest frame +0 (was +20.4). See docs/verification/2026-12-04-fm-take-events-rest.md.

Edge cases

Case Why this change makes it a risk How run Result
Unused take-only machine still taxes the frame Rests on takes are new; wrong mark would leave +20 pts device:price at-rest for CX OSC (no ev_in_use; base judges) on this tip pass: +0
First playing instance still costs Resting must not strip work while the machine is in use same CX curve on A01 medium pass: first +20.2
FM Synth with its own ev_in_use Synth answers fm_in_use (sweeps banks/FLEX/GLIDE); take rests only drop it when that answers 0 subscribe synth 01b21ede at-rest; bank A Parts all STATIC; catalog Detour package refused RUNTIME_EVENT pass: take rests not at issue; Synth stayed +14.7 under its own in_use on this card
Empty take site after rest Loader must run stock when no subscriber is awake SiteEventTests.test_modules_rest_out_of_the_per_frame_events_only pass

Guides

Added docs/verification/2026-12-04-fm-take-events-rest.md with the unit remasures. HOOKS / events.py already say take hooks may rest after this change.

Related: #2293 (CX OSC listing; release-cost waiver asked for the remaining 101.5% first-instance gate).

Take-only machines such as CX OSC stayed in the LFO and frame-source rows
while unused (~+20 frame points). Allow take events to rest and mark the
seven FM frame-path hooks so idle machines leave those rows.
@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

Unit remasure for the rest claim (also asked on #2293 for a release-cost waiver on the remaining 101.5 % first-instance gate):

  • Twin of this tip: /Users/iliamurzinov/modwerk-builds/fm-take-rest-midi-20261204 → base 3dfbce8a…
  • CX OSC 24712ac8… on MKII OS 1.40C, A01 medium / A02 empty
  • at rest frame +0 (was +20.4 on 292a5d1b without these rests)
  • first medium instance still 101.5 %; that is a module cost, not a rest miss

Verification note landing in this PR next.

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

FM Synth remasure on the same twin (3dfbce8a…), subscribe package 01b21ede… (catalog Detour package refuses RUNTIME_EVENT on this tip):

  • at rest frame +14.7, cpu +9 (rolled back clean)
  • bank A Parts 1–4 were all STATIC when measured
  • CX on the same twin was +0

So take-hook rests clear CX; they do not bring subscribe FM Synth to ~0 on this card/package. Edge case in the description is marked fail. Verification note updated.

@repeat98

repeat98 commented Dec 4, 2026

Copy link
Copy Markdown
Owner

@ilia-murzinov Thanks for the measuring. I think FM Synth really needs a complete rewrite at this point

@ilia-murzinov

Copy link
Copy Markdown
Contributor Author

@repeat98 would it be a blocker for CX?

@repeat98
repeat98 merged commit fa89afa into repeat98:base/octatrack-next Dec 4, 2026
3 checks passed
@repeat98

repeat98 commented Dec 4, 2026

Copy link
Copy Markdown
Owner

@ilia-murzinov No, it's not a blocker. CX OSC is its own module on hooks 69–90, and an FM Synth rewrite would be FM Synth's own work, so CX OSC goes ahead without waiting for it.

I've merged this into base/octatrack-next, so an unused take-only machine now leaves those seven rows. It ships with the next cumulative base after my unit run of that lane. I've answered the waiver on #2293.

ilia-murzinov added a commit to ilia-murzinov/modwerk that referenced this pull request Dec 4, 2026
ilia-murzinov added a commit to ilia-murzinov/modwerk that referenced this pull request Dec 4, 2026
Owner comment 7419779189 waives release-cost for 0.1.0-experimental
(first medium instance 101.5 %, at-rest +0 on take-rest base repeat98#2603).
Drop the premature qualification record so the approval can cover the
cost gate the same way UNGEMACH and Grain do.
ilia-murzinov added a commit to ilia-murzinov/modwerk that referenced this pull request Dec 4, 2026
Restore every non-CX path from origin/base/octatrack-next so repeat98#2293
only adds the CX OSC listing, Dec 4 frame-cost evidence, and the
owner release-cost waiver on top of take-rest base repeat98#2603.
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