diff --git a/public/licenses/THIRD_PARTY_NOTICES.html b/public/licenses/THIRD_PARTY_NOTICES.html
index 8ebfa15275..7d0a3d8cf1 100644
--- a/public/licenses/THIRD_PARTY_NOTICES.html
+++ b/public/licenses/THIRD_PARTY_NOTICES.html
@@ -3383,6 +3383,56 @@
========================================================================
+SHATTER (Ilia Murzinov; port of Sam Banks’s Octabam module)
+SPDX: MIT
+Used in: modules/shatter: SHATTER
+Notice source: https://raw.githubusercontent.com/sambanks/octabam/0e2ea1dabfafe11aa4ced362cc6f2e0e41890405/LICENSE
+
+MIT License
+
+Copyright (c) 2026 Sam Banks
+
+Portions of the firmware analysis tooling originate from the octamax project
+(https://github.com/mxldyn/octamax), Copyright (c) 2025-2026 Maxolydian,
+also under the MIT License.
+
+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 license covers this repository's own source code and documentation only.
+Transcribed third-party DSP sources, the community modifications carried as
+submodules and the tools fetched by `make setup` are listed with their own
+licences in THIRD_PARTY.md.
+
+It does not extend to any Elektron Music Machines firmware, which is not
+distributed here and remains the property of its copyright holder. Users
+supply their own copy of the official OS. The container-format tooling in
+this repository re-implements Elektron's firmware-update packaging solely for
+interoperability: so that an owner can build and flash a modified image for
+their own unit. Nothing in this project 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 project
+targets.
+
+========================================================================
+
elekloader kit (the formats Modwerk's firmware builder reads and writes)
SPDX: GPL-3.0-or-later
Used in: src/engine/elektron (Modwerk's firmware builder)
diff --git a/public/licenses/THIRD_PARTY_NOTICES.txt b/public/licenses/THIRD_PARTY_NOTICES.txt
index 26feb85bb5..bb63c3ea15 100644
--- a/public/licenses/THIRD_PARTY_NOTICES.txt
+++ b/public/licenses/THIRD_PARTY_NOTICES.txt
@@ -3382,6 +3382,56 @@ targets.
========================================================================
+SHATTER (Ilia Murzinov; port of Sam Banks’s Octabam module)
+SPDX: MIT
+Used in: modules/shatter: SHATTER
+Notice source: https://raw.githubusercontent.com/sambanks/octabam/0e2ea1dabfafe11aa4ced362cc6f2e0e41890405/LICENSE
+
+MIT License
+
+Copyright (c) 2026 Sam Banks
+
+Portions of the firmware analysis tooling originate from the octamax project
+(https://github.com/mxldyn/octamax), Copyright (c) 2025-2026 Maxolydian,
+also under the MIT License.
+
+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 license covers this repository's own source code and documentation only.
+Transcribed third-party DSP sources, the community modifications carried as
+submodules and the tools fetched by `make setup` are listed with their own
+licences in THIRD_PARTY.md.
+
+It does not extend to any Elektron Music Machines firmware, which is not
+distributed here and remains the property of its copyright holder. Users
+supply their own copy of the official OS. The container-format tooling in
+this repository re-implements Elektron's firmware-update packaging solely for
+interoperability: so that an owner can build and flash a modified image for
+their own unit. Nothing in this project 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 project
+targets.
+
+========================================================================
+
elekloader kit (the formats Modwerk's firmware builder reads and writes)
SPDX: GPL-3.0-or-later
Used in: src/engine/elektron (Modwerk's firmware builder)
diff --git a/public/module-sleeves/shatter.svg b/public/module-sleeves/shatter.svg
new file mode 100644
index 0000000000..368fa9110d
--- /dev/null
+++ b/public/module-sleeves/shatter.svg
@@ -0,0 +1,20 @@
+
diff --git a/public/octatrack-modules/shatter/0.1.0-experimental.mwrm b/public/octatrack-modules/shatter/0.1.0-experimental.mwrm
new file mode 100644
index 0000000000..7be8fcdbf4
Binary files /dev/null and b/public/octatrack-modules/shatter/0.1.0-experimental.mwrm differ
diff --git a/scripts/build-module-packages.py b/scripts/build-module-packages.py
index 104d034f96..1342c1ca92 100644
--- a/scripts/build-module-packages.py
+++ b/scripts/build-module-packages.py
@@ -8,7 +8,7 @@
import argparse, hashlib, importlib.util, json, os, re, shutil, struct, subprocess, sys, tempfile
APP = Path(__file__).resolve().parents[1]
-ORDER = ['miniverb', 'tapeecho', 'euclid', 'repitch', 'tapehead', 'airwindows-chorus', 'everb', 'bbd', 'lofi2', 'ring-sc', 'vibrato', 'resonator', 'mackity', 'midiverb', 'ringbank', 'void', 'fuzzbox', 'glitchbox']
+ORDER = ['miniverb', 'tapeecho', 'euclid', 'repitch', 'tapehead', 'airwindows-chorus', 'everb', 'bbd', 'lofi2', 'ring-sc', 'vibrato', 'resonator', 'mackity', 'midiverb', 'ringbank', 'void', 'fuzzbox', 'glitchbox', 'shatter']
# DSP code that stock code reaches through hooks. Output Matrix has no FX menu entry and is also a requested ColdFire module.
HOOKED = ['sidechain-compressor', 'output-matrix']
REQUESTED = ['analog-bassdrum', 'usb-audio-out-tracks-main-cue', 'quantizer', 'synth', 'vector', 'playmodes', 'mute-modes', 'recorder-loop-fix', 'poly8', 'output-matrix', 'quantize-live-rec-toggle', 'apply-scene', 'direct-jump-kyoti', 'dejavu', 'arp-key-locks', 'temp-save', 'tuner', 'scope', 'slow-lfo', 'bar-led', 'stem-rec', 'songbook', 'arr-rows', 'smart-reload', 'defrost', 'bounce']
@@ -635,6 +635,14 @@ def at(base):
donorSha256='3b3f9b15f2f6addfea9fc281f5b9fdf054bf305778059b8d43db41d390f0401f',
fx2Slot=0x400d6004,
slotSha256='79bc740214b4d029e385d06d21e224d04e8f91b53fb26ea08ffa4e5d70964b7a'))
+ if not any(row['id'] == 'shatter' for row in descriptor_guards):
+ # The DARK REV donor and stock NONE at unused FX2 id 0x0a, with the hashes the effects above recorded for
+ # them (npm run module:list); the build checks both against the private OS 1.40C. Never retain stock bytes.
+ descriptor_guards.append(dict(id='shatter', key='SHATTER', author='ilia-murzinov',
+ fxId=0x0a, donorAddress=0x400d58f0,
+ donorSha256='3b3f9b15f2f6addfea9fc281f5b9fdf054bf305778059b8d43db41d390f0401f',
+ fx2Slot=0x400d6004,
+ slotSha256='79bc740214b4d029e385d06d21e224d04e8f91b53fb26ea08ffa4e5d70964b7a'))
for old in descriptor_guards:
module = byid[old['id']]
if module.menu.donor_desc + 0x38 != old['donorAddress'] or module.menu.fx2_id != old['fxId']:
diff --git a/sdk/catalog.json b/sdk/catalog.json
index 7778894c1d..5decf4e869 100644
--- a/sdk/catalog.json
+++ b/sdk/catalog.json
@@ -92,6 +92,11 @@
"version": "0.1.0-experimental",
"addedAt": "2026-12-02T05:02:06Z"
},
+ {
+ "id": "shatter",
+ "version": "0.1.0-experimental",
+ "addedAt": "2026-12-05T22:41:37Z"
+ },
{
"id": "analog-bassdrum",
"version": "0.1.7-experimental",
diff --git a/sdk/cycle-scan/README.md b/sdk/cycle-scan/README.md
index 104bf7baf2..8521ad9126 100644
--- a/sdk/cycle-scan/README.md
+++ b/sdk/cycle-scan/README.md
@@ -118,6 +118,7 @@ runs, once 2.9. Records scanned 23 November 2026:
| lofi2 0.1.1 | 10.3 = 467 (T1 FX2) | – | RING/def | 425 | 654 | 1.10 | – | within 10 % |
| miniverb 0.2.3 | 14.1 = 639 (T1 FX2) | – | RATE=1.01/def | 641 | 699 | 1.00 | – | within 10 % |
| ring-sc 0.2.1 | 7.5 = 340 (T1 FX2) | – | DUCK/def | 5 + 43 keybus | 122 + 43 keybus | – | – | not comparable: the reading does not say what its key bus carried, the scan's was silent; the unit read on d3d71297, the keybus charge (43) was timed on 856cbbcf |
+| shatter 0.1.0 | 3.6 = 163 (T1 FX2) | 4.5 = 204 | HARD/def | 207 | 398 | 0.79 | 0.51 | **outlier** |
| sidechain-compressor 0.2.2 | 5.5 = 249 (T5 FX1) | – | MON=OFF/def | 107 | 107 | – | – | not comparable: the unit measured package 9f22861f, not the published 0.2.2-experimental (d004461e); the reading does not say what its key bus carried, the scan's was silent |
| tapehead 0.1.2 | 9.3 = 421 (T1 FX2) | – | COLOR=NORM/def | 425 | 426 | 0.99 | – | within 10 % |
| vibrato 0.1.0 | – | – | SHP=SINE/def | 204 | 207 | – | – | no in-use reading on the unit |
diff --git a/sdk/cycle-scan/records/shatter.json b/sdk/cycle-scan/records/shatter.json
new file mode 100644
index 0000000000..9eec4f743b
--- /dev/null
+++ b/sdk/cycle-scan/records/shatter.json
@@ -0,0 +1,34 @@
+{
+ "schema": 1,
+ "module": "shatter",
+ "version": "0.1.0-experimental",
+ "sourceSha256": "243aeec6d62511c40e26be82aeca1c695b2b42ff287209f82660d6e46921dcbd",
+ "scanRevision": "cc7cffc1a675a763c5b8d6fbe1659f2b322cc540",
+ "model": "DSP56300FM Table A-1 cycles and the A.2 and 3.5 stalls on one steady block of each --sweep setting; a model, not a measurement",
+ "dearest": {
+ "setting": "SOFT/max",
+ "settings": 12,
+ "instructions": 224.88,
+ "cycles": 398.44,
+ "stalls": 39.5,
+ "stallsByKind": {
+ "agu": 0.19,
+ "arith": 29.94,
+ "arith-tcc": 5.31,
+ "transfer": 4.06
+ }
+ },
+ "defaults": {
+ "setting": "HARD/def",
+ "instructions": 115,
+ "cycles": 207.19,
+ "stalls": 24
+ },
+ "stock": {
+ "comparator": "LO-FI",
+ "setting": "defaults/def",
+ "instructions": 279.56,
+ "cycles": 305.88,
+ "stalls": 15.81
+ }
+}
diff --git a/sdk/imports/shatter-0e2ea1d.json b/sdk/imports/shatter-0e2ea1d.json
new file mode 100644
index 0000000000..59f4e8a457
--- /dev/null
+++ b/sdk/imports/shatter-0e2ea1d.json
@@ -0,0 +1,68 @@
+{
+ "schemaVersion": 1,
+ "repository": "https://github.com/sambanks/octabam",
+ "revision": "0e2ea1dabfafe11aa4ced362cc6f2e0e41890405",
+ "moduleVersion": "0.1.0-experimental",
+ "root": "sdk/octabam/modules/shatter",
+ "modules": [
+ "shatter"
+ ],
+ "files": [
+ {
+ "path": "upstream/README.md",
+ "sourcePath": "modules/shatter/README.md",
+ "sourceBytes": 4229,
+ "sourceGitBlob": "0ff10c560133b1824adeded6a761594eda6d3fb2",
+ "sourceSha256": "83c4c83d6835e2182d86338943b0b3f1b647225f28de2f480cbfc07b0dd6fad5",
+ "vendoredSha256": "83c4c83d6835e2182d86338943b0b3f1b647225f28de2f480cbfc07b0dd6fad5"
+ },
+ {
+ "path": "upstream/manifest.py",
+ "sourcePath": "modules/shatter/manifest.py",
+ "sourceBytes": 4863,
+ "sourceGitBlob": "635ea40323b733d87a8b7f199174731ef6a08914",
+ "sourceSha256": "bae0d7ee3d68b37b2a523c33faff40a37031f41b637759f64c8802c2dd34cc7f",
+ "vendoredSha256": "bae0d7ee3d68b37b2a523c33faff40a37031f41b637759f64c8802c2dd34cc7f"
+ },
+ {
+ "path": "upstream/shatter.asm",
+ "sourcePath": "modules/shatter/shatter.asm",
+ "sourceBytes": 15351,
+ "sourceGitBlob": "02b2d46897c2ba98053224f5742396983461a4ac",
+ "sourceSha256": "8fca3bf6063e989dea2397e0847000fdfe532f39d54ffb102c88e666e938aea2",
+ "vendoredSha256": "8fca3bf6063e989dea2397e0847000fdfe532f39d54ffb102c88e666e938aea2"
+ },
+ {
+ "path": "upstream/tools/remix/peak_limiter.py",
+ "sourcePath": "tools/remix/peak_limiter.py",
+ "sourceBytes": 3960,
+ "sourceGitBlob": "cda4ddd0c4bf1bb6829a839bcaf9e82714380a3b",
+ "sourceSha256": "80188b9073be022dc291ab778e9f5196fcb54a0bf48228f047e99dca83a5690f",
+ "vendoredSha256": "80188b9073be022dc291ab778e9f5196fcb54a0bf48228f047e99dca83a5690f"
+ },
+ {
+ "path": "upstream/tools/verify/verify_shatter.py",
+ "sourcePath": "tools/verify/verify_shatter.py",
+ "sourceBytes": 15771,
+ "sourceGitBlob": "df5997290ef27b352445e7b5bde66b9847b966fe",
+ "sourceSha256": "fd8815ffb290034dff65cfa61a5de08c444e49391e048e6e22285601625ffd79",
+ "vendoredSha256": "fd8815ffb290034dff65cfa61a5de08c444e49391e048e6e22285601625ffd79"
+ },
+ {
+ "path": "upstream/ui.s",
+ "sourcePath": "modules/shatter/ui.s",
+ "sourceBytes": 13603,
+ "sourceGitBlob": "8d9cf40651bc6a209c22fb1f4dad092d9618de68",
+ "sourceSha256": "8b12ceecec96452c6a88f2f9804bba257eead4ed9c00dabe2889be6907399919",
+ "vendoredSha256": "8b12ceecec96452c6a88f2f9804bba257eead4ed9c00dabe2889be6907399919"
+ },
+ {
+ "path": "upstream/LICENSE",
+ "sourcePath": "LICENSE",
+ "sourceBytes": 2112,
+ "sourceGitBlob": "112114d5d319dc4a789dacf1e84b867420a03614",
+ "sourceSha256": "f91a43799d9e31ccc3540f385f68c4d6ff5a096f93ae933be2ce98f6b3f7f113",
+ "vendoredSha256": "f91a43799d9e31ccc3540f385f68c4d6ff5a096f93ae933be2ce98f6b3f7f113"
+ }
+ ]
+}
diff --git a/sdk/machines/octatrack/frame-costs.json b/sdk/machines/octatrack/frame-costs.json
index 817c02ea75..7744838953 100644
--- a/sdk/machines/octatrack/frame-costs.json
+++ b/sdk/machines/octatrack/frame-costs.json
@@ -19,6 +19,7 @@
"resonator": {"first":0.8,"each":0.8,"rest":0,"points":[0.1,0.7,-0.3,0.8],"measured":"resonator 0.1.0-experimental on T1 T3 T6 T7: Dev17 C04 at 126 BPM, trigs on steps 1/5/9/13 of T1-T4, T6, T7 (T2 and T4 play samples), picks on empty C02, Part 1; the effect measured on T1 FX2 in place of DELAY; owner's MKII, OS 1.40C; base development twin 8fd6d456 of base 0.8.1 (built from 9d5aec73a); 16 s a reading; 2026-11-24 (evidence/frame-cost.json)"},
"ring-sc": {"first":0.8,"each":0,"rest":0,"points":[-1.4,0.8,-1.2,-0.1],"measured":"ring-sc 0.2.1-experimental on T1 T3 T6 T7: Dev17 C04 at 126 BPM, trigs on steps 1/5/9/13 of T1-T4, T6, T7 (T2 and T4 play samples), picks on empty C02; owner's MKII; base 0.8 twin 28 053fd054; 8 s a reading; 2026-11-22"},
"ringbank": {"first":4.8,"each":1.5,"rest":0,"points":[1.6,6.3,7.8,4.9],"measured":"ringbank 0.1.0-experimental on T1 T3 T6 T7: MKII, dev twin 46a4d71d; bank A A01 medium (6 tracks) / A02 empty, Part 1 stopped; base 46a4d71dd9654e67cb892c36e2b960c7cae48939b95ac0a87c8dc293fb158007; 8 s a reading; 2026-11-29 (evidence/frame-cost.json)"},
+ "shatter": {"first":4.6,"each":4.6,"rest":0,"points":[-2.7,0.7,5.3,2],"measured":"shatter 0.1.0-experimental on T1 T3 T6 T7: the bank, pattern and Part the unit was on, transport stopped (test:procedure); base development twin 117eb07f2ebc8040, Octatrack MKII, OS 1.40C; 8 s a reading; 2026-12-06 (evidence/frame-cost.json)"},
"sidechain-compressor": {"first":0.9,"each":0.5,"measured":"On T5 FX1, base 0.7.8: +0.5 on the mean (evidence/cpu-price.json); the longest frame not measured"},
"synth": {"first":32.8,"each":0.5,"rest":0,"points":[29.9,33.3,31.3,31.8],"measured":"synth 0.1.5-experimental on T1 T3 T6 T7: Dev17 C04 at 126 BPM, trigs on steps 1/5/9/13 of T1-T4, T6, T7 (T2 and T4 play samples; the trigs placed again in the working copy on 26 November 2026, never saved: the card's copy of bank C had none), picks on empty C02, Part 1; owner's MKII; base 46c30886 (0.8 development twin of main 48f4a9b9c, base 24e480c4); 8 s a reading; 2026-11-26 (evidence/frame-cost.json)","price":17,"paused":20},
"syntiz": {"first":18.6,"each":5.5,"rest":0,"points":[16.2,24.1,29.6,30.9],"measured":"syntiz 0.1.1-experimental on T1 T3 T6 T7: Dev17 C04 at 126 BPM, trigs on steps 1/5/9/13 of T1-T4, T6, T7 (T2 and T4 play samples), picks on empty C02, Part 1; owner's MKII; base 678843cc (base 0.8 development twin, main b5864cce7); 8 s a reading; 2026-11-23 (evidence/frame-cost.json)","paused":2.2},
diff --git a/sdk/machines/octatrack/module-adapters/standalone-recipes.json b/sdk/machines/octatrack/module-adapters/standalone-recipes.json
index b1376ded28..5bcf61628b 100644
--- a/sdk/machines/octatrack/module-adapters/standalone-recipes.json
+++ b/sdk/machines/octatrack/module-adapters/standalone-recipes.json
@@ -233,9 +233,9 @@
"src/engine/coldfire-elf.ts": "319ca0d835d1b0c602c8f4b06990016d0ebfe246cedbfc596cea3cc7adfe3cd2",
"src/engine/module-build.ts": "dcd8397b8cecf6fab61debd9aa2f86f612da0ca6ccf363c79d56033bc170b993",
"src/catalog/modules.ts": "14304ea8450f8ec7ecaaf3ccf9e764929161288babe7b34cb37ff41e44fe1b43",
- "src/engine/assets/dsp-packages.json": "cf91b4e8e376aa7103dd96dd5a1af7d72b4c7e33466d08215016e841ac3d3767",
- "src/engine/assets/descriptor-recipes.json": "1cb1864d95aff572b1627a7e3b28856a500626c26ed3240f4838b217ab134890",
- "src/engine/assets/menu-recipes.json": "d90270e960e7ceb197e93d1ad58bfd705311c823a6e47df641b9c550a4be5a61",
+ "src/engine/assets/dsp-packages.json": "a49b6ee3fc0d24938d3acf19c34f10b81429fc6737dd520d6b34e96c2de15fd7",
+ "src/engine/assets/descriptor-recipes.json": "b8a519952e56179fc428a3249899d8e1c9dfba1c24091b78ce7951e6eb69dfda",
+ "src/engine/assets/menu-recipes.json": "892ea53fe15d9be35c7d25cd48093333a08c52186c28ba93bfd4423d779fca69",
"src/engine/assets/rom-packages.json": "68d9f0e5f388910e20cd00f5b00cbc1eb606258921d90d4a0d87dab934f835cb",
"sdk/firmware_builder/__init__.py": "4d179f74220ab956f7e27550d315337c5af053c80a217feeba75f5db91b590ff",
"sdk/firmware_builder/codec/__init__.py": "bdcd33ceb83a11ef027d0f6dd64d98c05e7665915d241bb2896e75140d1b49cb",
@@ -468,9 +468,9 @@
"src/engine/coldfire-elf.ts": "319ca0d835d1b0c602c8f4b06990016d0ebfe246cedbfc596cea3cc7adfe3cd2",
"src/engine/module-build.ts": "dcd8397b8cecf6fab61debd9aa2f86f612da0ca6ccf363c79d56033bc170b993",
"src/catalog/modules.ts": "14304ea8450f8ec7ecaaf3ccf9e764929161288babe7b34cb37ff41e44fe1b43",
- "src/engine/assets/dsp-packages.json": "cf91b4e8e376aa7103dd96dd5a1af7d72b4c7e33466d08215016e841ac3d3767",
- "src/engine/assets/descriptor-recipes.json": "1cb1864d95aff572b1627a7e3b28856a500626c26ed3240f4838b217ab134890",
- "src/engine/assets/menu-recipes.json": "d90270e960e7ceb197e93d1ad58bfd705311c823a6e47df641b9c550a4be5a61",
+ "src/engine/assets/dsp-packages.json": "a49b6ee3fc0d24938d3acf19c34f10b81429fc6737dd520d6b34e96c2de15fd7",
+ "src/engine/assets/descriptor-recipes.json": "b8a519952e56179fc428a3249899d8e1c9dfba1c24091b78ce7951e6eb69dfda",
+ "src/engine/assets/menu-recipes.json": "892ea53fe15d9be35c7d25cd48093333a08c52186c28ba93bfd4423d779fca69",
"src/engine/assets/rom-packages.json": "68d9f0e5f388910e20cd00f5b00cbc1eb606258921d90d4a0d87dab934f835cb",
"sdk/firmware_builder/__init__.py": "4d179f74220ab956f7e27550d315337c5af053c80a217feeba75f5db91b590ff",
"sdk/firmware_builder/codec/__init__.py": "bdcd33ceb83a11ef027d0f6dd64d98c05e7665915d241bb2896e75140d1b49cb",
diff --git a/sdk/octabam/licenses/THIRD_PARTY_NOTICES.txt b/sdk/octabam/licenses/THIRD_PARTY_NOTICES.txt
index 47e77a883c..c393e6b07b 100644
--- a/sdk/octabam/licenses/THIRD_PARTY_NOTICES.txt
+++ b/sdk/octabam/licenses/THIRD_PARTY_NOTICES.txt
@@ -2500,3 +2500,53 @@ their own unit. Nothing in this project 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 project
targets.
+
+========================================================================
+
+SHATTER (Ilia Murzinov; port of Sam Banks’s Octabam module)
+SPDX: MIT
+Used in: modules/shatter: SHATTER
+Notice source: https://raw.githubusercontent.com/sambanks/octabam/0e2ea1dabfafe11aa4ced362cc6f2e0e41890405/LICENSE
+
+MIT License
+
+Copyright (c) 2026 Sam Banks
+
+Portions of the firmware analysis tooling originate from the octamax project
+(https://github.com/mxldyn/octamax), Copyright (c) 2025-2026 Maxolydian,
+also under the MIT License.
+
+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 license covers this repository's own source code and documentation only.
+Transcribed third-party DSP sources, the community modifications carried as
+submodules and the tools fetched by `make setup` are listed with their own
+licences in THIRD_PARTY.md.
+
+It does not extend to any Elektron Music Machines firmware, which is not
+distributed here and remains the property of its copyright holder. Users
+supply their own copy of the official OS. The container-format tooling in
+this repository re-implements Elektron's firmware-update packaging solely for
+interoperability: so that an owner can build and flash a modified image for
+their own unit. Nothing in this project 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 project
+targets.
diff --git a/sdk/octabam/licenses/manifest.json b/sdk/octabam/licenses/manifest.json
index 679aaa3f87..ff1e79c64f 100644
--- a/sdk/octabam/licenses/manifest.json
+++ b/sdk/octabam/licenses/manifest.json
@@ -323,6 +323,22 @@
"usedIn": [
"modules/void: VOID"
]
+ },
+ {
+ "id": "shatter",
+ "name": "SHATTER (Ilia Murzinov; port of Sam Banks’s Octabam module)",
+ "spdx": "MIT",
+ "noticeFile": "shatter.txt",
+ "sources": [
+ {
+ "url": "https://raw.githubusercontent.com/sambanks/octabam/0e2ea1dabfafe11aa4ced362cc6f2e0e41890405/LICENSE",
+ "revision": "0e2ea1dabfafe11aa4ced362cc6f2e0e41890405",
+ "path": "LICENSE"
+ }
+ ],
+ "usedIn": [
+ "modules/shatter: SHATTER"
+ ]
}
],
"moduleComponents": {
@@ -368,6 +384,9 @@
],
"grain": [
"model-tg"
+ ],
+ "shatter": [
+ "shatter"
]
}
}
diff --git a/sdk/octabam/licenses/shatter.txt b/sdk/octabam/licenses/shatter.txt
new file mode 100644
index 0000000000..112114d5d3
--- /dev/null
+++ b/sdk/octabam/licenses/shatter.txt
@@ -0,0 +1,42 @@
+MIT License
+
+Copyright (c) 2026 Sam Banks
+
+Portions of the firmware analysis tooling originate from the octamax project
+(https://github.com/mxldyn/octamax), Copyright (c) 2025-2026 Maxolydian,
+also under the MIT License.
+
+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 license covers this repository's own source code and documentation only.
+Transcribed third-party DSP sources, the community modifications carried as
+submodules and the tools fetched by `make setup` are listed with their own
+licences in THIRD_PARTY.md.
+
+It does not extend to any Elektron Music Machines firmware, which is not
+distributed here and remains the property of its copyright holder. Users
+supply their own copy of the official OS. The container-format tooling in
+this repository re-implements Elektron's firmware-update packaging solely for
+interoperability: so that an owner can build and flash a modified image for
+their own unit. Nothing in this project 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 project
+targets.
diff --git a/sdk/octatrack/modules/shatter/LICENSE b/sdk/octatrack/modules/shatter/LICENSE
new file mode 100644
index 0000000000..112114d5d3
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/LICENSE
@@ -0,0 +1,42 @@
+MIT License
+
+Copyright (c) 2026 Sam Banks
+
+Portions of the firmware analysis tooling originate from the octamax project
+(https://github.com/mxldyn/octamax), Copyright (c) 2025-2026 Maxolydian,
+also under the MIT License.
+
+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 license covers this repository's own source code and documentation only.
+Transcribed third-party DSP sources, the community modifications carried as
+submodules and the tools fetched by `make setup` are listed with their own
+licences in THIRD_PARTY.md.
+
+It does not extend to any Elektron Music Machines firmware, which is not
+distributed here and remains the property of its copyright holder. Users
+supply their own copy of the official OS. The container-format tooling in
+this repository re-implements Elektron's firmware-update packaging solely for
+interoperability: so that an owner can build and flash a modified image for
+their own unit. Nothing in this project 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 project
+targets.
diff --git a/sdk/octatrack/modules/shatter/README.md b/sdk/octatrack/modules/shatter/README.md
new file mode 100644
index 0000000000..7305ce3884
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/README.md
@@ -0,0 +1,54 @@
+# Shatter
+
+Version 0.1.0-experimental · by @ilia-murzinov
+
+## Overview
+
+SHATTER is a sound destruction effect for Octatrack MKI and MKII on OS 1.40C. It folds, clips and crushes the track signal, then feeds part of the result back through a tone shelf. HARD and SOFT select clipping curves. CHAOS flips feedback polarity as it runs. MIX blends dry and processed sound. LIM limits the mixed peak.
+
+## Controls
+
+Open the FX2 control page for the first six controls. Open FX2 SETUP to select SHATTER and reach the second page.
+
+| Page | Encoder | LCD label | Range | Default | What it does |
+| --- | --- | --- | --- | --- | --- |
+| FX2 | A | DRV | 0–127 | 0 | Drives the signal before the dirt stages. Output compensation follows the chain. |
+| FX2 | B | FOLD | 0–127 | 0 | Folds the waveform. 0 is off; higher values fold more. |
+| FX2 | C | CLIP | 0–127 | 0 | Sets the clip threshold. 0 is open; 127 is a brick wall. |
+| FX2 | D | CRSH | 0–127 | 0 | Combines bit-depth and sample-rate reduction. |
+| FX2 | E | FDBK | 0–127 | 0 | Feeds the dirt stages back into the signal. CHAOS flips its polarity. |
+| FX2 | F | MIX | 0–127 | 127 | Blends dry and processed sound. 0 is exact dry when LIM is off. |
+| FX2 SETUP | A | MODE | HARD / SOFT / CHAOS | HARD | Selects hard clipping, soft clipping or changing feedback polarity. |
+| FX2 SETUP | B | TONE | 0–127 | 64 | Sets the feedback-loop tone shelf. Lower values are darker. |
+| FX2 SETUP | C | RATE | 0–127 | 64 | Sets the CHAOS polarity-flip rate. Ignored in HARD and SOFT. |
+| FX2 SETUP | D | LIM | 0–127 | 0 | Sets the stereo-linked peak limiter after MIX. 0 is off. |
+
+## Usage
+
+Select an audio track. Hold [FUNC] and press [FX2] to open FX2 SETUP. Turn LEVEL to SHATTER and press [YES]. Press [FX2] for DRV, FOLD, CLIP, CRSH, FDBK and MIX. Return to FX2 SETUP to adjust MODE, TONE, RATE and LIM.
+
+## Quick tutorial
+
+1. Select an audio track and choose SHATTER in FX2 SETUP.
+2. Raise FOLD or CRSH to add strong harmonics or stepped, reduced-rate sound.
+3. Raise FDBK and choose CHAOS for a changing feedback texture. Turn MIX to 0 for dry sound, or select NONE in FX2 SETUP to remove SHATTER.
+
+## Compatibility and limitations
+
+SHATTER targets Octatrack MKI and MKII with OS 1.40C. It uses FX2. The current base refuses SHATTER beside Analog BD because that pairing has not been reviewed. This restriction does not establish an intrinsic DSP collision. Folding, clipping and crush intentionally create strong harmonics and aliasing at extreme settings. High feedback can leave a tail after the input stops.
+
+## Tests and measurements
+
+See [TESTING.md](TESTING.md) for native and Modwerk checks, package identity and the hardware report. The native source is pinned to sambanks/octabam at `0e2ea1dabfafe11aa4ced362cc6f2e0e41890405`. Host DSP tests, performance analysis and a reversible MKII unit phase passed on the current catalog package. No audible result or power-cycle persistence claim is made.
+
+## Authorship and licences
+
+Ilia Murzinov is the original SHATTER module author named in the native manifest. This Modwerk port uses code from [sambanks/octabam](https://github.com/sambanks/octabam/tree/0e2ea1dabfafe11aa4ced362cc6f2e0e41890405). The full upstream MIT licence and copyright notice are kept in [LICENSE](LICENSE) and [upstream/LICENSE](upstream/LICENSE). The import record lists every copied file.
+
+## Screens and audio
+
+The following captures show the actual Octatrack MKII LCD over USB. No audio capture is available.
+
+
+
+
diff --git a/sdk/octatrack/modules/shatter/TESTING.md b/sdk/octatrack/modules/shatter/TESTING.md
new file mode 100644
index 0000000000..dab550416d
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/TESTING.md
@@ -0,0 +1,74 @@
+# Shatter testing
+
+## Version 0.1.0-experimental
+
+Native source: sambanks/octabam `0e2ea1dabfafe11aa4ced362cc6f2e0e41890405`. `import-record.json` lists every copied file with its source Git blob and SHA-256. The full upstream MIT licence and copyright notice remain in `LICENSE` and `upstream/LICENSE`.
+
+The exact Modwerk package used for the successful hardware trial and captures was `/private/tmp/shatter-modwerk-dev/shatter-238.mwrm`, SHA-256 `ec756c7f2f6974f32cdb7649ff869ba633604ebe1c4ae39a86bb68b48d724220`. The package was built from the same source as `shatter.mwrm`.
+
+Build command and declared budget: `npm run module:dev -- shatter --build-only --cycles 238 --cycles-kind modeled --state 32 --out /private/tmp/shatter-modwerk-dev/shatter-238.mwrm`.
+
+## Native build and comparison
+
+The pinned Octabam source's `make check REMIX=shatter` passed its runnable checks and restored the shipping image. Its USB runtime check skipped because no unit was connected. `tools/verify/verify_shatter.py` passed its control, feedback, limiter, two-instance and runaway checks.
+
+The pinned DSP56300 toolchain was `8b731966f9792789adc39fe180a8cf68508f816a`. `make cycles REMIX=shatter` counted 238 DSP cycles/sample per instance. The native build uses 494 DSP program words per core, a shared 128-word FOLD table per core, 32 X-state words per instance and 1,644 bytes of native ColdFire code/data with no BSS. These are native build estimates, not Modwerk package or chip measurements. Four FX2 instances account for 952 counted cycles/sample on one core before stock work.
+
+`python3 tools/harness/benchmark_stock_dsp.py --blocks 4096` measured stock effects on the pinned stock image. LO-FI was the closest functional comparator at 275.4375 executed instructions/sample. DJ EQ was the dearest stock effect at 293.375. These DSP-host instruction counts are not chip cycles.
+
+## Modwerk DSP checks
+
+The Modwerk manifest copies each nonnegative FOLD table coefficient from Y1 to X0, then multiplies it by the signal sample with a signed DSP instruction. This keeps the fold calculation within the module and leaves shared Octabam build tools unchanged.
+
+`python3 -B sdk/drafts/shatter/verify.py` passed source parity, instruction decoding, state bounds, deterministic stereo output over a knob sweep, initialized state, exact dry at MIX=0/LIM=0, silence stability at high drive and feedback, CHAOS and LIM output, limiter peak reduction and rails, and two independent instances. Its emulator meter reported 156.6 instructions/sample at defaults. That is a host-emulator count, not a chip-cycle measurement.
+
+The host `fx:audit` renders show strong intentional aliasing at extreme drive, fold, clip, crush, feedback and limiter settings. Idle output settles near −41.5 dBFS at that setting. At neutral nonlinear settings with feedback 64, tones stayed within audit limits and idle reached 1 LSB (−138.5 dBFS). A separate DC run measured −58.8 dBFS after 1.5 seconds. These host renders do not prove the Octatrack's audible result.
+
+The package contains 2,412 bytes of code/data, 552 DSP words, 238 modeled cycles and 32 state words in FX2. The 238-cycle value comes from the pinned native build, not a Modwerk hardware measurement.
+
+A later deterministic rebuild produced `shatter-final.mwrm`, SHA-256 `bfdda27e7438896ebd34c5924e191078666fb0a9c92a00d665eef08266ac516f`. It differs from the hardware-tested package by one MWRM header byte: the DSP init offset changed from 2 to 3; image, relocations and DSP words are identical. A repeat build produced the same new hash. The unit test could not start on this rebuilt package because the base reported `The Octatrack is busy; its installed module set could not be confirmed.` The hardware evidence below applies to the earlier `ec756c7f…` package only. The rebuilt package is not hardware-qualified.
+
+After the developer rebooted the unit, the full procedure was retried with `shatter-final.mwrm`. The unit answered status and inventory, but `device:test` again stopped before trial because the base could not confirm the installed module-set identity. Shatter remained in inventory. The procedure restored A02 Part 2 unchanged; dirty Part 1 remained at its original working and saved hashes. Record: `/private/tmp/shatter-release-procedure-2026-12-05-f/procedure.md`. No soak, unit cost run, or manual test ran on the rebuilt package.
+
+On 6 December, `npm run test:procedure -- shatter --share /tmp/shatter-release-share.sock` rebuilt the catalog USB package and reached the unit. The unit again refused before trial with `The Octatrack is busy; its installed module set could not be confirmed.` Software checks, compatibility, package build, unit status, inventory and Part read passed; the script restored A02 Part 2 unchanged. Dirty Part 1 stayed untouched. Shatter remains in the unit inventory. No device test, soak, unit cost run, or manual check ran. Record: `/var/folders/sg/1jwbnfbs6_34d8qg69b_28rc0000gn/T/modwerk-procedure/shatter-2026-12-05-42176af1/procedure.md`.
+
+`npm run test:procedure -- shatter` was repeated after the reboot on 5 December 2026 with rebuilt package `bfdda27e7438896ebd34c5924e191078666fb0a9c92a00d665eef08266ac516f`. It stopped before trial at `device:test`: `The Octatrack is busy; its installed module set could not be confirmed.` No test result is claimed for this package. The saved Part 2 was restored unchanged; dirty Part 1 stayed untouched. Full record: `/private/tmp/shatter-release-procedure-2026-12-05-f/procedure.md`.
+
+An earlier catalog USB package used SHA-256 `a8098c07331fe0a4734f91cbbfbabee6b1a357e7b494c326ae68d76349bfb3f8`. The procedure log above names that build: the identity check failed before trial, so it has no hardware test result.
+
+The current source uses signed multiplies for the FOLD table and ships as package SHA-256 `7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837`. On 6 December, the procedure was retried with `/tmp/shatter-release-share.sock`, but preflight stopped before software checks because the unit answered `the unit is away`. No test ran on this package. Record: `/var/folders/sg/1jwbnfbs6_34d8qg69b_28rc0000gn/T/modwerk-procedure/shatter-2026-12-06-bdbc616e/procedure.md`.
+
+After reconnecting, the same package reached a development twin of base `880958086c8fe3f1` on the MKII. `test:procedure` first stopped at its software gate: the stale performance stamp, then a doctor error that repeated the Octatrack qualification failure under the other Shatter for the Zoom pedal. The Modwerk DSP source was measured again and stamped below. The unit phase was then run directly with the procedure's own `--unit-phase` command, under the unit queue. Preflight and unit read passed. `device:test` stopped before trial: `The Octatrack is busy; its installed module set could not be confirmed.` No current-package DSP execution, soak or cost reading is claimed. Inventory still named Shatter before and after the attempt. A02 Part 2 remained byte-identical to its saved copy; dirty A01 Part 1 was untouched. The unit was RAM-booted back to its starting base `eb6679620d0c9ed7`. Evidence: `/private/tmp/shatter-unit-phase-20261206/unit-steps.json` and `device-test.md` in that folder.
+
+A fresh development twin `117eb07f2ebc8040` booted from RAM with an empty inventory and no saved modules. On that twin, the same package `7d11bcdb…` passed the procedure's unit phase: `device:test` ran all eight instances, knob sweeps and 12 Part switches with no crash, stall, freeze or skipped track. The 120-second soak passed 2,400 operations. `device:price --write` measured three 8-second readings per state and admitted SHATTER alone on the empty and medium patterns, with 0 dropped renders and 0 stalls. The instance curve reported first 4.6 and each 4.6 points of a frame. Trial rollback left inventory empty; A02 Part 2 was reloaded to its saved bytes, and dirty A01 Part 1 was untouched. The unit phase record is `/private/tmp/shatter-fresh-unit-phase-20261206/unit-steps.json`; pricing is in `evidence/cpu-price.json` and `evidence/frame-cost.json`.
+
+During a separate reversible trial of this package, USB LCD captures of the FX2 control and FX2 SETUP pages matched the README and were saved in `media/`. The trial was recovered, inventory returned to empty, and A02 Part 2 was reloaded to its saved bytes. An attempt to record MAIN/CUE through the local `rec` tool returned `Octatrack not found`, so no audio capture or dropout claim is made. The unit was left on the fresh development twin for the remaining clean-commit procedure.
+
+## Performance and stress
+
+`node scripts/cycle-scan.mjs record shatter` scanned the current Modwerk DSP source in an isolated Octabam tree with a freshly built `-steptrace` host. SOFT/max measured 224.88 decoded instructions/sample and 398.44 modeled DSP56300 cycles/sample, including 39.5 modeled stalls. The two signed-FOLD moves add two instructions/sample to the prior source. This is a cycle model, not a chip measurement. `npm run perf:audit -- check sdk/octatrack/modules/shatter/evidence/performance.json --stamp` passed on source `243aeec6d625…`. The native static count of 238 plus the two one-word moves is 240 cycles/sample before stalls; four instances use 960 of the 3,120-cycle budget before stock work.
+
+`python3 tools/harness/pressure.py price --remix shatter --out out/shatter-performance` reported four instances per core at 952 static cycles/sample. `python3 tools/harness/pressure.py render --remix shatter --top 1 --sample 0 --seconds 2 --out out/shatter-performance` rendered both core layouts without clobbers, stray writes or hangs. Host peaks were 848.9 and 850.8 instructions/sample per core for four instances.
+
+`python3 tools/harness/stress_project.py --remix shatter --source '/Users/iliamurzinov/projects/octabam/template_project/!DEF_N1'` generated eight FLEX tracks, three LFOs per track, 12 lockable FX2 controls, 1,024 trigs and 20,944 parameter-lock bytes. `ot_emu` rendered 2,500 frames from that project with nonzero audio. This stress run was on native Octabam, not the Modwerk package or hardware. It does not prove ColdFire event delivery or chip load.
+
+## Hardware report
+
+5 December 2026, Octatrack MKII, OS 1.40C, private development twin `880958086c8fe3f1`, built from the local stock OS. The exact package above passed `device:test` for 90 seconds. It exercised two independent T1/T5 instances, all eight instances at once, knob sweeps and Part changes. The device test reported no crash, stall, freeze or skipped track. Peak readings with eight instances were CPU 358 permille, DSP core 1 486 permille (peak 497), DSP core 0 571 permille (peak 714), and longest frame 421 µs. The scripted test rolled back. Inventory was empty afterwards.
+
+`test:procedure` completed on the exact package through unit restore. It ran the named medium pattern in A01 with six tracks and STATIC samples on T2/T5, and used clean A02 Part 2 as its restore point. Steps 1, 3, 4, and 6–10 passed. Step 5 was deliberately skipped (`--no-emulator`). Step 11 manual checks and step 12 submitter checks remain open. Full record: `/private/tmp/shatter-release-procedure-2026-12-05-e/procedure.md`.
+
+The procedure's scripted unit pass tested T1/T5 instances, all eight instances together, knob sweeps and 12 Part switches. It reported no crash, stall, freeze or skipped track. The 120-second soak completed 2,400 operations at 19.7 operations/second with no failures. Unit cost admission passed against the medium scene; see `evidence/cpu-price.json` and `evidence/frame-cost.json` for generated readings. The procedure restored A02 Part 2 with working bytes equal to saved bytes and no installed modules. Part 1 was not used or changed.
+
+After the procedure, separate manual trials were recovered to normal base operation. Part 2 was reloaded to its saved start hash `6b14c3caf4ef9803`; Part 1 remained at its original dirty working/saved hashes `7e1fb4f3ae02050e` / `e8684d310886d4ce`. The module is still in the unit's RAM inventory: removal and the rebuilt-package test returned busy, so it was left installed rather than changing another Part. No saved Part bytes changed in recovery. The rebuilt package retry is recorded in `/private/tmp/shatter-release-procedure-2026-12-05-e/procedure.md`.
+
+USB captures show the FX2 controls and setup labels. Manual MODE selection was verified on the setup screen: from HARD, `enc A+10` displayed CHAOS; `enc A-5` displayed SOFT; another `enc A-5` displayed HARD. The screen refresh needed a one-second wait after each encoder command. Captures are saved as `evidence/hardware-mode-hard.png`, `evidence/hardware-mode-soft.png` and `evidence/hardware-mode-chaos.png`. No listening judgement, Keep, power cycle, reboot persistence, MIDI/scenes/recording, or Analog BD coexistence is claimed. No firmware flash or power cycle was performed. The declared Analog BD conflict remains because the current base refuses that pairing; changing the base is outside this module task.
+
+## Remaining release gates
+
+- Run the full procedure from a clean commit on the current catalog package hash `7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837`. Preserve the dirty Part 1.
+- Complete remaining step 11 edge cases: memory saturation/adjacent delay, USB MAIN/CUE capture and saved-project lifecycle checks; record each result truthfully.
+- Submitter must judge sound and timing, test MIDI/scenes/recording, coexistence with their installed modules, and decide whether to Keep and power-cycle. These require the submitter's hands and ears.
+- Complete the module release checks only after those stages. Current base refusal of Analog BD is an explicit declared conflict; do not change base code here.
+
+The module is not release-qualified yet.
diff --git a/sdk/octatrack/modules/shatter/dc-tone.raw b/sdk/octatrack/modules/shatter/dc-tone.raw
new file mode 100644
index 0000000000..a2322b3a36
Binary files /dev/null and b/sdk/octatrack/modules/shatter/dc-tone.raw differ
diff --git a/sdk/octatrack/modules/shatter/dc.raw b/sdk/octatrack/modules/shatter/dc.raw
new file mode 100644
index 0000000000..d11959e6b4
Binary files /dev/null and b/sdk/octatrack/modules/shatter/dc.raw differ
diff --git a/sdk/octatrack/modules/shatter/engine.asm b/sdk/octatrack/modules/shatter/engine.asm
new file mode 100644
index 0000000000..e6f670c9e3
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/engine.asm
@@ -0,0 +1,6 @@
+; Original Octamod development scaffold. No effect is implemented.
+; init/proc form the native insert entry contract; proc leaves in-place audio unchanged.
+init:
+ rts
+proc:
+ rts
diff --git a/sdk/octatrack/modules/shatter/evidence/cpu-price.json b/sdk/octatrack/modules/shatter/evidence/cpu-price.json
new file mode 100644
index 0000000000..f74bef8f92
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/evidence/cpu-price.json
@@ -0,0 +1,146 @@
+{
+ "module": "shatter",
+ "version": "0.1.0-experimental",
+ "base": "development twin 117eb07f2ebc8040, Octatrack MKII, OS 1.40C",
+ "scene": "the bank, pattern and Part the unit was on, transport stopped (test:procedure)",
+ "inputs": {
+ "transport": "playing"
+ },
+ "seconds": 8,
+ "readings": 3,
+ "measuredAt": "2026-12-06T00:40:11.933Z",
+ "result": {
+ "id": "shatter",
+ "version": "0.1.0-experimental",
+ "packageSha256": "7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837",
+ "before": {
+ "frame": 33.8,
+ "frameMax": 78.6,
+ "frames": 67179,
+ "skipped": 0,
+ "cpu": 53.5,
+ "dsp1to4": 37.8,
+ "dsp5to8": 45.8,
+ "dsp1to4Peak": 39.7,
+ "dsp5to8Peak": 48.3,
+ "readings": 3,
+ "spread": {
+ "frame": 0,
+ "cpu": 0.3,
+ "dsp1to4": 0.5,
+ "dsp5to8": 3.5,
+ "frameMax": 4.7,
+ "dsp1to4Peak": 0.2,
+ "dsp5to8Peak": 0.6
+ }
+ },
+ "atRest": {
+ "frame": 33.7,
+ "frameMax": 76.6,
+ "frames": 67112,
+ "skipped": 0,
+ "cpu": 50,
+ "dsp1to4": 37.7,
+ "dsp5to8": 46.1,
+ "dsp1to4Peak": 39.7,
+ "dsp5to8Peak": 48.3,
+ "readings": 3,
+ "spread": {
+ "frame": 0,
+ "cpu": 0,
+ "dsp1to4": 0.1,
+ "dsp5to8": 3.5,
+ "frameMax": 1.3,
+ "dsp1to4Peak": 0.1,
+ "dsp5to8Peak": 0.6
+ }
+ },
+ "atRestAdds": {
+ "frame": -0.1,
+ "cpu": -3.5,
+ "dsp1to4": -0.1,
+ "dsp5to8": 0.3,
+ "dsp1to4Peak": 0,
+ "dsp5to8Peak": 0
+ },
+ "inUse": {
+ "frame": 33.7,
+ "frameMax": 78.3,
+ "frames": 67151,
+ "skipped": 0,
+ "cpu": 50.1,
+ "dsp1to4": 41.4,
+ "dsp5to8": 47.1,
+ "dsp1to4Peak": 44.2,
+ "dsp5to8Peak": 48.3,
+ "readings": 3,
+ "spread": {
+ "frame": 0,
+ "cpu": 0.2,
+ "dsp1to4": 0.2,
+ "dsp5to8": 0,
+ "frameMax": 3.8,
+ "dsp1to4Peak": 0,
+ "dsp5to8Peak": 0.7
+ }
+ },
+ "inUseAdds": {
+ "frame": -0.1,
+ "cpu": -3.4,
+ "dsp1to4": 3.6,
+ "dsp5to8": 1.3,
+ "dsp1to4Peak": 4.5,
+ "dsp5to8Peak": 0
+ },
+ "inUseOn": "T1 FX2",
+ "curve": {
+ "tracks": [
+ "T1",
+ "T3",
+ "T6",
+ "T7"
+ ],
+ "points": [
+ 76.6,
+ 73.9,
+ 77.3,
+ 81.9,
+ 78.6
+ ],
+ "adds": [
+ -2.7,
+ 0.7,
+ 5.3,
+ 2
+ ],
+ "first": 4.6,
+ "each": 4.6,
+ "notes": [],
+ "admission": [
+ {
+ "pattern": "empty",
+ "number": 2,
+ "track": "T1",
+ "seconds": 8,
+ "admitted": true,
+ "frameMax": 54.1,
+ "frame": 28.8,
+ "dropped": 0,
+ "stalls": 0
+ },
+ {
+ "pattern": "medium",
+ "number": 1,
+ "track": "T1",
+ "seconds": 8,
+ "admitted": true,
+ "frameMax": 77.7,
+ "frame": 33.7,
+ "dropped": 0,
+ "stalls": 0
+ }
+ ]
+ },
+ "rolledBack": true
+ }
+}
diff --git a/sdk/octatrack/modules/shatter/evidence/cycle-scan.json b/sdk/octatrack/modules/shatter/evidence/cycle-scan.json
new file mode 100644
index 0000000000..1de147bc48
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/evidence/cycle-scan.json
@@ -0,0 +1,27 @@
+{
+ "schema": 1,
+ "module": "shatter",
+ "version": "0.1.0-experimental",
+ "sourceSha256": "f46e6d32b75af41734aeabc1a9406653f16c98370762d89fa9d3575bb03c0e8b",
+ "scanRevision": "cc7cffc1a675a763c5b8d6fbe1659f2b322cc540",
+ "model": "DSP56300FM Table A-1 cycles and the A.2 and 3.5 stalls on one steady block of each --sweep setting; a model, not a measurement",
+ "dearest": {
+ "setting": "SOFT/max",
+ "settings": 12,
+ "instructions": 222.88,
+ "cycles": 396.44,
+ "stalls": 39.5,
+ "stallsByKind": {
+ "agu": 0.19,
+ "arith": 29.94,
+ "arith-tcc": 5.31,
+ "transfer": 4.06
+ }
+ },
+ "defaults": {
+ "setting": "HARD/def",
+ "instructions": 113,
+ "cycles": 205.19,
+ "stalls": 24
+ }
+}
diff --git a/sdk/octatrack/modules/shatter/evidence/frame-cost.json b/sdk/octatrack/modules/shatter/evidence/frame-cost.json
new file mode 100644
index 0000000000..6bda9037a9
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/evidence/frame-cost.json
@@ -0,0 +1,55 @@
+{
+ "module": "shatter",
+ "version": "0.1.0-experimental",
+ "base": "development twin 117eb07f2ebc8040, Octatrack MKII, OS 1.40C",
+ "scene": "the bank, pattern and Part the unit was on, transport stopped (test:procedure)",
+ "seconds": 8,
+ "measuredAt": "2026-12-06T00:40:11.933Z",
+ "tracks": [
+ "T1",
+ "T3",
+ "T6",
+ "T7"
+ ],
+ "rest": 0,
+ "first": 4.6,
+ "each": 4.6,
+ "points": [
+ 76.6,
+ 73.9,
+ 77.3,
+ 81.9,
+ 78.6
+ ],
+ "adds": [
+ -2.7,
+ 0.7,
+ 5.3,
+ 2
+ ],
+ "admission": [
+ {
+ "pattern": "empty",
+ "number": 2,
+ "track": "T1",
+ "seconds": 8,
+ "admitted": true,
+ "frameMax": 54.1,
+ "frame": 28.8,
+ "dropped": 0,
+ "stalls": 0
+ },
+ {
+ "pattern": "medium",
+ "number": 1,
+ "track": "T1",
+ "seconds": 8,
+ "admitted": true,
+ "frameMax": 77.7,
+ "frame": 33.7,
+ "dropped": 0,
+ "stalls": 0
+ }
+ ],
+ "notes": []
+}
diff --git a/sdk/octatrack/modules/shatter/evidence/hardware-mode-chaos.png b/sdk/octatrack/modules/shatter/evidence/hardware-mode-chaos.png
new file mode 100644
index 0000000000..c71bb2aae2
Binary files /dev/null and b/sdk/octatrack/modules/shatter/evidence/hardware-mode-chaos.png differ
diff --git a/sdk/octatrack/modules/shatter/evidence/hardware-mode-hard.png b/sdk/octatrack/modules/shatter/evidence/hardware-mode-hard.png
new file mode 100644
index 0000000000..5c9a759dcd
Binary files /dev/null and b/sdk/octatrack/modules/shatter/evidence/hardware-mode-hard.png differ
diff --git a/sdk/octatrack/modules/shatter/evidence/hardware-mode-soft.png b/sdk/octatrack/modules/shatter/evidence/hardware-mode-soft.png
new file mode 100644
index 0000000000..646ddaaa1f
Binary files /dev/null and b/sdk/octatrack/modules/shatter/evidence/hardware-mode-soft.png differ
diff --git a/sdk/octatrack/modules/shatter/evidence/performance.json b/sdk/octatrack/modules/shatter/evidence/performance.json
new file mode 100644
index 0000000000..cb4aee645b
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/evidence/performance.json
@@ -0,0 +1,34 @@
+{
+ "schema": 1,
+ "module": "shatter",
+ "version": "0.1.0-experimental",
+ "sourceSha256": "243aeec6d62511c40e26be82aeca1c695b2b42ff287209f82660d6e46921dcbd",
+ "kind": "dsp",
+ "cycles": {
+ "unit": "instructions/sample",
+ "static": 240,
+ "measured": 224.88,
+ "instancesPerCore": 4,
+ "method": "Static: pinned Octabam native count 238 DSP cycles/sample plus two one-word signed-FOLD moves per sample in the Modwerk adaptation, 240 before stalls. Measured: `cycle-scan.mjs record shatter` on the exact Modwerk source, SOFT/max, 224.88 decoded instructions and 398.44 modeled DSP56300 cycles/sample including 39.5 modeled stalls. Four FX2 instances per core use 960 static cycles/sample before stock work. The model is not a chip measurement."
+ },
+ "stock": {
+ "comparator": "LO-FI",
+ "comparatorWorst": 275.4375,
+ "dearestWorst": 293.375,
+ "baseline": "out/stock_dsp_bench/results.json; 4,096 blocks on pinned stock image, DSP host, null-stub peak subtracted; executed instructions/sample, not chip cycles.",
+ "stockSha256": "164f31224bf61181e3f50e7dec40df9afcae5b16dbf6e4c0d0cc5e986af0a84e",
+ "justification": "LO-FI is the closest stock effect in function because SHATTER combines drive, waveshaping, clipping and bit/sample-rate reduction. Its 275.4375 instruction/sample worst case exceeds SHATTER's 224.88 modeled-source instruction count, but these use different measurement methods. DJ EQ is the dearest stock effect at 293.375 instructions/sample. The comparison is directional, not a real-time guarantee."
+ },
+ "stress": {
+ "instancesPerCore": 4,
+ "tracks": 8,
+ "lfosPerTrack": 3,
+ "lockedSlots": 12,
+ "seconds": 2,
+ "guard": true,
+ "dirty": true,
+ "clobbers": 0,
+ "hangs": 0,
+ "method": "Native Octabam stress image, not Modwerk package/hardware: `pressure.py render --remix shatter --top 1 --sample 0 --seconds 2`; four SHATTER FX2 instances per core, eight tracks and hostile knob/LFO/lock settings. Both core layouts rendered without clobbers, stray writes or hangs; peak aggregate was 848.9 and 850.8 host instructions/sample per core. The separately generated dense stress project had three LFOs per track and 12 lockable FX2 controls, 1,024 trigs and 20,944 parameter-lock bytes; ot_emu completed 2,500 frames with nonzero audio. Host stress does not prove ColdFire event delivery or chip load."
+ }
+}
diff --git a/sdk/octatrack/modules/shatter/idle.raw b/sdk/octatrack/modules/shatter/idle.raw
new file mode 100644
index 0000000000..c316649522
Binary files /dev/null and b/sdk/octatrack/modules/shatter/idle.raw differ
diff --git a/sdk/octatrack/modules/shatter/import-record.json b/sdk/octatrack/modules/shatter/import-record.json
new file mode 100644
index 0000000000..59f4e8a457
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/import-record.json
@@ -0,0 +1,68 @@
+{
+ "schemaVersion": 1,
+ "repository": "https://github.com/sambanks/octabam",
+ "revision": "0e2ea1dabfafe11aa4ced362cc6f2e0e41890405",
+ "moduleVersion": "0.1.0-experimental",
+ "root": "sdk/octabam/modules/shatter",
+ "modules": [
+ "shatter"
+ ],
+ "files": [
+ {
+ "path": "upstream/README.md",
+ "sourcePath": "modules/shatter/README.md",
+ "sourceBytes": 4229,
+ "sourceGitBlob": "0ff10c560133b1824adeded6a761594eda6d3fb2",
+ "sourceSha256": "83c4c83d6835e2182d86338943b0b3f1b647225f28de2f480cbfc07b0dd6fad5",
+ "vendoredSha256": "83c4c83d6835e2182d86338943b0b3f1b647225f28de2f480cbfc07b0dd6fad5"
+ },
+ {
+ "path": "upstream/manifest.py",
+ "sourcePath": "modules/shatter/manifest.py",
+ "sourceBytes": 4863,
+ "sourceGitBlob": "635ea40323b733d87a8b7f199174731ef6a08914",
+ "sourceSha256": "bae0d7ee3d68b37b2a523c33faff40a37031f41b637759f64c8802c2dd34cc7f",
+ "vendoredSha256": "bae0d7ee3d68b37b2a523c33faff40a37031f41b637759f64c8802c2dd34cc7f"
+ },
+ {
+ "path": "upstream/shatter.asm",
+ "sourcePath": "modules/shatter/shatter.asm",
+ "sourceBytes": 15351,
+ "sourceGitBlob": "02b2d46897c2ba98053224f5742396983461a4ac",
+ "sourceSha256": "8fca3bf6063e989dea2397e0847000fdfe532f39d54ffb102c88e666e938aea2",
+ "vendoredSha256": "8fca3bf6063e989dea2397e0847000fdfe532f39d54ffb102c88e666e938aea2"
+ },
+ {
+ "path": "upstream/tools/remix/peak_limiter.py",
+ "sourcePath": "tools/remix/peak_limiter.py",
+ "sourceBytes": 3960,
+ "sourceGitBlob": "cda4ddd0c4bf1bb6829a839bcaf9e82714380a3b",
+ "sourceSha256": "80188b9073be022dc291ab778e9f5196fcb54a0bf48228f047e99dca83a5690f",
+ "vendoredSha256": "80188b9073be022dc291ab778e9f5196fcb54a0bf48228f047e99dca83a5690f"
+ },
+ {
+ "path": "upstream/tools/verify/verify_shatter.py",
+ "sourcePath": "tools/verify/verify_shatter.py",
+ "sourceBytes": 15771,
+ "sourceGitBlob": "df5997290ef27b352445e7b5bde66b9847b966fe",
+ "sourceSha256": "fd8815ffb290034dff65cfa61a5de08c444e49391e048e6e22285601625ffd79",
+ "vendoredSha256": "fd8815ffb290034dff65cfa61a5de08c444e49391e048e6e22285601625ffd79"
+ },
+ {
+ "path": "upstream/ui.s",
+ "sourcePath": "modules/shatter/ui.s",
+ "sourceBytes": 13603,
+ "sourceGitBlob": "8d9cf40651bc6a209c22fb1f4dad092d9618de68",
+ "sourceSha256": "8b12ceecec96452c6a88f2f9804bba257eead4ed9c00dabe2889be6907399919",
+ "vendoredSha256": "8b12ceecec96452c6a88f2f9804bba257eead4ed9c00dabe2889be6907399919"
+ },
+ {
+ "path": "upstream/LICENSE",
+ "sourcePath": "LICENSE",
+ "sourceBytes": 2112,
+ "sourceGitBlob": "112114d5d319dc4a789dacf1e84b867420a03614",
+ "sourceSha256": "f91a43799d9e31ccc3540f385f68c4d6ff5a096f93ae933be2ce98f6b3f7f113",
+ "vendoredSha256": "f91a43799d9e31ccc3540f385f68c4d6ff5a096f93ae933be2ce98f6b3f7f113"
+ }
+ ]
+}
diff --git a/sdk/octatrack/modules/shatter/manifest.py b/sdk/octatrack/modules/shatter/manifest.py
new file mode 100644
index 0000000000..0189ffbd72
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/manifest.py
@@ -0,0 +1,85 @@
+"""SHATTER, imported from sambanks/octabam at 0e2ea1d."""
+
+import math
+from pathlib import Path
+from runpy import run_path
+
+from remix.schema import (BusRole, Category, DspSection, Formatter, Gate,
+ Harness, Kind, Linked, MenuEntry, Module, Param, Proof, YBase)
+
+_P = Formatter.PLAIN
+_BLANK = Param(b"", 0)
+_UI = "shatter_ui"
+_ROOT = Path(__file__).resolve().parent
+peak_limiter_source = run_path(str(_ROOT / "upstream/tools/remix/peak_limiter.py"))["source"]
+_SIGNED_FOLD_PRODUCT = (" move y1,x0 ; Keep FOLD_GAIN signed\n"
+ " mpy y0,x0,a")
+_W = lambda sym: dict(formatter_word=0, widget_word=(_UI, sym))
+
+FOLD_GAIN = tuple(
+ ((1 << 23) - 1) if fold == 0 else
+ round(((1 << 23) - 1) / math.sqrt(2 + fold / 8))
+ for fold in range(128)
+)
+
+MODULE = Module(
+ name="shatter",
+ key="SHATTER",
+ kind=Kind.DSP_EFFECT,
+ category=Category.TRACK,
+ author="ilia-murzinov",
+ author_url="https://github.com/ilia-murzinov",
+ proof=Proof.UNTESTED,
+ proof_note="Port of sambanks/octabam SHATTER at 0e2ea1dabfafe11aa4ced362cc6f2e0e41890405; Modwerk behavior is untested.",
+ doc="Crush insert: fold, clip, crush, chaotic feedback, stereo peak limiter after MIX.",
+ menu=MenuEntry(
+ fx2_id=0x0a,
+ donor_desc=0x400d58b8,
+ abbr=b"SHTR",
+ fullname=b"SHATTER",
+ build_tag=False,
+ ),
+ params=(
+ Param(b"DRV", 0, active=True, formatter=_P,
+ doc="Dry-path drive; output gain is compensated after the dirt chain."),
+ Param(b"FOLD", 0, active=True, **_W("wid_fold"),
+ doc="Wavefolder. 0 is off; higher values fold more with partial output gain compensation."),
+ Param(b"CLIP", 0, active=True, **_W("wid_clip"),
+ doc="Clip threshold. 0 is open; 127 is a brick wall."),
+ Param(b"CRSH", 0, active=True, **_W("wid_crsh"),
+ doc="Bit-depth and sample-rate crush together."),
+ Param(b"FDBK", 0, active=True, **_W("wid_fdbk"),
+ doc="Feedback around the fold, clip and crush. CHAOS flips its polarity."),
+ Param(b"MIX", 127, active=True, formatter=_P,
+ doc="Dry/wet. 0 is bit-exact dry when LIM is 0."),
+ Param(b"MODE", 0, 3, active=True, formatter=Formatter.STEPPED,
+ labels=("HARD", "SOFT", "CHAOS"),
+ doc="HARD or SOFT clipping, or CHAOS feedback polarity flips."),
+ Param(b"TONE", 64, active=True, **_W("wid_tone"),
+ doc="Feedback-loop shelf. 0 is dark; 127 is bright."),
+ Param(b"RATE", 64, active=True, **_W("wid_rate"),
+ doc="CHAOS polarity-flip rate. Ignored in HARD and SOFT."),
+ Param(b"LIM", 0, 128, active=True, formatter=_P,
+ doc="Stereo-linked peak limiter after MIX. 0 is off; 1–127 sets the ceiling from about −2.5 to −12 dBFS."),
+ _BLANK,
+ _BLANK,
+ ),
+ mode_slot=6,
+ dsp=DspSection(
+ asm="modules/shatter/upstream/shatter.asm",
+ subst={pl: {**peak_limiter_source("shpk", 0x19, 0xd, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, knob=0xd),
+ " mpy y0,y1,a": _SIGNED_FOLD_PRODUCT}
+ for pl in ("A", "B")},
+ ptable=FOLD_GAIN,
+ priority=18,
+ bus_role=BusRole.NONE,
+ ybase=YBase.NEVER,
+ r7_latch_slot=None,
+ gate_label=None,
+ ),
+ linked=(Linked(_UI, "modules/shatter/upstream/ui.s", cpu="5475", dram=True),),
+ harness=Harness(layout_char="4", is_server=False),
+ gates=(Gate("modules/shatter/verify.py", remix_arg=False),),
+ dear={"DRV": 127, "FOLD": 127, "CLIP": 100, "CRSH": 100, "FDBK": 80,
+ "MIX": 127, "MODE": 2, "TONE": 100, "RATE": 100, "LIM": 100},
+)
diff --git a/sdk/octatrack/modules/shatter/media/controls.png b/sdk/octatrack/modules/shatter/media/controls.png
new file mode 100644
index 0000000000..c6ab048414
Binary files /dev/null and b/sdk/octatrack/modules/shatter/media/controls.png differ
diff --git a/sdk/octatrack/modules/shatter/media/library-cover.svg b/sdk/octatrack/modules/shatter/media/library-cover.svg
new file mode 100644
index 0000000000..368fa9110d
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/media/library-cover.svg
@@ -0,0 +1,20 @@
+
diff --git a/sdk/octatrack/modules/shatter/media/setup.png b/sdk/octatrack/modules/shatter/media/setup.png
new file mode 100644
index 0000000000..c6a8102ca1
Binary files /dev/null and b/sdk/octatrack/modules/shatter/media/setup.png differ
diff --git a/sdk/octatrack/modules/shatter/noise.raw b/sdk/octatrack/modules/shatter/noise.raw
new file mode 100644
index 0000000000..126f9ca771
Binary files /dev/null and b/sdk/octatrack/modules/shatter/noise.raw differ
diff --git a/sdk/octatrack/modules/shatter/octamod.module.json b/sdk/octatrack/modules/shatter/octamod.module.json
new file mode 100644
index 0000000000..3b5ad295ad
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/octamod.module.json
@@ -0,0 +1,347 @@
+{
+ "schemaVersion": 2,
+ "id": "shatter",
+ "key": "SHATTER",
+ "name": "Shatter",
+ "version": "0.1.0-experimental",
+ "category": "effects",
+ "source": {
+ "repository": "https://github.com/sambanks/octabam",
+ "revision": "0e2ea1dabfafe11aa4ced362cc6f2e0e41890405",
+ "path": "modules/shatter"
+ },
+ "author": {
+ "github": "ilia-murzinov",
+ "credits": [
+ "Ilia Murzinov (@ilia-murzinov), original SHATTER module author.",
+ "Sam Banks, sambanks/octabam source and MIT copyright."
+ ]
+ },
+ "nativeManifest": "manifest.py",
+ "presentation": {
+ "label": "SHATTER",
+ "family": "Destruction",
+ "summary": "Fold, clip, crush and feed the result back through a tone shelf.",
+ "overview": "SHATTER turns a track into a self-modulating crush effect. Drive and fold the signal, choose hard or soft clipping, then add bit and sample-rate reduction. CHAOS flips the feedback polarity. MIX sets the dry/wet balance, and LIM controls a stereo-linked peak limiter after the mix.",
+ "highlights": [
+ "Shape the input with drive, folding and hard or soft clipping.",
+ "Combine bit-depth and sample-rate reduction with feedback and tone.",
+ "Use CHAOS for changing feedback polarity, or LIM to cap the mixed peak."
+ ],
+ "usage": [
+ "Choose SHATTER in FX2 SETUP on an audio track, then press FX2 for its controls.",
+ "Start with FOLD, CLIP and CRSH low. Raise FDBK for a repeating, changing texture.",
+ "Turn MIX to 0 for dry sound. LIM is off at 0."
+ ]
+ },
+ "controls": [
+ {
+ "name": "DRV",
+ "default": 0,
+ "count": 128,
+ "doc": "Drive before the dirt stages. Output compensation follows the chain.",
+ "labels": null
+ },
+ {
+ "name": "FOLD",
+ "default": 0,
+ "count": 128,
+ "doc": "Wavefolder. 0 is off; higher values fold more with partial output compensation.",
+ "labels": null
+ },
+ {
+ "name": "CLIP",
+ "default": 0,
+ "count": 128,
+ "doc": "Clip threshold. 0 is open; 127 is a brick wall.",
+ "labels": null
+ },
+ {
+ "name": "CRSH",
+ "default": 0,
+ "count": 128,
+ "doc": "Bit-depth and sample-rate reduction together.",
+ "labels": null
+ },
+ {
+ "name": "FDBK",
+ "default": 0,
+ "count": 128,
+ "doc": "Feedback around the fold, clip and crush stages. CHAOS flips its polarity.",
+ "labels": null
+ },
+ {
+ "name": "MIX",
+ "default": 127,
+ "count": 128,
+ "doc": "Dry/wet balance. 0 is exact dry when LIM is off.",
+ "labels": null
+ },
+ {
+ "name": "MODE",
+ "default": 0,
+ "count": 3,
+ "doc": "HARD or SOFT clipping, or CHAOS feedback polarity flips.",
+ "labels": [
+ "HARD",
+ "SOFT",
+ "CHAOS"
+ ]
+ },
+ {
+ "name": "TONE",
+ "default": 64,
+ "count": 128,
+ "doc": "Tone shelf in the feedback loop. Lower values are darker.",
+ "labels": null
+ },
+ {
+ "name": "RATE",
+ "default": 64,
+ "count": 128,
+ "doc": "CHAOS polarity-flip rate. Ignored in HARD and SOFT.",
+ "labels": null
+ },
+ {
+ "name": "LIM",
+ "default": 0,
+ "count": 128,
+ "doc": "Stereo-linked peak limiter after MIX. 0 is off; higher values lower the ceiling.",
+ "labels": null
+ }
+ ],
+ "compatibility": {
+ "firmware": "1.40C",
+ "location": "FX2",
+ "conflicts": [
+ "analog-bassdrum"
+ ],
+ "uiClaims": [],
+ "limitations": [
+ "Current package 7d11bcdbb66a passed the scripted unit phase, 120-second soak and cost admission on an Octatrack MKII running OS 1.40C. Audible quality, Keep/Undo lifecycle and reboot persistence remain unqualified.",
+ "The base refuses SHATTER beside Analog BD until that pairing is reviewed. This restriction is not evidence of an intrinsic DSP collision. Fold, clipping and crush intentionally produce strong harmonics and aliasing at extreme settings; high feedback can leave a tail after input stops."
+ ],
+ "effectId": 10
+ },
+ "resources": {
+ "recorded": "2026-12-06",
+ "storage": {
+ "label": "DSP program / state",
+ "display": "624 words / 32-word state",
+ "value": null,
+ "unit": "see display",
+ "method": "static",
+ "conditions": "USB package 7d11bcdbb66a: 624 DSP P words copied to each core, 32 DSP X state words per instance, no delay buffer, and 760 ColdFire image bytes including code and data. Eight instances use 768 bytes of DSP X state. The ColdFire widget callback peaks at 76 bytes of additional stack: 44 saved-register bytes, seven 4-byte arguments plus the call return for STOCK_WIDGET. No module heap or BSS; the UI scratch data is included in the 2,412-byte image. Stock memory and base-owned stacks are excluded. DSP hardware canaries were not measured.",
+ "source": "TESTING.md"
+ },
+ "processing": {
+ "label": "DSP instruction peak",
+ "display": "225 instructions/sample per instance",
+ "value": null,
+ "unit": "see display",
+ "method": "emulator",
+ "conditions": "cycle-scan models the SOFT/max path at 398.44 DSP56300 cycles/sample, including 39.5 modeled stalls, from 224.88 executed instructions/sample. It scans 12 knob configurations using a deterministic input at 0.3 full scale. This is a manual-based model, not chip timing or a proof for every signal-dependent branch. The native Octabam build separately counts 238 cycles/sample on its unadapted source. See TESTING.md.",
+ "source": "evidence/performance.json"
+ },
+ "impact": {
+ "conditions": "Per active FX2 insert at high drive, fold, crush, feedback and limiter settings with changing controls. The current Modwerk source modeled 398.44 cycles/sample at SOFT/max; the native Octabam count of 238 covers its unadapted code. The current USB package declares 624 DSP program words per core and 32 X-state words per instance.",
+ "cpu": {
+ "level": "minimal",
+ "basis": "source-estimate",
+ "rationale": "No audio work runs on ColdFire. Its code clones the effect descriptor and supplies the panel controls; it has no per-frame DSP callback.",
+ "source": "TESTING.md"
+ },
+ "dsp": {
+ "level": "moderate",
+ "basis": "source-estimate",
+ "rationale": "The current Modwerk source models 398.44 cycles/sample at SOFT/max. Four FX2 instances account for 1,593.76 modeled cycles/sample on one core before stock work; the current package passed eight-instance playback on a development twin.",
+ "source": "TESTING.md"
+ },
+ "memory": {
+ "level": "low",
+ "basis": "source-estimate",
+ "rationale": "The current USB package declares 624 DSP program words per core, 32 X-state words per instance, 760 ColdFire image bytes and no BSS or delay buffer. The package header supplies these sizes; hardware canaries were not measured.",
+ "source": "TESTING.md"
+ }
+ },
+ "cpuPrice": {
+ "value": 0,
+ "unit": "percent-of-frame",
+ "measure": "frame-interrupt",
+ "tool": "npm run device:price -- --write",
+ "date": "2026-12-06",
+ "conditions": "the bank, pattern and Part the unit was on, transport stopped (test:procedure); base development twin 117eb07f2ebc8040, Octatrack MKII, OS 1.40C; 3 readings of 8 s a state. Frame interrupt 33.8 % before, 33.7 % installed and used nowhere, 33.7 % on T1 FX2; CPU meter 53.5 % before, 50 % at rest, 50.1 % in use.",
+ "source": "evidence/cpu-price.json"
+ }
+ },
+ "tests": {
+ "report": "TESTING.md",
+ "summary": "Current package 7d11bcdbb66a passed the scripted MKII unit phase: device:test, 120-second soak, load admission and inventory/Part restore. The FX2 control and setup screens were captured on the same package. MAIN/CUE recording was unavailable, and the submitter has not reported listening, MIDI/scenes/recording or persistence results.",
+ "hardwareStatus": "reported",
+ "evidenceRevision": "ed91a5df52435befc34b912942397a32e838b273",
+ "gates": [
+ "Submitter: listen to the current package on the MKII, then report timing, MIDI, scenes and recording.",
+ "Submitter: decide whether to Keep and power-cycle; report saved-project and kept-set persistence.",
+ "Review the declared Analog BD conflict; the current base refuses the pairing."
+ ],
+ "qualification": {
+ "moduleVersion": "0.1.0-experimental",
+ "sourceSha256": "8c011b2b9fef86d26002ff23d274b2afd82b8e6b039ec3883c0f9301afe2b28e",
+ "cycles": [
+ {
+ "processor": "dsp",
+ "worstCase": 399,
+ "maxConfiguration": 1596,
+ "maxInstances": 8,
+ "budget": 3120,
+ "unit": "cycles/sample",
+ "method": "emulator",
+ "conditions": {
+ "parameterExtremes": "cycle-scan record: 12 configurations. Dearest SOFT/max measured 224.88 instructions/sample and modeled 398.44 cycles/sample, including 39.5 modeled stalls; rounded up to 399. Native Octabam make cycles separately reports 238 cycles/sample on its unadapted source.",
+ "parameterModulation": "Native stress project used 8 tracks, 3 LFOs per track, 12 locked FX2 controls, 1,024 trigs and 20,944 parameter-lock bytes. Native stress rendered 2,500 frames without hangs or silent output. The hardware procedure changed knobs and Parts on the earlier package. MIDI CC and scene modulation were not tested; each reaches the DSP through the same block parameter words.",
+ "modeSwitching": "HARD, SOFT and CHAOS are DSP parameter states; cycle-scan covers mode settings. MODE changes do not call init. The current package passed a 12-Part-switch scripted trial; its FX2 control and setup screens were captured on the MKII.",
+ "maxLoad": "Four instances per core, eight total: 4 x 399 = 1,596 modeled cycles/sample per core against the 3,120-cycle core budget, before stock work and contention. Native stress covered four instances per core. The current package ran all eight instances on the MKII development twin.",
+ "inputConditions": "The cycle model used a deterministic 0.3-full-scale input. verify.py separately checks silence, high drive and feedback, CHAOS, limiter behavior, rail bounds and exact dry output. Those signal tests do not measure cycle cost. Full-scale signal-dependent cycle paths remain unqualified."
+ },
+ "report": "evidence/performance.json"
+ }
+ ],
+ "memory": {
+ "regions": [
+ {
+ "name": "DSP P program on DSP core 0, including SHATTER code and FOLD table",
+ "space": "dsp-p",
+ "words": 624,
+ "wordBits": 24,
+ "bytes": 1872,
+ "scope": "shared"
+ },
+ {
+ "name": "DSP P program on DSP core 1, including SHATTER code and FOLD table",
+ "space": "dsp-p",
+ "words": 624,
+ "wordBits": 24,
+ "bytes": 1872,
+ "scope": "shared"
+ },
+ {
+ "name": "DSP X state per instance",
+ "space": "dsp-x",
+ "words": 32,
+ "wordBits": 24,
+ "bytes": 96,
+ "scope": "instance"
+ },
+ {
+ "name": "ColdFire package image and data, including UI scratch",
+ "space": "cpu-ram",
+ "words": 760,
+ "wordBits": 8,
+ "bytes": 760,
+ "scope": "shared"
+ },
+ {
+ "name": "Peak module-added widget callback stack: 44 saved-register bytes, 28 argument bytes and 4 call-return bytes",
+ "space": "cpu-ram",
+ "words": 76,
+ "wordBits": 8,
+ "bytes": 76,
+ "scope": "shared"
+ }
+ ],
+ "perInstanceBytes": 96,
+ "sharedBytes": 4580,
+ "maxInstances": 8,
+ "totalBytes": 5348,
+ "conditions": "Package header 7d11bcdbb66a reports 624 DSP P words per core, 32 X-state words per instance, 760 ColdFire image bytes, zero BSS and zero delay-buffer words. The UI assembly reserves 44 bytes for 11 saved registers, then at most 28 argument bytes and a 4-byte return address at STOCK_WIDGET, for 76 bytes of module-added stack. Internal helpers nest at most one return address and stay below that peak. DSP code has no subroutine stack use; its DO loops use the hardware loop stack. No module heap, DSP Y allocation, external buffer or additional scratch exists. DSP state bounds are checked by verify.py through r7+$1f. Base-owned and stock memory are excluded; hardware canaries were not measured.",
+ "report": "TESTING.md"
+ },
+ "imageSha256": "7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837",
+ "hardware": {
+ "kind": "functional",
+ "status": "reported",
+ "model": "MKII",
+ "testedOn": "2026-12-06",
+ "tester": "ilia-murzinov",
+ "sourceRevision": "ed91a5df52435befc34b912942397a32e838b273",
+ "imageSha256": "7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837",
+ "summary": "On an Octatrack MKII with OS 1.40C, package 7d11bcdbb66a passed the procedure’s unit phase on development twin 117eb07f2ebc8040: device:test with eight instances, knob sweeps and Part changes; a 120-second, 2,400-operation soak; load pricing and admission on empty and medium patterns; and an unchanged inventory and clean A02 Part 2 after rollback. FX2 and FX2 SETUP LCD captures matched the controls. The full procedure still needs a clean-commit run.",
+ "limitations": [
+ "MAIN/CUE USB recording was not run: the recorder reported Octatrack not found.",
+ "No listening or timing judgement by the submitter, MIDI/scenes/recording check, Keep or power-cycle persistence is claimed.",
+ "The declared Analog BD pairing remains refused by the current base; this run did not test coexistence.",
+ "The unit phase ran while documentation and evidence were uncommitted; rerun the full procedure from a clean commit."
+ ],
+ "report": "TESTING.md"
+ },
+ "documentation": {
+ "tutorial": {
+ "title": "Quick tutorial",
+ "steps": [
+ "Select an audio track and choose SHATTER in FX2 SETUP.",
+ "Raise FOLD or CRSH to add strong harmonics or stepped, reduced-rate sound.",
+ "Raise FDBK and choose CHAOS for a changing feedback texture. Turn MIX to 0 for dry sound, or select NONE in FX2 SETUP to remove SHATTER."
+ ]
+ },
+ "screenshots": [
+ "media/controls.png",
+ "media/setup.png"
+ ],
+ "screenshotStyle": "black-and-white"
+ }
+ }
+ },
+ "license": {
+ "spdx": "MIT",
+ "file": "LICENSE",
+ "declaration": "SHATTER is ported from sambanks/octabam at the pinned commit. The original full MIT notice and copyright are retained in upstream/LICENSE and LICENSE. The original module author is credited above."
+ },
+ "media": [
+ {
+ "path": "media/controls.png",
+ "captureType": "hardware",
+ "credit": "Ilia Murzinov (USB LCD capture on his MKII)",
+ "license": "LicenseRef-OT-UI-Documentation",
+ "source": "original",
+ "caption": "SHATTER controls on FX2: DRV, FOLD, CLIP, CRSH, FDBK and MIX.",
+ "alt": "Octatrack FX2 controls page showing SHATTER, with DRV, FOLD, CLIP, CRSH, FDBK and MIX.",
+ "otUi": {
+ "page": "FX2",
+ "shows": "controls",
+ "firmware": "1.40C",
+ "moduleVersion": "0.1.0-experimental",
+ "setup": "Octatrack MKII on OS 1.40C, RAM-booted development twin 117eb07f2ebc8040; package 7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837 in a reversible trial; bank A pattern 02, Part 2, T1 FX2 selected; LCD read over USB.",
+ "imageSha256": "276500fc89dae26719b9caf53a353f68c1b7c44e6879adaac4a268417956af49"
+ }
+ },
+ {
+ "path": "media/setup.png",
+ "captureType": "hardware",
+ "credit": "Ilia Murzinov (USB LCD capture on his MKII)",
+ "license": "LicenseRef-OT-UI-Documentation",
+ "source": "original",
+ "caption": "SHATTER selected in FX2 SETUP; MODE, TONE, RATE and LIM appear on its setup controls.",
+ "alt": "Octatrack FX2 SETUP with SHATTER selected and controls MODE, TONE, RATE and LIM.",
+ "otUi": {
+ "page": "FX2 SETUP",
+ "shows": "location",
+ "firmware": "1.40C",
+ "moduleVersion": "0.1.0-experimental",
+ "setup": "Octatrack MKII on OS 1.40C, RAM-booted development twin 117eb07f2ebc8040; package 7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837 in a reversible trial; bank A pattern 02, Part 2, SHATTER selected in T1 FX2 SETUP; LCD read over USB.",
+ "imageSha256": "276500fc89dae26719b9caf53a353f68c1b7c44e6879adaac4a268417956af49"
+ }
+ }
+ ],
+ "access": {
+ "location": "FX2 SETUP on an audio track, then the FX2 control page",
+ "steps": [
+ "Select an audio track and hold [FUNC] while pressing [FX2] to open FX2 SETUP.",
+ "Turn LEVEL to SHATTER and press [YES]. Press [FX2] for DRV, FOLD, CLIP, CRSH, FDBK and MIX.",
+ "Hold [FUNC] and press [FX2] to open FX2 SETUP again. Adjust MODE, TONE, RATE and LIM in the right-side controls."
+ ],
+ "screenshots": [
+ "media/controls.png",
+ "media/setup.png"
+ ]
+ }
+}
diff --git a/sdk/octatrack/modules/shatter/plan.json b/sdk/octatrack/modules/shatter/plan.json
new file mode 100644
index 0000000000..a13bbe38e5
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/plan.json
@@ -0,0 +1,77 @@
+{
+ "sampleRate": 44100,
+ "fftSize": 32768,
+ "warmup": 16384,
+ "tones": [
+ {
+ "file": "tone-1100hz-12db",
+ "m": 817,
+ "hz": 1099.5391845703125,
+ "levelDbfs": -12
+ },
+ {
+ "file": "tone-1100hz-1db",
+ "m": 817,
+ "hz": 1099.5391845703125,
+ "levelDbfs": -1
+ },
+ {
+ "file": "tone-2701hz-12db",
+ "m": 2007,
+ "hz": 2701.0711669921875,
+ "levelDbfs": -12
+ },
+ {
+ "file": "tone-2701hz-1db",
+ "m": 2007,
+ "hz": 2701.0711669921875,
+ "levelDbfs": -1
+ },
+ {
+ "file": "tone-5301hz-12db",
+ "m": 3939,
+ "hz": 5301.2054443359375,
+ "levelDbfs": -12
+ },
+ {
+ "file": "tone-5301hz-1db",
+ "m": 3939,
+ "hz": 5301.2054443359375,
+ "levelDbfs": -1
+ },
+ {
+ "file": "tone-9102hz-12db",
+ "m": 6763,
+ "hz": 9101.815795898438,
+ "levelDbfs": -12
+ },
+ {
+ "file": "tone-9102hz-1db",
+ "m": 6763,
+ "hz": 9101.815795898438,
+ "levelDbfs": -1
+ }
+ ],
+ "idle": {
+ "file": "idle",
+ "tailSeconds": 3,
+ "samples": 143520
+ },
+ "noise": {
+ "file": "noise",
+ "tailSeconds": 3,
+ "samples": 176400
+ },
+ "dc": [
+ {
+ "file": "dc",
+ "tone": false,
+ "samples": 132480
+ },
+ {
+ "file": "dc-tone",
+ "tone": true,
+ "samples": 132480
+ }
+ ]
+}
diff --git a/sdk/octatrack/modules/shatter/presentation/thumbnail.svg b/sdk/octatrack/modules/shatter/presentation/thumbnail.svg
new file mode 100644
index 0000000000..8f96855e72
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/presentation/thumbnail.svg
@@ -0,0 +1,23 @@
+
diff --git a/sdk/octatrack/modules/shatter/tone-1100hz-12db.raw b/sdk/octatrack/modules/shatter/tone-1100hz-12db.raw
new file mode 100644
index 0000000000..d45c3195cd
Binary files /dev/null and b/sdk/octatrack/modules/shatter/tone-1100hz-12db.raw differ
diff --git a/sdk/octatrack/modules/shatter/tone-1100hz-1db.raw b/sdk/octatrack/modules/shatter/tone-1100hz-1db.raw
new file mode 100644
index 0000000000..d6ac7fcc01
Binary files /dev/null and b/sdk/octatrack/modules/shatter/tone-1100hz-1db.raw differ
diff --git a/sdk/octatrack/modules/shatter/tone-2701hz-12db.raw b/sdk/octatrack/modules/shatter/tone-2701hz-12db.raw
new file mode 100644
index 0000000000..1dbce2fd8a
Binary files /dev/null and b/sdk/octatrack/modules/shatter/tone-2701hz-12db.raw differ
diff --git a/sdk/octatrack/modules/shatter/tone-2701hz-1db.raw b/sdk/octatrack/modules/shatter/tone-2701hz-1db.raw
new file mode 100644
index 0000000000..bb108164ce
Binary files /dev/null and b/sdk/octatrack/modules/shatter/tone-2701hz-1db.raw differ
diff --git a/sdk/octatrack/modules/shatter/tone-5301hz-12db.raw b/sdk/octatrack/modules/shatter/tone-5301hz-12db.raw
new file mode 100644
index 0000000000..22551d2d62
Binary files /dev/null and b/sdk/octatrack/modules/shatter/tone-5301hz-12db.raw differ
diff --git a/sdk/octatrack/modules/shatter/tone-5301hz-1db.raw b/sdk/octatrack/modules/shatter/tone-5301hz-1db.raw
new file mode 100644
index 0000000000..ad5a0bedc6
Binary files /dev/null and b/sdk/octatrack/modules/shatter/tone-5301hz-1db.raw differ
diff --git a/sdk/octatrack/modules/shatter/tone-9102hz-12db.raw b/sdk/octatrack/modules/shatter/tone-9102hz-12db.raw
new file mode 100644
index 0000000000..67630151c3
Binary files /dev/null and b/sdk/octatrack/modules/shatter/tone-9102hz-12db.raw differ
diff --git a/sdk/octatrack/modules/shatter/tone-9102hz-1db.raw b/sdk/octatrack/modules/shatter/tone-9102hz-1db.raw
new file mode 100644
index 0000000000..3916153a2d
Binary files /dev/null and b/sdk/octatrack/modules/shatter/tone-9102hz-1db.raw differ
diff --git a/sdk/octatrack/modules/shatter/upstream/LICENSE b/sdk/octatrack/modules/shatter/upstream/LICENSE
new file mode 100644
index 0000000000..112114d5d3
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/upstream/LICENSE
@@ -0,0 +1,42 @@
+MIT License
+
+Copyright (c) 2026 Sam Banks
+
+Portions of the firmware analysis tooling originate from the octamax project
+(https://github.com/mxldyn/octamax), Copyright (c) 2025-2026 Maxolydian,
+also under the MIT License.
+
+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 license covers this repository's own source code and documentation only.
+Transcribed third-party DSP sources, the community modifications carried as
+submodules and the tools fetched by `make setup` are listed with their own
+licences in THIRD_PARTY.md.
+
+It does not extend to any Elektron Music Machines firmware, which is not
+distributed here and remains the property of its copyright holder. Users
+supply their own copy of the official OS. The container-format tooling in
+this repository re-implements Elektron's firmware-update packaging solely for
+interoperability: so that an owner can build and flash a modified image for
+their own unit. Nothing in this project 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 project
+targets.
diff --git a/sdk/octatrack/modules/shatter/upstream/README.md b/sdk/octatrack/modules/shatter/upstream/README.md
new file mode 100644
index 0000000000..0ff10c5601
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/upstream/README.md
@@ -0,0 +1,86 @@
+# `shatter`: SHATTER
+
+A per-track crush insert: drive into a wavefolder, hard or soft clip,
+combined bit-depth and sample-rate crush, then a feedback loop with a tone
+shelf. MODE CHAOS flips feedback polarity from a free-running ramp so the
+loop self-modulates into hash and dropouts. DRV gain is compensated after the
+dirt chain. FOLD gets partial output compensation. LIM is a stereo-linked peak limiter after MIX
+(current-block peak + one block-rate div). MIX 0 is bit-exact dry when LIM is 0.
+
+Sits beside CHARACTER (channel-strip dirt) and LOFI2 (modulator + SRR/BRR):
+this one is self-modulating destruction.
+
+## Knobs
+
+| page | slot | name | range | what it does |
+|---|---|---|---|---|
+| 1 | 0 | DRV | 0–127 | drive on dry only; output gain compensation follows the dirt stages |
+| 1 | 1 | FOLD | 0–127 | wavefolder; 0 = off; higher settings fold more with partial gain compensation |
+| 1 | 2 | CLIP | 0–127 | mid-chain clip amount (0 open, 127 brick) |
+| 1 | 3 | CRSH | 0–127 | bit + sample-rate crush |
+| 1 | 4 | FDBK | 0–127 | feedback around the crush path |
+| 1 | 5 | MIX | 0–127 | dry/wet; 0 = exact passthrough when LIM is 0 |
+| 2 | 6 | MODE | HARD / SOFT / CHAOS | clip flavour; CHAOS flips FDBK polarity |
+| 2 | 7 | TONE | 0–127 | feedback shelf |
+| 2 | 8 | RATE | 0–127 | CHAOS flip rate |
+| 2 | 9 | LIM | 0–127 | stereo peak limiter after MIX; 0 off, ceiling ~-2.5..-12 dB (count=128 overrides DARK GATE's 0/1) |
+
+**DRV** and **FOLD** add drive before the nonlinear stages. DRV's small-signal
+gain is fully compensated after the dirt chain. FOLD uses partial compensation
+to keep ordinary signals louder as the wave folds. In `dsp_host`, a 440 Hz,
+0.3 FS sine measured 0.98x dry RMS at FOLD 64 and 0.71x at 127. The previous
+full inverse curve measured 0.31x and 0.17x at those settings. At 0.003 FS,
+the new curve measured 3.16x dry RMS at FOLD 64 and 4.23x at 127. Those figures
+are `dsp_host` measurements; other signals, CLIP, CRSH, and FDBK change the
+output level. FDBK's maximum loop coefficient is now 0.25.
+On a 0.15 FS, 220 Hz sine with TONE 127, FDBK 127 raised late RMS by 2.47 dB;
+the previous 0.5 maximum raised it by 5.9 dB. The gate checks this sweep with
+LIM off. Raise LIM when the processed signal is already hot.
+
+On 24 Nov 2026, Ilia tested the revised FOLD compensation on an MKII with
+`CX CW.RMX`.
+
+Page-2 MODE/TONE/RATE are easiest to hear with CLIP open and FDBK up
+(CLIP 100 bricks the path so HARD≈SOFT and CHAOS is easy to miss).
+
+Live icons (`ui.s`): FOLD and FDBK match CX OSC; CLIP sine→square; CRSH
+sample-hold steps; MODE is brick / blob / shards; TONE is a shelf wedge
+(flat at 64); RATE is tick density. DRV, MIX, and LIM stay stock dials.
+
+## Storage and stock firmware
+
+The page descriptor is cloned from **DARK REV**. A Part saved with SHATTER
+keeps FX id `0x0a` and the page bytes. Stock 1.40C has no effect on that
+id (it aliases to NONE in a stock chooser). If the same page bytes are
+loaded under DARK REV, they read as DARK's knobs:
+
+| our slot | our name | stock DARK |
+|---|---|---|
+| 0–5 | DRV…MIX | TIME, SHVG, SHVF, HP, LP, MIX |
+| 6 | MODE (0–2) | PRE |
+| 7 | TONE | BAL |
+| 8 | RATE | MONO |
+| 9 | LIM | GATE |
+
+Keep a separate project copy, or re-select effects and save, before going
+back to stock.
+
+## Open
+
+- CHAOS voicing: RATE curve and polarity-flip energy
+- Whether CRSH should split into separate BRR / SRR knobs
+
+## Current limiter
+
+The shared implementation in `tools/remix/peak_limiter.py` measures both
+channels of the current mixed block, then applies one attenuation in a
+second pass. This catches the first transient, including at block boundaries.
+No makeup gain is applied. Below the ceiling, dry input stays bit-exact
+unless a preceding hot block is still releasing. LIM 0 bypasses attenuation
+and clears the release state. LIM 1..127 sets a ceiling from about -2.5 to -12 dBFS.
+The release is approximately 63 ms at 15 frames per block.
+
+The earlier -18 dB maximum and previous-block gain are superseded. Hardware
+reports above describe that earlier implementation. The new limiter awaits
+a unit test. Regression renders cover signed transients at block boundaries,
+quiet unity gain, stereo balance, and bypass.
diff --git a/sdk/octatrack/modules/shatter/upstream/manifest.py b/sdk/octatrack/modules/shatter/upstream/manifest.py
new file mode 100644
index 0000000000..635ea40323
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/upstream/manifest.py
@@ -0,0 +1,100 @@
+"""SHATTER -- multi-stage crush with chaotic feedback and a post-MIX ceiling.
+
+A per-track insert: DRV into a wavefolder, hard or soft clip, combined
+bit/sample-rate crush, then a feedback loop with a tone shelf. MODE CHAOS
+flips feedback polarity from a free-running ramp. LIM is a stereo-linked
+peak limiter after MIX (current-block peak + one block-rate div). MIX 0 is
+bit-exact dry when LIM is 0.
+"""
+
+import math
+
+from remix.peak_limiter import source as peak_limiter_source
+from remix.schema import (BusRole, Category, DspSection, Formatter, Gate, Harness,
+ Kind, Linked, MenuEntry, Module, Param, Evidence, Level, YBase)
+
+_P = Formatter.PLAIN
+_BLANK = Param(b"", 0)
+_UI = "shatter_ui"
+# Raw A=0 matches Formatter.PLAIN; B is the live icon (see ui.s).
+_W = lambda sym: dict(formatter_word=0, widget_word=(_UI, sym))
+
+# Partial makeup after the wavefolder: sqrt of its measured small-signal
+# reciprocal. Full inverse compensation made ordinary hot material much
+# quieter once the folder entered its nonlinear region.
+FOLD_GAIN = tuple(
+ ((1 << 23) - 1) if fold == 0 else
+ round(((1 << 23) - 1) / math.sqrt(2 + fold / 8))
+ for fold in range(128)
+)
+
+MODULE = Module(
+ name="shatter",
+ key="SHATTER",
+ kind=Kind.DSP_EFFECT,
+ category=Category.TRACK, author="ilia-murzinov",
+ author_url="https://github.com/ilia-murzinov",
+ evidence=(
+ Evidence(Level.UNIT, unit="MKII", who="Ilia", date="2026-10-21",
+ note="remix shatter BUILD S6 (SHATTER S6.RMX), 21 Oct 2026: every page-1/page-2 knob exercised (CLIP open "
+ "+ FDBK for MODE/TONE/RATE); verify_shatter"),
+ Evidence(Level.UNIT, unit="MKII", who="Ilia", image="SHTR LM4.RMX", date="2026-11-14",
+ commit="366e1bcd",
+ note="LIM confirmed working; verify_shatter passed."),
+ Evidence(Level.UNIT, unit="MKII", who="Ilia", image="CX CW.RMX", date="2026-11-24",
+ commit="6bd70d47",
+ note="Ilia tested the revised FOLD compensation on the unit."),
+ ),
+ doc="Crush insert: fold, clip, crush, chaotic FDBK, stereo peak limiter after MIX.",
+ menu=MenuEntry(
+ fx2_id=0x0a,
+ donor_desc=0x400d58b8, # DARK REV
+ abbr=b"SHTR",
+ fullname=b"SHATTER",
+ build_tag=False,
+ ),
+ params=(
+ Param(b"DRV", 0, active=True, formatter=_P,
+ doc="dry-path drive; output gain compensated after the dirt chain; feedback stays undriven"),
+ Param(b"FOLD", 0, active=True, **_W("wid_fold"),
+ doc="wavefolder; 0 is off; higher settings fold more with partial output gain compensation"),
+ Param(b"CLIP", 0, active=True, **_W("wid_clip"),
+ doc="clip threshold: 0 is open, 127 is a brick wall"),
+ Param(b"CRSH", 0, active=True, **_W("wid_crsh"),
+ doc="bit-depth and sample-rate crush together"),
+ Param(b"FDBK", 0, active=True, **_W("wid_fdbk"),
+ doc="feedback around the fold, clip and crush with a reduced maximum; CHAOS flips its polarity"),
+ Param(b"MIX", 127, active=True, formatter=_P,
+ doc="dry/wet; 0 is exact passthrough when LIM is 0"),
+ # MODE: DRAM label formatter + live icon (brick/blob/shards). Labels
+ # also feed the help row; raw words own the panel drawing.
+ Param(b"MODE", 0, 3, active=True, labels=("HARD", "SOFT", "CHAOS"),
+ formatter_word=(_UI, "fmt_mode"), widget_word=(_UI, "wid_mode"),
+ doc="HARD clip, SOFT (cubic) clip, or CHAOS (the feedback polarity flips)"),
+ Param(b"TONE", 64, active=True, **_W("wid_tone"),
+ doc="shelf in the feedback loop: 0 dark, 127 bright"),
+ Param(b"RATE", 64, active=True, **_W("wid_rate"),
+ doc="CHAOS: how fast the polarity flips; ignored in HARD and SOFT"),
+ # count=128 overrides DARK GATE's 0/1 companion (count None = donor).
+ Param(b"LIM", 0, 128, active=True, formatter=_P,
+ doc="stereo peak limiter after MIX; 0 off, 1..127 ceiling ~-2.5..-12 dB"),
+ _BLANK, _BLANK,
+ ),
+ mode_slot=6,
+ dsp=DspSection(
+ asm="modules/shatter/shatter.asm",
+ subst={pl: peak_limiter_source("shpk", 0x19, 0xd, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, knob=0xd) for pl in ("A", "B")},
+ priority=18,
+ ptable=FOLD_GAIN,
+ bus_role=BusRole.NONE,
+ ybase=YBase.NEVER,
+ r7_latch_slot=None,
+ gate_label=None,
+ ),
+ linked=(Linked(_UI, "modules/shatter/ui.s", cpu="5475", dram=True),),
+ harness=Harness(layout_char="4", is_server=False), # B = stock MULTIBCOMP
+
+ gates=(Gate("tools/verify/verify_shatter.py", remix_arg=False),),
+ dear={"DRV": 127, "FOLD": 127, "CLIP": 100, "CRSH": 100, "FDBK": 80,
+ "MIX": 127, "MODE": 2, "TONE": 100, "RATE": 100, "LIM": 100},
+)
diff --git a/sdk/octatrack/modules/shatter/upstream/shatter.asm b/sdk/octatrack/modules/shatter/upstream/shatter.asm
new file mode 100644
index 0000000000..02b2d46897
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/upstream/shatter.asm
@@ -0,0 +1,451 @@
+; CYCLES_SEQUENTIAL_LOOPS
+; CYCLES_FORWARD_BRANCHES
+; ---------------------------------------------------------------------------
+; SHATTER -- fold, clip, crush, chaotic feedback, brickwall after MIX.
+;
+; Insert: frames in place at x:(r0)/x:(r0+n0), knobs from r6, state in r7.
+; No bus, no buffers, no shared window.
+;
+; fb = FDBK * tone_lp * polarity (NOT driven — drive×fb self-oscillates)
+; d = dry * (1 + 8*DRV) + fb DRV 0 = unity; compensated after fold
+; f = fold(d*(1+8*FOLD))*sqrt(1/(2+FOLD/8)) FOLD 0 = unity skip
+; c = hard/soft clip(f) MODE HARD / SOFT / CHAOS
+; w = srr then brr(c) CRSH (LOFI2-style $400000 phase)
+; fb = tone_lp(w) TONE in the loop
+; m = dry + MIX * (w - dry)
+; out = lim(m) LIM brickwall after MIX; 0 = skip
+;
+; CHAOS: a block-rate phase advances by RATE; each wrap flips polarity (+/-1).
+;
+; LIM: shared current-block stereo peak limiter, one div outside sample DO.
+; Ceiling = 0.75 - LIM*0.5/128 (LIM 0 bypass), near -2.5..-12 dBFS.
+; Unity below ceiling, no makeup gain; approximately 63 ms block release.
+; The second pass controls the first transient without nested DO/div.
+;
+; r7: $00 fb L $01 fb R $02 hold L $03 hold R $04 srr phase
+; $05 tone L $06 tone R $07 polarity (+1/-1) $08 chaos phase
+; $09 srr wrap (1 this sample) $0a brr n (0..12) $0b srr inc
+; $0c clip thresh $0d lim level_s $19 lim thresh (0 = LIM off)
+; $1a lim gain $1b mixed L $1c mixed R $1d block peak $1e block start
+; $1f DRV/FOLD gain compensation (computed once per block)
+; $10..$18 per-block: drv, fold, clip, crsh, fdbk, mix, mode, tone, rate
+; Multipliers use audited signed/nonnegative operand pairs. No rep. init preserves r1.
+; SRR phase is stored from a1 (never move a,x: -- that saturates and sticks).
+; ---------------------------------------------------------------------------
+
+init:
+ clr a
+ move a,x:(r7+$00)
+ move a,x:(r7+$01)
+ move a,x:(r7+$02)
+ move a,x:(r7+$03)
+ move a,x:(r7+$04)
+ move a,x:(r7+$05)
+ move a,x:(r7+$06)
+ move a,x:(r7+$08)
+ move a,x:(r7+$09)
+ move a,x:(r7+$0a)
+ move a,x:(r7+$0b) ; srr inc (set each block)
+ move a,x:(r7+$0c) ; clip thresh
+ move a,x:(r7+$0d) ; lim level_s
+ move a,x:(r7+$19) ; lim thresh (0 = off)
+ move a,x:(r7+$1a) ; lim gain
+ move a,x:(r7+$1b) ; mixed L stash
+ move a,x:(r7+$1c) ; mixed R stash
+ move a,x:(r7+$1f) ; DRV/FOLD gain compensation
+ move #>$7fffff,x0 ; polarity +1
+ move x0,x:(r7+$07)
+ rts
+
+proc:
+; ---- knobs (mask LFO dirt) ------------------------------------------------
+ move x:(r6+$0),a ; DRV (×8 applied in sample loop)
+ and #>$7f0000,a ; LFO low byte must not leak
+ move a,x:(r7+$10)
+ move x:(r6+$1),a ; FOLD
+ and #>$7f0000,a ; LFO low byte must not arm the stage
+ move a,x:(r7+$11)
+ tst a
+ beq shfoldunity
+; Partial compensation from the 128-entry table. sqrt(reciprocal small-signal
+; gain) leaves more level in the folded signal than full inverse compensation.
+ asr #$10,a,a
+ move a1,n1
+ move #>$fab1e0,r1
+ move (r1)+n1
+ move p:(r1),a
+ move a,x:(r7+$1f)
+ bra shfoldgainready
+shfoldunity:
+ move #>$7fffff,a
+ move a,x:(r7+$1f)
+shfoldgainready:
+; DRV multiplies the dry path by 1 + 8*DRV. Its reciprocal is
+; (1/16) / (1/16 + DRV/2); combine with FOLD compensation.
+ move x:(r7+$10),a
+ tst a
+ beq shdrvunity
+ asr #$1,a,a
+ move #>$080000,b
+ add b,a
+ move a,x0
+ move #>$080000,a
+ andi #$fe,ccr
+ do #$18,>shdrvquot
+ div x0,a
+shdrvquot:
+ move a0,y1
+ bra shdrvcombine
+shdrvunity:
+ move #>$7fffff,y1
+shdrvcombine:
+ move x:(r7+$1f),x0
+ mpy x0,y1,a
+ move a,x:(r7+$1f)
+ move x:(r6+$2),a ; CLIP -> thresh = 1 - CLIP*0.875/128
+ and #>$7f0000,a
+ move a,x:(r7+$12) ; raw CLIP (0 = skip stage)
+ move a,x0
+ move #$70,y1 ; 0.875 (short immediate: bits 23-16)
+ mpy x0,y1,a
+ move #>$7fffff,b
+ sub a,b
+ move #$10,x0 ; floor ~0.125 so it never gates to 0 (short immediate: bits 23-16)
+ cmp x0,b
+ tlt x0,b
+ move b,x:(r7+$0c) ; thresh
+ move x:(r6+$3),a ; CRSH
+ and #>$7f0000,a
+ move a,x:(r7+$13)
+; BRR depth n = 1 + kn/8 (1..16), clamp 12 -- asr n / asl n keeps level
+ asr #$13,a,a ; kn>>3 → 0..15
+ add #$1,a ; (6-bit immediate)
+ move #>$c,x0
+ cmp x0,a
+ tgt x0,a
+ move a,x:(r7+$0a)
+; SRR inc: $400000 = 1.0. CRSH>0 starts at $200000 (hold ~2), then
+; asr by kn/16 more. Floor $008000 (~128-sample hold).
+ move x:(r7+$13),a
+ and #>$7f0000,a
+ asr #$14,a,a ; kn>>4 → 0..7
+ move #$20,b ; at least 2-sample hold (short immediate: bits 23-16)
+ tst a
+ beq shc0
+ asr #$1,b,b
+ move #>$1,x0
+ cmp x0,a
+ ble shc0
+ asr #$1,b,b
+ move #>$2,x0
+ cmp x0,a
+ ble shc0
+ asr #$1,b,b
+ move #>$3,x0
+ cmp x0,a
+ ble shc0
+ asr #$1,b,b
+ move #>$4,x0
+ cmp x0,a
+ ble shc0
+ asr #$1,b,b
+ move #>$5,x0
+ cmp x0,a
+ ble shc0
+ asr #$1,b,b
+ move #>$6,x0
+ cmp x0,a
+ ble shc0
+ asr #$1,b,b
+shc0:
+ move #>$008000,x0
+ cmp x0,b
+ tlt x0,b
+ move b,x:(r7+$0b)
+ move x:(r6+$4),a ; FDBK / 4 (loop gain capped at 0.25)
+ and #>$7f0000,a
+ asr #$2,a,a
+ move a,x:(r7+$14)
+ move x:(r6+$5),a ; MIX; 127 -> full scale
+ and #>$7f0000,a
+ move #$7f,x0 ; (short immediate: bits 23-16)
+ cmp x0,a
+ move #>$7fffff,x0
+ teq x0,a
+ move a,x:(r7+$15)
+; Page 2: PARAM_PAGES §6 — slot 6/7 share $c (knob / companion), slot 8 is $d.
+; Reading $6/$7/$8 left MODE/TONE/RATE dead on the unit and in dsp_host.
+ move x:(r6+$c),a ; MODE slot 6 = $c bits 16-23
+ and #>$7f0000,a
+ asr #$10,a,a
+ move a,x:(r7+$16)
+ move x:(r6+$c),a ; TONE slot 7 = $c bits 8-15
+ and #>$7f00,a
+ asl #$8,a,a ; -> TONE<<16 like page-1 knobs
+ asr #$1,a,a ; /2 for lp coeff
+ move #$04,x0 ; floor so dark still moves (short immediate: bits 23-16)
+ add x0,a
+ move a,x:(r7+$17)
+ move x:(r6+$d),a ; RATE slot 8 = $d bits 16-23
+ and #>$7f0000,a
+ asr #$4,a,a ; /16 so wraps are audible
+ move #>$001000,x0
+ add x0,a
+ move a,x:(r7+$18)
+; LIMIT_THRESHOLD
+; ---- CHAOS polarity (block rate) ------------------------------------------
+ move x:(r7+$16),a
+ move #>$2,x0
+ cmp x0,a
+ bne sh00
+ move x:(r7+$08),a
+ move x:(r7+$18),x0
+ add x0,a
+ move a,x:(r7+$08)
+ move a1,b ; wrap when high bits flip through 0
+ tst b
+ bpl sh00
+ move x:(r7+$07),a
+ neg a
+ move a,x:(r7+$07)
+ clr a
+ move a,x:(r7+$08)
+sh00:
+ move #$1,n0
+; LIMIT_PREPARE
+ do n7,>sh16
+; ---- dry * (1+8*DRV) + feedback (fb not driven) ---------------------------
+ move x:(r0),x0 ; dry L
+ move x:(r7+$10),y0 ; DRV (>=0)
+ mpy y0,x0,a ; DRV * dry
+ asl #$3,a,a ; 8 * DRV * dry
+ add x0,a ; dry * (1 + 8*DRV)
+ move a,b
+ move x:(r7+$00),x0 ; fb tone L
+ move x:(r7+$14),y1 ; fdbk (>=0)
+ mpy x0,y1,a
+ move a,x0
+ move x:(r7+$07),y1 ; polarity (+/-1)
+ mpy x0,y1,a
+ add b,a ; driven dry + undriven fb
+ move a,y0
+; ---- FOLD (skip at 0 = unity; otherwise compensate measured drive gain)
+ move x:(r7+$11),a
+ tst a
+ beq sh01
+ move y0,x0 ; v
+ move a,y1 ; FOLD
+ mpy x0,y1,a #$40,b ; FOLD*v ; 0.5
+ asl #$3,a,a ; 8*FOLD*v
+ add x0,a ; v*(1+8*FOLD) (>= v)
+ add b,a ; +0.5 into triangle fold
+ move a1,x1
+ move x1,a
+ abs a
+ sub b,a
+ asl a
+ move a,y0 ; folded L in [-1,1)
+sh01:
+; ---- CLIP (skip at 0; leave y0 alone) ------------------------------------
+ move x:(r7+$12),a ; raw CLIP
+ tst a
+ beq sh03
+ move x:(r7+$0c),x0 ; thresh
+ move y0,a
+ abs a
+ cmp x0,a
+ tgt x0,a
+ move y0,b
+ tst b
+ bpl sh02
+ neg a
+sh02:
+ move x:(r7+$16),b ; MODE
+ move #>$1,x0
+ cmp x0,b
+ bne sh18 ; HARD/CHAOS
+; SOFT: cubic on the hard-limited value
+ move a,x0
+ mpy x0,x0,b
+ move b,y1
+ mpy x0,y1,b
+ asr #$2,b,b
+ sub b,a
+sh18:
+ move a,y0
+sh03:
+; ---- CRSH: SRR ($400000 phase) then BRR asr/asl --------------------------
+ clr a
+ move a,x:(r7+$09)
+ move x:(r7+$13),b
+ tst b
+ beq sh08
+ move x:(r7+$04),b
+ move x:(r7+$0b),x0
+ add x0,b
+ move #$40,x1 ; (short immediate: bits 23-16)
+ move b,a
+ sub x1,a
+ move a,y1
+ tge y1,b
+ move b1,x:(r7+$04)
+ move #$00,a ; move #imm keeps the sub's CC (clr would not) (short immediate: bits 23-16)
+ move #>$1,x0
+ tge x0,a
+ move a,x:(r7+$09)
+ tst a
+ beq sh06
+ move y0,x:(r7+$02)
+sh06:
+ move x:(r7+$02),a
+ move y0,x0
+ tst a
+ teq x0,a ; first samples: hold still 0
+ move a,x:(r7+$02)
+ move x:(r7+$0a),y1 ; BRR n
+ move y1,b
+ tst b
+ beq sh07
+ asr y1,a,a
+ asl y1,a,a
+sh07:
+ move a,y0
+sh08:
+; ---- feedback tone LP + MIX L ---------------------------------------------
+ move x:(r7+$05),a
+ move a,x0 ; prev lp
+ move y0,a
+ sub x0,a ; in - lp
+ move a,x0 ; (in-lp) for mpy
+ move x:(r7+$17),y1
+ mpy x0,y1,b
+ move x:(r7+$05),a ; restore lp
+ add b,a
+ move a,x:(r7+$05)
+ move a,x:(r7+$00)
+; Compensate after the nonlinear chain so DRV still drives CLIP and FOLD.
+; The feedback state above remains pre-compensation.
+ move x:(r7+$1f),y1
+ mpy y0,y1,a
+ move a,y0
+ move x:(r0),b ; dry L
+ move y0,a
+ sub b,a ; wet - dry
+ move a,x0
+ move x:(r7+$15),y1 ; MIX
+ mpy x0,y1,a
+ add b,a
+ move a,x:(r7+$1b) ; mixed L stash; r0 stays on L
+; ============================= R channel ===================================
+; Dry R via (r0+n0); r0 stays on L until the unified write below.
+ move x:(r0+n0),x0 ; dry R
+ move x:(r7+$10),y0 ; DRV
+ mpy y0,x0,a
+ asl #$3,a,a ; 8 * DRV * dry
+ add x0,a ; dry * (1 + 8*DRV)
+ move a,b
+ move x:(r7+$01),x0
+ move x:(r7+$14),y1
+ mpy x0,y1,a
+ move a,x0
+ move x:(r7+$07),y1
+ mpy x0,y1,a
+ add b,a ; driven dry + undriven fb
+ move a,y0
+ move x:(r7+$11),a
+ tst a
+ beq sh09
+ move y0,x0 ; v
+ move a,y1 ; FOLD
+ mpy x0,y1,a #$40,b ; FOLD*v ; 0.5
+ asl #$3,a,a ; 8*FOLD*v
+ add x0,a ; v*(1+8*FOLD)
+ add b,a
+ move a1,x1
+ move x1,a
+ abs a
+ sub b,a
+ asl a
+ move a,y0
+sh09:
+; CLIP R
+ move x:(r7+$12),a
+ tst a
+ beq sh11
+ move x:(r7+$0c),x0
+ move y0,a
+ abs a
+ cmp x0,a
+ tgt x0,a
+ move y0,b
+ tst b
+ bpl sh10
+ neg a
+sh10:
+ move x:(r7+$16),b
+ move #>$1,x0
+ cmp x0,b
+ bne sh19
+ move a,x0
+ mpy x0,x0,b
+ move b,y1
+ mpy x0,y1,b
+ asr #$2,b,b
+ sub b,a
+sh19:
+ move a,y0
+sh11:
+; CRSH R (phase/wrap already done on L)
+ move x:(r7+$13),b
+ tst b
+ beq sh15
+ move x:(r7+$09),a
+ tst a
+ beq sh13
+ move y0,x:(r7+$03)
+sh13:
+ move x:(r7+$03),a
+ move y0,x0
+ tst a
+ teq x0,a
+ move a,x:(r7+$03)
+ move x:(r7+$0a),y1
+ move y1,b
+ tst b
+ beq sh14
+ asr y1,a,a
+ asl y1,a,a
+sh14:
+ move a,y0
+sh15:
+ move x:(r7+$06),a
+ move a,x0 ; prev lp
+ move y0,a
+ sub x0,a ; in - lp
+ move a,x0
+ move x:(r7+$17),y1
+ mpy x0,y1,b
+ move x:(r7+$06),a
+ add b,a
+ move a,x:(r7+$06)
+ move a,x:(r7+$01)
+ move x:(r7+$1f),y1
+ mpy y0,y1,a
+ move a,y0
+ move x:(r0+n0),b ; dry R (r0 still on L)
+ move y0,a
+ sub b,a
+ move a,x0
+ move x:(r7+$15),y1
+ mpy x0,y1,a
+ add b,a
+ move a,x:(r7+$1c) ; mixed R stash (LIM)
+; LIMIT_COLLECT
+ move x:(r7+$1b),a
+ move a,x:(r0)+n0
+ move x:(r7+$1c),a
+ move a,x:(r0)+
+sh16:
+ nop
+; LIMIT_FINISH
+ rts
diff --git a/sdk/octatrack/modules/shatter/upstream/tools/remix/peak_limiter.py b/sdk/octatrack/modules/shatter/upstream/tools/remix/peak_limiter.py
new file mode 100644
index 0000000000..cda4ddd0c4
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/upstream/tools/remix/peak_limiter.py
@@ -0,0 +1,124 @@
+"""Stereo block peak limiter shared by SHATTER and RESONATOR.
+
+The effect writes its mixed block first. A second pass applies one linked
+attenuation, computed from that same block, so the first transient is covered.
+No makeup gain. Its default ceiling range is 0.75 to 0.25 FS; callers may
+choose a lower floor. Quiet input below the active ceiling retains unity gain.
+"""
+
+
+def source(prefix, threshold, level, gain, left, right, peak, start, knob,
+ min_ceiling=0.25, smooth_bypass=False):
+ span_word = round((0.75 - min_ceiling) * (1 << 23))
+ ceiling_note = ("ceiling range 0.75 to 0.25 FS" if min_ceiling == 0.25
+ else f"ceiling span {0.75 - min_ceiling:.3f} FS")
+ drop_note = ("LIM*0.5/128, max ceiling 0.25 FS" if min_ceiling == 0.25
+ else f"LIM*{0.75 - min_ceiling:.2f}/128, min ceiling {min_ceiling:.2f} FS")
+ def cell(offset):
+ return f"x:(r7+${offset:02x})"
+ t, e, g, l, r, p, s = map(cell, (threshold, level, gain, left, right, peak, start))
+ threshold_code = f""" move x:(r6+${knob:x}),a
+ and #>$7f00,a
+ beq {prefix}off
+ asl #$8,a,a
+ move a,x0
+ move #>${span_word:06x},y1 ; {ceiling_note}
+ mpy x0,y1,a
+ move #>$600000,b ; 0.75 FS base ceiling
+ sub a,b ; {drop_note}
+ move b,{t}
+ bra {prefix}ready
+{prefix}off:
+ clr a
+ move a,{t}
+ move a,{e} ; clear release while bypassed
+{prefix}ready:
+"""
+ prepare = f""" move r0,{s}
+ clr a
+ move a,{p}
+"""
+ collect = f""" move {l},a
+ abs a
+ move a,x1
+ move {r},a
+ abs a
+ cmp x1,a
+ tlt x1,a
+ move {p},b
+ cmp b,a
+ tlt b,a
+ move a,{p}
+"""
+ if smooth_bypass:
+ bypass = f"""{prefix}zzrelease:
+; LIM off: return a previous attenuation to unity over the limiter release.
+ move {g},x0
+ move #>$7f4f10,y1
+ mpy x0,y1,a
+ add #>$00b0ef,a
+ move #>$7f0000,x0
+ cmp x0,a
+ move #>$7fffff,x0
+ tge x0,a
+ move a,{g}
+ cmp x0,a
+ beq {prefix}done
+ move {s},r0
+ move {g},y1
+ do n7,>{prefix}zzscale
+ move x:(r0),x0
+ mpy x0,y1,a
+ move a,x:(r0)+
+ move x:(r0),x0
+ mpy x0,y1,a
+ move a,x:(r0)+
+{prefix}zzscale:
+ nop
+"""
+ bypass_branch = f" beq {prefix}zzrelease\n"
+ else:
+ bypass = ""
+ bypass_branch = f" beq {prefix}done\n"
+ active_bypass_skip = (f" bra {prefix}done\n"
+ if smooth_bypass else "")
+ finish = f""" move {t},a
+ tst a
+{bypass_branch.rstrip()}
+; Block envelope: immediate attack, approximately 63 ms release at 15 frames.
+ move {e},x0
+ move #>$7f4f10,y1
+ mpy x0,y1,a
+ move {p},b
+ cmp b,a
+ tlt b,a
+ move a,{e}
+ move {t},b
+ cmp b,a
+ ble {prefix}done
+; g = ceiling / max(current block peak, released envelope), always < 1.
+ move a,x0
+ move b,y1
+ move y1,a
+ andi #$fe,ccr
+ do #$18,>{prefix}quot
+ div x0,a
+{prefix}quot:
+ move a0,{g}
+ move {s},r0
+ move {g},y1
+ do n7,>{prefix}scale
+ move x:(r0),x0
+ mpy x0,y1,a
+ move a,x:(r0)+
+ move x:(r0),x0
+ mpy x0,y1,a
+ move a,x:(r0)+
+{prefix}scale:
+ nop
+{active_bypass_skip}{bypass}
+{prefix}done:
+"""
+ return {"; LIMIT_THRESHOLD": threshold_code,
+ "; LIMIT_PREPARE": prepare, "; LIMIT_COLLECT": collect,
+ "; LIMIT_FINISH": finish}
diff --git a/sdk/octatrack/modules/shatter/upstream/tools/verify/verify_shatter.py b/sdk/octatrack/modules/shatter/upstream/tools/verify/verify_shatter.py
new file mode 100644
index 0000000000..df5997290e
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/upstream/tools/verify/verify_shatter.py
@@ -0,0 +1,341 @@
+#!/usr/bin/env python3
+"""SHATTER render gates.
+
+ MIX=0 -> bit-exact passthrough (LIM default 0)
+ defaults -> near-passthrough (dirt knobs 0)
+ DRV+FOLD -> both signs fold (negated in ~= negated out)
+ FDBK -> raises energy vs FDBK 0 on a tone
+ CHAOS -> non-silent with FDBK up
+ LIM -> transparent GR lowers hot peak; LIM 0 == off; LIM 1 quiet ~match
+ every knob -> renders without dsp_host dying
+ max knobs -> ~3 s no runaway; rail fraction bounded
+ DRV/FOLD -> level checked at low and ordinary input; hot peaks bounded
+ two inst -> both produce audio; rail fraction bounded
+"""
+import math, pathlib, struct, subprocess, sys
+
+sys.path.insert(0, str(pathlib.Path(__file__).resolve().parents[1]))
+import toolpath # noqa: E402,F401
+import send_probe
+from remix import registry
+
+MOD = registry.by_name("shatter")
+SEND = registry.by_name("send")
+K = MOD.knob_map()
+MEM = f"out/dsp/_audition_{MOD.name}_A.mem"
+HOST = "vendor/dsp56300/build/source/dsp_host/dsp_host"
+FXID = MOD.menu.fx2_id
+FRAMES = 15
+FS = 44100.0
+# 24-bit full scale. peak <= RAIL is always true for a 24-bit store; assert
+# on the *fraction* of samples sitting on the rail instead.
+RAIL = (1 << 23) - 1
+TMP = pathlib.Path("out/_shgate")
+TMP.mkdir(parents=True, exist_ok=True)
+
+pathlib.Path(MEM).unlink(missing_ok=True)
+subprocess.run([sys.executable, "tools/remix/audition.py", MOD.name, "out/dry/drums_110.wav"],
+ capture_output=True)
+if not pathlib.Path(MEM).exists():
+ sys.exit(f"no {MEM} -- audition failed for {MOD.name}")
+init, proc = send_probe.entry_points(MEM, FXID)
+if (init, proc) == send_probe.entry_points(MEM, SEND.menu.fx2_id):
+ sys.exit(f"fx id 0x{FXID:02x} is SEND -- SHATTER not in dump")
+print(f"entries: init=P:0x{init:04x} proc=P:0x{proc:04x}")
+
+DEFAULTS = [(p.default or 0) for p in MOD.params]
+
+
+def params(**kw):
+ v = list(DEFAULTS)
+ for name, val in kw.items():
+ v[K[name]] = val
+ return v
+
+
+def render(samples, inst=1, right_samples=None, **kw):
+ n = len(samples) - len(samples) % FRAMES
+ src, out = TMP / "in.raw", TMP / "out.raw"
+ words = samples[:n] if right_samples is None else [
+ v for pair in zip(samples[:n], right_samples[:n]) for v in pair]
+ src.write_bytes(b"".join(struct.pack("= RAIL) / len(samples)
+
+
+N = 2400
+ramp = [((i % 200) - 100) * (1 << 16) for i in range(N)]
+tone = [int(0.3 * (1 << 23) * __import__("math").sin(2 * 3.14159265 * 440 * i / 44100))
+ for i in range(N)]
+
+print("SHATTER gates")
+L, R = render(ramp, MIX=0, DRV=100, FOLD=100, CLIP=80, CRSH=80, FDBK=60)
+check("MIX=0 bit-exact", L == ramp and R == ramp, f"max|d|={max(abs(a-b) for a,b in zip(L,ramp))}")
+
+# Hot DRV + FDBK on silence must stay quiet (old: drive×fb self-oscillated)
+sil = [0] * N
+Ls, _ = render(sil, DRV=127, FOLD=80, CLIP=60, CRSH=40, FDBK=100, MIX=127, MODE=0)
+peak_s = max(abs(x) for x in Ls)
+jump_s = max((abs(Ls[i] - Ls[i - 1]) for i in range(1, len(Ls))), default=0)
+check("silence stays quiet", peak_s < (1 << 12) and jump_s < (1 << 12),
+ f"peak={peak_s} maxjump={jump_s}")
+
+L0, _ = render(ramp)
+check("defaults near dry", max(abs(a - b) for a, b in zip(L0, ramp)) < (1 << 10),
+ f"max|d|={max(abs(a-b) for a,b in zip(L0,ramp))}")
+
+Lp, _ = render(ramp, DRV=80, FOLD=90, MIX=127)
+Ln, _ = render([-x for x in ramp], DRV=80, FOLD=90, MIX=127)
+neg = [-x for x in Lp]
+err = max(abs(a - b) for a, b in zip(Ln, neg))
+check("DRV+FOLD both signs", err < (1 << 14), f"max|d|={err}")
+
+Lf0, _ = render(tone, FDBK=0, DRV=10, FOLD=16, MIX=127)
+Lf1, _ = render(tone, FDBK=90, DRV=10, FOLD=16, MIX=127)
+dfb = max(abs(a - b) for a, b in zip(Lf0, Lf1))
+check("FDBK changes tone", dfb > (1 << 14), f"max|d|={dfb}")
+
+# FDBK's loop coefficient is capped at 0.25. Measure a steady 220 Hz tone
+# over a full second and bound its late RMS rise with the limiter bypassed.
+N_FB = int(FS)
+N_FB -= N_FB % FRAMES
+feedback_probe = [int(0.15 * RAIL * __import__("math").sin(
+ 2 * 3.14159265 * 220 * i / FS)) for i in range(N_FB)]
+fb_rms = []
+for fb in (0, 32, 64, 96, 127):
+ fb_out, _ = render(feedback_probe, DRV=0, FOLD=0, CLIP=0, CRSH=0,
+ FDBK=fb, MIX=127, MODE=0, TONE=127, LIM=0)
+ tail = fb_out[N_FB // 2:]
+ fb_rms.append((sum(x * x for x in tail) / len(tail)) ** 0.5)
+ check(f"FDBK {fb} sweep audible", fb_rms[-1] >= fb_rms[0] * (1 if fb == 0 else 1.02),
+ f"rms={fb_rms[-1]/RAIL:.6f} FS")
+check("FDBK sweep rises with amount", all(a < b for a, b in zip(fb_rms, fb_rms[1:])),
+ "RMS=" + ",".join(f"{x/RAIL:.4f}" for x in fb_rms))
+check("FDBK 127 rise stays below 3.6 dB", fb_rms[-1] <= fb_rms[0] * 1.5,
+ f"ratio={fb_rms[-1]/fb_rms[0]:.3f}")
+
+Lc, _ = render(tone, MODE=2, FDBK=100, DRV=60, FOLD=60, RATE=100, MIX=127)
+check("CHAOS non-silent", max(abs(x) for x in Lc) > (1 << 16),
+ f"peak={max(abs(x) for x in Lc)}")
+
+# CRSH must change the signal (SRR hold + BRR); was a no-op when phase saturated
+Ldry, _ = render(tone, CRSH=0, MIX=127, DRV=0, FOLD=0, CLIP=0, FDBK=0)
+Lcr, _ = render(tone, CRSH=100, MIX=127, DRV=0, FOLD=0, CLIP=0, FDBK=0)
+dcr = max(abs(a - b) for a, b in zip(Ldry, Lcr))
+check("CRSH changes tone", dcr > (1 << 14), f"max|d|={dcr}")
+
+# FOLD 0 skips the stage. Below the fold threshold, partial compensation leaves
+# sqrt(measured drive gain). At ordinary input, folding should retain at least
+# half the dry RMS, and peaks must stay below -6 dBFS.
+L0, _ = render(tone, FOLD=0, DRV=0, CLIP=0, CRSH=0, FDBK=0, MIX=127)
+d01, _ = render(tone, FOLD=1, DRV=0, CLIP=0, CRSH=0, FDBK=0, MIX=127)
+e0 = sum(x * x for x in L0)
+check("FOLD 0 bit-near dry (MIX 127 passthrough path)", e0 > 0, f"e0={e0}")
+
+fold_quiet = [int(0.003 * RAIL * math.sin(
+ 2 * 3.14159265 * 440 * i / 44100)) for i in range(N)]
+q_dry, _ = render(fold_quiet, FOLD=0, DRV=0, CLIP=0, CRSH=0, FDBK=0, MIX=127)
+q_rms = (sum(x * x for x in q_dry) / len(q_dry)) ** 0.5
+for fold in (1, 16, 64, 127):
+ q_fold, _ = render(fold_quiet, FOLD=fold, DRV=0, CLIP=0, CRSH=0, FDBK=0, MIX=127)
+ f_rms = (sum(x * x for x in q_fold) / len(q_fold)) ** 0.5
+ expected = math.sqrt(2 + fold / 8)
+ check(f"FOLD {fold} partial small-signal compensation",
+ 0.95 * expected <= f_rms / q_rms <= 1.05 * expected,
+ f"expected={expected:.3f} measured={f_rms/q_rms:.3f}")
+
+hot_fold = [int(0.3 * RAIL * __import__("math").sin(
+ 2 * 3.14159265 * 440 * i / 44100)) for i in range(N)]
+hot_dry, _ = render(hot_fold, FOLD=0, DRV=0, CLIP=0, CRSH=0, FDBK=0, MIX=127)
+hot_rms = (sum(x * x for x in hot_dry) / len(hot_dry)) ** 0.5
+for fold in (1, 16, 64, 127):
+ h_fold, _ = render(hot_fold, FOLD=fold, DRV=0, CLIP=0, CRSH=0, FDBK=0, MIX=127)
+ p_fold = max(abs(x) for x in h_fold)
+ f_rms = (sum(x * x for x in h_fold) / len(h_fold)) ** 0.5
+ check(f"FOLD {fold} retains at least half hot-input RMS",
+ f_rms >= 0.5 * hot_rms,
+ f"dry={hot_rms/RAIL:.4f} fold={f_rms/RAIL:.4f} ratio={f_rms/hot_rms:.3f}")
+ check(f"FOLD {fold} hot peak below -6 dBFS", p_fold < (RAIL >> 1),
+ f"peak={p_fold} limit={RAIL >> 1}")
+
+# DRV also raises gain before the nonlinear stages. Its measured small-signal
+# gain is 1 + 8*DRV; compensation should retain level while keeping hot peaks
+# below -6 dBFS, including with FOLD bypassed.
+for drv in (1, 16, 64, 127):
+ q_drv, _ = render(fold_quiet, DRV=drv, FOLD=0, CLIP=0, CRSH=0, FDBK=0, MIX=127)
+ d_rms = (sum(x * x for x in q_drv) / len(q_drv)) ** 0.5
+ check(f"DRV {drv} compensation keeps quiet RMS within 10%",
+ 0.9 * q_rms <= d_rms <= 1.1 * q_rms,
+ f"dry={q_rms:.0f} drv={d_rms:.0f} ratio={d_rms/q_rms:.3f}")
+ h_drv, _ = render(hot_fold, DRV=drv, FOLD=0, CLIP=0, CRSH=0, FDBK=0, MIX=127)
+ p_drv = max(abs(x) for x in h_drv)
+ check(f"DRV {drv} hot peak below -6 dBFS", p_drv < (RAIL >> 1),
+ f"peak={p_drv} limit={RAIL >> 1}")
+phot = max(abs(x) for x in render(tone, DRV=100, FOLD=0, CLIP=0, CRSH=0, MIX=127)[0])
+
+# CLIP hard must reduce peak vs CLIP 0 on a hot drive
+pclip = max(abs(x) for x in render(tone, DRV=100, FOLD=0, CLIP=100, CRSH=0, MIX=127, MODE=0)[0])
+check("CLIP HARD lowers peak", pclip < phot * 0.9, f"hot={phot} clip={pclip}")
+
+psoft = max(abs(x) for x in render(tone, DRV=100, FOLD=0, CLIP=100, CRSH=0, MIX=127, MODE=1)[0])
+check("CLIP SOFT lowers peak", psoft < phot * 0.95, f"hot={phot} soft={psoft}")
+
+# Page-2 map (PARAM_PAGES §6): MODE/TONE/RATE must change the signal. A wrong
+# r6 offset ($6/$7/$8 instead of $c/$d) made all three bit-identical forever.
+Lh, _ = render(tone, DRV=100, FOLD=0, CLIP=100, CRSH=0, FDBK=0, MIX=127, MODE=0)
+Ls, _ = render(tone, DRV=100, FOLD=0, CLIP=100, CRSH=0, FDBK=0, MIX=127, MODE=1)
+d_hs = max(abs(a - b) for a, b in zip(Lh, Ls))
+check("HARD vs SOFT differs (page-2 MODE on $c)", d_hs > (1 << 12), f"max|d|={d_hs}")
+
+N_CHAOS = int(1.0 * FS)
+N_CHAOS -= N_CHAOS % FRAMES
+drive_c = [int(0.25 * (1 << 23) * __import__("math").sin(
+ 2 * 3.14159265 * 220 * i / FS)) for i in range(N_CHAOS)]
+Lt0, _ = render(drive_c, DRV=60, FOLD=40, CLIP=40, CRSH=0, FDBK=100,
+ MIX=127, MODE=2, TONE=0, RATE=64)
+Lt1, _ = render(drive_c, DRV=60, FOLD=40, CLIP=40, CRSH=0, FDBK=100,
+ MIX=127, MODE=2, TONE=127, RATE=64)
+d_tone = max(abs(a - b) for a, b in zip(Lt0, Lt1))
+check("CHAOS TONE 0 vs 127 differs (page-2 on $c companion)", d_tone > (1 << 12),
+ f"max|d|={d_tone}")
+Lr0, _ = render(drive_c, DRV=60, FOLD=40, CLIP=40, CRSH=0, FDBK=100,
+ MIX=127, MODE=2, TONE=64, RATE=0)
+Lr1, _ = render(drive_c, DRV=60, FOLD=40, CLIP=40, CRSH=0, FDBK=100,
+ MIX=127, MODE=2, TONE=64, RATE=127)
+d_rate = max(abs(a - b) for a, b in zip(Lr0, Lr1))
+check("CHAOS RATE 0 vs 127 differs (page-2 on $d)", d_rate > (1 << 12),
+ f"max|d|={d_rate}")
+
+# LIM after MIX: slot 9 = $d companion. Stereo-linked envelope + block-rate
+# g = thresh/max(level, thresh). Off path stable; on path lowers a hot peak
+# to the ceiling (transparent GR — makeup-to-FS cancelled the GR on hot).
+N_LIM = FRAMES * 32
+drive_lim = [int(0.8 * (1 << 23) * __import__("math").sin(
+ 2 * 3.14159265 * 220 * i / FS)) for i in range(N_LIM)]
+Loff, _ = render(drive_lim, MIX=127, DRV=0, FOLD=0, CLIP=0, CRSH=0, FDBK=0,
+ MODE=0, TONE=64, RATE=64, LIM=0)
+Loff2, _ = render(drive_lim, MIX=127, DRV=0, FOLD=0, CLIP=0, CRSH=0, FDBK=0,
+ MODE=0, TONE=64, RATE=64, LIM=0)
+check("LIM 0 path stable (two runs match)", Loff == Loff2)
+L100, _ = render(drive_lim, MIX=127, DRV=0, FOLD=0, CLIP=0, CRSH=0, FDBK=0,
+ MODE=0, TONE=64, RATE=64, LIM=100)
+L127, _ = render(drive_lim, MIX=127, DRV=0, FOLD=0, CLIP=0, CRSH=0, FDBK=0,
+ MODE=0, TONE=64, RATE=64, LIM=127)
+p0 = max(abs(x) for x in Loff[FRAMES:])
+p100 = max(abs(x) for x in L100[FRAMES:])
+p127 = max(abs(x) for x in L127[FRAMES:])
+check("LIM 100 lowers peak vs LIM 0", p100 < p0 * 0.85,
+ f"p0={p0} p100={p100}")
+check("LIM 127 peak below LIM 100", p127 < p100 * 0.95,
+ f"p100={p100} p127={p127}")
+# Floor ~0.125 FS: max LIM is quiet, not mute.
+check("LIM 127 still audible (floor ~0.125)", p127 > (RAIL >> 4),
+ f"p127={p127}")
+d_lim = max(abs(a - b) for a, b in zip(Loff, L100))
+check("LIM 100 changes vs LIM 0 (page-2 $d companion)", d_lim > (1 << 16),
+ f"max|d|={d_lim}")
+# Quiet below ceiling: g=1, near bit-match to LIM 0.
+quiet_lim = [int(0.05 * (1 << 23) * __import__("math").sin(
+ 2 * 3.14159265 * 220 * i / FS)) for i in range(N_LIM)]
+Q0, _ = render(quiet_lim, MIX=127, DRV=0, FOLD=0, CLIP=0, CRSH=0, FDBK=0,
+ MODE=0, TONE=64, RATE=64, LIM=0)
+Q1, _ = render(quiet_lim, MIX=127, DRV=0, FOLD=0, CLIP=0, CRSH=0, FDBK=0,
+ MODE=0, TONE=64, RATE=64, LIM=32)
+d_q = max(abs(a - b) for a, b in zip(Q0[FRAMES:], Q1[FRAMES:]))
+check("LIM 32 quiet near-matches LIM 0 (under ceiling)", d_q < (1 << 14),
+ f"max|d|={d_q}")
+
+for name in K:
+ render(ramp[:FRAMES * 4], **{name: 64})
+check("every named knob renders", True)
+
+# Max knobs, ~3 s: no runaway growth (CHAOS included). Rail fraction — not
+# peak<=RAIL (always true for 24-bit) — is the bound that can fail.
+N_LONG = int(3.0 * FS)
+N_LONG -= N_LONG % FRAMES
+drive = [int(0.25 * (1 << 23) * __import__("math").sin(
+ 2 * 3.14159265 * 220 * i / FS)) for i in range(N_LONG)]
+# Test feedback stability with the limiter bypassed.
+Lmax, Rmax = render(
+ drive, MIX=127, DRV=127, FOLD=127, CLIP=127, CRSH=127, FDBK=127,
+ MODE=2, TONE=127, RATE=127, LIM=0)
+rf_max = max(rail_frac(Lmax), rail_frac(Rmax))
+check(f"max-knob rail frac bounded ({rf_max:.3f} < 0.50)", rf_max < 0.50)
+half = len(Lmax) // 2
+e0 = sum(abs(x) for x in Lmax[:half]) / half
+e1 = sum(abs(x) for x in Lmax[half:]) / half
+check(f"max-knob no runaway (late/early={e1 / e0 if e0 else 0:.2f} < 8)",
+ e0 > 0 and e1 < e0 * 8)
+
+# DRV 127 alone at ordinary input (0.25 FS): compensation keeps the signal
+# below the rail and near the input level.
+N_DRV = int(1.0 * FS)
+N_DRV -= N_DRV % FRAMES
+drive_1s = drive[:N_DRV]
+Ldrv, Rdrv = render(
+ drive_1s, MIX=127, DRV=127, FOLD=0, CLIP=0, CRSH=0, FDBK=0,
+ MODE=0, TONE=64, RATE=64)
+rf_drv = max(rail_frac(Ldrv), rail_frac(Rdrv))
+drv_err = max(abs(a - b) for a, b in zip(Ldrv, drive_1s))
+check(f"DRV 127 compensated at 0.25 FS (rail frac {rf_drv:.3f} < 0.05)", rf_drv < 0.05)
+check("DRV 127 hot input remains audible after compensation",
+ max(abs(x) for x in Ldrv) > (1 << 16),
+ f"peak={max(abs(x) for x in Ldrv)}")
+
+# Two FX2 instances, same dear/hot knobs: both produce audio; rail frac bounded.
+pair = render(
+ tone, inst=2, MIX=127, DRV=100, FOLD=90, CLIP=40, CRSH=40, FDBK=40,
+ MODE=0, TONE=64, RATE=64)
+for i, (Li, Ri) in enumerate(pair):
+ rf = max(rail_frac(Li), rail_frac(Ri))
+ e = sum(abs(x) for x in Li[512:])
+ check(f"two-instance[{i}] has energy ({e})", e > 10_000)
+ check(f"two-instance[{i}] rail frac bounded ({rf:.3f} < 0.50)", rf < 0.50)
+
+from peak_limiter_gate import verify as verify_limiter
+verify_limiter(render, check, FRAMES, RAIL)
+
+if FAILS:
+ sys.exit(f"verify_shatter: {len(FAILS)} FAILED: {', '.join(FAILS)}")
+print("verify_shatter: OK")
diff --git a/sdk/octatrack/modules/shatter/upstream/ui.s b/sdk/octatrack/modules/shatter/upstream/ui.s
new file mode 100644
index 0000000000..8d9cf40651
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/upstream/ui.s
@@ -0,0 +1,514 @@
+| SHATTER -- live param icons (DRAM Linked). GNU as, -mcpu=5475.
+| Same widget ABI as CX OSC / VOID ui.s: stock value-only, then 17x13 blit.
+| Compact (flags bit 1) = stock only. trap-icon-bit31: bit 31 = bottom.
+|
+| Locked set: FOLD=CX, CLIP=H squareize, CRSH=v4 plateaus (8→2),
+| FDBK=CX box+loop, MODE=A brick/blob/shards, TONE=B shelf, RATE=A ticks.
+| DRV / MIX / LIM stay stock dials (no widgets here).
+
+ .text
+ .global wid_fold, wid_clip, wid_crsh, wid_fdbk
+ .global wid_mode, wid_tone, wid_rate
+ .global fmt_mode
+
+ .set STOCK_WIDGET, 0x400479b4
+ .set BLIT, 0x400128a8
+ .set SPRINTF, 0x40013a08
+
+| MODE label formatter: void fmt(char *buf, int value) — same cave shape as
+| tools/build/label_fmt.py. HARD / SOFT / CHAOS.
+fmt_mode:
+ movel %sp@(8),%d0
+ cmpil #3,%d0
+ blo fmt_mode_ok
+ moveq #0,%d0
+fmt_mode_ok:
+ lea fmt_mode_tab(%pc),%a0
+ movew %a0@(0,%d0:l:2),%d1
+ andil #0xffff,%d1
+ addal %d1,%a0
+ movel %a0,%sp@(8)
+ jmp SPRINTF
+
+wid_fold:
+ moveq #0,%d0
+ bra wid
+wid_clip:
+ moveq #1,%d0
+ bra wid
+wid_crsh:
+ moveq #2,%d0
+ bra wid
+wid_fdbk:
+ moveq #3,%d0
+ bra wid
+wid_mode:
+ moveq #4,%d0
+ bra wid
+wid_tone:
+ moveq #5,%d0
+ bra wid
+wid_rate:
+ moveq #6,%d0
+ bra wid
+
+| widget(x, y, slot, value, flags, fmt, window)
+wid:
+ lea %sp@(-44),%sp
+ moveml %d2-%d7/%a2-%a6,%sp@
+ movel %d0,%d7
+ movel %sp@(64),%d5
+ movel %d5,%d0
+ btst #1,%d5
+ bne wid_stock
+ bset #1,%d0
+ movel %d0,%sp@(64)
+wid_stock:
+ movel %sp@(72),%sp@-
+ movel %sp@(72),%sp@-
+ movel %sp@(72),%sp@-
+ movel %sp@(72),%sp@-
+ movel %sp@(72),%sp@-
+ movel %sp@(72),%sp@-
+ movel %sp@(72),%sp@-
+ jsr STOCK_WIDGET
+ lea %sp@(28),%sp
+ movel %d5,%sp@(64)
+ btst #1,%d5
+ bne wid_out
+ movel %sp@(60),%d6
+ tstl %d7
+ beq ic_fold
+ subql #1,%d7
+ beq ic_clip
+ subql #1,%d7
+ beq ic_crsh
+ subql #1,%d7
+ beq ic_fdbk
+ subql #1,%d7
+ beq ic_mode
+ subql #1,%d7
+ beq ic_tone
+ bra ic_rate
+
+
+| FOLD: CX wavefolder (Buchla cartoon). drive Q6 = 64 + value*192/127.
+ic_fold:
+ bsr ic_clr
+ movel %d6,%d5
+ movel #192,%d0
+ mulul %d0,%d5
+ moveq #127,%d0
+ divul %d0,%d5
+ addil #64,%d5
+ moveq #1,%d7
+ic_fold_col:
+ lea fold_sin(%pc),%a0
+ mvsb %a0@(0,%d7:l),%d3
+ mulsl %d5,%d3
+ asrl #6,%d3
+ic_fold_f:
+ cmpil #5,%d3
+ bgt ic_fold_hi
+ cmpil #-5,%d3
+ blt ic_fold_lo
+ bra ic_fold_ok
+ic_fold_hi:
+ moveq #10,%d0
+ subl %d3,%d0
+ movel %d0,%d3
+ bra ic_fold_f
+ic_fold_lo:
+ moveq #-10,%d0
+ subl %d3,%d0
+ movel %d0,%d3
+ bra ic_fold_f
+ic_fold_ok:
+ moveq #6,%d1
+ subl %d3,%d1
+ bpl ic_fold_r0
+ moveq #0,%d1
+ic_fold_r0:
+ cmpil #12,%d1
+ ble ic_fold_r1
+ moveq #12,%d1
+ic_fold_r1:
+ moveq #6,%d2
+ cmpl %d1,%d2
+ bge ic_fold_ord
+ movel %d1,%d0
+ movel %d2,%d1
+ movel %d0,%d2
+ic_fold_ord:
+ movel %d7,%d0
+ bsr vline
+ addql #1,%d7
+ cmpil #15,%d7
+ ble ic_fold_col
+ bra blit
+
+
+| CLIP: sine → square by lerp. h = s + (±5 − s) * v / 127. Continuous.
+| Lobe fill like FOLD so it reads next to the folder.
+ic_clip:
+ bsr ic_clr
+ moveq #1,%d7
+ic_clip_lp:
+ lea fold_sin(%pc),%a0
+ mvsb %a0@(0,%d7:l),%d3 | s
+ tstl %d3
+ bmi ic_clip_neg
+ moveq #5,%d4 | sq = +5
+ bra ic_clip_sq
+ic_clip_neg:
+ moveq #-5,%d4 | sq = −5
+ic_clip_sq:
+ movel %d4,%d0
+ subl %d3,%d0 | sq − s
+ mulsl %d6,%d0
+ moveq #127,%d1
+ divsl %d1,%d0 | (sq−s)*v/127
+ addl %d0,%d3 | h
+ moveq #6,%d1
+ subl %d3,%d1
+ bpl ic_clip_r0
+ moveq #0,%d1
+ic_clip_r0:
+ cmpil #12,%d1
+ ble ic_clip_r1
+ moveq #12,%d1
+ic_clip_r1:
+ moveq #6,%d2
+ cmpl %d1,%d2
+ bge ic_clip_draw
+ movel %d1,%d0
+ movel %d2,%d1
+ movel %d0,%d2
+ic_clip_draw:
+ movel %d7,%d0
+ bsr vline
+ addql #1,%d7
+ cmpil #15,%d7
+ ble ic_clip_lp
+ bra blit
+
+
+| CRSH: thin sample-hold LINE (not a filled lobe). hold 1..8; flats + walls.
+ic_crsh:
+ bsr ic_clr
+ movel %d6,%d5
+ moveq #7,%d0
+ mulul %d0,%d5
+ moveq #127,%d0
+ divul %d0,%d5
+ addql #1,%d5 | hold 1..8
+ moveq #-1,%d4 | prev row
+ moveq #1,%d7
+ic_crsh_lp:
+ movel %d7,%d0
+ subql #1,%d0
+ divul %d5,%d0
+ mulul %d5,%d0
+ addql #1,%d0 | src
+ cmpil #15,%d0
+ ble ic_crsh_src
+ moveq #15,%d0
+ic_crsh_src:
+ lea fold_sin(%pc),%a0
+ mvsb %a0@(0,%d0:l),%d3
+ moveq #5,%d1 | mid 5: 1 px down from FOLD; peak clears top
+ subl %d3,%d1
+ bpl ic_crsh_r0
+ moveq #0,%d1
+ic_crsh_r0:
+ cmpil #11,%d1 | never row 12 (clips the widget top)
+ ble ic_crsh_r1
+ moveq #11,%d1
+ic_crsh_r1:
+ movel %d1,%a3 | this row
+ movel %d7,%d0 | 1-px plateau (vline clobbers d1)
+ movel %a3,%d1
+ movel %a3,%d2
+ bsr vline
+ cmpil #-1,%d4
+ beq ic_crsh_next
+ cmpl %d4,%a3
+ beq ic_crsh_next
+ movel %d4,%d1
+ movel %a3,%d2
+ cmpl %d1,%d2
+ bge ic_crsh_w
+ movel %d1,%a5
+ movel %d2,%d1
+ movel %a5,%d2
+ic_crsh_w:
+ movel %d7,%d0
+ bsr vline
+ic_crsh_next:
+ movel %a3,%d4
+ addql #1,%d7
+ cmpil #15,%d7
+ ble ic_crsh_lp
+ bra blit
+
+
+| FDBK: CX modulator box; loop OR'd when value > 0; lsll #1 nudge down.
+ic_fdbk:
+ lea img_fdbk(%pc),%a0
+ bsr copy
+ tstl %d6
+ beq ic_fdbk_n
+ lea img_loop(%pc),%a0
+ bsr orimg
+ic_fdbk_n:
+ lea data(%pc),%a0
+ moveq #16,%d0
+ic_fdbk_lsl:
+ movel %a0@,%d1
+ lsll #1,%d1
+ andil #0xfff80000,%d1
+ movel %d1,%a0@+
+ subql #1,%d0
+ bge ic_fdbk_lsl
+ bra blit
+
+
+| MODE A: HARD brick / SOFT blob / CHAOS shards (static glyphs).
+ic_mode:
+ lea img_mode_hard(%pc),%a0
+ tstl %d6
+ beq ic_mode_go
+ lea img_mode_soft(%pc),%a0
+ cmpil #1,%d6
+ beq ic_mode_go
+ lea img_mode_chaos(%pc),%a0
+ic_mode_go:
+ bsr copy
+ bra blit
+
+
+| TONE B: shelf wedge, low-left ↔ high-right; double-column thick.
+| h = round(10*((15-x)*(127-v)+(x-1)*v)/(14*127)); v=64 is a flat bar.
+ic_tone:
+ bsr ic_clr
+ moveq #1,%d7
+ic_tone_lp:
+ moveq #15,%d0
+ subl %d7,%d0 | 15-x
+ moveq #127,%d1
+ subl %d6,%d1 | 127-v
+ mulul %d1,%d0 | (15-x)*(127-v)
+ movel %d7,%d1
+ subql #1,%d1 | x-1
+ mulul %d6,%d1 | (x-1)*v
+ addl %d1,%d0
+ moveq #10,%d1
+ mulul %d1,%d0
+ addil #889,%d0 | + 14*127/2 for round
+ movel #1778,%d1 | 14*127
+ divul %d1,%d0 | h
+ tstl %d0
+ bgt ic_tone_h0
+ bra ic_tone_next
+ic_tone_h0:
+ cmpil #12,%d0
+ ble ic_tone_h1
+ moveq #12,%d0
+ic_tone_h1:
+ movel %d0,%d5 | h; draw 1..h (1 px up from sitting on bottom)
+ moveq #1,%d1
+ movel %d5,%d2
+ cmpil #12,%d2
+ ble ic_tone_d0
+ moveq #12,%d2
+ic_tone_d0:
+ movel %d7,%d0
+ bsr vline
+ movel %d7,%d0
+ addql #1,%d0
+ cmpil #16,%d0
+ bgt ic_tone_next
+ moveq #1,%d1
+ movel %d5,%d2
+ cmpil #12,%d2
+ ble ic_tone_d1
+ moveq #12,%d2
+ic_tone_d1:
+ bsr vline
+ic_tone_next:
+ addql #1,%d7
+ cmpil #15,%d7
+ ble ic_tone_lp
+ bra blit
+
+
+| RATE A: tick density, 1-px ticks.
+ic_rate:
+ bsr ic_clr
+ movel %d6,%d5
+ moveq #7,%d0
+ mulul %d0,%d5
+ moveq #127,%d0
+ divul %d0,%d5
+ addql #1,%d5 | n = 1..8
+ cmpil #1,%d5
+ bne ic_rate_many
+ moveq #8,%d0 | single centre tick
+ moveq #2,%d1
+ moveq #10,%d2
+ bsr vline
+ bra blit
+ic_rate_many:
+ moveq #0,%d7 | i
+ic_rate_lp:
+ movel %d7,%d0
+ moveq #14,%d1
+ mulul %d1,%d0
+ movel %d5,%d1
+ subql #1,%d1 | n-1
+ divul %d1,%d0
+ addql #1,%d0 | x
+ moveq #2,%d1
+ moveq #10,%d2
+ bsr vline
+ addql #1,%d7
+ cmpl %d5,%d7
+ blt ic_rate_lp
+ bra blit
+
+
+blit:
+ movel %sp@(64),%d0
+ btst #0,%d0
+ beq blit1
+ lea data(%pc),%a0
+ moveq #16,%d0
+blit_inv:
+ movel %a0@,%d1
+ eoril #0xfff00000,%d1
+ movel %d1,%a0@+
+ subql #1,%d0
+ bge blit_inv
+blit1:
+ movel %sp@(52),%d0
+ addql #7,%d0
+ movel %d0,%sp@-
+ movel %sp@(52),%d0
+ addql #1,%d0
+ movel %d0,%sp@-
+ movel %sp@(80),%sp@-
+ pea bmp(%pc)
+ jsr BLIT
+ lea %sp@(16),%sp
+wid_out:
+ moveml %sp@,%d2-%d7/%a2-%a6
+ lea %sp@(44),%sp
+ rts
+
+ic_clr:
+ lea data(%pc),%a0
+ moveq #16,%d0
+ic_clr1:
+ clrl %a0@+
+ subql #1,%d0
+ bge ic_clr1
+ rts
+copy:
+ lea data(%pc),%a1
+ moveq #16,%d0
+copy1:
+ movel %a0@+,%a1@+
+ subql #1,%d0
+ bge copy1
+ rts
+orimg:
+ lea data(%pc),%a1
+ moveq #16,%d0
+orimg1:
+ movel %a0@+,%d1
+ orl %d1,%a1@+
+ subql #1,%d0
+ bge orimg1
+ rts
+| vline(x=d0, row0=d1, row1=d2) inclusive; clobbers d3,a0
+vline:
+ lea data(%pc),%a0
+ lea %a0@(0,%d0:l:4),%a0
+ movel #0x80000000,%d3
+ lsrl %d1,%d3
+vline1:
+ orl %d3,%a0@
+ lsrl #1,%d3
+ addql #1,%d1
+ cmpl %d1,%d2
+ bge vline1
+ rts
+| hline(x0=d0, row=d1, x1=d2); clobbers d3,a0
+hline:
+ lea data(%pc),%a0
+ movel #0x80000000,%d3
+ lsrl %d1,%d3
+hline1:
+ lea %a0@(0,%d0:l:4),%a1
+ orl %d3,%a1@
+ addql #1,%d0
+ cmpl %d0,%d2
+ bge hline1
+ rts
+
+fold_sin:
+ .byte 0, 3, 5, 6, 5, 3, 0, -3, -5, -6, -5, -3, 0, 3, 5, 3, 0
+ .align 2
+
+fmt_mode_tab:
+ .word fmt_mode_s0 - fmt_mode_tab
+ .word fmt_mode_s1 - fmt_mode_tab
+ .word fmt_mode_s2 - fmt_mode_tab
+fmt_mode_s0:
+ .asciz "HARD"
+fmt_mode_s1:
+ .asciz "SOFT"
+fmt_mode_s2:
+ .asciz "CHAOS"
+ .align 2
+
+bmp:
+ .long 17, 13, 1, data, mask
+mask:
+ .rept 17
+ .long 0xfff80000
+ .endr
+data:
+ .fill 17, 4, 0
+
+img_fdbk:
+ .long 0x00000000, 0x00000000, 0x00000000, 0x00000000
+ .long 0x00000000, 0x3f800000, 0x20800000, 0x20800000
+ .long 0x20800000, 0x20800000, 0x20800000, 0x3f800000
+ .long 0x00000000, 0x00000000, 0x00000000, 0x00000000
+ .long 0x00000000
+img_loop:
+ .long 0x00000000, 0x00000000, 0x07f00000, 0x0e100000
+ .long 0x04100000, 0x00100000, 0x00100000, 0x00100000
+ .long 0x00100000, 0x00100000, 0x00100000, 0x00100000
+ .long 0x04100000, 0x07f00000, 0x00000000, 0x00000000
+ .long 0x00000000
+
+img_mode_hard:
+ .long 0x00000000, 0x00000000, 0x00000000, 0x1fc00000
+ .long 0x1fc00000, 0x1fc00000, 0x1fc00000, 0x1fc00000
+ .long 0x1fc00000, 0x1fc00000, 0x1fc00000, 0x1fc00000
+ .long 0x1fc00000, 0x1fc00000, 0x00000000, 0x00000000
+ .long 0x00000000
+img_mode_soft:
+ .long 0x00000000, 0x00000000, 0x00000000, 0x00000000
+ .long 0x00000000, 0x07000000, 0x0f800000, 0x1fc00000
+ .long 0x3fe00000, 0x1fc00000, 0x0f800000, 0x07000000
+ .long 0x00000000, 0x00000000, 0x00000000, 0x00000000
+ .long 0x00000000
+img_mode_chaos:
+ .long 0x00000000, 0x00000000, 0x00200000, 0x04600000
+ .long 0x24600000, 0x28a00000, 0x48900000, 0x45100000
+ .long 0x25200000, 0x32200000, 0x52100000, 0x48900000
+ .long 0x18c00000, 0x31400000, 0x21200000, 0x00200000
+ .long 0x00000000
diff --git a/sdk/octatrack/modules/shatter/verify.py b/sdk/octatrack/modules/shatter/verify.py
new file mode 100644
index 0000000000..2751e68931
--- /dev/null
+++ b/sdk/octatrack/modules/shatter/verify.py
@@ -0,0 +1,165 @@
+#!/usr/bin/env python3
+"""Host-side gates for the pinned Octabam SHATTER DSP port.
+
+Run with python3 -B verify.py. Uses a synthetic image and dsp_host; it does not
+prove the composed image, panel, sound on an Octatrack, or hardware timing.
+"""
+import math
+import pathlib
+import sys
+import ast
+
+HERE = pathlib.Path(__file__).resolve().parent
+for base in HERE.parents:
+ tools = base / "sdk/octatrack/tools"
+ if (tools / "dsp_gate.py").is_file():
+ sys.path.insert(0, str(tools))
+ sys.path.insert(0, str(base / "sdk/octabam/tools"))
+ sys.path.insert(0, str(HERE))
+ break
+else:
+ sys.exit("[FAIL] sdk/octatrack/tools/dsp_gate.py not found")
+
+import dsp_gate as G
+from runpy import run_path
+
+MOD = run_path(str(HERE / "manifest.py"))["MODULE"]
+SOURCE = HERE / "upstream/shatter.asm"
+Q = 1 << 23
+RAIL = Q - 1
+N = 16 * 96
+KNOBS = [p.default or 0 for p in MOD.params]
+
+
+def params(**values):
+ row = list(KNOBS)
+ for name, value in values.items():
+ row[MOD.knob_map()[name]] = value
+ return row
+
+
+def main():
+ G.require_tools(HERE)
+ gate = G.Gates("SHATTER pinned Octabam port")
+ with G.workdir("shatter-verify-") as tmp:
+ work = pathlib.Path(tmp)
+ original = SOURCE.read_text()
+ emitted = MOD.dsp.source_for("A", original).replace("$fab1e0", "$3000")
+ asm = G.assemble(emitted, work, name="shatter")
+ table_record = [(G.P, 0x3000, MOD.dsp.ptable)]
+ image = asm.image(extra=table_record, name="shatter.mem")
+
+ decoded, listed = G.disassemble(asm), G.listing(asm)
+ unsigned = [line for line in decoded if line.mnemonic in ("mpysu", "macsu")]
+ safe_unsigned = [line for line in unsigned if line.mnemonic == "mpysu" and
+ line.operands == "x0,x0,b"]
+ products = [line for line in decoded if line.mnemonic.startswith(("mpy", "mac"))]
+ signed_fold = [line for line in products if line.mnemonic == "mpy" and
+ line.operands == "y0,x0,a"]
+ signed = [line for line in products if line.mnemonic not in ("mpysu", "macsu")
+ and ",".join(line.operands.split(",")[:2]) not in ("x0,y1", "y0,x0", "x0,x0")]
+ mismatches = [f"P:{line.addr:04x} {listed[line.addr].mnemonic} != {line.mnemonic}"
+ for line in decoded if line.addr in listed
+ and listed[line.addr].mnemonic != line.mnemonic
+ and line not in safe_unsigned]
+ reps = [line for line in decoded if line.mnemonic == "rep"]
+ gate("DSP decode matches source; fold table uses signed multiplies",
+ not mismatches and not unsigned and len(signed_fold) == 4 and not signed and not reps,
+ f"unsigned={[(x.mnemonic, x.operands) for x in unsigned]}, "
+ f"fold signed={len(signed_fold)}, signed={[(x.mnemonic, x.operands) for x in signed]}, "
+ + "; ".join(mismatches + [f"unexpected unsigned {x.mnemonic} {x.operands}" for x in unsigned
+ if x not in safe_unsigned] +
+ [f"unexpected signed form {x.mnemonic} {x.operands}" for x in signed] +
+ [f"REP at P:{x.addr:04x}" for x in reps]))
+ offsets = G.state_offsets(original)
+ gate("DSP state stays inside module instance block",
+ not offsets or offsets[-1] < 0x20,
+ f"highest X:(r7+${offsets[-1]:02x})" if offsets else "no r7 state")
+ limiter = run_path(str(HERE / "upstream/tools/remix/peak_limiter.py"))
+ source_tree = ast.parse((HERE / "upstream/manifest.py").read_text())
+ fold_assignment = next(node for node in source_tree.body
+ if isinstance(node, ast.Assign)
+ and any(isinstance(target, ast.Name) and target.id == "FOLD_GAIN"
+ for target in node.targets))
+ native_values = {"math": math}
+ exec(compile(ast.Module(body=[fold_assignment], type_ignores=[]),
+ "upstream/manifest.py", "exec"), native_values)
+ expected_a = original.replace("; LIMIT_THRESHOLD",
+ limiter["source"]("shpk", 0x19, 0xd, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e, knob=0xd)["; LIMIT_THRESHOLD"])
+ for marker, text in limiter["source"]("shpk", 0x19, 0xd, 0x1a, 0x1b, 0x1c, 0x1d, 0x1e,
+ knob=0xd).items():
+ expected_a = expected_a.replace(marker, text)
+ expected_a = expected_a.replace(" mpy y0,y1,a",
+ " move y1,x0 ; Keep FOLD_GAIN signed\n"
+ " mpy y0,x0,a")
+ expected_a = expected_a.replace("$fab1e0", "$3000")
+ gate("Modwerk DSP source and FOLD table match pinned Octabam manifest",
+ emitted == expected_a and MOD.dsp.ptable == native_values["FOLD_GAIN"]
+ and len(MOD.dsp.ptable) == 128)
+
+ if len(sys.argv) >= 4 and sys.argv[1] == "--fx-audit":
+ settings = dict(MOD.dear)
+ for value in sys.argv[4:]:
+ name, raw = value.split("=", 1)
+ settings[name] = int(raw)
+ G.render_fx_audit(asm, sys.argv[2], sys.argv[3], params(**settings), image=image)
+ return
+
+ x = G.noise(N, 0.65, 101)
+ xr = G.noise(N, 0.65, 202)
+ defaults = tuple(KNOBS)
+ rows = {0: defaults}
+ block = 1
+ for slot in range(10):
+ for value in (0, 64, 127):
+ row = list(defaults)
+ row[slot] = value
+ rows[block] = tuple(row)
+ block += 1
+ inst = G.Instance(x, xr, rows=rows)
+
+ a = G.run(asm, [inst], image=image, tag="normal")
+ b = G.run(asm, [inst], image=image, tag="repeat")
+ gate.same("deterministic stereo output across knob sweep", a.outputs[0], b.outputs[0])
+ gate("knob sweep stays finite and DSP host completes", a.returncode == 0)
+ gate.two_seeds("initialization clears every state word before use", asm, [inst],
+ extra=table_record)
+
+ ramp = [((i % 200) - 100) * (1 << 16) for i in range(N)]
+ dry, = G.run(asm, [G.Instance(ramp, ramp, knobs=params(MIX=0, LIM=0))], image=image,
+ tag="dry").outputs
+ gate("MIX 0 with LIM 0 is bit-exact stereo dry", dry == (ramp, ramp))
+
+ silence = [0] * N
+ quiet, = G.run(asm, [G.Instance(silence, silence,
+ knobs=params(DRV=127, FOLD=80, CLIP=60, CRSH=40, FDBK=100, MIX=127))],
+ image=image, tag="silence").outputs
+ gate("silence does not self-oscillate at high drive and feedback",
+ max(map(abs, quiet[0] + quiet[1]), default=0) < (1 << 12))
+
+ tone = G.tone(440, 0.85, N)
+ plain, = G.run(asm, [G.Instance(tone, tone, knobs=params(MIX=127, LIM=0))], image=image,
+ tag="lim-off").outputs
+ limited, = G.run(asm, [G.Instance(tone, tone,
+ knobs=params(DRV=127, FOLD=127, CLIP=100, CRSH=100, FDBK=80,
+ MIX=127, MODE=2, TONE=100, RATE=100, LIM=100))],
+ image=image, tag="lim-on").outputs
+ gate("CHAOS and LIM produce non-silent output", any(limited[0] + limited[1]))
+ gate("LIM reduces full-chain peak", max(map(abs, limited[0] + limited[1])) <
+ max(map(abs, plain[0] + plain[1])))
+ gate("limiter output remains within 24-bit rails",
+ max(map(abs, limited[0] + limited[1])) <= RAIL)
+ pair = G.run(asm, [G.Instance(tone, tone, knobs=params(MIX=127, LIM=0)),
+ G.Instance(tone, tone, knobs=params(DRV=80, FOLD=64,
+ CLIP=80, CRSH=90, FDBK=64,
+ MODE=1, MIX=127, LIM=0))],
+ image=image, tag="pair").outputs
+ gate("two independent instances both emit audio",
+ all(any(ch) for instance in pair for ch in instance))
+ print(f"[INFO] cycle meter: {a.meter} instructions/sample at defaults")
+ print(f"[INFO] dsp_gate provenance: {G.provenance(HERE)}")
+ gate.finish()
+
+
+if __name__ == "__main__":
+ main()
diff --git a/src/catalog/module-documents.json b/src/catalog/module-documents.json
index 2cf34e16b9..22460fa12b 100644
--- a/src/catalog/module-documents.json
+++ b/src/catalog/module-documents.json
@@ -6241,6 +6241,353 @@
}
]
},
+ {
+ "schemaVersion": 2,
+ "id": "shatter",
+ "key": "SHATTER",
+ "name": "Shatter",
+ "version": "0.1.0-experimental",
+ "category": "effects",
+ "source": {
+ "repository": "https://github.com/sambanks/octabam",
+ "revision": "0e2ea1dabfafe11aa4ced362cc6f2e0e41890405",
+ "path": "modules/shatter"
+ },
+ "access": {
+ "location": "FX2 SETUP on an audio track, then the FX2 control page",
+ "steps": [
+ "Select an audio track and hold [FUNC] while pressing [FX2] to open FX2 SETUP.",
+ "Turn LEVEL to SHATTER and press [YES]. Press [FX2] for DRV, FOLD, CLIP, CRSH, FDBK and MIX.",
+ "Hold [FUNC] and press [FX2] to open FX2 SETUP again. Adjust MODE, TONE, RATE and LIM in the right-side controls."
+ ],
+ "screenshots": [
+ "media/controls.png",
+ "media/setup.png"
+ ]
+ },
+ "author": {
+ "github": "ilia-murzinov",
+ "credits": [
+ "Ilia Murzinov (@ilia-murzinov), original SHATTER module author.",
+ "Sam Banks, sambanks/octabam source and MIT copyright."
+ ]
+ },
+ "nativeManifest": "manifest.py",
+ "presentation": {
+ "label": "SHATTER",
+ "family": "Destruction",
+ "summary": "Fold, clip, crush and feed the result back through a tone shelf.",
+ "overview": "SHATTER turns a track into a self-modulating crush effect. Drive and fold the signal, choose hard or soft clipping, then add bit and sample-rate reduction. CHAOS flips the feedback polarity. MIX sets the dry/wet balance, and LIM controls a stereo-linked peak limiter after the mix.",
+ "highlights": [
+ "Shape the input with drive, folding and hard or soft clipping.",
+ "Combine bit-depth and sample-rate reduction with feedback and tone.",
+ "Use CHAOS for changing feedback polarity, or LIM to cap the mixed peak."
+ ],
+ "usage": [
+ "Choose SHATTER in FX2 SETUP on an audio track, then press FX2 for its controls.",
+ "Start with FOLD, CLIP and CRSH low. Raise FDBK for a repeating, changing texture.",
+ "Turn MIX to 0 for dry sound. LIM is off at 0."
+ ]
+ },
+ "controls": [
+ {
+ "name": "DRV",
+ "default": 0,
+ "count": 128,
+ "doc": "Drive before the dirt stages. Output compensation follows the chain.",
+ "labels": null
+ },
+ {
+ "name": "FOLD",
+ "default": 0,
+ "count": 128,
+ "doc": "Wavefolder. 0 is off; higher values fold more with partial output compensation.",
+ "labels": null
+ },
+ {
+ "name": "CLIP",
+ "default": 0,
+ "count": 128,
+ "doc": "Clip threshold. 0 is open; 127 is a brick wall.",
+ "labels": null
+ },
+ {
+ "name": "CRSH",
+ "default": 0,
+ "count": 128,
+ "doc": "Bit-depth and sample-rate reduction together.",
+ "labels": null
+ },
+ {
+ "name": "FDBK",
+ "default": 0,
+ "count": 128,
+ "doc": "Feedback around the fold, clip and crush stages. CHAOS flips its polarity.",
+ "labels": null
+ },
+ {
+ "name": "MIX",
+ "default": 127,
+ "count": 128,
+ "doc": "Dry/wet balance. 0 is exact dry when LIM is off.",
+ "labels": null
+ },
+ {
+ "name": "MODE",
+ "default": 0,
+ "count": 3,
+ "doc": "HARD or SOFT clipping, or CHAOS feedback polarity flips.",
+ "labels": [
+ "HARD",
+ "SOFT",
+ "CHAOS"
+ ]
+ },
+ {
+ "name": "TONE",
+ "default": 64,
+ "count": 128,
+ "doc": "Tone shelf in the feedback loop. Lower values are darker.",
+ "labels": null
+ },
+ {
+ "name": "RATE",
+ "default": 64,
+ "count": 128,
+ "doc": "CHAOS polarity-flip rate. Ignored in HARD and SOFT.",
+ "labels": null
+ },
+ {
+ "name": "LIM",
+ "default": 0,
+ "count": 128,
+ "doc": "Stereo-linked peak limiter after MIX. 0 is off; higher values lower the ceiling.",
+ "labels": null
+ }
+ ],
+ "compatibility": {
+ "firmware": "1.40C",
+ "effectId": 10,
+ "location": "FX2",
+ "conflicts": [
+ "analog-bassdrum"
+ ],
+ "uiClaims": [],
+ "limitations": [
+ "Current package 7d11bcdbb66a passed the scripted unit phase, 120-second soak and cost admission on an Octatrack MKII running OS 1.40C. Audible quality, Keep/Undo lifecycle and reboot persistence remain unqualified.",
+ "The base refuses SHATTER beside Analog BD until that pairing is reviewed. This restriction is not evidence of an intrinsic DSP collision. Fold, clipping and crush intentionally produce strong harmonics and aliasing at extreme settings; high feedback can leave a tail after input stops."
+ ]
+ },
+ "resources": {
+ "recorded": "2026-12-06",
+ "storage": {
+ "label": "DSP program / state",
+ "display": "624 words / 32-word state",
+ "value": null,
+ "unit": "see display",
+ "method": "static",
+ "conditions": "USB package 7d11bcdbb66a: 624 DSP P words copied to each core, 32 DSP X state words per instance, no delay buffer, and 760 ColdFire image bytes including code and data. Eight instances use 768 bytes of DSP X state. The ColdFire widget callback peaks at 76 bytes of additional stack: 44 saved-register bytes, seven 4-byte arguments plus the call return for STOCK_WIDGET. No module heap or BSS; the UI scratch data is included in the 2,412-byte image. Stock memory and base-owned stacks are excluded. DSP hardware canaries were not measured.",
+ "source": "TESTING.md"
+ },
+ "processing": {
+ "label": "DSP instruction peak",
+ "display": "225 instructions/sample per instance",
+ "value": null,
+ "unit": "see display",
+ "method": "emulator",
+ "conditions": "cycle-scan models the SOFT/max path at 398.44 DSP56300 cycles/sample, including 39.5 modeled stalls, from 224.88 executed instructions/sample. It scans 12 knob configurations using a deterministic input at 0.3 full scale. This is a manual-based model, not chip timing or a proof for every signal-dependent branch. The native Octabam build separately counts 238 cycles/sample on its unadapted source. See TESTING.md.",
+ "source": "evidence/performance.json"
+ },
+ "impact": {
+ "conditions": "Per active FX2 insert at high drive, fold, crush, feedback and limiter settings with changing controls. The current Modwerk source modeled 398.44 cycles/sample at SOFT/max; the native Octabam count of 238 covers its unadapted code. The current USB package declares 624 DSP program words per core and 32 X-state words per instance.",
+ "cpu": {
+ "level": "minimal",
+ "basis": "source-estimate",
+ "rationale": "No audio work runs on ColdFire. Its code clones the effect descriptor and supplies the panel controls; it has no per-frame DSP callback.",
+ "source": "TESTING.md"
+ },
+ "dsp": {
+ "level": "moderate",
+ "basis": "source-estimate",
+ "rationale": "The current Modwerk source models 398.44 cycles/sample at SOFT/max. Four FX2 instances account for 1,593.76 modeled cycles/sample on one core before stock work; the current package passed eight-instance playback on a development twin.",
+ "source": "TESTING.md"
+ },
+ "memory": {
+ "level": "low",
+ "basis": "source-estimate",
+ "rationale": "The current USB package declares 624 DSP program words per core, 32 X-state words per instance, 760 ColdFire image bytes and no BSS or delay buffer. The package header supplies these sizes; hardware canaries were not measured.",
+ "source": "TESTING.md"
+ }
+ },
+ "cpuPrice": {
+ "value": 0,
+ "unit": "percent-of-frame",
+ "measure": "frame-interrupt",
+ "tool": "npm run device:price -- --write",
+ "date": "2026-12-06",
+ "conditions": "the bank, pattern and Part the unit was on, transport stopped (test:procedure); base development twin 117eb07f2ebc8040, Octatrack MKII, OS 1.40C; 3 readings of 8 s a state. Frame interrupt 33.8 % before, 33.7 % installed and used nowhere, 33.7 % on T1 FX2; CPU meter 53.5 % before, 50 % at rest, 50.1 % in use.",
+ "source": "evidence/cpu-price.json"
+ }
+ },
+ "tests": {
+ "report": "TESTING.md",
+ "summary": "Current package 7d11bcdbb66a passed the scripted MKII unit phase: device:test, 120-second soak, load admission and inventory/Part restore. The FX2 control and setup screens were captured on the same package. MAIN/CUE recording was unavailable, and the submitter has not reported listening, MIDI/scenes/recording or persistence results.",
+ "hardwareStatus": "reported",
+ "evidenceRevision": "ed91a5df52435befc34b912942397a32e838b273",
+ "gates": [
+ "Submitter: listen to the current package on the MKII, then report timing, MIDI, scenes and recording.",
+ "Submitter: decide whether to Keep and power-cycle; report saved-project and kept-set persistence.",
+ "Review the declared Analog BD conflict; the current base refuses the pairing."
+ ],
+ "qualification": {
+ "documentation": {
+ "tutorial": {
+ "title": "Quick tutorial",
+ "steps": [
+ "Select an audio track and choose SHATTER in FX2 SETUP.",
+ "Raise FOLD or CRSH to add strong harmonics or stepped, reduced-rate sound.",
+ "Raise FDBK and choose CHAOS for a changing feedback texture. Turn MIX to 0 for dry sound, or select NONE in FX2 SETUP to remove SHATTER."
+ ]
+ },
+ "screenshots": [
+ "media/controls.png",
+ "media/setup.png"
+ ],
+ "screenshotStyle": "black-and-white"
+ },
+ "moduleVersion": "0.1.0-experimental",
+ "sourceSha256": "8c011b2b9fef86d26002ff23d274b2afd82b8e6b039ec3883c0f9301afe2b28e",
+ "imageSha256": "7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837",
+ "cycles": [
+ {
+ "processor": "dsp",
+ "worstCase": 399,
+ "maxConfiguration": 1596,
+ "maxInstances": 8,
+ "budget": 3120,
+ "unit": "cycles/sample",
+ "method": "emulator",
+ "conditions": {
+ "parameterExtremes": "cycle-scan record: 12 configurations. Dearest SOFT/max measured 224.88 instructions/sample and modeled 398.44 cycles/sample, including 39.5 modeled stalls; rounded up to 399. Native Octabam make cycles separately reports 238 cycles/sample on its unadapted source.",
+ "parameterModulation": "Native stress project used 8 tracks, 3 LFOs per track, 12 locked FX2 controls, 1,024 trigs and 20,944 parameter-lock bytes. Native stress rendered 2,500 frames without hangs or silent output. The hardware procedure changed knobs and Parts on the earlier package. MIDI CC and scene modulation were not tested; each reaches the DSP through the same block parameter words.",
+ "modeSwitching": "HARD, SOFT and CHAOS are DSP parameter states; cycle-scan covers mode settings. MODE changes do not call init. The current package passed a 12-Part-switch scripted trial; its FX2 control and setup screens were captured on the MKII.",
+ "maxLoad": "Four instances per core, eight total: 4 x 399 = 1,596 modeled cycles/sample per core against the 3,120-cycle core budget, before stock work and contention. Native stress covered four instances per core. The current package ran all eight instances on the MKII development twin.",
+ "inputConditions": "The cycle model used a deterministic 0.3-full-scale input. verify.py separately checks silence, high drive and feedback, CHAOS, limiter behavior, rail bounds and exact dry output. Those signal tests do not measure cycle cost. Full-scale signal-dependent cycle paths remain unqualified."
+ },
+ "report": "evidence/performance.json"
+ }
+ ],
+ "memory": {
+ "regions": [
+ {
+ "name": "DSP P program on DSP core 0, including SHATTER code and FOLD table",
+ "space": "dsp-p",
+ "words": 624,
+ "wordBits": 24,
+ "bytes": 1872,
+ "scope": "shared"
+ },
+ {
+ "name": "DSP P program on DSP core 1, including SHATTER code and FOLD table",
+ "space": "dsp-p",
+ "words": 624,
+ "wordBits": 24,
+ "bytes": 1872,
+ "scope": "shared"
+ },
+ {
+ "name": "DSP X state per instance",
+ "space": "dsp-x",
+ "words": 32,
+ "wordBits": 24,
+ "bytes": 96,
+ "scope": "instance"
+ },
+ {
+ "name": "ColdFire package image and data, including UI scratch",
+ "space": "cpu-ram",
+ "words": 760,
+ "wordBits": 8,
+ "bytes": 760,
+ "scope": "shared"
+ },
+ {
+ "name": "Peak module-added widget callback stack: 44 saved-register bytes, 28 argument bytes and 4 call-return bytes",
+ "space": "cpu-ram",
+ "words": 76,
+ "wordBits": 8,
+ "bytes": 76,
+ "scope": "shared"
+ }
+ ],
+ "perInstanceBytes": 96,
+ "sharedBytes": 4580,
+ "maxInstances": 8,
+ "totalBytes": 5348,
+ "conditions": "Package header 7d11bcdbb66a reports 624 DSP P words per core, 32 X-state words per instance, 760 ColdFire image bytes, zero BSS and zero delay-buffer words. The UI assembly reserves 44 bytes for 11 saved registers, then at most 28 argument bytes and a 4-byte return address at STOCK_WIDGET, for 76 bytes of module-added stack. Internal helpers nest at most one return address and stay below that peak. DSP code has no subroutine stack use; its DO loops use the hardware loop stack. No module heap, DSP Y allocation, external buffer or additional scratch exists. DSP state bounds are checked by verify.py through r7+$1f. Base-owned and stock memory are excluded; hardware canaries were not measured.",
+ "report": "TESTING.md"
+ },
+ "hardware": {
+ "kind": "functional",
+ "status": "reported",
+ "model": "MKII",
+ "testedOn": "2026-12-06",
+ "tester": "ilia-murzinov",
+ "sourceRevision": "ed91a5df52435befc34b912942397a32e838b273",
+ "imageSha256": "7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837",
+ "summary": "On an Octatrack MKII with OS 1.40C, package 7d11bcdbb66a passed the procedure’s unit phase on development twin 117eb07f2ebc8040: device:test with eight instances, knob sweeps and Part changes; a 120-second, 2,400-operation soak; load pricing and admission on empty and medium patterns; and an unchanged inventory and clean A02 Part 2 after rollback. FX2 and FX2 SETUP LCD captures matched the controls. The full procedure still needs a clean-commit run.",
+ "limitations": [
+ "MAIN/CUE USB recording was not run: the recorder reported Octatrack not found.",
+ "No listening or timing judgement by the submitter, MIDI/scenes/recording check, Keep or power-cycle persistence is claimed.",
+ "The declared Analog BD pairing remains refused by the current base; this run did not test coexistence.",
+ "The unit phase ran while documentation and evidence were uncommitted; rerun the full procedure from a clean commit."
+ ],
+ "report": "TESTING.md"
+ }
+ }
+ },
+ "license": {
+ "spdx": "MIT",
+ "file": "LICENSE",
+ "declaration": "SHATTER is ported from sambanks/octabam at the pinned commit. The original full MIT notice and copyright are retained in upstream/LICENSE and LICENSE. The original module author is credited above."
+ },
+ "media": [
+ {
+ "path": "media/controls.png",
+ "captureType": "hardware",
+ "caption": "SHATTER controls on FX2: DRV, FOLD, CLIP, CRSH, FDBK and MIX.",
+ "alt": "Octatrack FX2 controls page showing SHATTER, with DRV, FOLD, CLIP, CRSH, FDBK and MIX.",
+ "credit": "Ilia Murzinov (USB LCD capture on his MKII)",
+ "license": "LicenseRef-OT-UI-Documentation",
+ "source": "original",
+ "otUi": {
+ "page": "FX2",
+ "shows": "controls",
+ "firmware": "1.40C",
+ "moduleVersion": "0.1.0-experimental",
+ "imageSha256": "276500fc89dae26719b9caf53a353f68c1b7c44e6879adaac4a268417956af49",
+ "setup": "Octatrack MKII on OS 1.40C, RAM-booted development twin 117eb07f2ebc8040; package 7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837 in a reversible trial; bank A pattern 02, Part 2, T1 FX2 selected; LCD read over USB."
+ }
+ },
+ {
+ "path": "media/setup.png",
+ "captureType": "hardware",
+ "caption": "SHATTER selected in FX2 SETUP; MODE, TONE, RATE and LIM appear on its setup controls.",
+ "alt": "Octatrack FX2 SETUP with SHATTER selected and controls MODE, TONE, RATE and LIM.",
+ "credit": "Ilia Murzinov (USB LCD capture on his MKII)",
+ "license": "LicenseRef-OT-UI-Documentation",
+ "source": "original",
+ "otUi": {
+ "page": "FX2 SETUP",
+ "shows": "location",
+ "firmware": "1.40C",
+ "moduleVersion": "0.1.0-experimental",
+ "imageSha256": "276500fc89dae26719b9caf53a353f68c1b7c44e6879adaac4a268417956af49",
+ "setup": "Octatrack MKII on OS 1.40C, RAM-booted development twin 117eb07f2ebc8040; package 7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837 in a reversible trial; bank A pattern 02, Part 2, SHATTER selected in T1 FX2 SETUP; LCD read over USB."
+ }
+ }
+ ]
+ },
{
"schemaVersion": 2,
"id": "analog-bassdrum",
diff --git a/src/community/module-changelogs/shatter.json b/src/community/module-changelogs/shatter.json
new file mode 100644
index 0000000000..1713807937
--- /dev/null
+++ b/src/community/module-changelogs/shatter.json
@@ -0,0 +1,12 @@
+[
+ {
+ "version": "0.1.0-experimental",
+ "date": "2026-12-05",
+ "changes": [
+ "New: SHATTER brings sound destruction to FX2.",
+ "Drive, fold, clip and crush the track signal, then feed it through adjustable feedback.",
+ "Choose HARD or SOFT clipping, or CHAOS feedback polarity flips.",
+ "MIX sets dry and wet balance. LIM caps the mixed stereo peak."
+ ]
+ }
+]
diff --git a/src/engine/assets/descriptor-recipes.json b/src/engine/assets/descriptor-recipes.json
index 012ea09a5b..a0ccd5918b 100644
--- a/src/engine/assets/descriptor-recipes.json
+++ b/src/engine/assets/descriptor-recipes.json
@@ -6212,6 +6212,351 @@
"value": "DGRD"
}
]
+ },
+ {
+ "id": "shatter",
+ "key": "SHATTER",
+ "author": "ilia-murzinov",
+ "fxId": 10,
+ "donorAddress": 1074616560,
+ "donorSha256": "3b3f9b15f2f6addfea9fc281f5b9fdf054bf305778059b8d43db41d390f0401f",
+ "fx2Slot": 1074618372,
+ "slotSha256": "79bc740214b4d029e385d06d21e224d04e8f91b53fb26ea08ffa4e5d70964b7a",
+ "sourceSha256": "373b2cda807dd93822de36b2f8a4438b361069b80f4c4f37e04f7fda992acef6",
+ "integers": [
+ {
+ "offset": 3,
+ "width": 1,
+ "value": 10
+ },
+ {
+ "offset": 94,
+ "width": 1,
+ "value": 0
+ },
+ {
+ "offset": 95,
+ "width": 1,
+ "value": 0
+ },
+ {
+ "offset": 96,
+ "width": 1,
+ "value": 0
+ },
+ {
+ "offset": 97,
+ "width": 1,
+ "value": 0
+ },
+ {
+ "offset": 98,
+ "width": 1,
+ "value": 0
+ },
+ {
+ "offset": 99,
+ "width": 1,
+ "value": 127
+ },
+ {
+ "offset": 100,
+ "width": 1,
+ "value": 0
+ },
+ {
+ "offset": 101,
+ "width": 1,
+ "value": 64
+ },
+ {
+ "offset": 102,
+ "width": 1,
+ "value": 64
+ },
+ {
+ "offset": 103,
+ "width": 1,
+ "value": 0
+ },
+ {
+ "offset": 104,
+ "width": 1,
+ "value": 0
+ },
+ {
+ "offset": 105,
+ "width": 1,
+ "value": 0
+ },
+ {
+ "offset": 202,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 250,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 206,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 254,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 210,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 258,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 214,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 262,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 218,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 266,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 222,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 270,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 226,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 274,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 230,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 278,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 234,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 282,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 238,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 286,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 242,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 290,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 246,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 294,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 226,
+ "width": 4,
+ "value": 1073989400
+ },
+ {
+ "offset": 274,
+ "width": 4,
+ "value": 1074033236
+ },
+ {
+ "offset": 322,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 178,
+ "width": 4,
+ "value": 3
+ },
+ {
+ "offset": 130,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 190,
+ "width": 4,
+ "value": 128
+ },
+ {
+ "offset": 142,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 206,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 210,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 214,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 218,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 230,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 234,
+ "width": 4,
+ "value": 0
+ },
+ {
+ "offset": 398,
+ "width": 4,
+ "value": 286331153
+ },
+ {
+ "offset": 394,
+ "width": 4,
+ "value": 17
+ }
+ ],
+ "strings": [
+ {
+ "offset": 4,
+ "width": 5,
+ "value": "SHTR"
+ },
+ {
+ "offset": 9,
+ "width": 13,
+ "value": "SHATTER"
+ },
+ {
+ "offset": 22,
+ "width": 6,
+ "value": "DRV"
+ },
+ {
+ "offset": 28,
+ "width": 6,
+ "value": "FOLD"
+ },
+ {
+ "offset": 34,
+ "width": 6,
+ "value": "CLIP"
+ },
+ {
+ "offset": 40,
+ "width": 6,
+ "value": "CRSH"
+ },
+ {
+ "offset": 46,
+ "width": 6,
+ "value": "FDBK"
+ },
+ {
+ "offset": 52,
+ "width": 6,
+ "value": "MIX"
+ },
+ {
+ "offset": 58,
+ "width": 6,
+ "value": "MODE"
+ },
+ {
+ "offset": 64,
+ "width": 6,
+ "value": "TONE"
+ },
+ {
+ "offset": 70,
+ "width": 6,
+ "value": "RATE"
+ },
+ {
+ "offset": 76,
+ "width": 6,
+ "value": "LIM"
+ },
+ {
+ "offset": 82,
+ "width": 6,
+ "value": ""
+ },
+ {
+ "offset": 88,
+ "width": 6,
+ "value": ""
+ }
+ ]
}
]
}
diff --git a/src/engine/assets/dsp-packages.json b/src/engine/assets/dsp-packages.json
index 3f55ad2da2..5b3bbf9407 100644
--- a/src/engine/assets/dsp-packages.json
+++ b/src/engine/assets/dsp-packages.json
@@ -566,6 +566,47 @@
}
]
},
+ {
+ "id": "shatter",
+ "version": "0.1.0-experimental",
+ "key": "SHATTER",
+ "author": "ilia-murzinov",
+ "sources": {
+ "modules/shatter/upstream/shatter.asm": "8fca3bf6063e989dea2397e0847000fdfe532f39d54ffb102c88e666e938aea2",
+ "modules/shatter/manifest.py": "373b2cda807dd93822de36b2f8a4438b361069b80f4c4f37e04f7fda992acef6"
+ },
+ "fxId": 10,
+ "words": 624,
+ "code": "7fffff57cea9555555530eaf50f44d4f00d94d2fd84b7d8349e69d48686147006a45aca3446b3b433a984219524106294000003f05d93e16d03d32193c56fb3b84cf3abafd39f8fb393e4b388a7b37dd203735db36945235f83335613334cf0b34417a33b84533333332b20f3234aa31bad631446830d1393061232ff4042f89ba2f22272ebd2e2e5ab32dfa9d2d9cd22d413c2ce7c62c905a2c3ae52be7542b95972b459b2af7512aaaaa2a5f982a160d29cdfc29875729421528fe2828bb87287a262839fd27fb0127bd2927806c2744c3270a2526d08b2697ec26604326298725f3b425bec1258aaa2557682524f624f34e24c26c2492492462e124343024063123d8e023ac382380352354d4232a1022ffe522d65222ad512284df225cfa22359e220ec721e87421c2a1219d4c21787221540f213023210ca920e9a020c70620a4d82083142061b82040c22020302000001fe02f1fc0bd1fa1a71f82ec1f648a1f467f1f28c91f0b681eee591ed19b1eb52d1e990d1e7d391e61b11e467320001302078e0207ce020f8e020fce02178e0217ce021f8e02278e0227ce022f8e022fce02378e0237ce0267ce026f8e026fce02778e027fce44f4007fffff021fc400000c02069e0140c67f000002478e0206de0140c67f00000247ce2000030d104a00000b0c1c2021990061f40000000020490007e18e027fce0d10c000000556f4007fffff027fce02479e2000030d104a0000100c1c0257f40008000020001021c40056f40008000000feb90618800000bc0180402107000d10c000000447f4007fffff027fd42000c0027fce020e9e0140c67f0000024f8e21c4002770002000c057f4007fffff20001c24100020004d02904802378f020ede0140c67f0000024fce0c1c2601418044f40000000c200045027040022f8e024fde0140c67f00000c1c282f20002000030d104a0000270c1c8344f4000000012000450d104f0000210c1c8344f4000000022000450d104f00001b0c1c8344f4000000032000450d104f0000150c1c8344f4000000042000450d104f00000f0c1c8344f4000000052000450d104f0000090c1c8344f4000000062000450d104f0000030c1c8344f40000800020004d029048022fcf02169e0140c67f00000c1c0402578e0216de0140c67f0000247f0020004544f4007fffff02a0400257ce02369e0140c67f00000c1c20025f8e02369e0140c6007f000c1d100c1c02240400200040025fce0236de0140c67f00000c1c0844f40000100020004002678e0236de0140c6007f000d104a00000d0c1d1021c40047f4004000002000c057f40060000020001c0267cf0d10c00000052000130267ce0237ce025f9e44f4000000022000450d104200000f02279e02679420004002278e218f0020000b0d1043000007021fde200036021fce20001302278e3801000a779000001e2000130277ce06df0000024944e0000247962000d00c1d0620004021cf000207940257972000c021c400021fd72000c020001021c6000247de2000030d104a00000e20c40021c7002f40c00c1d0620004020001021850020ae0020002620001420003221c600024f9e2000030d104a00001902379420ce0020002620004502704020cf0020000b0d1043000003200036025f9f44f40000000120004d0d104200000821c40020008821e7002000c80c1c8520001421c6002000130227ce024fdf20000b0d104a00002102179f022fd420004825400021ee0020006421c70002107802178d2e000044f4000000010210400227ce2000030d104a000003020f86020f9e20c40020000302a040020f8e022f9720ef0020000b0d104a0000040c1e6e0c1e4e21c6000217de21c40020ce0020004421c400025fd72000c80217de2000100217ce02078e027fd720e4002000d021c60057e00020ce0020001421c4000257d72000c0200010026fce44e8000247962000d00c1d0620004021cf000207d40257972000c021c400021fd72000c020001021c6000247de2000030d104a00000e20c40021c7002f40c00c1d0620004020001021850020ae0020002620001420003221c600024f9e2000030d104a00001902379420ce0020002620004502704020cf0020000b0d1043000003200036025f9f44f40000000120004d0d104200000821c40020008821e7002000c80c1c8520001421c600024fdf20000b0d104a0000140227de2000030d104a000003020fc6020fde20c40020000302a040020fce022f9720ef0020000b0d104a0000040c1e6e0c1e4e21c600021f9e21c40020ce0020004421c400025fd72000c8021f9e200010021f8e0207ce027fd720e4002000d021c60057e80020ce0020001421c4000257d72000c020001002778e026fde20002621c50002779e2000262000650290600277df2000050290000277ce026fde56480002779e5658000000000267de2000030d104a0000220237d447f4007f4f102000c00277df2000050290000237ce0267df2000050d104f00001621c40021e70020ee0000feb9061880000261018040026f880a77d000001e026f9706df0000026d44e0002000c056580044e0002000c056580000000000000c",
+ "sha256": "52a8cb9d79424924bf9399aa4b9fa1fa878bda777ce478961c78d47898c61f89",
+ "relocations": [
+ 165,
+ 187,
+ 351,
+ 608,
+ 615
+ ],
+ "init": 128,
+ "proc": 151,
+ "proofs": [
+ {
+ "base": 4096,
+ "sha256": "40907eec744b2b6235f3f31622070e1405782f1f477d826da909e40cfcf65e07"
+ },
+ {
+ "base": 5120,
+ "sha256": "9e1a0432719ac288cf8d80ad82bc0c296b7b9840ec60d80023b5c3d7af47bfa9"
+ },
+ {
+ "base": 6145,
+ "sha256": "3a82f17dccb50d04427bb285e4eb71a7c191bb64240d4705c58a56457c2892c1"
+ },
+ {
+ "base": 9223,
+ "sha256": "3c81a8f43c594300c52472ff0814bea3667c3e8d7e7e6c26314aab9a6dd3f7e7"
+ }
+ ]
+ },
{
"id": "tapeecho",
"version": "0.1.9-experimental",
diff --git a/src/engine/assets/menu-recipes.json b/src/engine/assets/menu-recipes.json
index c24eb9aa62..7991acd61e 100644
--- a/src/engine/assets/menu-recipes.json
+++ b/src/engine/assets/menu-recipes.json
@@ -1329,6 +1329,42 @@
"sha256": "f5641d626d17265a6e715abe4ace7d36b315ebac3450d163cc34c8ca165702b5"
}
]
+ },
+ {
+ "id": "shatter",
+ "key": "SHATTER",
+ "author": "ilia-murzinov",
+ "slot": 6,
+ "name": "MODE",
+ "labels": [
+ "HARD",
+ "SOFT",
+ "CHAOS"
+ ],
+ "renames": {
+ "0": {
+ "6": "HARD"
+ },
+ "1": {
+ "6": "SOFT"
+ },
+ "2": {
+ "6": "CHAOS"
+ }
+ },
+ "wideMaximum": null,
+ "proofs": [
+ {
+ "namesAddress": 1074621238,
+ "bytes": 166,
+ "sha256": "cbd1fd91ee1625e107eb0be3586ff33cfc7b108369ffa8d1ee83550df9b6ed94"
+ },
+ {
+ "namesAddress": 1074623350,
+ "bytes": 166,
+ "sha256": "611ca6cd93dfbe2a8a86f40cefe01624b99ccbe518c87bc1c514f3c802415193"
+ }
+ ]
}
],
"repitchPatches": [
diff --git a/src/engine/assets/module-build.json b/src/engine/assets/module-build.json
index 276a347e09..e261bd5b3f 100644
--- a/src/engine/assets/module-build.json
+++ b/src/engine/assets/module-build.json
@@ -1,10 +1,10 @@
{
"schemaVersion": 1,
"kind": "source-packages",
- "sourceCommit": "4d4073fdbad7e4505fdb463f09e717a4c6dbd8bf",
+ "sourceCommit": "e9f2fa33a7c5197f02a3a07e6ab2df16da2664f4",
"nativeRevision": "b8deefc88b2c3e5f3c6158e364eb741df1924e1d",
- "sourceTreeSha256": "28784f6974acdcf070f72ec69760b0c060384904f3f63c1d9866e386ad16df3f",
- "compilerSha256": "766ea9cbc6be006bb0c3cd7402571901c01fabe24d3830385a94fbce703a570e",
+ "sourceTreeSha256": "fad781f288c5d7786cc72ab3d24ecedf9e32ee994bcaaa492456344115e30a9c",
+ "compilerSha256": "3d6e31ca0fda168f289e3efa5d1be6164479f79b7c0742cceb200a4c350b4a79",
"moduleVersions": {
"miniverb": "0.2.3-experimental",
"tapeecho": "0.1.9-experimental",
@@ -24,6 +24,7 @@
"void": "0.1.1-experimental",
"fuzzbox": "0.2.0-experimental",
"glitchbox": "0.1.0-experimental",
+ "shatter": "0.1.0-experimental",
"analog-bassdrum": "0.1.7-experimental",
"usb-audio-out-tracks-main-cue": "0.4.3-experimental",
"quantizer": "0.1.5-experimental",
@@ -56,8 +57,8 @@
},
"files": {
"dsp-packages.json": {
- "bytes": 124674,
- "sha256": "cf91b4e8e376aa7103dd96dd5a1af7d72b4c7e33466d08215016e841ac3d3767"
+ "bytes": 129627,
+ "sha256": "a49b6ee3fc0d24938d3acf19c34f10b81429fc6737dd520d6b34e96c2de15fd7"
},
"resident-dsp.json": {
"bytes": 6981,
@@ -76,12 +77,12 @@
"sha256": "f4b17e0eb4e297e6dbfc61781fe5aed41262c1e7263e42579184c7cc15fa843e"
},
"menu-recipes.json": {
- "bytes": 37502,
- "sha256": "d90270e960e7ceb197e93d1ad58bfd705311c823a6e47df641b9c550a4be5a61"
+ "bytes": 38273,
+ "sha256": "892ea53fe15d9be35c7d25cd48093333a08c52186c28ba93bfd4423d779fca69"
},
"descriptor-recipes.json": {
- "bytes": 116967,
- "sha256": "1cb1864d95aff572b1627a7e3b28856a500626c26ed3240f4838b217ab134890"
+ "bytes": 123409,
+ "sha256": "b8a519952e56179fc428a3249899d8e1c9dfba1c24091b78ce7951e6eb69dfda"
},
"platform-writes.json": {
"bytes": 15585,
diff --git a/src/engine/assets/octatrack-module-packages.json b/src/engine/assets/octatrack-module-packages.json
index b1411bc120..1de1487771 100644
--- a/src/engine/assets/octatrack-module-packages.json
+++ b/src/engine/assets/octatrack-module-packages.json
@@ -1001,6 +1001,25 @@
"sha256": "6a12608622c77e3d60d06be8faf6c0b2004cdfa6b726f0b351431e35d2998cff",
"path": "octatrack-modules/void/0.1.1-experimental.mwrm"
},
+ {
+ "id": "shatter",
+ "slots": "both",
+ "cycles": 238,
+ "cyclesKind": "modeled",
+ "state": 32,
+ "buffer": 0,
+ "version": "0.1.0-experimental",
+ "path": "octatrack-modules/shatter/0.1.0-experimental.mwrm",
+ "abi": 6,
+ "features": 0,
+ "sites": 0,
+ "copies": 0,
+ "fills": 0,
+ "name": "Shatter",
+ "module": "70929dc7",
+ "bytes": 3338,
+ "sha256": "7d11bcdbb66ad5e9d58c1d041a5d52550abbcbb952d5b0de2625365002f82837"
+ },
{
"id": "defrost",
"octabam": true,