From 8f401173b7c4467fab5230953672f9dd4516c431 Mon Sep 17 00:00:00 2001 From: Takuhito-bit <364694452+Takuhito-bit@users.noreply.github.com> Date: Fri, 4 Dec 2026 18:28:05 +0900 Subject: [PATCH 1/9] Master Thru draft: THRU's controls on the master's PLAYBACK page With MASTER TRACK on, stock leaves T8's PLAYBACK page empty. One detour in the page selector returns a page built from the unit's own THRU page, with PAN in THRU's two empty slots and the three knobs of each pair linked. Tried on an MKI (TESTING.md). The DSP part waits on base support (#2602). Co-Authored-By: Claude Opus 5.5 --- sdk/drafts/master-thru/LICENSE | 30 ++++ sdk/drafts/master-thru/README.md | 41 ++++++ sdk/drafts/master-thru/TESTING.md | 27 ++++ sdk/drafts/master-thru/manifest.py | 34 +++++ sdk/drafts/master-thru/octamod.module.json | 132 ++++++++++++++++++ .../master-thru/qualification.example.json | 84 +++++++++++ .../master-thru/resource-impact.example.json | 21 +++ sdk/drafts/master-thru/unit.s | 116 +++++++++++++++ sdk/drafts/master-thru/verify.py | 19 +++ 9 files changed, 504 insertions(+) create mode 100644 sdk/drafts/master-thru/LICENSE create mode 100644 sdk/drafts/master-thru/README.md create mode 100644 sdk/drafts/master-thru/TESTING.md create mode 100644 sdk/drafts/master-thru/manifest.py create mode 100644 sdk/drafts/master-thru/octamod.module.json create mode 100644 sdk/drafts/master-thru/qualification.example.json create mode 100644 sdk/drafts/master-thru/resource-impact.example.json create mode 100644 sdk/drafts/master-thru/unit.s create mode 100644 sdk/drafts/master-thru/verify.py diff --git a/sdk/drafts/master-thru/LICENSE b/sdk/drafts/master-thru/LICENSE new file mode 100644 index 0000000000..6274d5d007 --- /dev/null +++ b/sdk/drafts/master-thru/LICENSE @@ -0,0 +1,30 @@ +MIT License + +Copyright (c) 2026 takuhito-bit + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. + +--- + +This licence covers this module's own source code and documentation only. It +does not extend to any Elektron Music Machines firmware, which is not +distributed here and remains the property of its copyright holder. Nothing in +this module is endorsed by, supported by, or affiliated with Elektron. +Octatrack and Elektron are trademarks of Elektron Music Machines MAV AB, used +only to identify the hardware this module targets. diff --git a/sdk/drafts/master-thru/README.md b/sdk/drafts/master-thru/README.md new file mode 100644 index 0000000000..6a5380c6a8 --- /dev/null +++ b/sdk/drafts/master-thru/README.md @@ -0,0 +1,41 @@ +# Master Thru + +Version: 0.1.0-experimental · author: @takuhito-bit + +## Overview + +With MASTER TRACK on, track 8 is the master: it hears tracks 1–7 and the DIR inputs, and stock leaves its PLAYBACK page empty. Master Thru puts THRU's controls there, so the live inputs can join the master's mix at their own level and pan, before T8's AMP, FX1 and FX2, with locks, LFOs and scenes, and without spending a track on a THRU machine. A THRU machine on any other track works as before. + +**Prototype status.** The page is built and works on an MKI (TESTING.md). The sound part, a DSP engine on the `dsp_track_source` chain that adds the inputs to the master's mix, needs base support first ([#2602](https://github.com/repeat98/modwerk/issues/2602)). Until then the controls change nothing you hear. + +## Controls + +T8's PLAYBACK page while T8 is the master. The page is stock's THRU page, so INAB, VOL, INCD and VOL look, read and edit as on a THRU track; PAN fills THRU's two empty slots. + +| Knob | Name | Values | What it does | +| --- | --- | --- | --- | +| A | INAB | –, A, B, A+B, A B | Inputs A/B: off, A, B, A+B (their mono sum) or A B (stereo, A left). Starts off. | +| B | VOL | -64..+63 | Their level, as THRU's VOL. | +| C | PAN | -64..+63 | Where a mono A, B or A+B sits; the balance for the stereo A B. 0 is centre, both sides at unity, as AMP's BAL. | +| D | INCD | –, C, D, C+D, C D | Inputs C/D, as INAB. Starts off. | +| E | VOL | -64..+63 | Their level. | +| F | PAN | -64..+63 | Their pan or balance. | + +INAB > VOL > PAN and INCD > VOL > PAN are linked by stock's arrows. + +## How to reach it + +1. PROJECT > CONTROL > AUDIO: turn MASTER TRACK on. +2. Select track 8 and press PLAYBACK (SRC on an MKII). + +## Changes to stock flows + +- **T8's PLAYBACK page with MASTER TRACK on.** Stock shows nothing; with the module installed it shows the page above. Why: the master has no other page for its source, and a musician looks for THRU's controls there. Only while the module is installed; removing it brings stock's empty page back. Every other track, and T8 with MASTER TRACK off, take stock's path unchanged (the detour replays the stock instruction for them). + +## How it works + +One detour at 0x40031e6a, in stock's page selector (0x40031e08): for the master it returns this module's page, built once from the unit's own THRU page (unit.s). Nothing runs per frame. The page's values reach the DSP as every track's PLAYBACK values do. + +## Compatibility + +Declares `screen:MASTER PLAYBACK`. Nothing else in the base or the library patches the selector. diff --git a/sdk/drafts/master-thru/TESTING.md b/sdk/drafts/master-thru/TESTING.md new file mode 100644 index 0000000000..271a6c7597 --- /dev/null +++ b/sdk/drafts/master-thru/TESTING.md @@ -0,0 +1,27 @@ +# Master Thru testing + +Record what you ran, on which build and which unit, and what you saw. "Not tested" is a valid answer; never write a result you did not observe, and keep emulator runs apart from hardware ones. + +## On the unit + +**4 December 2026, MKI, OS 1.40C, base `ddb56b72`, prototype trial `a48f2bce` (the page only), RAM trial over USB, rolled back.** Reported by the developer (@takuhito-bit) from the unit's screen: + +- With MASTER TRACK on, T8 → PLAYBACK opens the page (stock shows nothing there). +- INAB and INCD read as on a THRU track; the controls are named INAB, VOL, PAN, INCD, VOL, PAN, inside their frames. +- INAB > VOL > PAN and INCD > VOL > PAN are linked by stock's arrows. +- VOL and PAN show -64..+63 with 0 at the centre, as AMP's BAL. +- The knobs change their values, and a trig held while turning one takes a lock. + +The trial's log: no crash, stall, freeze or skipped track (`device.mjs try` verdict). + +An earlier trial the same day (`9f8e33d6`, built on FLEX's page) opened the page with numbers for INAB and names that crowded their frames; that is why the page is now THRU's. + +Not tested: T1–T7's PLAYBACK pages and T8's with MASTER TRACK off under this build (the detour returns stock's path for them), LFOs on these slots, scenes, saving and reloading a project, the sound (no DSP part yet). + +## Stock flows + +Not tested beyond the above. + +## Performance + +Not measured. The page is built once, on the first PLAYBACK press on the master; nothing runs per frame. diff --git a/sdk/drafts/master-thru/manifest.py b/sdk/drafts/master-thru/manifest.py new file mode 100644 index 0000000000..1f8093d74e --- /dev/null +++ b/sdk/drafts/master-thru/manifest.py @@ -0,0 +1,34 @@ +"""MASTER THRU -- THRU's controls on T8's PLAYBACK page while T8 is the master. + +Prototype, part 1 of 2: the page only. With MASTER TRACK on, stock's page +selector (0x40031e08) gives track 8's PLAYBACK page the empty descriptor +0x400d2e8a, so PLAYBACK shows nothing. One detour at 0x40031e6a returns this +module's page instead: INAB, VOL, PAN, INCD, VOL, PAN, built at run time +from the unit's own FLEX page (unit.s). No other track and no other page +changes. Part 2, the DSP engine that adds the inputs to the master's mix at +the dsp_track_source chain (site 5), waits on base support (issue #2602). + +Inferred from OS 1.40C, not yet seen on a unit: that this selector is the +one PLAYBACK uses for the master, and that the page's values reach the DSP +(0x4000d63c converts all eight tracks' live lanes with MASTER TRACK on). +""" + +from remix.schema import Category, Proof, Detour, Gate, Kind, Linked, Module +from remix.stock_guard import stock_guard + +MODULE = Module( + name="master-thru", + key="MASTER THRU", + kind=Kind.CF_PATCH, + doc="T8 as the master: THRU's INAB/VOL/PAN and INCD/VOL/PAN on its PLAYBACK page.", + category=Category.MACHINES, author="takuhito-bit", author_url="https://github.com/takuhito-bit", + proof=Proof.UNTESTED, proof_note="Prototype: the page only; not yet tried on a unit.", + linked=( + Linked("unit", "modules/master-thru/unit.s", dram=True), + ), + detours=( + Detour(0x40031E6A, stock_guard(0x40031e6a, 6, "64885133d7843d50aa58773c2314b3cd8eeacb58d768fe12f3d57c0b0c9af831"), + "unit", "mt_pb", "the master's PLAYBACK page: this module's instead of stock's empty one", kind="jmp"), + ), + gates=(Gate("modules/master-thru/verify.py", remix_arg=False),), +) diff --git a/sdk/drafts/master-thru/octamod.module.json b/sdk/drafts/master-thru/octamod.module.json new file mode 100644 index 0000000000..0a615d0dea --- /dev/null +++ b/sdk/drafts/master-thru/octamod.module.json @@ -0,0 +1,132 @@ +{ + "schemaVersion": 2, + "id": "master-thru", + "key": "MASTER THRU", + "name": "Master Thru", + "version": "0.1.0-experimental", + "category": "machines", + "author": { + "github": "takuhito-bit", + "credits": [ + "takuhito-bit" + ] + }, + "nativeManifest": "manifest.py", + "presentation": { + "label": "INPUT", + "family": "Input", + "summary": "With MASTER TRACK on, T8's empty PLAYBACK page gets THRU's controls, so the live inputs join the master without spending a track on THRU.", + "overview": "The master (T8) hears T1-T7 and DIR. Master Thru adds inputs A/B and C/D at their own level and pan before T8's AMP, FX1 and FX2, with locks, LFOs and scenes like any PLAYBACK control. Prototype: the page only; the sound part waits on base support (issue #2602).", + "highlights": [ + "THRU's own INAB, VOL, INCD and VOL on the master's PLAYBACK page, plus a PAN for each pair", + "INAB > VOL > PAN and INCD > VOL > PAN linked by stock's arrows", + "INAB and INCD start off: installing it changes nothing until you pick an input" + ], + "usage": [ + "Turn MASTER TRACK on (PROJECT > CONTROL > AUDIO), select T8 and press PLAYBACK." + ] + }, + "controls": [ + { + "name": "INAB", + "default": 0, + "count": 5, + "doc": "Inputs A/B, as THRU shows them: off, A, B, A+B (mono sum) or A B (stereo, A left).", + "labels": null + }, + { + "name": "VOL AB", + "default": 64, + "count": 128, + "doc": "Level of inputs A/B in the master, -64..+63 as THRU's VOL; 0 is unity. Shown as VOL.", + "labels": null + }, + { + "name": "PAN AB", + "default": 64, + "count": 128, + "doc": "Where a mono A, B or A+B sits; the balance for the stereo A B. -64..+63 as AMP's BAL; 0 is centre, unity on both sides. Shown as PAN.", + "labels": null + }, + { + "name": "INCD", + "default": 0, + "count": 5, + "doc": "Inputs C/D, as THRU shows them: off, C, D, C+D (mono sum) or C D (stereo, C left).", + "labels": null + }, + { + "name": "VOL CD", + "default": 64, + "count": 128, + "doc": "Level of inputs C/D in the master, as VOL AB. Shown as VOL.", + "labels": null + }, + { + "name": "PAN CD", + "default": 64, + "count": 128, + "doc": "Where a mono C, D or C+D sits; the balance for the stereo C D. Shown as PAN.", + "labels": null + } + ], + "compatibility": { + "firmware": "1.40C", + "effectId": null, + "location": "Track machine", + "conflicts": [], + "uiClaims": [ + "screen:MASTER PLAYBACK" + ], + "limitations": [ + "Prototype: the page only. The inputs are not added to the sound until the DSP part lands with base support (issue #2602).", + "Not tried on a unit yet." + ] + }, + "resources": { + "recorded": "Not measured", + "storage": { + "label": "Storage", + "display": "Not measured", + "value": null, + "unit": "unknown", + "method": "unmeasured", + "conditions": "No measurements exist yet. Add exact conditions and source evidence when available.", + "source": "TESTING.md" + }, + "processing": { + "label": "CPU / DSP load", + "display": "Not measured", + "value": null, + "unit": "unknown", + "method": "unmeasured", + "conditions": "No measurements exist yet. Add exact conditions and source evidence when available.", + "source": "TESTING.md" + } + }, + "tests": { + "report": "TESTING.md", + "summary": "No tests have been run. Add tests.qualification with worst-case cycles, exact memory and attributed owner-reviewed hardware evidence before submitting. This scaffold cannot pass publication checks.", + "hardwareStatus": "untested", + "evidenceRevision": "b8deefc88b2c3e5f3c6158e364eb741df1924e1d", + "gates": [ + "Worst-case cycles under parameter modulation and maximum load", + "Exact memory region and maximum-instance totals", + "Owner-reviewed real-hardware evidence with actual coverage and limitations" + ] + }, + "license": { + "spdx": "MIT", + "file": "LICENSE", + "declaration": "Replace with accurate authorship, attribution and original/licensed source and media rights. Never include Elektron firmware, extracted routines or tables." + }, + "media": [], + "access": { + "location": "T8's PLAYBACK page while T8 is the master.", + "steps": [ + "PROJECT > CONTROL > AUDIO: turn MASTER TRACK on.", + "Select track 8 and press PLAYBACK (SRC on an MKII)." + ], + "screenshots": [] + } +} diff --git a/sdk/drafts/master-thru/qualification.example.json b/sdk/drafts/master-thru/qualification.example.json new file mode 100644 index 0000000000..f24ba06cd4 --- /dev/null +++ b/sdk/drafts/master-thru/qualification.example.json @@ -0,0 +1,84 @@ +{ + "moduleVersion": "0.1.0", + "sourceSha256": "REPLACE_WITH_NATIVE_SOURCE_SHA256", + "imageSha256": "REPLACE_WITH_LOCAL_TESTED_IMAGE_SHA256", + "cycles": [ + { + "processor": "dsp", + "worstCase": null, + "maxConfiguration": null, + "maxInstances": null, + "budget": null, + "unit": "cycles/sample", + "method": "emulator", + "conditions": { + "parameterExtremes": "Describe every minimum, maximum and branch boundary tested.", + "parameterModulation": "Describe simultaneous LFOs, p-locks, MIDI CC and scene sweeps; justify each inapplicable mechanism.", + "modeSwitching": "Describe repeated/interrupted mode, bypass and Part changes.", + "maxLoad": "Describe maximum voices/instances, both cores, FX slots, streaming and USB/MIDI load.", + "inputConditions": "Describe silence, impulses, full-scale inputs, feedback and other worst-case signal conditions." + }, + "report": "TESTING.md" + } + ], + "memory": { + "regions": [ + { + "name": "Replace with each code, state, table, buffer, stack/heap and padding allocation", + "space": "dsp-p", + "words": null, + "wordBits": 24, + "bytes": null, + "scope": "shared" + } + ], + "perInstanceBytes": null, + "sharedBytes": null, + "maxInstances": null, + "totalBytes": null, + "conditions": "State exact build options, alignment, accounting convention, allocator/stack bounds and reused stock/shared memory; justify every absent allocation class.", + "report": "TESTING.md" + }, + "hardware": { + "status": "pending", + "model": "MKII", + "testedOn": "YYYY-MM-DD", + "tester": "Your credited tester handle; no email", + "project": { + "name": "Your local stress project", + "sha256": "REPLACE_WITH_PROJECT_FINGERPRINT", + "recipe": "Record generator/tool revision and command, local source template fingerprint, sample recipe, all settings and modifications needed to reproduce this stress project. Keep the project/card/firmware local." + }, + "durationMinutes": null, + "audioTracks": 8, + "midiTracks": null, + "conditions": { + "parameterExtremes": "Describe every minimum, maximum and branch boundary tested.", + "parameterModulation": "Describe simultaneous LFOs, p-locks, MIDI CC and scene sweeps; justify each inapplicable mechanism.", + "modeSwitching": "Describe repeated/interrupted mode, bypass and Part changes.", + "maxLoad": "Describe maximum voices/instances, both cores, FX slots, streaming and USB/MIDI load.", + "inputConditions": "Describe silence, impulses, full-scale inputs, feedback and other worst-case signal conditions." + }, + "checks": { + "audioContinuity": "failed", + "transport": "failed", + "controls": "failed", + "memoryIntegrity": "failed", + "recovery": "failed" + }, + "report": "TESTING.md", + "maxInstances": null + }, + "documentation": { + "tutorial": { + "title": "Quick tutorial", + "steps": [ + "Explain setup and exactly where to select or enable the module.", + "Demonstrate the main controls with a useful example setting.", + "Explain what to hear/observe and how to stop, reset or bypass." + ] + }, + "screenshots": [], + "screenshotStyle": "black-and-white" + } +} diff --git a/sdk/drafts/master-thru/resource-impact.example.json b/sdk/drafts/master-thru/resource-impact.example.json new file mode 100644 index 0000000000..8f7457a054 --- /dev/null +++ b/sdk/drafts/master-thru/resource-impact.example.json @@ -0,0 +1,21 @@ +{ + "conditions": "Describe the active workload, expensive modes, changing controls, instance count, and whether shared/stock allocations are included.", + "cpu": { + "level": null, + "basis": "source-estimate", + "rationale": "Choose minimal, low, moderate or high from source inspection or a documented workload comparison. Explain the ColdFire work and cite the record; do not invent a utilization percentage.", + "source": "TESTING.md" + }, + "dsp": { + "level": null, + "basis": "source-estimate", + "rationale": "Choose a relative demand tier covering the expensive DSP modes and modulation. Minimal needs an explanation of the small or absent added DSP path.", + "source": "TESTING.md" + }, + "memory": { + "level": null, + "basis": "source-estimate", + "rationale": "Choose a relative footprint tier covering code, state, tables and buffers. Distinguish shared reservations and reused stock buffers from extra per-instance memory.", + "source": "TESTING.md" + } +} diff --git a/sdk/drafts/master-thru/unit.s b/sdk/drafts/master-thru/unit.s new file mode 100644 index 0000000000..e575f4f55f --- /dev/null +++ b/sdk/drafts/master-thru/unit.s @@ -0,0 +1,116 @@ +| Master Thru -- T8's PLAYBACK page while T8 is the master (OS 1.40C). +| +| Stock's page selector (0x40031e08) picks a track's page descriptor by page +| index. For page 0 (PLAYBACK) it loads the empty descriptor 0x400d2e8a and +| returns it when d2 is set, which it is exactly for track 8 with MASTER TRACK +| on (0x40031e2c..0x40031e44); otherwise it looks the page up by the track's +| machine byte. The detour replaces `move.l #0x400d2e8a,%d0` (0x40031e6a, +| six bytes): for the master it returns this module's page instead, for every +| other track it replays the move and goes on at 0x40031e70 as stock. +| +| The page is stock's THRU PLAYBACK page (0x1ca bytes from 0x400d3308; the +| selector's table points 0x38 bytes into it, at 0x400d3340, and so does what +| this returns), copied from the unit's own OS the first time it is asked for, +| as Amiga copies FLEX's (amiga.c). So INAB, VOL, INCD and VOL look, read and +| edit exactly as on a THRU track. THRU leaves slots 2 and 5 empty ("---"); +| this fills them with PAN, a copy of the slot before (VOL: the centred knob, +| -64..+63 as AMP's BAL shows it, start 64), and links each pair's three +| knobs with stock's arrows. Slot fields as modwerk_page.h has them: name at +| 0x4e + 6s, start at 0x96 + s, then longs at 0xa2, 0xd2 (count), 0x102 +| (text), 0x132 (widget), 0x162 (editor) + 4s; one nibble a slot at 0x1c6, +| slot 0 lowest: 0 not drawn, 1 a knob, 3 a knob linked to the one before +| (THRU's own word is 0x00031031). +| +| Runs only when stock asks for the page (a key press or a redraw of that +| page), never per frame. Keeps every register but d0, as the selector expects. + .text + .global mt_pb + + .equ STOCK_EMPTY, 0x400d2e8a | stock's empty page for the master + .equ THRU_PAGE, 0x400d3308 | stock's THRU PLAYBACK page, 0x38 before its table entry + .equ PAGE_BYTES, 0x1ca + .equ LINKS, 0x00331331 | INAB > VOL > PAN, INCD > VOL > PAN + .equ BUILT, 0x4d545049 | "MTPI" + +mt_pb: + tst.l %d2 + bne.s 1f + move.l #STOCK_EMPTY,%d0 | the instruction the detour displaced + jmp (0x40031e70).l | stock: tst.l %d2 (clear), then the machine's page +1: bsr.s mt_build + move.l %a0,%d0 + addi.l #0x38,%d0 | what the selector's table points at + jmp (0x40031ed6).l | stock's return with d0 = the page + +| a0 <- the page, built on first use. Keeps every other register. +mt_build: + lea -16(%sp),%sp + movem.l %d1-%d2/%a1-%a2,(%sp) + lea mt_page:l,%a0 + move.l mt_built:l,%d1 + cmpi.l #BUILT,%d1 + beq.s 9f + lea (THRU_PAGE).l,%a1 + move.l %a0,%a2 + move.l #PAGE_BYTES-1,%d1 +2: move.b (%a1)+,(%a2)+ + subq.l #1,%d1 + bpl.s 2b + moveq #2,%d2 + bsr.s mt_pan + moveq #5,%d2 + bsr.s mt_pan + move.l #LINKS,%d1 | 0x1c6, not long-aligned: byte by byte + move.b %d1,0x1c9(%a0) + lsr.l #8,%d1 + move.b %d1,0x1c8(%a0) + lsr.l #8,%d1 + move.b %d1,0x1c7(%a0) + lsr.l #8,%d1 + move.b %d1,0x1c6(%a0) + move.l #BUILT,%d1 + move.l %d1,mt_built:l +9: movem.l (%sp),%d1-%d2/%a1-%a2 + lea 16(%sp),%sp + rts + +| Slot d2 becomes PAN: a copy of slot d2 - 1 (VOL) under its own name. +| a0 the page. Keeps every register. +mt_pan: + lea -12(%sp),%sp + movem.l %d0-%d1/%a1,(%sp) + move.l %d2,%d0 | name at 0x4e + 6s + mulu.w #6,%d0 + lea 0x4e(%a0,%d0.l),%a1 + move.b #'P',(%a1)+ + move.b #'A',(%a1)+ + move.b #'N',(%a1)+ + clr.b (%a1)+ + clr.b (%a1)+ + clr.b (%a1) + lea 0x96(%a0),%a1 | start at 0x96 + s + adda.l %d2,%a1 + move.b -1(%a1),(%a1) + move.l %d2,%d0 | the five longs at 0xa2 + 4s, 0x30 apart + lsl.l #2,%d0 + lea 0xa2(%a0),%a1 + adda.l %d0,%a1 + moveq #5,%d1 +3: move.b -4(%a1),(%a1) + move.b -3(%a1),1(%a1) + move.b -2(%a1),2(%a1) + move.b -1(%a1),3(%a1) + lea 0x30(%a1),%a1 + subq.l #1,%d1 + bne.s 3b + movem.l (%sp),%d0-%d1/%a1 + lea 12(%sp),%sp + rts + + .bss + .balign 4 +mt_built: + .space 4 +mt_page: + .space PAGE_BYTES + .balign 4 diff --git a/sdk/drafts/master-thru/verify.py b/sdk/drafts/master-thru/verify.py new file mode 100644 index 0000000000..e87e5d43de --- /dev/null +++ b/sdk/drafts/master-thru/verify.py @@ -0,0 +1,19 @@ +"""Master Thru, prototype: static checks of the page unit (no firmware, no unit). + +What a unit run must still show is in TESTING.md. +""" +from pathlib import Path + +unit = (Path(__file__).resolve().parent / "unit.s").read_text() +checks = { + "the detour's target is global": ".global mt_pb" in unit, + "the other tracks go on at stock's next instruction": "jmp (0x40031e70).l" in unit, + "the master returns through stock's exit": "jmp (0x40031ed6).l" in unit, + "the page is copied from the unit's own THRU page": "THRU_PAGE, 0x400d3308" in unit, + "the selector gets the page 0x38 bytes in": "addi.l #0x38,%d0" in unit, + "PAN in THRU's empty slots 2 and 5": "moveq #2,%d2\n bsr.s mt_pan" in unit and "moveq #5,%d2\n bsr.s mt_pan" in unit, + "INAB > VOL > PAN and INCD > VOL > PAN linked": "LINKS, 0x00331331" in unit, +} +for name, ok in checks.items(): + print(("[ OK ] " if ok else "[FAIL] ") + name) +raise SystemExit(0 if all(checks.values()) else 1) From d56c045e410bee76b276a7026378267b6c1afbd9 Mon Sep 17 00:00:00 2001 From: Takuhito-bit <364694452+Takuhito-bit@users.noreply.github.com> Date: Fri, 4 Dec 2026 18:44:08 +0900 Subject: [PATCH 2/9] Master Thru draft: the inputs' envelopes on the master's AMP page A second detour, at the selector's AMP branch (0x40031e7e), returns stock's AMP page with ATK/HOLD/REL for inputs A/B on the top row and C/D on the bottom. On an MKI the page shows, and moving or locking its knobs leaves the master's sound alone (TESTING.md). Co-Authored-By: Claude Opus 5.5 --- sdk/drafts/master-thru/README.md | 14 ++- sdk/drafts/master-thru/TESTING.md | 9 +- sdk/drafts/master-thru/manifest.py | 11 +- sdk/drafts/master-thru/octamod.module.json | 3 +- sdk/drafts/master-thru/unit.s | 113 +++++++++++++++++++-- sdk/drafts/master-thru/verify.py | 5 +- 6 files changed, 135 insertions(+), 20 deletions(-) diff --git a/sdk/drafts/master-thru/README.md b/sdk/drafts/master-thru/README.md index 6a5380c6a8..e97af12e7c 100644 --- a/sdk/drafts/master-thru/README.md +++ b/sdk/drafts/master-thru/README.md @@ -23,6 +23,15 @@ T8's PLAYBACK page while T8 is the master. The page is stock's THRU page, so INA INAB > VOL > PAN and INCD > VOL > PAN are linked by stock's arrows. +T8's AMP page while T8 is the master: an envelope for each pair of inputs, on the inputs only, never on T1–T7 or DIR. + +| Knob | Name | What it does | +| --- | --- | --- | +| A, B, C | ATK, HOLD, REL | The envelope of inputs A/B, as on AMP. | +| D, E, F | ATK, HOLD, REL | The envelope of inputs C/D. | + +Without trigs on T8 the inputs always pass (HOLD at its maximum holds). A trig on T8 restarts both envelopes; lock their knobs on it like any other. Each row is linked by stock's arrows. The envelopes need the DSP part too. + ## How to reach it 1. PROJECT > CONTROL > AUDIO: turn MASTER TRACK on. @@ -30,12 +39,13 @@ INAB > VOL > PAN and INCD > VOL > PAN are linked by stock's arrows. ## Changes to stock flows +- **T8's AMP page with MASTER TRACK on.** Stock shows nothing; with the module installed it shows the envelopes above, stored in T8's AMP slots. Stock's AMP stage leaves the master's sound alone with them set (heard on an MKI, TESTING.md). Only while the module is installed. - **T8's PLAYBACK page with MASTER TRACK on.** Stock shows nothing; with the module installed it shows the page above. Why: the master has no other page for its source, and a musician looks for THRU's controls there. Only while the module is installed; removing it brings stock's empty page back. Every other track, and T8 with MASTER TRACK off, take stock's path unchanged (the detour replays the stock instruction for them). ## How it works -One detour at 0x40031e6a, in stock's page selector (0x40031e08): for the master it returns this module's page, built once from the unit's own THRU page (unit.s). Nothing runs per frame. The page's values reach the DSP as every track's PLAYBACK values do. +Two detours in stock's page selector (0x40031e08), at 0x40031e6a (PLAYBACK) and 0x40031e7e (AMP): for the master each returns this module's page, built once from the unit's own THRU or AMP page (unit.s). Nothing runs per frame. The page's values reach the DSP as every track's PLAYBACK values do. ## Compatibility -Declares `screen:MASTER PLAYBACK`. Nothing else in the base or the library patches the selector. +Declares `screen:MASTER PLAYBACK` and `screen:MASTER AMP`. Nothing else in the base or the library patches the selector. diff --git a/sdk/drafts/master-thru/TESTING.md b/sdk/drafts/master-thru/TESTING.md index 271a6c7597..7342d3e146 100644 --- a/sdk/drafts/master-thru/TESTING.md +++ b/sdk/drafts/master-thru/TESTING.md @@ -14,9 +14,16 @@ Record what you ran, on which build and which unit, and what you saw. "Not teste The trial's log: no crash, stall, freeze or skipped track (`device.mjs try` verdict). +**4 December 2026, MKI, OS 1.40C, base `ddb56b72`, prototype trial `07c177fc` (both pages, still no DSP part), RAM trial over USB, rolled back.** Reported by the developer from the unit: + +- With MASTER TRACK on, T8 → AMP opens the page (stock shows nothing there), and its knobs turn. +- Moving the envelope knobs, and locking them on T8's trigs, changed nothing heard in the master's mix. So stock's AMP stage leaves the master alone with these slots set (they are stock's ATK, HOLD, REL, VOL, BAL and XVOL slots of T8), as Master Thru's design needs. + +The trial's log: no crash, stall, freeze or skipped track. + An earlier trial the same day (`9f8e33d6`, built on FLEX's page) opened the page with numbers for INAB and names that crowded their frames; that is why the page is now THRU's. -Not tested: T1–T7's PLAYBACK pages and T8's with MASTER TRACK off under this build (the detour returns stock's path for them), LFOs on these slots, scenes, saving and reloading a project, the sound (no DSP part yet). +Not tested: T1–T7's PLAYBACK and AMP pages and T8's with MASTER TRACK off under this build (the detour returns stock's path for them), LFOs on these slots, scenes, saving and reloading a project, the sound (no DSP part yet). ## Stock flows diff --git a/sdk/drafts/master-thru/manifest.py b/sdk/drafts/master-thru/manifest.py index 1f8093d74e..1b5ea93cdb 100644 --- a/sdk/drafts/master-thru/manifest.py +++ b/sdk/drafts/master-thru/manifest.py @@ -1,11 +1,12 @@ """MASTER THRU -- THRU's controls on T8's PLAYBACK page while T8 is the master. -Prototype, part 1 of 2: the page only. With MASTER TRACK on, stock's page +Prototype, part 1 of 2: the pages only. With MASTER TRACK on, stock's page selector (0x40031e08) gives track 8's PLAYBACK page the empty descriptor 0x400d2e8a, so PLAYBACK shows nothing. One detour at 0x40031e6a returns this module's page instead: INAB, VOL, PAN, INCD, VOL, PAN, built at run time -from the unit's own FLEX page (unit.s). No other track and no other page -changes. Part 2, the DSP engine that adds the inputs to the master's mix at +from the unit's own THRU page (unit.s). A second detour at 0x40031e7e does +the same for the AMP page: ATK, HOLD, REL for inputs A/B on the top row and +for C/D on the bottom, from stock's AMP page. No other track changes. Part 2, the DSP engine that adds the inputs to the master's mix at the dsp_track_source chain (site 5), waits on base support (issue #2602). Inferred from OS 1.40C, not yet seen on a unit: that this selector is the @@ -22,13 +23,15 @@ kind=Kind.CF_PATCH, doc="T8 as the master: THRU's INAB/VOL/PAN and INCD/VOL/PAN on its PLAYBACK page.", category=Category.MACHINES, author="takuhito-bit", author_url="https://github.com/takuhito-bit", - proof=Proof.UNTESTED, proof_note="Prototype: the page only; not yet tried on a unit.", + proof=Proof.UNTESTED, proof_note="Prototype: the pages only; the PLAYBACK page tried on an MKI (TESTING.md).", linked=( Linked("unit", "modules/master-thru/unit.s", dram=True), ), detours=( Detour(0x40031E6A, stock_guard(0x40031e6a, 6, "64885133d7843d50aa58773c2314b3cd8eeacb58d768fe12f3d57c0b0c9af831"), "unit", "mt_pb", "the master's PLAYBACK page: this module's instead of stock's empty one", kind="jmp"), + Detour(0x40031E7E, stock_guard(0x40031e7e, 6, "64885133d7843d50aa58773c2314b3cd8eeacb58d768fe12f3d57c0b0c9af831"), + "unit", "mt_amp", "the master's AMP page: the inputs' two envelopes instead of stock's empty page", kind="jmp"), ), gates=(Gate("modules/master-thru/verify.py", remix_arg=False),), ) diff --git a/sdk/drafts/master-thru/octamod.module.json b/sdk/drafts/master-thru/octamod.module.json index 0a615d0dea..2c1bb144fd 100644 --- a/sdk/drafts/master-thru/octamod.module.json +++ b/sdk/drafts/master-thru/octamod.module.json @@ -76,7 +76,8 @@ "location": "Track machine", "conflicts": [], "uiClaims": [ - "screen:MASTER PLAYBACK" + "screen:MASTER PLAYBACK", + "screen:MASTER AMP" ], "limitations": [ "Prototype: the page only. The inputs are not added to the sound until the DSP part lands with base support (issue #2602).", diff --git a/sdk/drafts/master-thru/unit.s b/sdk/drafts/master-thru/unit.s index e575f4f55f..61c85ac9b1 100644 --- a/sdk/drafts/master-thru/unit.s +++ b/sdk/drafts/master-thru/unit.s @@ -21,27 +21,119 @@ | slot 0 lowest: 0 not drawn, 1 a knob, 3 a knob linked to the one before | (THRU's own word is 0x00031031). | -| Runs only when stock asks for the page (a key press or a redraw of that +| The AMP page (page 2) has the same master branch at 0x40031e7e. There the +| detour returns stock's AMP page (0x1ca bytes from 0x400d3950) with its top +| row, ATK HOLD REL, copied onto the bottom row too: the top row is the +| envelope of inputs A/B, the bottom row that of C/D (slots 12-17 of T8's +| locks), each row linked. The envelopes run in the DSP engine, on the inputs +| only; stock's AMP stage must leave the master's mix alone with these slots +| set (to be heard on a unit: TESTING.md). +| +| Runs only when stock asks for a page (a key press or a redraw of that | page), never per frame. Keeps every register but d0, as the selector expects. .text - .global mt_pb + .global mt_pb, mt_amp .equ STOCK_EMPTY, 0x400d2e8a | stock's empty page for the master .equ THRU_PAGE, 0x400d3308 | stock's THRU PLAYBACK page, 0x38 before its table entry .equ PAGE_BYTES, 0x1ca .equ LINKS, 0x00331331 | INAB > VOL > PAN, INCD > VOL > PAN .equ BUILT, 0x4d545049 | "MTPI" + .equ AMP_PAGE, 0x400d3950 | stock's AMP page, 0x38 before 0x400d3988 + .equ AMP_LINKS, 0x11331331 | ATK > HOLD > REL twice; AMP SETUP's 6-7 as stock + .equ AMP_BUILT, 0x4d544150 | "MTAP" mt_pb: tst.l %d2 bne.s 1f move.l #STOCK_EMPTY,%d0 | the instruction the detour displaced jmp (0x40031e70).l | stock: tst.l %d2 (clear), then the machine's page -1: bsr.s mt_build +1: bsr mt_build move.l %a0,%d0 addi.l #0x38,%d0 | what the selector's table points at jmp (0x40031ed6).l | stock's return with d0 = the page +| The AMP page's master branch (0x40031e7e), as mt_pb's. +mt_amp: + tst.l %d2 + bne.s 1f + move.l #STOCK_EMPTY,%d0 | the instruction the detour displaced + jmp (0x40031e84).l +1: bsr mt_build_amp + move.l %a0,%d0 + addi.l #0x38,%d0 + jmp (0x40031ed6).l + +| a0 <- the AMP page, built on first use. Keeps every other register. +mt_build_amp: + lea -16(%sp),%sp + movem.l %d1-%d2/%a1-%a2,(%sp) + lea mt_amp_page:l,%a0 + move.l mt_amp_built:l,%d1 + cmpi.l #AMP_BUILT,%d1 + beq.s 9f + lea (AMP_PAGE).l,%a1 + move.l %a0,%a2 + move.l #PAGE_BYTES-1,%d1 +2: move.b (%a1)+,(%a2)+ + subq.l #1,%d1 + bpl.s 2b + moveq #3,%d2 | slot 3 <- 0, 4 <- 1, 5 <- 2 +3: bsr mt_copy3 + addq.l #1,%d2 + moveq #6,%d1 + cmp.l %d1,%d2 + bne.s 3b + move.l #AMP_LINKS,%d1 + bsr mt_links + move.l #AMP_BUILT,%d1 + move.l %d1,mt_amp_built:l +9: movem.l (%sp),%d1-%d2/%a1-%a2 + lea 16(%sp),%sp + rts + +| Slot d2 becomes a copy of slot d2 - 3, name included. a0 the page. +| Keeps every register. +mt_copy3: + lea -12(%sp),%sp + movem.l %d0-%d1/%a1,(%sp) + move.l %d2,%d0 | name at 0x4e + 6s, from 18 bytes before + mulu.w #6,%d0 + lea 0x4e(%a0,%d0.l),%a1 + moveq #6,%d1 +4: move.b -18(%a1),(%a1)+ + subq.l #1,%d1 + bne.s 4b + lea 0x96(%a0),%a1 | start at 0x96 + s + adda.l %d2,%a1 + move.b -3(%a1),(%a1) + move.l %d2,%d0 | the five longs at 0xa2 + 4s, 0x30 apart + lsl.l #2,%d0 + lea 0xa2(%a0),%a1 + adda.l %d0,%a1 + moveq #5,%d1 +5: move.b -12(%a1),(%a1) + move.b -11(%a1),1(%a1) + move.b -10(%a1),2(%a1) + move.b -9(%a1),3(%a1) + lea 0x30(%a1),%a1 + subq.l #1,%d1 + bne.s 5b + movem.l (%sp),%d0-%d1/%a1 + lea 12(%sp),%sp + rts + +| The link nibbles d1 at 0x1c6 (not long-aligned: byte by byte). a0 the page. +mt_links: + move.b %d1,0x1c9(%a0) + lsr.l #8,%d1 + move.b %d1,0x1c8(%a0) + lsr.l #8,%d1 + move.b %d1,0x1c7(%a0) + lsr.l #8,%d1 + move.b %d1,0x1c6(%a0) + rts + | a0 <- the page, built on first use. Keeps every other register. mt_build: lea -16(%sp),%sp @@ -60,14 +152,8 @@ mt_build: bsr.s mt_pan moveq #5,%d2 bsr.s mt_pan - move.l #LINKS,%d1 | 0x1c6, not long-aligned: byte by byte - move.b %d1,0x1c9(%a0) - lsr.l #8,%d1 - move.b %d1,0x1c8(%a0) - lsr.l #8,%d1 - move.b %d1,0x1c7(%a0) - lsr.l #8,%d1 - move.b %d1,0x1c6(%a0) + move.l #LINKS,%d1 + bsr mt_links move.l #BUILT,%d1 move.l %d1,mt_built:l 9: movem.l (%sp),%d1-%d2/%a1-%a2 @@ -114,3 +200,8 @@ mt_built: mt_page: .space PAGE_BYTES .balign 4 +mt_amp_built: + .space 4 +mt_amp_page: + .space PAGE_BYTES + .balign 4 diff --git a/sdk/drafts/master-thru/verify.py b/sdk/drafts/master-thru/verify.py index e87e5d43de..bc1bfb8393 100644 --- a/sdk/drafts/master-thru/verify.py +++ b/sdk/drafts/master-thru/verify.py @@ -6,13 +6,16 @@ unit = (Path(__file__).resolve().parent / "unit.s").read_text() checks = { - "the detour's target is global": ".global mt_pb" in unit, + "the detour's target is global": ".global mt_pb, mt_amp" in unit, "the other tracks go on at stock's next instruction": "jmp (0x40031e70).l" in unit, "the master returns through stock's exit": "jmp (0x40031ed6).l" in unit, "the page is copied from the unit's own THRU page": "THRU_PAGE, 0x400d3308" in unit, "the selector gets the page 0x38 bytes in": "addi.l #0x38,%d0" in unit, "PAN in THRU's empty slots 2 and 5": "moveq #2,%d2\n bsr.s mt_pan" in unit and "moveq #5,%d2\n bsr.s mt_pan" in unit, "INAB > VOL > PAN and INCD > VOL > PAN linked": "LINKS, 0x00331331" in unit, + "the AMP page's other tracks go on at stock's next instruction": "jmp (0x40031e84).l" in unit, + "the AMP page is copied from the unit's own AMP page": "AMP_PAGE, 0x400d3950" in unit, + "ATK > HOLD > REL linked on both rows, AMP SETUP's slots as stock": "AMP_LINKS, 0x11331331" in unit, } for name, ok in checks.items(): print(("[ OK ] " if ok else "[FAIL] ") + name) From 03817a479602c91fbeb93e29c40d8875fdb59829 Mon Sep 17 00:00:00 2001 From: Takuhito-bit <364694452+Takuhito-bit@users.noreply.github.com> Date: Fri, 4 Dec 2026 18:50:17 +0900 Subject: [PATCH 3/9] Master Thru draft: the other tracks' pages stay stock's on an MKI Co-Authored-By: Claude Opus 5.5 --- sdk/drafts/master-thru/TESTING.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/sdk/drafts/master-thru/TESTING.md b/sdk/drafts/master-thru/TESTING.md index 7342d3e146..eea20b7088 100644 --- a/sdk/drafts/master-thru/TESTING.md +++ b/sdk/drafts/master-thru/TESTING.md @@ -21,9 +21,11 @@ The trial's log: no crash, stall, freeze or skipped track (`device.mjs try` verd The trial's log: no crash, stall, freeze or skipped track. +**4 December 2026, MKI, same build (`07c177fc`), a second RAM trial, rolled back.** Reported by the developer: with MASTER TRACK on, T1–T7's PLAYBACK and AMP pages were stock's for their machines; with MASTER TRACK off, T8's PLAYBACK and AMP pages were stock's for its machine; turned back on, T8 showed this module's two pages again. The machines on each track were not recorded. + An earlier trial the same day (`9f8e33d6`, built on FLEX's page) opened the page with numbers for INAB and names that crowded their frames; that is why the page is now THRU's. -Not tested: T1–T7's PLAYBACK and AMP pages and T8's with MASTER TRACK off under this build (the detour returns stock's path for them), LFOs on these slots, scenes, saving and reloading a project, the sound (no DSP part yet). +Not tested: LFOs on these slots, scenes, saving and reloading a project, the sound (no DSP part yet). ## Stock flows From 90f15376a999b9092d641742c9dbcdf07196a4b0 Mon Sep 17 00:00:00 2001 From: Takuhito-bit <364694452+Takuhito-bit@users.noreply.github.com> Date: Fri, 4 Dec 2026 19:14:00 +0900 Subject: [PATCH 4/9] Master Thru draft: PAN> and >ATK, no link marks, the master named MASTER+THRU The pages' marks show that PLAYBACK's rows read on into AMP's (A/B on top, C/D below); the master's name says it also takes the inputs. Seen on an MKI (TESTING.md). Co-Authored-By: Claude Opus 5.5 --- sdk/drafts/master-thru/README.md | 13 ++++---- sdk/drafts/master-thru/TESTING.md | 6 +++- sdk/drafts/master-thru/manifest.py | 29 +++++++++------- sdk/drafts/master-thru/octamod.module.json | 6 ++-- sdk/drafts/master-thru/unit.s | 39 ++++++++++++++++++---- sdk/drafts/master-thru/verify.py | 8 +++-- 6 files changed, 69 insertions(+), 32 deletions(-) diff --git a/sdk/drafts/master-thru/README.md b/sdk/drafts/master-thru/README.md index e97af12e7c..780337021a 100644 --- a/sdk/drafts/master-thru/README.md +++ b/sdk/drafts/master-thru/README.md @@ -16,21 +16,21 @@ T8's PLAYBACK page while T8 is the master. The page is stock's THRU page, so INA | --- | --- | --- | --- | | A | INAB | –, A, B, A+B, A B | Inputs A/B: off, A, B, A+B (their mono sum) or A B (stereo, A left). Starts off. | | B | VOL | -64..+63 | Their level, as THRU's VOL. | -| C | PAN | -64..+63 | Where a mono A, B or A+B sits; the balance for the stereo A B. 0 is centre, both sides at unity, as AMP's BAL. | +| C | PAN> | -64..+63 | Where a mono A, B or A+B sits; the balance for the stereo A B. 0 is centre, both sides at unity, as AMP's BAL. | | D | INCD | –, C, D, C+D, C D | Inputs C/D, as INAB. Starts off. | | E | VOL | -64..+63 | Their level. | -| F | PAN | -64..+63 | Their pan or balance. | +| F | PAN> | -64..+63 | Their pan or balance. | -INAB > VOL > PAN and INCD > VOL > PAN are linked by stock's arrows. +PAN's `>` leads on to the AMP page, where ATK starts with one: the top rows of both pages are inputs A/B, the bottom rows C/D. The knobs carry no link marks. T8's AMP page while T8 is the master: an envelope for each pair of inputs, on the inputs only, never on T1–T7 or DIR. | Knob | Name | What it does | | --- | --- | --- | -| A, B, C | ATK, HOLD, REL | The envelope of inputs A/B, as on AMP. | -| D, E, F | ATK, HOLD, REL | The envelope of inputs C/D. | +| A, B, C | >ATK, HOLD, REL | The envelope of inputs A/B, as on AMP. | +| D, E, F | >ATK, HOLD, REL | The envelope of inputs C/D. | -Without trigs on T8 the inputs always pass (HOLD at its maximum holds). A trig on T8 restarts both envelopes; lock their knobs on it like any other. Each row is linked by stock's arrows. The envelopes need the DSP part too. +Without trigs on T8 the inputs always pass (HOLD at its maximum holds). A trig on T8 restarts both envelopes; lock their knobs on it like any other. The envelopes need the DSP part too. ## How to reach it @@ -39,6 +39,7 @@ Without trigs on T8 the inputs always pass (HOLD at its maximum holds). A trig o ## Changes to stock flows +- **The master's name.** While MASTER TRACK is on, stock names T8 MASTER; with the module installed it reads MASTER+THRU, so the player can see that the master also takes the inputs. Two references to stock's MASTER string point at the module's own (manifest.py); nothing else that says MASTER changes. Only while the module is installed. - **T8's AMP page with MASTER TRACK on.** Stock shows nothing; with the module installed it shows the envelopes above, stored in T8's AMP slots. Stock's AMP stage leaves the master's sound alone with them set (heard on an MKI, TESTING.md). Only while the module is installed. - **T8's PLAYBACK page with MASTER TRACK on.** Stock shows nothing; with the module installed it shows the page above. Why: the master has no other page for its source, and a musician looks for THRU's controls there. Only while the module is installed; removing it brings stock's empty page back. Every other track, and T8 with MASTER TRACK off, take stock's path unchanged (the detour replays the stock instruction for them). diff --git a/sdk/drafts/master-thru/TESTING.md b/sdk/drafts/master-thru/TESTING.md index eea20b7088..61e35a5c38 100644 --- a/sdk/drafts/master-thru/TESTING.md +++ b/sdk/drafts/master-thru/TESTING.md @@ -8,12 +8,16 @@ Record what you ran, on which build and which unit, and what you saw. "Not teste - With MASTER TRACK on, T8 → PLAYBACK opens the page (stock shows nothing there). - INAB and INCD read as on a THRU track; the controls are named INAB, VOL, PAN, INCD, VOL, PAN, inside their frames. -- INAB > VOL > PAN and INCD > VOL > PAN are linked by stock's arrows. +- INAB > VOL > PAN and INCD > VOL > PAN were linked by stock's arrows in this build (a later one drops the link marks). - VOL and PAN show -64..+63 with 0 at the centre, as AMP's BAL. - The knobs change their values, and a trig held while turning one takes a lock. The trial's log: no crash, stall, freeze or skipped track (`device.mjs try` verdict). +**4 December 2026, MKI, OS 1.40C, base `ddb56b72`, prototype trial `f99c4cb4` (the current pages), RAM trial over USB, rolled back.** Reported by the developer from the unit: PLAYBACK reads INAB VOL PAN> over INCD VOL PAN>, AMP reads >ATK HOLD REL on both rows, no link marks; the master is named MASTER+THRU, nothing cut off or overlapping; nothing else on other tracks or screens changed. Which screens showed the name was not recorded. Trial log: no crash, stall, freeze or skipped track. + +Between that build and the ones below, trials `12824cd8`, `f1d4baa5`, `39903350`, `b543346f` and `39ac8669` tried the look of these marks (stock's link arrow drawn after PAN, the font's arrow, a triangle glyph added to the label font): each displayed, each rolled back with nothing logged, and the developer chose the plain `>`. + **4 December 2026, MKI, OS 1.40C, base `ddb56b72`, prototype trial `07c177fc` (both pages, still no DSP part), RAM trial over USB, rolled back.** Reported by the developer from the unit: - With MASTER TRACK on, T8 → AMP opens the page (stock shows nothing there), and its knobs turn. diff --git a/sdk/drafts/master-thru/manifest.py b/sdk/drafts/master-thru/manifest.py index 1b5ea93cdb..0f95e8936a 100644 --- a/sdk/drafts/master-thru/manifest.py +++ b/sdk/drafts/master-thru/manifest.py @@ -1,20 +1,19 @@ -"""MASTER THRU -- THRU's controls on T8's PLAYBACK page while T8 is the master. +"""MASTER THRU -- THRU's controls and an input envelope on the master's pages. Prototype, part 1 of 2: the pages only. With MASTER TRACK on, stock's page -selector (0x40031e08) gives track 8's PLAYBACK page the empty descriptor -0x400d2e8a, so PLAYBACK shows nothing. One detour at 0x40031e6a returns this -module's page instead: INAB, VOL, PAN, INCD, VOL, PAN, built at run time -from the unit's own THRU page (unit.s). A second detour at 0x40031e7e does -the same for the AMP page: ATK, HOLD, REL for inputs A/B on the top row and -for C/D on the bottom, from stock's AMP page. No other track changes. Part 2, the DSP engine that adds the inputs to the master's mix at -the dsp_track_source chain (site 5), waits on base support (issue #2602). +selector (0x40031e08) gives track 8 empty PLAYBACK and AMP pages. Two +detours (0x40031e6a, 0x40031e7e) return this module's pages instead, built +at run time from the unit's own THRU and AMP pages (unit.s): INAB VOL PAN> +and INCD VOL PAN> on PLAYBACK, >ATK HOLD REL for A/B and C/D on AMP. Two +references to stock's MASTER string name the master MASTER+THRU. No other +track changes. Seen on an MKI (TESTING.md). -Inferred from OS 1.40C, not yet seen on a unit: that this selector is the -one PLAYBACK uses for the master, and that the page's values reach the DSP -(0x4000d63c converts all eight tracks' live lanes with MASTER TRACK on). +Part 2, the DSP engine that adds the inputs to the master's mix at the +dsp_track_source chain (site 5) and runs their envelopes, waits on base +support (issue #2602). """ -from remix.schema import Category, Proof, Detour, Gate, Kind, Linked, Module +from remix.schema import Category, Proof, Detour, Gate, Kind, Linked, Module, SymbolRef from remix.stock_guard import stock_guard MODULE = Module( @@ -33,5 +32,11 @@ Detour(0x40031E7E, stock_guard(0x40031e7e, 6, "64885133d7843d50aa58773c2314b3cd8eeacb58d768fe12f3d57c0b0c9af831"), "unit", "mt_amp", "the master's AMP page: the inputs' two envelopes instead of stock's empty page", kind="jmp"), ), + symbol_refs=( + SymbolRef(0x4003D684, 0x400B44E1, "unit", "mt_name", + note="the master's machine name on its pages: MASTER+THRU instead of MASTER"), + SymbolRef(0x4004C180, 0x400B44E1, "unit", "mt_name", + note="the master's machine name in the track's name: MASTER+THRU instead of MASTER"), + ), gates=(Gate("modules/master-thru/verify.py", remix_arg=False),), ) diff --git a/sdk/drafts/master-thru/octamod.module.json b/sdk/drafts/master-thru/octamod.module.json index 2c1bb144fd..949b0c97b0 100644 --- a/sdk/drafts/master-thru/octamod.module.json +++ b/sdk/drafts/master-thru/octamod.module.json @@ -19,7 +19,7 @@ "overview": "The master (T8) hears T1-T7 and DIR. Master Thru adds inputs A/B and C/D at their own level and pan before T8's AMP, FX1 and FX2, with locks, LFOs and scenes like any PLAYBACK control. Prototype: the page only; the sound part waits on base support (issue #2602).", "highlights": [ "THRU's own INAB, VOL, INCD and VOL on the master's PLAYBACK page, plus a PAN for each pair", - "INAB > VOL > PAN and INCD > VOL > PAN linked by stock's arrows", + "An envelope (ATK, HOLD, REL) for each pair of inputs on the master's AMP page: A/B on the top rows, C/D on the bottom", "INAB and INCD start off: installing it changes nothing until you pick an input" ], "usage": [ @@ -45,7 +45,7 @@ "name": "PAN AB", "default": 64, "count": 128, - "doc": "Where a mono A, B or A+B sits; the balance for the stereo A B. -64..+63 as AMP's BAL; 0 is centre, unity on both sides. Shown as PAN.", + "doc": "Where a mono A, B or A+B sits; the balance for the stereo A B. -64..+63 as AMP's BAL; 0 is centre, unity on both sides. Shown as PAN>.", "labels": null }, { @@ -66,7 +66,7 @@ "name": "PAN CD", "default": 64, "count": 128, - "doc": "Where a mono C, D or C+D sits; the balance for the stereo C D. Shown as PAN.", + "doc": "Where a mono C, D or C+D sits; the balance for the stereo C D. Shown as PAN>.", "labels": null } ], diff --git a/sdk/drafts/master-thru/unit.s b/sdk/drafts/master-thru/unit.s index 61c85ac9b1..9009c9d211 100644 --- a/sdk/drafts/master-thru/unit.s +++ b/sdk/drafts/master-thru/unit.s @@ -14,8 +14,8 @@ | as Amiga copies FLEX's (amiga.c). So INAB, VOL, INCD and VOL look, read and | edit exactly as on a THRU track. THRU leaves slots 2 and 5 empty ("---"); | this fills them with PAN, a copy of the slot before (VOL: the centred knob, -| -64..+63 as AMP's BAL shows it, start 64), and links each pair's three -| knobs with stock's arrows. Slot fields as modwerk_page.h has them: name at +| -64..+63 as AMP's BAL shows it, start 64), and draws the six knobs without +| stock's link marks. Slot fields as modwerk_page.h has them: name at | 0x4e + 6s, start at 0x96 + s, then longs at 0xa2, 0xd2 (count), 0x102 | (text), 0x132 (widget), 0x162 (editor) + 4s; one nibble a slot at 0x1c6, | slot 0 lowest: 0 not drawn, 1 a knob, 3 a knob linked to the one before @@ -25,22 +25,26 @@ | detour returns stock's AMP page (0x1ca bytes from 0x400d3950) with its top | row, ATK HOLD REL, copied onto the bottom row too: the top row is the | envelope of inputs A/B, the bottom row that of C/D (slots 12-17 of T8's -| locks), each row linked. The envelopes run in the DSP engine, on the inputs +| locks), without link marks. The envelopes run in the DSP engine, on the inputs | only; stock's AMP stage must leave the master's mix alone with these slots | set (to be heard on a unit: TESTING.md). | +| PAN's name ends with '>' and ATK's starts with it, so each row reads on +| from PLAYBACK into AMP: A/B on the top rows, C/D on the bottom ones. +| | Runs only when stock asks for a page (a key press or a redraw of that | page), never per frame. Keeps every register but d0, as the selector expects. .text - .global mt_pb, mt_amp + .global mt_pb, mt_amp, mt_name .equ STOCK_EMPTY, 0x400d2e8a | stock's empty page for the master .equ THRU_PAGE, 0x400d3308 | stock's THRU PLAYBACK page, 0x38 before its table entry .equ PAGE_BYTES, 0x1ca - .equ LINKS, 0x00331331 | INAB > VOL > PAN, INCD > VOL > PAN + .equ LINKS, 0x00111111 | six knobs, no link marks .equ BUILT, 0x4d545049 | "MTPI" .equ AMP_PAGE, 0x400d3950 | stock's AMP page, 0x38 before 0x400d3988 - .equ AMP_LINKS, 0x11331331 | ATK > HOLD > REL twice; AMP SETUP's 6-7 as stock + .equ AMP_LINKS, 0x11111111 | six knobs, no link marks; AMP SETUP's 6-7 as stock + .equ MARK, 0x3e | '>' after PAN and before ATK .equ AMP_BUILT, 0x4d544150 | "MTAP" mt_pb: @@ -84,6 +88,10 @@ mt_build_amp: moveq #6,%d1 cmp.l %d1,%d2 bne.s 3b + lea 0x4e(%a0),%a1 | slot 0's name, then slot 3's: > before ATK + bsr.s mt_atk + lea 0x60(%a0),%a1 + bsr.s mt_atk move.l #AMP_LINKS,%d1 bsr mt_links move.l #AMP_BUILT,%d1 @@ -92,6 +100,16 @@ mt_build_amp: lea 16(%sp),%sp rts +| The name at (a1) becomes >ATK. Keeps every register but a1. +mt_atk: + move.b #MARK,(%a1)+ + move.b #'A',(%a1)+ + move.b #'T',(%a1)+ + move.b #'K',(%a1)+ + clr.b (%a1)+ + clr.b (%a1) + rts + | Slot d2 becomes a copy of slot d2 - 3, name included. a0 the page. | Keeps every register. mt_copy3: @@ -171,7 +189,7 @@ mt_pan: move.b #'P',(%a1)+ move.b #'A',(%a1)+ move.b #'N',(%a1)+ - clr.b (%a1)+ + move.b #MARK,(%a1)+ clr.b (%a1)+ clr.b (%a1) lea 0x96(%a0),%a1 | start at 0x96 + s @@ -193,6 +211,13 @@ mt_pan: lea 12(%sp),%sp rts + .data +| The master's machine name, where stock writes MASTER (two references, +| manifest.py): this module's master is THRU's as well. +mt_name: + .asciz "MASTER+THRU" + .balign 4 + .bss .balign 4 mt_built: diff --git a/sdk/drafts/master-thru/verify.py b/sdk/drafts/master-thru/verify.py index bc1bfb8393..c45bb9f53f 100644 --- a/sdk/drafts/master-thru/verify.py +++ b/sdk/drafts/master-thru/verify.py @@ -6,16 +6,18 @@ unit = (Path(__file__).resolve().parent / "unit.s").read_text() checks = { - "the detour's target is global": ".global mt_pb, mt_amp" in unit, + "the detour's target is global": ".global mt_pb, mt_amp, mt_name" in unit, "the other tracks go on at stock's next instruction": "jmp (0x40031e70).l" in unit, "the master returns through stock's exit": "jmp (0x40031ed6).l" in unit, "the page is copied from the unit's own THRU page": "THRU_PAGE, 0x400d3308" in unit, "the selector gets the page 0x38 bytes in": "addi.l #0x38,%d0" in unit, "PAN in THRU's empty slots 2 and 5": "moveq #2,%d2\n bsr.s mt_pan" in unit and "moveq #5,%d2\n bsr.s mt_pan" in unit, - "INAB > VOL > PAN and INCD > VOL > PAN linked": "LINKS, 0x00331331" in unit, + "six knobs on PLAYBACK, no link marks": "LINKS, 0x00111111" in unit, "the AMP page's other tracks go on at stock's next instruction": "jmp (0x40031e84).l" in unit, "the AMP page is copied from the unit's own AMP page": "AMP_PAGE, 0x400d3950" in unit, - "ATK > HOLD > REL linked on both rows, AMP SETUP's slots as stock": "AMP_LINKS, 0x11331331" in unit, + "six knobs on AMP, no link marks, AMP SETUP's slots as stock": "AMP_LINKS, 0x11111111" in unit, + "PAN> and >ATK": "MARK, 0x3e" in unit and "move.b #MARK,(%a1)+" in unit, + "the master's name": '.asciz "MASTER+THRU"' in unit, } for name, ok in checks.items(): print(("[ OK ] " if ok else "[FAIL] ") + name) From 8ae23cfac278ea9c19709232e83c247b46d70365 Mon Sep 17 00:00:00 2001 From: Takuhito-bit <364694452+Takuhito-bit@users.noreply.github.com> Date: Sat, 5 Dec 2026 14:58:27 +0900 Subject: [PATCH 5/9] Master Thru draft: TESTING.md names 0.1.0-experimental Co-Authored-By: Claude Opus 5.5 --- sdk/drafts/master-thru/TESTING.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sdk/drafts/master-thru/TESTING.md b/sdk/drafts/master-thru/TESTING.md index 61e35a5c38..61ea759ca1 100644 --- a/sdk/drafts/master-thru/TESTING.md +++ b/sdk/drafts/master-thru/TESTING.md @@ -4,6 +4,8 @@ Record what you ran, on which build and which unit, and what you saw. "Not teste ## On the unit +Version 0.1.0-experimental, a draft: every trial below ran a prototype build of it (the pages only, no DSP part), not a package. + **4 December 2026, MKI, OS 1.40C, base `ddb56b72`, prototype trial `a48f2bce` (the page only), RAM trial over USB, rolled back.** Reported by the developer (@takuhito-bit) from the unit's screen: - With MASTER TRACK on, T8 → PLAYBACK opens the page (stock shows nothing there). From 15c4124b54fc60cacca653d07b26e8fd095b2d2a Mon Sep 17 00:00:00 2001 From: Takuhito-bit <364694452+Takuhito-bit@users.noreply.github.com> Date: Sat, 5 Dec 2026 17:19:59 +0900 Subject: [PATCH 6/9] Master Thru draft: the master keeps stock's name; README places the detours beside the base's resolver Co-Authored-By: Claude Opus 5.5 --- sdk/drafts/master-thru/README.md | 7 ++++--- sdk/drafts/master-thru/TESTING.md | 2 +- sdk/drafts/master-thru/manifest.py | 16 +++++----------- sdk/drafts/master-thru/octamod.module.json | 2 +- sdk/drafts/master-thru/unit.s | 9 +-------- sdk/drafts/master-thru/verify.py | 4 ++-- 6 files changed, 14 insertions(+), 26 deletions(-) diff --git a/sdk/drafts/master-thru/README.md b/sdk/drafts/master-thru/README.md index 780337021a..8f14363f7a 100644 --- a/sdk/drafts/master-thru/README.md +++ b/sdk/drafts/master-thru/README.md @@ -39,14 +39,15 @@ Without trigs on T8 the inputs always pass (HOLD at its maximum holds). A trig o ## Changes to stock flows -- **The master's name.** While MASTER TRACK is on, stock names T8 MASTER; with the module installed it reads MASTER+THRU, so the player can see that the master also takes the inputs. Two references to stock's MASTER string point at the module's own (manifest.py); nothing else that says MASTER changes. Only while the module is installed. - **T8's AMP page with MASTER TRACK on.** Stock shows nothing; with the module installed it shows the envelopes above, stored in T8's AMP slots. Stock's AMP stage leaves the master's sound alone with them set (heard on an MKI, TESTING.md). Only while the module is installed. - **T8's PLAYBACK page with MASTER TRACK on.** Stock shows nothing; with the module installed it shows the page above. Why: the master has no other page for its source, and a musician looks for THRU's controls there. Only while the module is installed; removing it brings stock's empty page back. Every other track, and T8 with MASTER TRACK off, take stock's path unchanged (the detour replays the stock instruction for them). ## How it works -Two detours in stock's page selector (0x40031e08), at 0x40031e6a (PLAYBACK) and 0x40031e7e (AMP): for the master each returns this module's page, built once from the unit's own THRU or AMP page (unit.s). Nothing runs per frame. The page's values reach the DSP as every track's PLAYBACK values do. +Two detours in stock's page selector (0x40031e08), at 0x40031e6a (PLAYBACK) and 0x40031e7e (AMP): for the master each returns this module's page, built once from the unit's own THRU or AMP page (unit.s). Nothing runs per frame. The page's values reach the DSP as every track's PLAYBACK values do. The master keeps stock's name, MASTER. + +**Beside the base's sites.** The base patches the same selector: its page resolver for contributed machines, `mw_resolve_pb`, takes the 10 bytes at 0x40031e74..0x40031e7d (sdk/machines/octatrack/HOOKS.md). The PLAYBACK detour (0x40031e6a, 6 bytes) ends 4 bytes before it, and the AMP detour (0x40031e7e, 6 bytes) starts on the byte after it; no bytes overlap. For every track that is not the master, the PLAYBACK detour replays the displaced `move.l` and rejoins stock at 0x40031e70, which runs on into 0x40031e74, so a contributed machine's page still goes through the base's resolver; the AMP detour rejoins at 0x40031e84. For the master both leave through stock's exit at 0x40031ed6, as stock's own master branch does. The module touches none of the base's name lookups (`mw_name_a` 0x4003d718, `mw_name_b` 0x4004c36a). ## Compatibility -Declares `screen:MASTER PLAYBACK` and `screen:MASTER AMP`. Nothing else in the base or the library patches the selector. +Declares `screen:MASTER PLAYBACK` and `screen:MASTER AMP`. The base's `mw_resolve_pb` sits in the same selector, between the two detours (see above); no module in the library patches 0x40031e6a or 0x40031e7e. diff --git a/sdk/drafts/master-thru/TESTING.md b/sdk/drafts/master-thru/TESTING.md index 61ea759ca1..10d0a42213 100644 --- a/sdk/drafts/master-thru/TESTING.md +++ b/sdk/drafts/master-thru/TESTING.md @@ -16,7 +16,7 @@ Version 0.1.0-experimental, a draft: every trial below ran a prototype build of The trial's log: no crash, stall, freeze or skipped track (`device.mjs try` verdict). -**4 December 2026, MKI, OS 1.40C, base `ddb56b72`, prototype trial `f99c4cb4` (the current pages), RAM trial over USB, rolled back.** Reported by the developer from the unit: PLAYBACK reads INAB VOL PAN> over INCD VOL PAN>, AMP reads >ATK HOLD REL on both rows, no link marks; the master is named MASTER+THRU, nothing cut off or overlapping; nothing else on other tracks or screens changed. Which screens showed the name was not recorded. Trial log: no crash, stall, freeze or skipped track. +**4 December 2026, MKI, OS 1.40C, base `ddb56b72`, prototype trial `f99c4cb4` (the current pages), RAM trial over USB, rolled back.** Reported by the developer from the unit: PLAYBACK reads INAB VOL PAN> over INCD VOL PAN>, AMP reads >ATK HOLD REL on both rows, no link marks; the master is named MASTER+THRU, nothing cut off or overlapping; nothing else on other tracks or screens changed. Which screens showed the name was not recorded. Trial log: no crash, stall, freeze or skipped track. On 5 December the developer dropped the name: the master is MASTER again, as stock. The build without it has not been tried on a unit yet. Between that build and the ones below, trials `12824cd8`, `f1d4baa5`, `39903350`, `b543346f` and `39ac8669` tried the look of these marks (stock's link arrow drawn after PAN, the font's arrow, a triangle glyph added to the label font): each displayed, each rolled back with nothing logged, and the developer chose the plain `>`. diff --git a/sdk/drafts/master-thru/manifest.py b/sdk/drafts/master-thru/manifest.py index 0f95e8936a..25092685e3 100644 --- a/sdk/drafts/master-thru/manifest.py +++ b/sdk/drafts/master-thru/manifest.py @@ -4,16 +4,16 @@ selector (0x40031e08) gives track 8 empty PLAYBACK and AMP pages. Two detours (0x40031e6a, 0x40031e7e) return this module's pages instead, built at run time from the unit's own THRU and AMP pages (unit.s): INAB VOL PAN> -and INCD VOL PAN> on PLAYBACK, >ATK HOLD REL for A/B and C/D on AMP. Two -references to stock's MASTER string name the master MASTER+THRU. No other -track changes. Seen on an MKI (TESTING.md). +and INCD VOL PAN> on PLAYBACK, >ATK HOLD REL for A/B and C/D on AMP. The +master keeps stock's name, MASTER. No other track changes. Seen on an MKI +(TESTING.md). Part 2, the DSP engine that adds the inputs to the master's mix at the dsp_track_source chain (site 5) and runs their envelopes, waits on base support (issue #2602). """ -from remix.schema import Category, Proof, Detour, Gate, Kind, Linked, Module, SymbolRef +from remix.schema import Category, Proof, Detour, Gate, Kind, Linked, Module from remix.stock_guard import stock_guard MODULE = Module( @@ -22,7 +22,7 @@ kind=Kind.CF_PATCH, doc="T8 as the master: THRU's INAB/VOL/PAN and INCD/VOL/PAN on its PLAYBACK page.", category=Category.MACHINES, author="takuhito-bit", author_url="https://github.com/takuhito-bit", - proof=Proof.UNTESTED, proof_note="Prototype: the pages only; the PLAYBACK page tried on an MKI (TESTING.md).", + proof=Proof.UNTESTED, proof_note="Prototype: the pages only; both pages tried on an MKI (TESTING.md).", linked=( Linked("unit", "modules/master-thru/unit.s", dram=True), ), @@ -32,11 +32,5 @@ Detour(0x40031E7E, stock_guard(0x40031e7e, 6, "64885133d7843d50aa58773c2314b3cd8eeacb58d768fe12f3d57c0b0c9af831"), "unit", "mt_amp", "the master's AMP page: the inputs' two envelopes instead of stock's empty page", kind="jmp"), ), - symbol_refs=( - SymbolRef(0x4003D684, 0x400B44E1, "unit", "mt_name", - note="the master's machine name on its pages: MASTER+THRU instead of MASTER"), - SymbolRef(0x4004C180, 0x400B44E1, "unit", "mt_name", - note="the master's machine name in the track's name: MASTER+THRU instead of MASTER"), - ), gates=(Gate("modules/master-thru/verify.py", remix_arg=False),), ) diff --git a/sdk/drafts/master-thru/octamod.module.json b/sdk/drafts/master-thru/octamod.module.json index 949b0c97b0..9d55e68efe 100644 --- a/sdk/drafts/master-thru/octamod.module.json +++ b/sdk/drafts/master-thru/octamod.module.json @@ -81,7 +81,7 @@ ], "limitations": [ "Prototype: the page only. The inputs are not added to the sound until the DSP part lands with base support (issue #2602).", - "Not tried on a unit yet." + "Tried on an MKI only, in RAM trials of the pages (TESTING.md); not on an MKII." ] }, "resources": { diff --git a/sdk/drafts/master-thru/unit.s b/sdk/drafts/master-thru/unit.s index 9009c9d211..c3f6058622 100644 --- a/sdk/drafts/master-thru/unit.s +++ b/sdk/drafts/master-thru/unit.s @@ -35,7 +35,7 @@ | Runs only when stock asks for a page (a key press or a redraw of that | page), never per frame. Keeps every register but d0, as the selector expects. .text - .global mt_pb, mt_amp, mt_name + .global mt_pb, mt_amp .equ STOCK_EMPTY, 0x400d2e8a | stock's empty page for the master .equ THRU_PAGE, 0x400d3308 | stock's THRU PLAYBACK page, 0x38 before its table entry @@ -211,13 +211,6 @@ mt_pan: lea 12(%sp),%sp rts - .data -| The master's machine name, where stock writes MASTER (two references, -| manifest.py): this module's master is THRU's as well. -mt_name: - .asciz "MASTER+THRU" - .balign 4 - .bss .balign 4 mt_built: diff --git a/sdk/drafts/master-thru/verify.py b/sdk/drafts/master-thru/verify.py index c45bb9f53f..22518582cd 100644 --- a/sdk/drafts/master-thru/verify.py +++ b/sdk/drafts/master-thru/verify.py @@ -6,7 +6,7 @@ unit = (Path(__file__).resolve().parent / "unit.s").read_text() checks = { - "the detour's target is global": ".global mt_pb, mt_amp, mt_name" in unit, + "the detour's target is global": ".global mt_pb, mt_amp" in unit, "the other tracks go on at stock's next instruction": "jmp (0x40031e70).l" in unit, "the master returns through stock's exit": "jmp (0x40031ed6).l" in unit, "the page is copied from the unit's own THRU page": "THRU_PAGE, 0x400d3308" in unit, @@ -17,7 +17,7 @@ "the AMP page is copied from the unit's own AMP page": "AMP_PAGE, 0x400d3950" in unit, "six knobs on AMP, no link marks, AMP SETUP's slots as stock": "AMP_LINKS, 0x11111111" in unit, "PAN> and >ATK": "MARK, 0x3e" in unit and "move.b #MARK,(%a1)+" in unit, - "the master's name": '.asciz "MASTER+THRU"' in unit, + "the master keeps stock's name": "mt_name" not in unit, } for name, ok in checks.items(): print(("[ OK ] " if ok else "[FAIL] ") + name) From 9dfbdb924406d554e774232428e1c18f35d55dcf Mon Sep 17 00:00:00 2001 From: Takuhito-bit <364694452+Takuhito-bit@users.noreply.github.com> Date: Sat, 5 Dec 2026 18:15:33 +0900 Subject: [PATCH 7/9] Master Thru draft: stock's master pages captured; what T8 keeps when the master goes away, on an MKI Co-Authored-By: Claude Opus 5.5 --- sdk/drafts/master-thru/TESTING.md | 16 +++++++++++++++- .../master-thru/media/stock-master-amp-mki.png | Bin 0 -> 1294 bytes .../media/stock-master-playback-mki.png | Bin 0 -> 1324 bytes 3 files changed, 15 insertions(+), 1 deletion(-) create mode 100644 sdk/drafts/master-thru/media/stock-master-amp-mki.png create mode 100644 sdk/drafts/master-thru/media/stock-master-playback-mki.png diff --git a/sdk/drafts/master-thru/TESTING.md b/sdk/drafts/master-thru/TESTING.md index 10d0a42213..05c7511e7d 100644 --- a/sdk/drafts/master-thru/TESTING.md +++ b/sdk/drafts/master-thru/TESTING.md @@ -31,7 +31,21 @@ The trial's log: no crash, stall, freeze or skipped track. An earlier trial the same day (`9f8e33d6`, built on FLEX's page) opened the page with numbers for INAB and names that crowded their frames; that is why the page is now THRU's. -Not tested: LFOs on these slots, scenes, saving and reloading a project, the sound (no DSP part yet). +**5 December 2026, MKI, OS 1.40C, base `ddb56b72`, prototype trial `b026a357` (the master keeps stock's MASTER), RAM trial over USB, rolled back.** Reported by the developer from the unit: + +- With MASTER TRACK on, the master is named MASTER; T8's PLAYBACK and AMP open this module's pages. +- INAB and INCD offer –, A B, A, B, A+B (C/D likewise); VOL and PAN run -64..+63; ATK 0..127, HOLD from 0.007 up to INF, REL 0 to INF, on both rows. +- With the values moved and MASTER TRACK then turned off, T8's own machine (STATIC, with a sample) took them: on its AMP page VOL and BAL, among others, sat all the way left. T8 sounded once its VOL was raised. So the master's PLAYBACK and AMP values are T8's own slots, and its machine reads them when the master goes away. + +The trial's log: no crash, stall, freeze or skipped track. + +Stock's master pages, without the module (5 December 2026, MKI, OS 1.40C, captured over USB): `media/stock-master-playback-mki.png` (PLAYBACK: no controls, MASTER in the bottom bar) and `media/stock-master-amp-mki.png` (AMP: no controls). No MKII captures. + +**5 December 2026, MKI, same build (`b026a357`), a second RAM trial, then removed.** Reported by the developer from the unit: with MASTER TRACK on, the pages' knobs behaved as in the trial above; the values were moved and the project saved. USB was then unplugged (the base rolled the module back) and the unit restarted: the module's pages were gone and the master was stock's. With the saved project loaded on that unit, without the module, and MASTER TRACK turned off, T8's STATIC machine loaded with the saved values in its own slots: on AMP, its values all the way left; on PLAYBACK, PTCH and RATE all the way left, STRT all the way right, LEN, RTRG and RTIM at the centre. What T8 sounded like after the reload was not recorded. This trial's log did not report a verdict (USB was unplugged during it). + +So the values set on the master's pages stay in T8's PLAYBACK and AMP slots, are saved with the project, and become T8's own machine's values whenever the master goes away, with the module or without it. + +Not tested: LFOs on these slots, scenes, the sound (no DSP part yet). ## Stock flows diff --git a/sdk/drafts/master-thru/media/stock-master-amp-mki.png b/sdk/drafts/master-thru/media/stock-master-amp-mki.png new file mode 100644 index 0000000000000000000000000000000000000000..322cdc33cdb1670db5c97dc765fc687201eb96ae GIT binary patch literal 1294 zcmX|BX;2ea9N)LuluaVAq)4&Uuq9PHKs6DiV2o@OPSZHmAAfzWIQu3v`%3c+_w@)ySnOQV2^TX(R(Nc~c zUl*&^w@j9tOIcHLO^LKuOjvu#-C?&*ckM)P0+5i66s=ixvn?>(PsD+*4BL8B54`S5RfR!y(|zhlBqnhi;Xt_S(Wj|tbr_$cW!#L%e;>1 z5g7klLsGh@V+_kkrQLtr_q!E#r6)V@IW6ExH3Op)$^?6q3Xo%z{f|5_9`k@C=h4_T zL+Q!Zq5J8{`_pDZy+I01-++dl4{0qk*Z_)=kg(Vri(o~(s0}wo?Dis|k6#{ww|tW6 z*09-pc=D-1q{;CV;B;c&lH^zXW3+gxD~FkB((JFP0Th8r_^K{;Y?WrwTrx>4DP;+Y zWo{-!zD1L!Sm~mg|7>Zm{-86Za+#%BVb|0Sx{q+Accv6mV?ML$OG#B*udrUd^?k81 zvCn{Fi4@WVGi!;R0jvO6r(Fh5JJV@vEFYE8RSQbDB z{KYOLk(Q`pADwN5R0~s&6p}VN=rY*c9%QK73jzzo zv(0V_tnrAd|I=;GDNQ*v-!zKjg+p1GUXrn@dfY#h)yT*6N2ylophdG5W`YK1dfOF; z8#`Jhu2`b%dvk%0Zn#BN_XNkcuGc3k*DT@nGh8UVoFI=kk-ew$#4W>>)yJ6k?Lgy> zRCUr%QH$(Hb8&Q~MYDYi$wssi@^}wVzI^1ya9M@|yyOi@h)r~ju9CZs_HTn`-Ha!j zv=OgX-@g0NGWaDmdmk{};P^=BZz3TMj&lroBC%2$jkuT~;TFrXbfyjdBjr=CNO6P=o#Q4I00bZIvhXQbeD0`>G|szJ@3(4^^2LU`9rTm y!;}WMqAd~#_Fhd8zi?gJOV`j#3lZ(1AeZ0s5=Z2eUC*EwT};%*$ojSNf`0%O=Oz6B literal 0 HcmV?d00001 diff --git a/sdk/drafts/master-thru/media/stock-master-playback-mki.png b/sdk/drafts/master-thru/media/stock-master-playback-mki.png new file mode 100644 index 0000000000000000000000000000000000000000..8080e0004b0a023f5c0e466d82d1b8c73979f22b GIT binary patch literal 1324 zcmX|BYfuwc7~S1$!V-jRYCz0bTrJd!$U}>QXu4R?GAj6LV?<4gJVXHz6e5_o1`(|w zRx1+}2U?+3L6Z_h5QN}FNEI?s5Q?FKVTg7T(1BnSCfHqY`sdF5aqcUL34cVfZXavpR|h=6RKg+(4rbr0G@gS!23=Ls==_Qrp+u-dA0K zDh$yAU`!DV7e9&Um>g+}lf;&8qqQGJ&tD}OLpY+Q9UOFiRbjhp{Ys?_Ztnkt-?&_o z_mGQj&n^NXOJ>gexf&7_OwDcKT__4hx^CFu>=s1=_nqzyy4sc&kEqv zDg;fiee}@xAAYyAGgNM53lAI;(FIv9xLShY?Zc3)sK1*i8#Ahn0gov#8`F8rPCXe5 zdZQQvj4?sRjSsYY_AbjUPj2KXWuGXIFBq6SUK{PESSArmQ3TBa0@`5t-n$iZlwuu! zgQaYMC-piD93qEIy2RDnGMnvIEMS_-9OFa(?XedTT=dl=*ekL_WEpI6;L~y)k^bGVv zk;!EbKat-kv}b6d6d+?d0~R?&dD=`91b-6Fk6e7n=j7Bvb!Nc+kwJd-jMdU2z;)U^ zKE0+OG`l~Dc@yTe&onIL!^QIA+M}Uwd@Cm-`<+crn_o^d^XmpW)TfiY{pr*fPQN~yAvPoKaku@t1uw2K zYA}pO_F8>x!P9Ef>KU`g={3ufCW{mOUc{X{Hw10Bn%_>GrYtuRK<8^WM_YxVH*IU| z{N@XR8wv;u)%8taCl^IR#37UQfdI(I33)xSrPXy{WVDNTSQX5Is;O#4G53Wi`f4B1 zuOqGb(}XvPRh-^7)~6!aeL!#7zZjMyT7_saxh}z;x9Ncefj#48|^eX`l z_A|1g=tX0iqy}EH6Lf*v{uQ*Y=fIr94TeyU-Lwg}=^WBQMfa5W-r$weOZ2W=pgj;x zT|w3|W1;$=^5=?mIjPM{m*Dhi;{DG4bJLaYJ$DI+Muru`7E?GO9{7KBzUm|+>uQ3a zZzvr1AS3X@{%#bpsb4`}2~G6av)d|m^w&)mcBV6$+mQDTkmi@!1AC;0eebTV`}SDQ z&ZmCi1`q455+3v=hHrEvEfc|Vo~^3gYn^Jv61`u{HyuyXir=vjoRB# Date: Sat, 5 Dec 2026 18:15:42 +0900 Subject: [PATCH 8/9] Master Thru draft: README says what T8's machine takes when the master goes away Co-Authored-By: Claude Opus 5.5 --- sdk/drafts/master-thru/README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/sdk/drafts/master-thru/README.md b/sdk/drafts/master-thru/README.md index 8f14363f7a..b29d87e5cb 100644 --- a/sdk/drafts/master-thru/README.md +++ b/sdk/drafts/master-thru/README.md @@ -42,6 +42,8 @@ Without trigs on T8 the inputs always pass (HOLD at its maximum holds). A trig o - **T8's AMP page with MASTER TRACK on.** Stock shows nothing; with the module installed it shows the envelopes above, stored in T8's AMP slots. Stock's AMP stage leaves the master's sound alone with them set (heard on an MKI, TESTING.md). Only while the module is installed. - **T8's PLAYBACK page with MASTER TRACK on.** Stock shows nothing; with the module installed it shows the page above. Why: the master has no other page for its source, and a musician looks for THRU's controls there. Only while the module is installed; removing it brings stock's empty page back. Every other track, and T8 with MASTER TRACK off, take stock's path unchanged (the detour replays the stock instruction for them). +- **T8's own machine after the master.** The pages' values are T8's own PLAYBACK and AMP slots, saved with the project. Turn MASTER TRACK off, remove the module, or load the project on a unit without it, and T8's machine takes them as its own values (seen on an MKI with STATIC: AMP's values all the way left, so T8 is silent until its VOL is raised; TESTING.md). Set T8's pages again after turning the master off. + ## How it works Two detours in stock's page selector (0x40031e08), at 0x40031e6a (PLAYBACK) and 0x40031e7e (AMP): for the master each returns this module's page, built once from the unit's own THRU or AMP page (unit.s). Nothing runs per frame. The page's values reach the DSP as every track's PLAYBACK values do. The master keeps stock's name, MASTER. From af5434633efc6c2349300ebedacfd35b175b3390 Mon Sep 17 00:00:00 2001 From: Takuhito-bit <364694452+Takuhito-bit@users.noreply.github.com> Date: Sat, 5 Dec 2026 19:55:36 +0900 Subject: [PATCH 9/9] Master Thru draft: LFOs and scenes on these slots, on an MKI Co-Authored-By: Claude Opus 5.5 --- sdk/drafts/master-thru/TESTING.md | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/sdk/drafts/master-thru/TESTING.md b/sdk/drafts/master-thru/TESTING.md index 05c7511e7d..3d6fd165d2 100644 --- a/sdk/drafts/master-thru/TESTING.md +++ b/sdk/drafts/master-thru/TESTING.md @@ -45,7 +45,16 @@ Stock's master pages, without the module (5 December 2026, MKI, OS 1.40C, captur So the values set on the master's pages stay in T8's PLAYBACK and AMP slots, are saved with the project, and become T8's own machine's values whenever the master goes away, with the module or without it. -Not tested: LFOs on these slots, scenes, the sound (no DSP part yet). +**5 December 2026, MKI, OS 1.40C, base `ddb56b72`, same build (`b026a357`), a third RAM trial over USB (30 minutes), rolled back.** Reported by the developer from the unit, with MASTER TRACK on: + +- LFOs: T8's LFO DEST offers these slots by stock's AMP names, so the module's PAN is listed as BAL. With an LFO on them and the pattern playing, nothing froze, nothing on screen broke and no other track misbehaved. As on stock, the pages' knobs keep showing the set value while an LFO moves it; with no DSP part yet, nothing is heard. +- Scenes: on both pages, holding a scene key and turning a knob assigns the slot as stock does, with the trig keys showing the assignments as on any other page. + +The trial's log: no crash, stall, freeze or skipped track. + +Not tested: the sound (no DSP part yet). + +Known: LFO DEST names the module's PAN as stock's BAL. Whether to rename it there is left open until the slot question on the PR is settled. ## Stock flows