From 8aae4227a9202894771debe2deddc8c4b2e3a173 Mon Sep 17 00:00:00 2001 From: repeat98 Date: Thu, 3 Dec 2026 16:15:22 +0100 Subject: [PATCH 1/3] Attack 0.1.0-experimental for Model:Cycles OS 1.13, on main after its base durchgemacht's Attack (#2568), unchanged: approved by the owner on 3 December 2026 and merged into base/model-cycles-next, then reverted there because a module ships on main in its own pull request once its base has shipped (#2319). Co-Authored-By: durchgemacht <15388868+durchgemacht@users.noreply.github.com> Co-Authored-By: Claude Opus 5.5 --- .../2026-12-01-model-cycles-attack-package.md | 10 + sdk/imports/elekloader-attack-2026-12-01.json | 34 + .../attack-0.1.0-experimental-os1.13.elemod | 393 ++++++++++ sdk/model-cycles/modules/README.md | 4 +- sdk/model-cycles/modules/attack/LICENSE | 674 ++++++++++++++++++ sdk/model-cycles/modules/attack/README.md | 83 +++ sdk/model-cycles/modules/attack/TESTING.md | 98 +++ sdk/model-cycles/modules/attack/build.json | 51 ++ .../modules/attack/media/LICENSE.md | 7 + .../modules/attack/media/amp-attack-0.png | Bin 0 -> 1699 bytes .../modules/attack/media/amp-attack-127.png | Bin 0 -> 1852 bytes .../modules/attack/media/amp-attack-64.png | Bin 0 -> 1829 bytes .../modules/attack/media/capture.json | 37 + .../modules/attack/media/thumbnail.svg | 11 + .../modules/attack/modwerk.module.json | 188 +++++ sdk/model-cycles/modules/attack/src/attack.c | 107 +++ .../modules/attack/src/attack_pictures.h | 185 +++++ .../modules/attack/src/attack_table.h | 25 + .../modules/attack/src/gen_pictures.py | 85 +++ .../modules/attack/src/gen_table.py | 19 + .../model-cycles-attack.json | 13 + .../attack-0.1.0-experimental-os1.13.elemod | 393 ++++++++++ 22 files changed, 2416 insertions(+), 1 deletion(-) create mode 100644 docs/verification/2026-12-01-model-cycles-attack-package.md create mode 100644 sdk/imports/elekloader-attack-2026-12-01.json create mode 100644 sdk/imports/packages/attack/attack-0.1.0-experimental-os1.13.elemod create mode 100644 sdk/model-cycles/modules/attack/LICENSE create mode 100644 sdk/model-cycles/modules/attack/README.md create mode 100644 sdk/model-cycles/modules/attack/TESTING.md create mode 100644 sdk/model-cycles/modules/attack/build.json create mode 100644 sdk/model-cycles/modules/attack/media/LICENSE.md create mode 100644 sdk/model-cycles/modules/attack/media/amp-attack-0.png create mode 100644 sdk/model-cycles/modules/attack/media/amp-attack-127.png create mode 100644 sdk/model-cycles/modules/attack/media/amp-attack-64.png create mode 100644 sdk/model-cycles/modules/attack/media/capture.json create mode 100644 sdk/model-cycles/modules/attack/media/thumbnail.svg create mode 100644 sdk/model-cycles/modules/attack/modwerk.module.json create mode 100644 sdk/model-cycles/modules/attack/src/attack.c create mode 100644 sdk/model-cycles/modules/attack/src/attack_pictures.h create mode 100644 sdk/model-cycles/modules/attack/src/attack_table.h create mode 100644 sdk/model-cycles/modules/attack/src/gen_pictures.py create mode 100644 sdk/model-cycles/modules/attack/src/gen_table.py create mode 100644 src/community/module-changelogs/model-cycles-attack.json create mode 100644 vendor/elekloader/catalog/attack-0.1.0-experimental-os1.13.elemod diff --git a/docs/verification/2026-12-01-model-cycles-attack-package.md b/docs/verification/2026-12-01-model-cycles-attack-package.md new file mode 100644 index 0000000000..faec3be0d2 --- /dev/null +++ b/docs/verification/2026-12-01-model-cycles-attack-package.md @@ -0,0 +1,10 @@ +# Model:Cycles Attack package in the Elekloader catalog (1 December 2026) + +`sdk/imports/elekloader-attack-2026-12-01.json` pins `attack-0.1.0-experimental-os1.13.elemod` (sha256 `1b099c7d…`), +compiled from `sdk/model-cycles/modules/attack` by `scripts/build-elemod-packages.mjs` and kept at +`sdk/imports/packages/attack/`. `npm run elekloader:update -- --overlay sdk/imports/elekloader-attack-2026-12-01.json`: +34 cores and 75 mods, the package already in `vendor/elekloader/catalog/` with its pinned SHA-256, nothing downloaded. +`npm run module:doctor -- attack` then reads "pinned in the elekloader catalog for OS 1.13". + +The same source linked into an image with the Modwerk base 50a44d75 by the kit-pinned Elekloader patcher ran on the +author's Model:Cycles through a saved project and a power cycle (`sdk/model-cycles/modules/attack/TESTING.md`). diff --git a/sdk/imports/elekloader-attack-2026-12-01.json b/sdk/imports/elekloader-attack-2026-12-01.json new file mode 100644 index 0000000000..8ade43c864 --- /dev/null +++ b/sdk/imports/elekloader-attack-2026-12-01.json @@ -0,0 +1,34 @@ +{ + "schema": 1, + "kind": "elekloader-catalog", + "revision": "attack-2026-12-01", + "about": "Modwerk source-only Attack package for Model:Cycles OS 1.13, compiled from sdk/model-cycles/modules/attack. It contributes to the base's tables mw_voice_hooks and mw_sound_word, so the site builds it on the Modwerk base 50a44d75 or later.", + "cores": [], + "mods": [ + { + "file": "attack-0.1.0-experimental-os1.13.elemod", + "sha256": "1b099c7d4fc6b662d2a4abaa7fd51d7c122b4af68ef8901f925005cecb5768e5", + "id": "attack", + "version": "0.1.0-experimental", + "device": "model-cycles", + "os": "1.13", + "license": "GPL-3.0-or-later", + "source": { + "repo": "repeat98/modwerk", + "commit": "92154f77806399c72d174bafa4e532562d727564", + "path": "sdk/imports/packages/attack/attack-0.1.0-experimental-os1.13.elemod" + }, + "title": "ATTACK", + "requires": [ + "core" + ], + "conflicts": [], + "summary": "A rise time of up to 3 s for every track's sound, whatever its machine: hold MACHINES and turn DECAY.", + "description": "A rise time of up to 3 s for every track's sound, whatever its machine: hold MACHINES and turn DECAY.", + "category": "Playback", + "author": "durchgemacht", + "needs_core": "0.3", + "on_unit": "This source linked into an image on the Modwerk base 50a44d75 (AT10) ran on a Model:Cycles on OS 1.13, as the author reported, through a saved project and a power cycle; this package is the same source built locally." + } + ] +} diff --git a/sdk/imports/packages/attack/attack-0.1.0-experimental-os1.13.elemod b/sdk/imports/packages/attack/attack-0.1.0-experimental-os1.13.elemod new file mode 100644 index 0000000000..f82031a0fc --- /dev/null +++ b/sdk/imports/packages/attack/attack-0.1.0-experimental-os1.13.elemod @@ -0,0 +1,393 @@ +{ + "elemod": 2, + "id": "attack", + "version": "0.1.0-experimental", + "title": "Attack", + "description": "A rise time for every track's sound, whatever its machine: hold MACHINES and turn DECAY.", + "category": "playback", + "author": "durchgemacht", + "license": "GPL-3.0-or-later", + "target": { + "device": "model-cycles", + "product": "Model:Cycles", + "os": "1.13", + "syx_sha256": "44fe586269631a0ca7da25a3383fc6733c314809505fc3cc52f1e0ed9800640c", + "section3_sha256": "cc99d4f0175d34d1e91d046e6ec85a5e8ab58ab9edbb3c24406acd48cb99ee98", + "section3_len": 1744192 + }, + "sections": { + ".run": { + "align": 4, + "len": 4429, + "parts": [ + [ + "hex", + "518f2f0a72052f02202f0014b280657ae988206f001c7328003e41f90000000043f008001429000c1f4200084a416f6245f90000000022321c002f41000c4a02660000cc226f001845e902482192080074011230080d246f00181182080c242f000c21820804254202484a0166464aaa024c67164aaa023c66104aaa0244670a70012540023c42aa0244241f245f508f4e754a2f0008671622690004246f0018b3ea02486700008842011181080c1230080d67d67581d1c0202800085381226f00182f420008740fe4a0740394af00081141000d2f42000c74022342023c242f000c42a9024443f90000000075712a00226f00184c002800234202304a01668a70011140000e241f245f508f4e7522690004246f0018b3ea02486700ff34226f001845e90248219208006000ff24420143f00800255102481181080c6000ff702f027205202f0008b280655ce9882040d1fc000000004a28000e66504a28000d6666206f000c4aa80034673c206f00107328003e4a416f30226f000c2229023020414a816d3ab1fc0020c49b6f1a2040d1fc000000007003226f000c2141000842a900341140000d241f4e75420270011142000e206f000c21400034241f4e7524014482204260be226f000c241f42a900344e750002007f000000000000000000000000000000000e0000000001000000000000000000005ed0213000000000000000000032000000160000000100000000000000000000000000000000000000320000001600000001000000000000000000000000000000000000003200000016000000010000000000000000000000000000000000000032000000160000000100000000000000000000000000000000000000320000001600000001000000000000000000000000000000000000003200000016000000010000000000000000000000000000000000000032000000160000000100000000000000000000000000000000000000320000001600000001000000000000000000000000000000000000003200000016000000010000000000000000000000000000000000000032000000160000000100000000000000000000000000000000000000320000001600000001000000000000000000000000000000000000003200000016000000010000000000000000000000000000000000000032000000160000000100000000000000000000000000000000000000320000001600000001000000000000000000000000000000007ffff800fffffc00fffffc00fffffc00fffffc007ffffc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f8000000600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007c000000ffff0000fffff800fffffc00fffffc007ffffc0003fffc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f8000000600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000060000000ff800000fffc0000ffffe000fffff8007ffffc001ffffc0000fffc000007fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f800000060000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000060000000fc000000ffc00000fff80000ffff80007ffff0003ffff80007fffc00007ffc00000ffc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f80000006000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000f8000000fe000000ffc00000fff800007ffe00007fffc0000ffff80001fff800007ffc00000ffc000001fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f8000000600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000f0000000fc000000ff000000ffc000007ff800007ffe00001fff800007ffe00001fff800007ff800000ffc000003fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f800000060000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000f0000000f8000000fe000000ff8000007fe000007ff000001ffc00000fff000003ffc00000ffe000003ff800001ff8000007fc000001fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f80000006000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000f0000000f8000000fe000000ff0000007fc000007ff000003ff800000ffe000003ff000001ffc000007ff000003ff800000ff8000003fc000001fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f800000060000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000e0000000f8000000fc000000fe0000007f8000007fc000003ff000001ff8000007fc000003ff000000ff8000007fe000003ff000000ff8000007f8000001fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f800000060000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000e0000000f0000000fc000000fe000000ff0000007f8000003fe000001ff000000ff8000007fc000001fe000000ff8000007fc000003fe000001ff0000007f8000003fc000001fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f80000006000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000e0000000f0000000f8000000fc000000fe0000007f8000007fc000003fe000000ff0000007f8000003fc000001fe000000ff0000007f8000003fc000001ff000000ff8000007f8000001fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f8000000600000000000000000000000000000000000000000000000000000000000000000000000c0000000e0000000f0000000f8000000fc000000fe0000007f0000007f8000003fc000001fe000000ff0000007f8000003fc000001fe000000ff0000007f8000003fc000001fe000000ff0000007f8000003f8000001fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f800000060000000000000000000000000000000000000000000000000000000c0000000e0000000f0000000f8000000fc000000fc0000007e0000007f0000003f8000001fc000000fe0000007f0000007f8000003fc000001fe000000ff0000007f8000003f8000001fc000000fe0000007f0000003f8000001f8000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f80000006000000000000000000000000000000000000000c0000000e0000000f0000000f0000000f8000000fc0000007e0000007f0000003f8000003fc000001fc000000fe0000007f0000003f8000001fc000001fe000000fe0000007f0000003f8000001fc000000fe000000ff0000007f0000003f8000001f8000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f80000006000000000000000fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc000000000080000001c0000000d5555555e0000000e6666666eaaaaaabedb6db6ef0000000f1c71c72f3333333f45d1746f657f693f8136b0df966bd93fa6f6b38fb4155f3fbea4287fc73f354fce577e4fd4403edfd937ca6fdd6d7c0fe105c99fe41d1b9fe6c9d31fe91dbe3feb27294fecf1a87fee86af3fefee02eff12e122ff24c38cff34cf42ff4340cfff504b7aff5c1ae8ff66d46cff709815ff798187ff81a8b2ff892263ff9000bdff96539fff9c28f7ffa18d0affa68aabffab2b73ffaf77e4ffb37792ffb73141ffbaaafcffbdea2fffc0f3b7ffc3cbf7ffc676e2ffc8f80affcb52abffcd89b3ffcf9fccffd19762ffd372abffd533acffd6dc3bffd86e08ffd9eaa1ffdb5370ffdca9c4ffddeed0ffdf23b0ffe0496affe160eeffe26b1effe368c6ffe45aa8ffe54175ffe61dd3ffe6f05affe7b99bffe87a19ffe93252ffe9e2b9ffea8bb9ffeb2db9ffebc917ffec5e2bffeced49ffed76bdffedfad2ffee79cbffeef3e9ffef6969ffefda83fff0476efff0b05bfff1157afff176fafff1d502fff22fbdfff28750fff2dbdffff32d8cfff37c76fff3c8bcfff4127cfff459d0fff49ed2fff4e19cfff52244fff560e0fff59d86fff5d84afff6113ffff64878fff67e04fff6b1f6fff6e45cfff71547fff744c3fff772dffff79fa7fff7cb29fff7f570fff81e88fff8467bfff86d53fff8931cfff8b7dd416d702041747461636b0041544b00" + ] + ] + }, + ".bss": { + "align": 4, + "size": 96 + } + }, + "symbols": { + "attack_updated": [ + ".run", + 0 + ], + "trk": [ + ".bss", + 0 + ], + "ATTACK_STEP": [ + ".run", + 3902 + ], + "FALL": [ + ".run", + 504 + ], + "attack_before": [ + ".run", + 320 + ], + "ATTACK_PICTURES": [ + ".run", + 510 + ], + "ATTACK_PIXELS": [ + ".run", + 902 + ], + "ATTACK_MASK": [ + ".run", + 3702 + ], + "attack_word": [ + ".run", + 468 + ], + "attack_hook": [ + ".run", + 492 + ] + }, + "exports": [ + "attack_hook", + "attack_word" + ], + "imports": [], + "weak": [], + "relocs": [ + [ + ".run", + 28, + "abs32", + "sec:.bss", + 0 + ], + [ + ".run", + 50, + "abs32", + "sec:.run", + 3902 + ], + [ + ".run", + 232, + "abs32", + "sec:.run", + 504 + ], + [ + ".run", + 338, + "abs32", + "sec:.bss", + 0 + ], + [ + ".run", + 402, + "abs32", + "sec:.bss", + 0 + ], + [ + ".run", + 472, + "abs32", + "sec:.run", + 4414 + ], + [ + ".run", + 476, + "abs32", + "sec:.run", + 4425 + ], + [ + ".run", + 484, + "abs32", + "sec:.run", + 510 + ], + [ + ".run", + 496, + "abs32", + "sec:.run", + 320 + ], + [ + ".run", + 500, + "abs32", + "sec:.run", + 0 + ], + [ + ".run", + 526, + "abs32", + "sec:.run", + 902 + ], + [ + ".run", + 530, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 554, + "abs32", + "sec:.run", + 1102 + ], + [ + ".run", + 558, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 582, + "abs32", + "sec:.run", + 1302 + ], + [ + ".run", + 586, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 610, + "abs32", + "sec:.run", + 1502 + ], + [ + ".run", + 614, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 638, + "abs32", + "sec:.run", + 1702 + ], + [ + ".run", + 642, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 666, + "abs32", + "sec:.run", + 1902 + ], + [ + ".run", + 670, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 694, + "abs32", + "sec:.run", + 2102 + ], + [ + ".run", + 698, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 722, + "abs32", + "sec:.run", + 2302 + ], + [ + ".run", + 726, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 750, + "abs32", + "sec:.run", + 2502 + ], + [ + ".run", + 754, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 778, + "abs32", + "sec:.run", + 2702 + ], + [ + ".run", + 782, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 806, + "abs32", + "sec:.run", + 2902 + ], + [ + ".run", + 810, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 834, + "abs32", + "sec:.run", + 3102 + ], + [ + ".run", + 838, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 862, + "abs32", + "sec:.run", + 3302 + ], + [ + ".run", + 866, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 890, + "abs32", + "sec:.run", + 3502 + ], + [ + ".run", + 894, + "abs32", + "sec:.run", + 3702 + ] + ], + "sites": [], + "collections": {}, + "contribute": [ + { + "to": "mw_voice_hooks", + "order": 50, + "data": "00000000", + "relocs": [ + [ + 0, + "abs32", + "sym:attack_hook", + 0 + ] + ], + "claims": [] + }, + { + "to": "mw_sound_word", + "order": 50, + "data": "00000000", + "relocs": [ + [ + 0, + "abs32", + "sym:attack_word", + 0 + ] + ], + "claims": [] + } + ], + "copied": [], + "resources": { + "regions": [], + "names": [], + "core": "0.3" + }, + "requires": [ + "core" + ], + "conflicts": [], + "signature": null +} diff --git a/sdk/model-cycles/modules/README.md b/sdk/model-cycles/modules/README.md index 725f6789b8..89618e0ab9 100644 --- a/sdk/model-cycles/modules/README.md +++ b/sdk/model-cycles/modules/README.md @@ -1,5 +1,7 @@ # Model:Cycles modules -Each folder here will be a library module for Model:Cycles OS 1.13 on Modwerk's Model:Cycles base. There are none yet; the base is in development and downloads stay off. +Each folder here is a library module for Model:Cycles OS 1.13 on Modwerk's Model:Cycles base. The base is in development and downloads stay off. + +- [Attack](attack/README.md): adds Attack to every track, up to 3 seconds; hold MACHINES and turn DECAY. Create one with `npm run module:new -- my-mod --machine model-cycles --author your-github-login`; see [the Model:Cycles SDK guide](../../machines/model-cycles/README.md). diff --git a/sdk/model-cycles/modules/attack/LICENSE b/sdk/model-cycles/modules/attack/LICENSE new file mode 100644 index 0000000000..f288702d2f --- /dev/null +++ b/sdk/model-cycles/modules/attack/LICENSE @@ -0,0 +1,674 @@ + GNU GENERAL PUBLIC LICENSE + Version 3, 29 June 2007 + + Copyright (C) 2007 Free Software Foundation, Inc. + Everyone is permitted to copy and distribute verbatim copies + of this license document, but changing it is not allowed. + + Preamble + + The GNU General Public License is a free, copyleft license for +software and other kinds of works. + + The licenses for most software and other practical works are designed +to take away your freedom to share and change the works. By contrast, +the GNU General Public License is intended to guarantee your freedom to +share and change all versions of a program--to make sure it remains free +software for all its users. We, the Free Software Foundation, use the +GNU General Public License for most of our software; it applies also to +any other work released this way by its authors. You can apply it to +your programs, too. + + When we speak of free software, we are referring to freedom, not +price. Our General Public Licenses are designed to make sure that you +have the freedom to distribute copies of free software (and charge for +them if you wish), that you receive source code or can get it if you +want it, that you can change the software or use pieces of it in new +free programs, and that you know you can do these things. + + To protect your rights, we need to prevent others from denying you +these rights or asking you to surrender the rights. Therefore, you have +certain responsibilities if you distribute copies of the software, or if +you modify it: responsibilities to respect the freedom of others. + + For example, if you distribute copies of such a program, whether +gratis or for a fee, you must pass on to the recipients the same +freedoms that you received. You must make sure that they, too, receive +or can get the source code. And you must show them these terms so they +know their rights. + + Developers that use the GNU GPL protect your rights with two steps: +(1) assert copyright on the software, and (2) offer you this License +giving you legal permission to copy, distribute and/or modify it. + + For the developers' and authors' protection, the GPL clearly explains +that there is no warranty for this free software. For both users' and +authors' sake, the GPL requires that modified versions be marked as +changed, so that their problems will not be attributed erroneously to +authors of previous versions. + + Some devices are designed to deny users access to install or run +modified versions of the software inside them, although the manufacturer +can do so. This is fundamentally incompatible with the aim of +protecting users' freedom to change the software. The systematic +pattern of such abuse occurs in the area of products for individuals to +use, which is precisely where it is most unacceptable. Therefore, we +have designed this version of the GPL to prohibit the practice for those +products. If such problems arise substantially in other domains, we +stand ready to extend this provision to those domains in future versions +of the GPL, as needed to protect the freedom of users. + + Finally, every program is threatened constantly by software patents. +States should not allow patents to restrict development and use of +software on general-purpose computers, but in those that do, we wish to +avoid the special danger that patents applied to a free program could +make it effectively proprietary. To prevent this, the GPL assures that +patents cannot be used to render the program non-free. + + The precise terms and conditions for copying, distribution and +modification follow. + + TERMS AND CONDITIONS + + 0. Definitions. + + "This License" refers to version 3 of the GNU General Public License. + + "Copyright" also means copyright-like laws that apply to other kinds of +works, such as semiconductor masks. + + "The Program" refers to any copyrightable work licensed under this +License. Each licensee is addressed as "you". "Licensees" and +"recipients" may be individuals or organizations. + + To "modify" a work means to copy from or adapt all or part of the work +in a fashion requiring copyright permission, other than the making of an +exact copy. The resulting work is called a "modified version" of the +earlier work or a work "based on" the earlier work. + + A "covered work" means either the unmodified Program or a work based +on the Program. + + To "propagate" a work means to do anything with it that, without +permission, would make you directly or secondarily liable for +infringement under applicable copyright law, except executing it on a +computer or modifying a private copy. Propagation includes copying, +distribution (with or without modification), making available to the +public, and in some countries other activities as well. + + To "convey" a work means any kind of propagation that enables other +parties to make or receive copies. Mere interaction with a user through +a computer network, with no transfer of a copy, is not conveying. + + An interactive user interface displays "Appropriate Legal Notices" +to the extent that it includes a convenient and prominently visible +feature that (1) displays an appropriate copyright notice, and (2) +tells the user that there is no warranty for the work (except to the +extent that warranties are provided), that licensees may convey the +work under this License, and how to view a copy of this License. If +the interface presents a list of user commands or options, such as a +menu, a prominent item in the list meets this criterion. + + 1. Source Code. + + The "source code" for a work means the preferred form of the work +for making modifications to it. "Object code" means any non-source +form of a work. + + A "Standard Interface" means an interface that either is an official +standard defined by a recognized standards body, or, in the case of +interfaces specified for a particular programming language, one that +is widely used among developers working in that language. + + The "System Libraries" of an executable work include anything, other +than the work as a whole, that (a) is included in the normal form of +packaging a Major Component, but which is not part of that Major +Component, and (b) serves only to enable use of the work with that +Major Component, or to implement a Standard Interface for which an +implementation is available to the public in source code form. A +"Major Component", in this context, means a major essential component +(kernel, window system, and so on) of the specific operating system +(if any) on which the executable work runs, or a compiler used to +produce the work, or an object code interpreter used to run it. + + The "Corresponding Source" for a work in object code form means all +the source code needed to generate, install, and (for an executable +work) run the object code and to modify the work, including scripts to +control those activities. However, it does not include the work's +System Libraries, or general-purpose tools or generally available free +programs which are used unmodified in performing those activities but +which are not part of the work. For example, Corresponding Source +includes interface definition files associated with source files for +the work, and the source code for shared libraries and dynamically +linked subprograms that the work is specifically designed to require, +such as by intimate data communication or control flow between those +subprograms and other parts of the work. + + The Corresponding Source need not include anything that users +can regenerate automatically from other parts of the Corresponding +Source. + + The Corresponding Source for a work in source code form is that +same work. + + 2. Basic Permissions. + + All rights granted under this License are granted for the term of +copyright on the Program, and are irrevocable provided the stated +conditions are met. This License explicitly affirms your unlimited +permission to run the unmodified Program. The output from running a +covered work is covered by this License only if the output, given its +content, constitutes a covered work. This License acknowledges your +rights of fair use or other equivalent, as provided by copyright law. + + You may make, run and propagate covered works that you do not +convey, without conditions so long as your license otherwise remains +in force. You may convey covered works to others for the sole purpose +of having them make modifications exclusively for you, or provide you +with facilities for running those works, provided that you comply with +the terms of this License in conveying all material for which you do +not control copyright. Those thus making or running the covered works +for you must do so exclusively on your behalf, under your direction +and control, on terms that prohibit them from making any copies of +your copyrighted material outside their relationship with you. + + Conveying under any other circumstances is permitted solely under +the conditions stated below. Sublicensing is not allowed; section 10 +makes it unnecessary. + + 3. Protecting Users' Legal Rights From Anti-Circumvention Law. + + No covered work shall be deemed part of an effective technological +measure under any applicable law fulfilling obligations under article +11 of the WIPO copyright treaty adopted on 20 December 1996, or +similar laws prohibiting or restricting circumvention of such +measures. + + When you convey a covered work, you waive any legal power to forbid +circumvention of technological measures to the extent such circumvention +is effected by exercising rights under this License with respect to +the covered work, and you disclaim any intention to limit operation or +modification of the work as a means of enforcing, against the work's +users, your or third parties' legal rights to forbid circumvention of +technological measures. + + 4. Conveying Verbatim Copies. + + You may convey verbatim copies of the Program's source code as you +receive it, in any medium, provided that you conspicuously and +appropriately publish on each copy an appropriate copyright notice; +keep intact all notices stating that this License and any +non-permissive terms added in accord with section 7 apply to the code; +keep intact all notices of the absence of any warranty; and give all +recipients a copy of this License along with the Program. + + You may charge any price or no price for each copy that you convey, +and you may offer support or warranty protection for a fee. + + 5. Conveying Modified Source Versions. + + You may convey a work based on the Program, or the modifications to +produce it from the Program, in the form of source code under the +terms of section 4, provided that you also meet all of these conditions: + + a) The work must carry prominent notices stating that you modified + it, and giving a relevant date. + + b) The work must carry prominent notices stating that it is + released under this License and any conditions added under section + 7. This requirement modifies the requirement in section 4 to + "keep intact all notices". + + c) You must license the entire work, as a whole, under this + License to anyone who comes into possession of a copy. This + License will therefore apply, along with any applicable section 7 + additional terms, to the whole of the work, and all its parts, + regardless of how they are packaged. This License gives no + permission to license the work in any other way, but it does not + invalidate such permission if you have separately received it. + + d) If the work has interactive user interfaces, each must display + Appropriate Legal Notices; however, if the Program has interactive + interfaces that do not display Appropriate Legal Notices, your + work need not make them do so. + + A compilation of a covered work with other separate and independent +works, which are not by their nature extensions of the covered work, +and which are not combined with it such as to form a larger program, +in or on a volume of a storage or distribution medium, is called an +"aggregate" if the compilation and its resulting copyright are not +used to limit the access or legal rights of the compilation's users +beyond what the individual works permit. Inclusion of a covered work +in an aggregate does not cause this License to apply to the other +parts of the aggregate. + + 6. Conveying Non-Source Forms. + + You may convey a covered work in object code form under the terms +of sections 4 and 5, provided that you also convey the +machine-readable Corresponding Source under the terms of this License, +in one of these ways: + + a) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by the + Corresponding Source fixed on a durable physical medium + customarily used for software interchange. + + b) Convey the object code in, or embodied in, a physical product + (including a physical distribution medium), accompanied by a + written offer, valid for at least three years and valid for as + long as you offer spare parts or customer support for that product + model, to give anyone who possesses the object code either (1) a + copy of the Corresponding Source for all the software in the + product that is covered by this License, on a durable physical + medium customarily used for software interchange, for a price no + more than your reasonable cost of physically performing this + conveying of source, or (2) access to copy the + Corresponding Source from a network server at no charge. + + c) Convey individual copies of the object code with a copy of the + written offer to provide the Corresponding Source. This + alternative is allowed only occasionally and noncommercially, and + only if you received the object code with such an offer, in accord + with subsection 6b. + + d) Convey the object code by offering access from a designated + place (gratis or for a charge), and offer equivalent access to the + Corresponding Source in the same way through the same place at no + further charge. You need not require recipients to copy the + Corresponding Source along with the object code. If the place to + copy the object code is a network server, the Corresponding Source + may be on a different server (operated by you or a third party) + that supports equivalent copying facilities, provided you maintain + clear directions next to the object code saying where to find the + Corresponding Source. Regardless of what server hosts the + Corresponding Source, you remain obligated to ensure that it is + available for as long as needed to satisfy these requirements. + + e) Convey the object code using peer-to-peer transmission, provided + you inform other peers where the object code and Corresponding + Source of the work are being offered to the general public at no + charge under subsection 6d. + + A separable portion of the object code, whose source code is excluded +from the Corresponding Source as a System Library, need not be +included in conveying the object code work. + + A "User Product" is either (1) a "consumer product", which means any +tangible personal property which is normally used for personal, family, +or household purposes, or (2) anything designed or sold for incorporation +into a dwelling. In determining whether a product is a consumer product, +doubtful cases shall be resolved in favor of coverage. For a particular +product received by a particular user, "normally used" refers to a +typical or common use of that class of product, regardless of the status +of the particular user or of the way in which the particular user +actually uses, or expects or is expected to use, the product. A product +is a consumer product regardless of whether the product has substantial +commercial, industrial or non-consumer uses, unless such uses represent +the only significant mode of use of the product. + + "Installation Information" for a User Product means any methods, +procedures, authorization keys, or other information required to install +and execute modified versions of a covered work in that User Product from +a modified version of its Corresponding Source. The information must +suffice to ensure that the continued functioning of the modified object +code is in no case prevented or interfered with solely because +modification has been made. + + If you convey an object code work under this section in, or with, or +specifically for use in, a User Product, and the conveying occurs as +part of a transaction in which the right of possession and use of the +User Product is transferred to the recipient in perpetuity or for a +fixed term (regardless of how the transaction is characterized), the +Corresponding Source conveyed under this section must be accompanied +by the Installation Information. But this requirement does not apply +if neither you nor any third party retains the ability to install +modified object code on the User Product (for example, the work has +been installed in ROM). + + The requirement to provide Installation Information does not include a +requirement to continue to provide support service, warranty, or updates +for a work that has been modified or installed by the recipient, or for +the User Product in which it has been modified or installed. Access to a +network may be denied when the modification itself materially and +adversely affects the operation of the network or violates the rules and +protocols for communication across the network. + + Corresponding Source conveyed, and Installation Information provided, +in accord with this section must be in a format that is publicly +documented (and with an implementation available to the public in +source code form), and must require no special password or key for +unpacking, reading or copying. + + 7. Additional Terms. + + "Additional permissions" are terms that supplement the terms of this +License by making exceptions from one or more of its conditions. +Additional permissions that are applicable to the entire Program shall +be treated as though they were included in this License, to the extent +that they are valid under applicable law. If additional permissions +apply only to part of the Program, that part may be used separately +under those permissions, but the entire Program remains governed by +this License without regard to the additional permissions. + + When you convey a copy of a covered work, you may at your option +remove any additional permissions from that copy, or from any part of +it. (Additional permissions may be written to require their own +removal in certain cases when you modify the work.) You may place +additional permissions on material, added by you to a covered work, +for which you have or can give appropriate copyright permission. + + Notwithstanding any other provision of this License, for material you +add to a covered work, you may (if authorized by the copyright holders of +that material) supplement the terms of this License with terms: + + a) Disclaiming warranty or limiting liability differently from the + terms of sections 15 and 16 of this License; or + + b) Requiring preservation of specified reasonable legal notices or + author attributions in that material or in the Appropriate Legal + Notices displayed by works containing it; or + + c) Prohibiting misrepresentation of the origin of that material, or + requiring that modified versions of such material be marked in + reasonable ways as different from the original version; or + + d) Limiting the use for publicity purposes of names of licensors or + authors of the material; or + + e) Declining to grant rights under trademark law for use of some + trade names, trademarks, or service marks; or + + f) Requiring indemnification of licensors and authors of that + material by anyone who conveys the material (or modified versions of + it) with contractual assumptions of liability to the recipient, for + any liability that these contractual assumptions directly impose on + those licensors and authors. + + All other non-permissive additional terms are considered "further +restrictions" within the meaning of section 10. If the Program as you +received it, or any part of it, contains a notice stating that it is +governed by this License along with a term that is a further +restriction, you may remove that term. If a license document contains +a further restriction but permits relicensing or conveying under this +License, you may add to a covered work material governed by the terms +of that license document, provided that the further restriction does +not survive such relicensing or conveying. + + If you add terms to a covered work in accord with this section, you +must place, in the relevant source files, a statement of the +additional terms that apply to those files, or a notice indicating +where to find the applicable terms. + + Additional terms, permissive or non-permissive, may be stated in the +form of a separately written license, or stated as exceptions; +the above requirements apply either way. + + 8. Termination. + + You may not propagate or modify a covered work except as expressly +provided under this License. Any attempt otherwise to propagate or +modify it is void, and will automatically terminate your rights under +this License (including any patent licenses granted under the third +paragraph of section 11). + + However, if you cease all violation of this License, then your +license from a particular copyright holder is reinstated (a) +provisionally, unless and until the copyright holder explicitly and +finally terminates your license, and (b) permanently, if the copyright +holder fails to notify you of the violation by some reasonable means +prior to 60 days after the cessation. + + Moreover, your license from a particular copyright holder is +reinstated permanently if the copyright holder notifies you of the +violation by some reasonable means, this is the first time you have +received notice of violation of this License (for any work) from that +copyright holder, and you cure the violation prior to 30 days after +your receipt of the notice. + + Termination of your rights under this section does not terminate the +licenses of parties who have received copies or rights from you under +this License. If your rights have been terminated and not permanently +reinstated, you do not qualify to receive new licenses for the same +material under section 10. + + 9. Acceptance Not Required for Having Copies. + + You are not required to accept this License in order to receive or +run a copy of the Program. Ancillary propagation of a covered work +occurring solely as a consequence of using peer-to-peer transmission +to receive a copy likewise does not require acceptance. However, +nothing other than this License grants you permission to propagate or +modify any covered work. These actions infringe copyright if you do +not accept this License. Therefore, by modifying or propagating a +covered work, you indicate your acceptance of this License to do so. + + 10. Automatic Licensing of Downstream Recipients. + + Each time you convey a covered work, the recipient automatically +receives a license from the original licensors, to run, modify and +propagate that work, subject to this License. You are not responsible +for enforcing compliance by third parties with this License. + + An "entity transaction" is a transaction transferring control of an +organization, or substantially all assets of one, or subdividing an +organization, or merging organizations. If propagation of a covered +work results from an entity transaction, each party to that +transaction who receives a copy of the work also receives whatever +licenses to the work the party's predecessor in interest had or could +give under the previous paragraph, plus a right to possession of the +Corresponding Source of the work from the predecessor in interest, if +the predecessor has it or can get it with reasonable efforts. + + You may not impose any further restrictions on the exercise of the +rights granted or affirmed under this License. For example, you may +not impose a license fee, royalty, or other charge for exercise of +rights granted under this License, and you may not initiate litigation +(including a cross-claim or counterclaim in a lawsuit) alleging that +any patent claim is infringed by making, using, selling, offering for +sale, or importing the Program or any portion of it. + + 11. Patents. + + A "contributor" is a copyright holder who authorizes use under this +License of the Program or a work on which the Program is based. The +work thus licensed is called the contributor's "contributor version". + + A contributor's "essential patent claims" are all patent claims +owned or controlled by the contributor, whether already acquired or +hereafter acquired, that would be infringed by some manner, permitted +by this License, of making, using, or selling its contributor version, +but do not include claims that would be infringed only as a +consequence of further modification of the contributor version. For +purposes of this definition, "control" includes the right to grant +patent sublicenses in a manner consistent with the requirements of +this License. + + Each contributor grants you a non-exclusive, worldwide, royalty-free +patent license under the contributor's essential patent claims, to +make, use, sell, offer for sale, import and otherwise run, modify and +propagate the contents of its contributor version. + + In the following three paragraphs, a "patent license" is any express +agreement or commitment, however denominated, not to enforce a patent +(such as an express permission to practice a patent or covenant not to +sue for patent infringement). To "grant" such a patent license to a +party means to make such an agreement or commitment not to enforce a +patent against the party. + + If you convey a covered work, knowingly relying on a patent license, +and the Corresponding Source of the work is not available for anyone +to copy, free of charge and under the terms of this License, through a +publicly available network server or other readily accessible means, +then you must either (1) cause the Corresponding Source to be so +available, or (2) arrange to deprive yourself of the benefit of the +patent license for this particular work, or (3) arrange, in a manner +consistent with the requirements of this License, to extend the patent +license to downstream recipients. "Knowingly relying" means you have +actual knowledge that, but for the patent license, your conveying the +covered work in a country, or your recipient's use of the covered work +in a country, would infringe one or more identifiable patents in that +country that you have reason to believe are valid. + + If, pursuant to or in connection with a single transaction or +arrangement, you convey, or propagate by procuring conveyance of, a +covered work, and grant a patent license to some of the parties +receiving the covered work authorizing them to use, propagate, modify +or convey a specific copy of the covered work, then the patent license +you grant is automatically extended to all recipients of the covered +work and works based on it. + + A patent license is "discriminatory" if it does not include within +the scope of its coverage, prohibits the exercise of, or is +conditioned on the non-exercise of one or more of the rights that are +specifically granted under this License. You may not convey a covered +work if you are a party to an arrangement with a third party that is +in the business of distributing software, under which you make payment +to the third party based on the extent of your activity of conveying +the work, and under which the third party grants, to any of the +parties who would receive the covered work from you, a discriminatory +patent license (a) in connection with copies of the covered work +conveyed by you (or copies made from those copies), or (b) primarily +for and in connection with specific products or compilations that +contain the covered work, unless you entered into that arrangement, +or that patent license was granted, prior to 28 March 2007. + + Nothing in this License shall be construed as excluding or limiting +any implied license or other defenses to infringement that may +otherwise be available to you under applicable patent law. + + 12. No Surrender of Others' Freedom. + + If conditions are imposed on you (whether by court order, agreement or +otherwise) that contradict the conditions of this License, they do not +excuse you from the conditions of this License. If you cannot convey a +covered work so as to satisfy simultaneously your obligations under this +License and any other pertinent obligations, then as a consequence you may +not convey it at all. For example, if you agree to terms that obligate you +to collect a royalty for further conveying from those to whom you convey +the Program, the only way you could satisfy both those terms and this +License would be to refrain entirely from conveying the Program. + + 13. Use with the GNU Affero General Public License. + + Notwithstanding any other provision of this License, you have +permission to link or combine any covered work with a work licensed +under version 3 of the GNU Affero General Public License into a single +combined work, and to convey the resulting work. The terms of this +License will continue to apply to the part which is the covered work, +but the special requirements of the GNU Affero General Public License, +section 13, concerning interaction through a network will apply to the +combination as such. + + 14. Revised Versions of this License. + + The Free Software Foundation may publish revised and/or new versions of +the GNU General Public License from time to time. Such new versions will +be similar in spirit to the present version, but may differ in detail to +address new problems or concerns. + + Each version is given a distinguishing version number. If the +Program specifies that a certain numbered version of the GNU General +Public License "or any later version" applies to it, you have the +option of following the terms and conditions either of that numbered +version or of any later version published by the Free Software +Foundation. If the Program does not specify a version number of the +GNU General Public License, you may choose any version ever published +by the Free Software Foundation. + + If the Program specifies that a proxy can decide which future +versions of the GNU General Public License can be used, that proxy's +public statement of acceptance of a version permanently authorizes you +to choose that version for the Program. + + Later license versions may give you additional or different +permissions. However, no additional obligations are imposed on any +author or copyright holder as a result of your choosing to follow a +later version. + + 15. Disclaimer of Warranty. + + THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY +APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT +HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY +OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, +THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR +PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM +IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF +ALL NECESSARY SERVICING, REPAIR OR CORRECTION. + + 16. Limitation of Liability. + + IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING +WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS +THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY +GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE +USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF +DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD +PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), +EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF +SUCH DAMAGES. + + 17. Interpretation of Sections 15 and 16. + + If the disclaimer of warranty and limitation of liability provided +above cannot be given local legal effect according to their terms, +reviewing courts shall apply local law that most closely approximates +an absolute waiver of all civil liability in connection with the +Program, unless a warranty or assumption of liability accompanies a +copy of the Program in return for a fee. + + END OF TERMS AND CONDITIONS + + How to Apply These Terms to Your New Programs + + If you develop a new program, and you want it to be of the greatest +possible use to the public, the best way to achieve this is to make it +free software which everyone can redistribute and change under these terms. + + To do so, attach the following notices to the program. It is safest +to attach them to the start of each source file to most effectively +state the exclusion of warranty; and each file should have at least +the "copyright" line and a pointer to where the full notice is found. + + + Copyright (C) + + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +Also add information on how to contact you by electronic and paper mail. + + If the program does terminal interaction, make it output a short +notice like this when it starts in an interactive mode: + + Copyright (C) + This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'. + This is free software, and you are welcome to redistribute it + under certain conditions; type `show c' for details. + +The hypothetical commands `show w' and `show c' should show the appropriate +parts of the General Public License. Of course, your program's commands +might be different; for a GUI interface, you would use an "about box". + + You should also get your employer (if you work as a programmer) or school, +if any, to sign a "copyright disclaimer" for the program, if necessary. +For more information on this, and how to apply and follow the GNU GPL, see +. + + The GNU General Public License does not permit incorporating your program +into proprietary programs. If your program is a subroutine library, you +may consider it more useful to permit linking proprietary applications with +the library. If this is what you want to do, use the GNU Lesser General +Public License instead of this License. But first, please read +. diff --git a/sdk/model-cycles/modules/attack/README.md b/sdk/model-cycles/modules/attack/README.md new file mode 100644 index 0000000000..3a64c57d95 --- /dev/null +++ b/sdk/model-cycles/modules/attack/README.md @@ -0,0 +1,83 @@ +# Attack + +A Model:Cycles mod by @durchgemacht. Version 0.1.0-experimental, for OS 1.13 on Modwerk's Model:Cycles base. + +## Overview + +Adds Attack to every track, up to 3 seconds. Hold MACHINES and turn DECAY. + +The Model:Cycles' amp envelope has a decay but no attack: each machine starts its notes at its own fixed speed. With +Attack you set it from 0 to 127 on every track, with any machine; 0 leaves the machine's own start, as stock plays it. +The display shows Amp Attack on two lines, as stock's Amp Decay, with an envelope for the value: the rise slants further +the higher you turn it. + +Attack is a parameter of the sound like any other: parameter locks, the LFO, velocity, Control All and MIDI CC 73 +reach it, and the sound saves it. It uses the base's sound word (k 31 of every sound, saved in record slot 31) and its +voice hooks; it patches no stock code. + +When a slow attack retriggers a track that still sounds, stock would pull the old note to silence within one block +(0.67 ms) and start the new note from there: a click that a slow rise lays bare. Attack holds such a trig back for +2 ms while the old note fades out on an S curve, then lets it play as stock does, from silence. + +With GATE on, stock's envelope holds at the top while the note lasts, but it reads the note's end only once the +attack is at the top: a short note would play the whole rise and then the decay. With Attack above 0 and GATE on, a +note that ends during the rise turns to the decay at once, from the level it reached, as an ADSR envelope does. With +GATE off the rise and the decay play out, as stock's decay does. + +## Controls + +| Control | What it does | +| --- | --- | +| Hold MACHINES, turn DECAY (Amp Attack, ATK) | Attack time, 0 to 127, up to 3 seconds; 0 is off | +| MIDI CC 73 | Sets ATK on the track's channel | + +The knob's curve has the shape of DECAY's: low values are a few milliseconds, 64 is about 0.55 s, 127 is 3 s. Each +value has its own time. ATK is a parameter lock, LFO and velocity destination; FUNC and Control All work on it as on +DECAY. + +## Usage + +Slow swells on pads and drones, softer hits on a busy pattern, or a single note that fades in. Lock a high ATK on one +step so that one hit fades in; put the LFO on ATK for swells that change from note to note. + +### Quick tutorial + +1. Pick a track with a long sound, for example TONE with a long DECAY. +2. Hold MACHINES and turn DECAY to about 90. The notes now fade in slowly. +3. Turn it back to 0 to switch Attack off. + +## Compatibility and limitations + +- Built for OS 1.13 only, on Modwerk's Model:Cycles base with voice hooks and the sound word, ABI 2, each table read from the + build (base 50a44d75 or later). Built into the image it stays through a power cycle; loaded over USB it lives until + the next one. +- It owns the base's sound word (`mw_sound_word`, room 1): only one module that owns it can be installed. +- Covers all six tracks and every machine, stock and added. +- Overrides the machine's own attack step (the amp envelope's step a block) while ATK is above 0; DECAY, AMP and + everything else still apply. +- With ATK above 0, a trig on a track that still sounds (above −60 dB) starts its note 2 ms later, while the old note + fades out. A silent track starts at once. +- Without the module the saved value stays in the sound and plays nothing; MACHINES + DECAY turns DECAY and CC 73 does + nothing. +- Stock 1.13 plays such a project without the rise, and the state it leaves open has no ATK. Back on the base, load the + project from the list before you save: the saved values are still in it. + +## Tests and measurements + +Tested on a Model:Cycles; see [TESTING.md](TESTING.md). Code 376 bytes, tables and pictures 3,961 bytes, state 96 +bytes, in the base's shared DDR area. Per track and block it does a few compares and one table read; not measured on the unit. + +## Authorship and licences + +By durchgemacht and Claude, under the GPL-3.0-or-later ([LICENSE](LICENSE)). The base and its hooks are Modwerk's. +`src/gen_table.py` writes `src/attack_table.h`, the step for each value; `src/gen_pictures.py` writes +`src/attack_pictures.h`, the display's 14 envelope pictures (50 x 22, drawn there, no stock pixels). + +## Screens and audio + +Hold MACHINES and turn DECAY: the display shows Amp Attack and, beside the number, the module's envelope picture for the +value, as it does for Amp Decay. + +![Amp Attack at 0: off](media/amp-attack-0.png) +![Amp Attack at 64: about half a second](media/amp-attack-64.png) +![Amp Attack at 127: 3 seconds](media/amp-attack-127.png) diff --git a/sdk/model-cycles/modules/attack/TESTING.md b/sdk/model-cycles/modules/attack/TESTING.md new file mode 100644 index 0000000000..a253d53980 --- /dev/null +++ b/sdk/model-cycles/modules/attack/TESTING.md @@ -0,0 +1,98 @@ +# Attack — test report + +Version 0.1.0-experimental, OS 1.13, on Modwerk's Model:Cycles base 9192a8ce and 50a44d75 (voice hooks and the sound +word, ABI 2 with the knob's pictures; 50a44d75 also reads the tables from the build). + +## Build + +- Package built from this folder's `src/attack.c` with m68k-elf GCC 16.2.0 and binutils 2.47: + `python3 -B sdk/machines/model-cycles/tools/build_sites.py sdk/model-cycles/modules/attack/src/attack.c + --contribute mw_voice_hooks=attack_hook:50 --contribute mw_sound_word=attack_word:50 -o attack.mwrm`. + 4,604 bytes, 2 records, no stock-code site, SHA-256 `140442ee8d558b8e6d5493b7d1626a6486fdac9a47cba7bb9105acf83978d00d` + (`attack.mwrm`; the package carries its file's stem as the module's name). Code 376 bytes, tables and pictures 3,961 + bytes, state 96 bytes. Earlier packages named in the tables below: `fc785e1f…` (before the GATE handling) and older. +- `src/attack_table.h` and `src/attack_pictures.h` are `src/gen_table.py`'s and `src/gen_pictures.py`'s output, + unchanged. +- Test image: stock `model-cycles_OS1.13.syx` (`44fe5862…`) with the base 9192a8ce, patched with the kit-pinned + Elekloader patcher (`--version AT04`): `8673fc0d…`, 1,019,808 bytes. + +## Hardware + +The submitter's Model:Cycles, OS 1.13 with the base flashed, the module loaded on trial over USB +(`mc_link.py try`, then kept for the session), 1 December 2026. The module's code changed between the runs below +only in what the display shows; the rise, the fade and the records are the same. + +| Test | Base | Result | +| --- | --- | --- | +| Without the module: hold MACHINES, turn DECAY | 49e751ef | pass: turns DECAY, as stock | +| With the module: hold MACHINES, turn DECAY, the display, a sustained sound from 0 to 127 | 49e751ef | pass: the display shows ATK, sound swells up to 3 s; 0 plays as stock | +| Retrigger a sounding track with ATK at about 0.55 s, then with ATK 0 | 49e751ef | pass: no click; at 0 as stock | +| ATK locked on one step, LFO on ATK, project saved and loaded | 49e751ef | pass: lock, LFO destination and value come back | +| CC 73 with the module; after a restart without it, CC 73 and MACHINES + DECAY | 49e751ef | pass: CC 73 sets ATK; without the module CC 73 does nothing and MACHINES + DECAY turns DECAY | +| LFO destination list with and without the module | 6723c268 | pass: ATK listed with the module, no extra entry without it | +| The display shows 0 to 127 (an earlier package without pictures, `d09ea04b…`) | 6723c268 | pass | +| This package (`fc785e1f…`) on image AT04: MACHINES + DECAY from 0 to 127 | 9192a8ce | pass: the display shows Amp Attack on two lines; the envelope picture follows the value, its release the same in every picture; the number stays beside it | +| Screenshots of the display at 0, 64 and 127 over USB (`media/`, `capture.json`) | 9192a8ce | the unit's own screenshot replies, unmodified pixels at 6x | +| Image AT09 (`de717f3e…`, the base alone): MACHINES + DECAY, then this package loaded over USB and kept | 50a44d75 | pass: DECAY as stock before; Amp Attack on the display after | +| Image AT08 (`19becb79…`, the module before the GATE handling linked in from its `.elemod`), nothing over USB: MACHINES + DECAY; attack about 90 on a long sound, project saved, power off and on | 50a44d75 | pass: Amp Attack on the display without USB; after the power cycle the sound still swells in and the display still shows it | +| Image AT10 (`46ce0fa2…`, this source linked in): GATE on, attack about 100, medium decay; a short key press, then a long one | 50a44d75 | pass: the short press plays part of the rise and decays from there; the long one rises, holds while the key is down, decays on release | +| Image AT10: GATE off, the same sound, a short key press | 50a44d75 | pass: the rise and the decay play out, as before | +| GATE on, trigs on back-to-back steps (12 to 15), on AT10, on AT08 and on stock 1.13 | 50a44d75 | the same on all three: artefacts on some sounds, as stock 1.13 plays them | +| Image AT13 (`b9a04ff3…`, this package linked in), 2 December 2026: three TONE tracks with attack 0, 60 and 120, GATE off, at the slowest and the fastest tempo; then track 2 turned to 0 while playing | 6ecdd4b9 | pass: each track keeps its own rise; the change reaches track 2 only | +| The same project saved on AT13, then stock 1.13 flashed, the project loaded there and played, nothing saved; AT13 flashed again, 2 December 2026 | 6ecdd4b9 | pass: stock loads it and plays all three tracks without a rise. Back on AT13 the project still open has no attack; loaded from the list it has 0, 60 and 120 again | +| Linked in and loaded over USB at once, 3 December 2026: image MX01 (`9fdd50a5…`, this package linked in beside the author's MAXSAW, a machine not listed yet), then `attack.mwrm` (`140442ee…`) loaded with `mc_link.py try --seconds 20 --keep`; a TONE track, GATE off, attack 60, then 120, then 0, then power off and on | 6ecdd4b9 | pass: kept; the rise at 60 is the same as before the load, 120 is slower and the display shows Amp Attack with its value, 0 starts the notes as stock; the unit starts normally after | + +## Load and memory + +4,433 bytes in the shared DDR area. Per track and 32-frame block: before the machine's update a few compares (and, on a +held trig, two writes); after it one table read and at most four writes to the voice. Not measured on the unit. + +## Not tested + +- Beside another Model:Cycles module: none is listed yet. + +## Source fingerprint, 0.1.0-experimental + +`evidence.sourceSha256` is the sha256 of `sha256sum build.json src/attack.c src/attack_table.h src/attack_pictures.h src/gen_table.py src/gen_pictures.py` (in that order): `0ae6d05215edcc4c2ec1aff7d9d233675339f39ba6710b4d26042708dae7345c`. + +### Test procedure: attack 0.1.0-experimental, 2026-12-01 + +Build: revision `1e44bc3cc320`, package `AT12-base-50a44d75-attack-0.1.0.syx` SHA-256 `5dc25647cf97e81608b6fdd9df1308902c3078f60593eee3bb8b3ae6b7de1735`. `npm run test:procedure -- model-cycles:attack --package ../images/aktuell/attack/AT12-base-50a44d75-attack-0.1.0.syx --no-unit --out /tmp/claude-501/proc-1796154536`, 5 s. Emulator results are not hardware evidence; only what ran on the unit is. + +| # | Step | Layer | Result | Command | Evidence | +|---|---|---|---|---|---| +| 1 | Software checks | host | passed | `npm run module:doctor -- attack` | logs/01-software.log | +| 2 | Beside every other module | contract | not run: modules:compat compares the Octatrack's modules only; Model:Cycles has no gate beside every other module yet: its link refuses two modules on one site, so link the image beside the modules it must work with | | | +| 3 | Name the build | host | passed | | logs/03-build.log | +| 4 | DSP cost model | contract | not run: the DSP cycle scan models the Octatrack's DSP only | | | +| 5 | Emulator rehearsal | emulator | not run: Model:Cycles has no scripted emulator rehearsal yet | | | +| 6 | Read the unit | unit | not run: Model:Cycles has no USB link the procedure drives yet: the machine recipe's next piece (docs/MACHINE_RECIPE.md#where-each-machine-stands) | | | +| 7 | Scripted unit pass | unit | not run: Model:Cycles has no USB link the procedure drives yet: the machine recipe's next piece (docs/MACHINE_RECIPE.md#where-each-machine-stands) | | | +| 8 | Soak | unit | not run: no soak for Model:Cycles yet (scripts/octatrack-soak.mjs drives the Octatrack) | | | +| 9 | Cost on the unit | unit | not run: no price on the unit for Model:Cycles yet (device:price reads the Octatrack's frame interrupt) | | | +| 10 | Put back | unit | not run: Model:Cycles has no USB link the procedure drives yet: the machine recipe's next piece (docs/MACHINE_RECIPE.md#where-each-machine-stands) | | | +| 11 | Agent by hand | unit | done before this build: screenshots of the display at 0, 64 and 127 over USB on base 9192a8ce with package fc785e1f… (`media/`, `capture.json`) | | | +| 12 | Submitter's own stage | unit | done: AT10, the same main OS as this build (`007dda0c…`), and earlier builds; the table below and the Hardware table above, as reported | | | + +This build's main OS is the one of image AT10 (`46ce0fa2…`) byte for byte (`007dda0c…`); only the version field +differs. Modwerk's own image writer does not seal the Model:Cycles OS yet, so the image is linked with the kit-pinned +Elekloader patcher and named with `--package`. + +#### Edge cases + +| Case | Why this change makes it a risk | How run | Result | +|---|---|---|---| +| A retrig on a track that still sounds | the module holds the trig back 2 ms and fades the old note | by ear, attack about 0.55 s, then 0 | pass, as reported (base 49e751ef, the same fade) | +| GATE on: a short and a long note | the module ends the rise when the note ends | AT10, attack about 100, medium decay | pass, as reported | +| GATE off: a short note | must stay stock's: rise and decay play out | AT10 | pass, as reported | +| GATE on, trigs on back-to-back steps | the rise meets the next trig early | AT10, AT08 and stock 1.13 | as stock 1.13 plays them (artefacts on some sounds there too) | +| Saved project, reload and power cycle | the word is saved in record slot 31; the module must come back | AT08 (linked in): attack about 90, saved, power off and on | pass, as reported | +| Without the module | MACHINES + DECAY and CC 73 must stay stock's | AT09, and base 49e751ef after a restart | pass, as reported | +| Over USB on the base alone | the loader's row as well as the build's | AT09 + package fc785e1f…, kept | pass, as reported | +| A sound with attack above 0 under stock 1.13 and back | stock reads k 31 nowhere | AT13, stock 1.13, AT13, nothing saved in between | pass, as reported: no rise on stock; back on the base the values return once the project is loaded from the list | +| Linked in and loaded over USB at once | both copies' hooks run | MX01 + `attack.mwrm` (`140442ee…`) kept; attack 60, 120, 0 | pass, as reported: plays as with one copy. From the code: the linked copy runs first and holds the trig back; the other sees it once the track is silent | +| Different values on several tracks at once, slowest and fastest tempo | per-track state (`trk[6]`) | AT13, three tracks with 0, 60 and 120 | pass, as reported | + +For the pull request: +Tested on a unit: the source of this build (image AT10, same main OS) on the author's Model:Cycles, OS 1.13, as reported; the procedure's unit steps are not run: Model:Cycles has no USB link the procedure drives yet. +Edge cases: the table above. diff --git a/sdk/model-cycles/modules/attack/build.json b/sdk/model-cycles/modules/attack/build.json new file mode 100644 index 0000000000..ec734fbd61 --- /dev/null +++ b/sdk/model-cycles/modules/attack/build.json @@ -0,0 +1,51 @@ +{ + "schemaVersion": 1, + "sources": [ + "src/attack.c" + ], + "defsym": {}, + "cflags": [], + "weak": [], + "subscribe": [], + "contribute": [ + { + "to": "mw_voice_hooks", + "order": 50, + "data": "00000000", + "relocs": [ + [ + 0, + "abs32", + "sym:attack_hook", + 0 + ] + ] + }, + { + "to": "mw_sound_word", + "order": 50, + "data": "00000000", + "relocs": [ + [ + 0, + "abs32", + "sym:attack_word", + 0 + ] + ] + } + ], + "collections": {}, + "copied": [], + "regions": [], + "claims": [], + "requires": [], + "derive": null, + "releases": { + "1.13": { + "defsym": {}, + "cflags": [], + "sites": [] + } + } +} diff --git a/sdk/model-cycles/modules/attack/media/LICENSE.md b/sdk/model-cycles/modules/attack/media/LICENSE.md new file mode 100644 index 0000000000..bbf4ceef59 --- /dev/null +++ b/sdk/model-cycles/modules/attack/media/LICENSE.md @@ -0,0 +1,7 @@ +# Model:Cycles UI documentation captures + +The Modwerk contributor dedicates their original capture contribution to the public domain under CC0-1.0. This declaration covers the act of capture and accompanying original captions, not the depicted firmware interface. + +Elektron retains rights in its underlying interface and firmware. The module's own pictures (the envelope drawn by `src/gen_pictures.py`) retain the module's terms in [../LICENSE](../LICENSE). No firmware, extracted stock code, raw memory/framebuffer data or audio samples are included. The images are unmodified screen pixels at integer scale. + +Manifest identifier: `LicenseRef-Model-Cycles-UI-Documentation`. Capture identity and inputs: [capture.json](capture.json). diff --git a/sdk/model-cycles/modules/attack/media/amp-attack-0.png b/sdk/model-cycles/modules/attack/media/amp-attack-0.png new file mode 100644 index 0000000000000000000000000000000000000000..2ceb99d04b618ab09aabd59b8d6a2fde04c5a70a GIT binary patch literal 1699 zcmeAS@N?(olHy`uVBq!ia0y~yUrm>{)qnWg#6Rq1~PYSk{BzxpCPc=wb|@*vG9z(T0Ou$7U4k)eTs z!GVE6fq_AQVJoAA7Y~qT0NTaEz`z8w7FilBeBd1ej}jX`6*x4a3%}rJVVJpkix`Tl zz?=uSFWR>seCNFX_byDyhB*vT(wA?ox@K6}a8>&6-Y|AdH8rNc{@#E8@6!DfJUpxV z{^?}{J%bLk7%R%k8Q$3$qe}q!4k;WAC+vUyHo_ve?=OQ@_JZHipWnU!#R~>75O>IC z{#4Jzh9LtKNVxV9n=tvIiE7#g<%WNcuFL;FHUk)S7+?<1ga4`h{Gfz|3BEGisr@=} z?X0ba<%~AY*tAcOcc^FCT+6oC`r709<;v%=dhkFsL)zWiYr$6&HawPM#IUB}$FsHU z2K!ci+o4{{mSUKg?4x4-i5N7uI=dl&)Cu*rR66}Xwk@XW~Krw*ocf^EajaCr8|l?*kQ8IX;}5e5OO3=&Wq8W2Sax|vfM z5(4s`?(HoFA_tGv7=_zoYHG+l92?V%myh2zvK<4U%3Cnnui?P z7WUh7VrmQEKXBsthVAW-w+DnTO#8bWOU8M^sKAf~Dx~lfys#vNJ8T(Jm_NLiZ_fC_ zh$D)i!VbI)5)!pwha$@NbBqkl3*lucG(QAvvG?Scf3s)F8aI$~Pgg&ebxsLQ0NE%N A!vFvP literal 0 HcmV?d00001 diff --git a/sdk/model-cycles/modules/attack/media/amp-attack-127.png b/sdk/model-cycles/modules/attack/media/amp-attack-127.png new file mode 100644 index 0000000000000000000000000000000000000000..f2be4433c914472dbd71cc121a4e3cd510e0b5dc GIT binary patch literal 1852 zcmeAS@N?(olHy`uVBq!ia0y~yUiakg-3Mf!vNakW@U;>)W z(7?dpz`&ruki~2;MFL1O2rw`J?PFm;l?Dqp++~z-;lZZ@hemYa4>ke}Tc+0k{n1ri zE`;JVFlUDKujd9QB+p)SzQ64q*KbZt6>B&j(d*Jg9 z_kZVS^B?`jYEU(GPCC$67~lo#g50lD8GGVVk8FJQ;{3l`>)0^VFsw0VVK~CiYuwI* zDaWuN_lFX5?EB;$k?m_Yvz2@?)W%d4z)?1?* zObK9QB-}ZkwRk^YS?*xQt<|Es8LAN7T)8(dzlxoHDnhci9(qN;u!YX6{Iv*)A7BxZ81$h@B&NBF)$Pydhy%-28IKci|xA`1%V-g6yyP_47ujp zKMCq$)4}k&ug~)z2%+vR6)Su zqK@+K_=VFaIPym;0yj!yL%jUC(ON|_UR&xE#%IJ6c1~LN`gfkf|Ghk3)U=Uzn z0GiFhz`*n%hoMb~8O#LQ$k4#R;J|>Y0w_E|w!!fTZfP94un2!`WJpNeeN8OU9MxeU zUc=tS_595l&im8m7Jg&Fl<(kNux0Afv%0lvd>ei&wlCXy5u2(TroX<<-~ZS1^!&KH z%nFBQF=86T@Qm@tw=dNUJ-_~F)L}{=xXBP@#@ArFIR1V;rYu84Ap3&FY`gw3ee0_e zWB5Fe4~rTDF^A0P$MTHlr4LSZX2YUjgOI}+C59Q>x1FeF!jyi&#*lsO=UZ`kOevtq zZiYRvx#vG(2|=J_HRG1`JD)~@;u9ULVYy&@#P&Rs1G+>C%ZG0}a=$%K?|E6tkQOsL zI~`pGFmmz_U);yaFo#{?@jpyihGfP)wV}4_%Z?Ss{hnWmEzIYzFR*L6*ynh^uk`oF zyz{sGm<*;JoHZAV(sOJEuU;+=6P*#rN z7o$TQ+vf5I&sJl4ts$1-noQ1J&IKjge+5^qtNPs=whrhlbZ~?9L8Jt_Aee8?aN;O7 zi3dCk$?jqe+wcFvYHbF?qPv#*XhlheZNp9XX|OT}7ABDlDV3ly4->rRcVI*d!*5Ix zmcP;s44P2G#Y)uSp8XyyQNh5FaGf!ujO}|*)S35KGHHs89m77}r*8~(@2VfdBG0gs z&*8IC2Xn%)8QWrZmt)C`4SSf`4{VS3H10FPOvVky3@+9TXHO{bHT+t&Z|%4LtE1|$ zWc4GA0+nAFXSk;x3&jithcbr9W84k%7~lSk$COntYWTsvfT2g~SD>~I4nN$FyPbbx zld$dL8TVx|O%Px(2PJoCO#q7()bItm8CR{q&;Y6|T$n$+mv7Gaf*xOJ70Cff1_Og% pU^gI)yu-}E=FAUs7_3IR@Q-0-e@6Gc4yS`4DNk2Fmvv4FO#t7}QS<-+ literal 0 HcmV?d00001 diff --git a/sdk/model-cycles/modules/attack/media/capture.json b/sdk/model-cycles/modules/attack/media/capture.json new file mode 100644 index 0000000000..1351b5a8f7 --- /dev/null +++ b/sdk/model-cycles/modules/attack/media/capture.json @@ -0,0 +1,37 @@ +{ + "schemaVersion": 1, + "machine": "model-cycles", + "moduleId": "attack", + "moduleVersion": "0.1.0-experimental", + "firmware": "1.13", + "capturedAt": "2026-12-01T17:05:00Z", + "imageSha256": "8673fc0d96f913d2aab0009e47a505a2735acbd64ccd7f44bf2ca5f46e508bf2", + "stockSha256": "44fe586269631a0ca7da25a3383fc6733c314809505fc3cc52f1e0ed9800640c", + "packageSha256": "fc785e1ff10de9cfe344f36b34288e74330353c3ba315af91378746e3960695d", + "build": "elekloader patch: the owner's stock OS 1.13 + modwerk-base-model-cycles-9192a8ce.elemod (npm run machine:base -- model-cycles), --version AT04. The module is not in the image: it is a runtime package (build_sites.py, mw_voice_hooks and mw_sound_word), loaded over USB and kept.", + "hardware": { + "device": "Model:Cycles", + "source": "the unit's answer to Elektron's screenshot request over USB MIDI (F0 00 20 3C 10 00 ... cmd 0x04), decoded column by column; on the Model:Cycles a set bit is a dark pixel" + }, + "conditions": "Each frame was requested over USB while the display showed Amp Attack: hold MACHINES, turn DECAY; the raw replies are kept by the submitter.", + "captures": [ + { + "path": "media/amp-attack-0.png", + "frame": "attack0.syx", + "plan": "hold MACHINES, turn DECAY down to 0", + "sha256": "c1de947ff3d29e7fb7b8b2d460a848ed351dbf76c1aaa30121ac24a40a12969b" + }, + { + "path": "media/amp-attack-64.png", + "frame": "attack64.syx", + "plan": "hold MACHINES, turn DECAY to 64", + "sha256": "656dd5c3b3577ec1f08ab65a30937d3438734643cffd460e8b69f3941a10ea6e" + }, + { + "path": "media/amp-attack-127.png", + "frame": "attack127.syx", + "plan": "hold MACHINES, turn DECAY up to 127", + "sha256": "d9b5aa4dc4a850e08d20d1589ea8e11cf1a8c94e9af728ae5d67e342dc82e539" + } + ] +} diff --git a/sdk/model-cycles/modules/attack/media/thumbnail.svg b/sdk/model-cycles/modules/attack/media/thumbnail.svg new file mode 100644 index 0000000000..d478af33d7 --- /dev/null +++ b/sdk/model-cycles/modules/attack/media/thumbnail.svg @@ -0,0 +1,11 @@ + +ATTACK +Two amp envelopes: a ghosted one that jumps up at once and decays, and a bright one that rises over a set time before the same decay. Original conceptual illustration, not an instrument screen or a measured result. + + + + + + +ATTACKATKDEC + diff --git a/sdk/model-cycles/modules/attack/modwerk.module.json b/sdk/model-cycles/modules/attack/modwerk.module.json new file mode 100644 index 0000000000..cc9dc57ceb --- /dev/null +++ b/sdk/model-cycles/modules/attack/modwerk.module.json @@ -0,0 +1,188 @@ +{ + "schemaVersion": 3, + "id": "attack", + "name": "Attack", + "version": "0.1.0-experimental", + "machine": "model-cycles", + "category": "playback", + "exclusive": false, + "author": { + "github": "durchgemacht", + "credits": [ + "durchgemacht" + ] + }, + "maintainers": [ + "durchgemacht" + ], + "presentation": { + "label": "ATTACK", + "family": "Envelope", + "summary": "Adds Attack to every track, up to 3 seconds. Hold MACHINES and turn DECAY.", + "overview": "The Model:Cycles has a decay but no attack. This module adds Attack to every track, with any machine. Hold MACHINES and turn DECAY to set it from 0 to 127, up to 3 seconds. At 0 it is off. Attack works with parameter locks, the LFO, velocity, Control All and MIDI CC 73, and it is saved with the sound. With GATE on, a note that ends before the attack is finished goes straight into its decay.", + "highlights": [ + "Attack up to 3 seconds on every track, with any machine", + "Hold MACHINES and turn DECAY, or use MIDI CC 73", + "Works with parameter locks, LFO, velocity and Control All", + "With GATE on, short notes go straight into their decay" + ], + "usage": [ + "Pick a track with a long sound, for example TONE with a long DECAY.", + "Hold MACHINES and turn DECAY to about 90. The notes now fade in slowly.", + "Turn it back to 0 to switch Attack off." + ] + }, + "access": { + "location": "MACHINES + DECAY on any track", + "steps": [ + "Hold MACHINES and turn DECAY to set Attack from 0 to 127.", + "At 0 it is off." + ], + "screenshots": [ + "media/amp-attack-0.png", + "media/amp-attack-64.png" + ] + }, + "controls": [ + { + "name": "ATK", + "default": 0, + "doc": "Attack time, 0 to 127, up to 3 seconds. 0 is off. Works with parameter locks, LFO, velocity and MIDI CC 73.", + "labels": null + } + ], + "compatibility": { + "releases": [ + "1.13" + ], + "requires": [], + "conflicts": [], + "limitations": [ + "Built for OS 1.13 only, on Modwerk's Model:Cycles base with voice hooks and the sound word, ABI 2, each table read from the build (base 50a44d75 or later).", + "It owns the sound word: only one module that does can be installed.", + "With attack above 0, a trig on a track that still sounds starts its note 2 ms later, while the old note fades out.", + "Without the module the saved value stays in the sound and plays nothing; MACHINES + DECAY turns DECAY.", + "Stock 1.13 plays such a project without the rise, and the state it leaves open has no ATK: back on the base, load the project from the list before you save." + ] + }, + "platform": { + "kind": "elemod", + "core": "0.3", + "build": "build.json", + "events": [], + "claims": [] + }, + "resources": { + "memoryBytes": 4433, + "fastBytes": 0, + "load": { + "display": "Small: a few compares and one table read per track and block", + "method": "static", + "conditions": "Static: per track and 32-frame block, before and after the machine's update, a few compares, one table read and at most four writes to the voice. Not a measurement." + } + }, + "evidence": { + "tier": "author-hardware", + "moduleVersion": "0.1.0-experimental", + "sourceSha256": "0ae6d05215edcc4c2ec1aff7d9d233675339f39ba6710b4d26042708dae7345c", + "reports": [ + "TESTING.md" + ], + "hardware": { + "model": "Model:Cycles", + "release": "1.13", + "testedOn": "2026-12-01", + "tester": "durchgemacht", + "durationMinutes": null, + "summary": "0.1.0-experimental on the author's Model:Cycles, OS 1.13, 1 December 2026. This source linked into image AT10 (sha256 46ce0fa2…, Modwerk's base 50a44d75): with GATE on a short note decays from where its rise got to and a long one holds; GATE off plays out. The source before the GATE handling, linked into AT08: Amp Attack on the display with the envelope for each value, and the attack still there after a saved project and a power cycle; loaded over USB (fc785e1f…) on the base alone: the same display. Earlier packages with the same rise and fade: sounds swell up to 3 s, 0 plays as stock, retriggers do not click, p-locks, LFO, CC 73 and saving work.", + "limitations": [ + "The load on the unit is not measured." + ] + }, + "verifiedBy": null + }, + "tests": { + "report": "TESTING.md", + "summary": "On the submitter's Model:Cycles (OS 1.13, base 50a44d75): linked into the image, Amp Attack on the display and the attack stay through a power cycle; with GATE on a short note decays from where its rise got to; sounds swell up to 3 s, 0 plays as stock, retriggers do not click, p-locks, LFO, CC 73 and saving work.", + "documentation": { + "tutorial": { + "title": "Quick tutorial", + "steps": [ + "Pick a track with a long sound, for example TONE with a long DECAY.", + "Hold MACHINES and turn DECAY to about 90. The notes now fade in slowly.", + "Turn it back to 0 to switch Attack off." + ] + }, + "screenshots": [ + "media/amp-attack-0.png", + "media/amp-attack-64.png", + "media/amp-attack-127.png" + ], + "captureRecord": "media/capture.json" + } + }, + "license": { + "spdx": "GPL-3.0-or-later", + "file": "LICENSE", + "declaration": "Original work by durchgemacht and Claude, the display's envelope pictures included (drawn by src/gen_pictures.py). It reads and writes the OS 1.13 voice through the offsets the base's voice hooks document; it patches no stock code." + }, + "media": [ + { + "path": "media/thumbnail.svg", + "kind": "thumbnail", + "caption": "Attack: a note swells in over a set rise time instead of starting at once", + "alt": "A stock envelope that jumps up at once, beside one that rises slowly before it decays, labelled ATK", + "credit": "durchgemacht", + "license": "GPL-3.0-or-later", + "source": "Original conceptual illustration in the shared signal-art style." + }, + { + "path": "media/amp-attack-0.png", + "kind": "screenshot", + "caption": "Hold MACHINES and turn DECAY. At 0, Attack is off.", + "alt": "Display: Amp Attack, an envelope with an upright rise, the value 0", + "credit": "durchgemacht capture; Elektron interface", + "license": "LicenseRef-Model-Cycles-UI-Documentation", + "source": "original", + "capture": { + "type": "hardware", + "release": "1.13", + "moduleVersion": "0.1.0-experimental", + "imageSha256": "8673fc0d96f913d2aab0009e47a505a2735acbd64ccd7f44bf2ca5f46e508bf2", + "setup": "The submitter's Model:Cycles on OS 1.13 with Modwerk's Model:Cycles base 9192a8ce flashed (image AT04), and this folder's Attack 0.1.0-experimental loaded over USB and kept (package fc785e1f..., mc_link.py try --keep). The unit's own screenshot reply over USB, 128x64, unmodified pixels at 6x in two grays." + } + }, + { + "path": "media/amp-attack-64.png", + "kind": "screenshot", + "caption": "At 64, the attack takes about half a second.", + "alt": "Display: Amp Attack, an envelope with a slanted rise, the value 64", + "credit": "durchgemacht capture; Elektron interface", + "license": "LicenseRef-Model-Cycles-UI-Documentation", + "source": "original", + "capture": { + "type": "hardware", + "release": "1.13", + "moduleVersion": "0.1.0-experimental", + "imageSha256": "8673fc0d96f913d2aab0009e47a505a2735acbd64ccd7f44bf2ca5f46e508bf2", + "setup": "The submitter's Model:Cycles on OS 1.13 with Modwerk's Model:Cycles base 9192a8ce flashed (image AT04), and this folder's Attack 0.1.0-experimental loaded over USB and kept (package fc785e1f..., mc_link.py try --keep). The unit's own screenshot reply over USB, 128x64, unmodified pixels at 6x in two grays." + } + }, + { + "path": "media/amp-attack-127.png", + "kind": "screenshot", + "caption": "At 127, it takes 3 seconds.", + "alt": "Display: Amp Attack, an envelope with a long shallow rise, the value 127", + "credit": "durchgemacht capture; Elektron interface", + "license": "LicenseRef-Model-Cycles-UI-Documentation", + "source": "original", + "capture": { + "type": "hardware", + "release": "1.13", + "moduleVersion": "0.1.0-experimental", + "imageSha256": "8673fc0d96f913d2aab0009e47a505a2735acbd64ccd7f44bf2ca5f46e508bf2", + "setup": "The submitter's Model:Cycles on OS 1.13 with Modwerk's Model:Cycles base 9192a8ce flashed (image AT04), and this folder's Attack 0.1.0-experimental loaded over USB and kept (package fc785e1f..., mc_link.py try --keep). The unit's own screenshot reply over USB, 128x64, unmodified pixels at 6x in two grays." + } + } + ] +} diff --git a/sdk/model-cycles/modules/attack/src/attack.c b/sdk/model-cycles/modules/attack/src/attack.c new file mode 100644 index 0000000000..3939abaa87 --- /dev/null +++ b/sdk/model-cycles/modules/attack/src/attack.c @@ -0,0 +1,107 @@ +/* SPDX-License-Identifier: GPL-3.0-or-later + * Attack for the Model:Cycles base (include/mc/voice.h): a rise time for every track's sound, whatever its machine. + * MACHINES held + DECAY turns it (also p-locks, LFO, velocity, Control All, CC 73); the popup reads "Amp Attack" and + * shows a picture for the value, as Amp Decay's (gen_pictures.py). 0 leaves the machine's own rise and every trig as + * stock plays it. Up to 3 s; the knob's curve has the shape of the stock DECAY's, each value its own + * time (gen_table.py). + * + * python3 -B /sdk/machines/model-cycles/tools/build_sites.py attack.c \ + * --contribute mw_voice_hooks=attack_hook:50 --contribute mw_sound_word=attack_word:50 -o attack.mwrm + * + * The voice (OS 1.13): +0x34 a trig this block, +0x38 a trig the block before (the voice loop copies +0x34 there after + * the render; the machine starts its note and the envelope its attack on +0x38), +0x230 the envelope's level (0 silent, + * 0x80000000 full: it runs negative), +0x234 the level the VCA ramps from, +0x23c its stage (0 attack, 1 decay, 2 hold), + * +0x244 the note's end seen, +0x248 the attack's step a block (each machine sets it as it likes: TONE never, KICK at + * once, PERC and SNARE their own), +0x24c GATE on (the envelope holds at the top while the note lasts). + * + * The rise: after the machine's update the step at +0x248 is ours while the word is above 0, and the machine's again + * when it returns to 0. + * GATE: stock's envelope notes the note's end in every stage but reads it only once the attack is at the top, so with + * GATE on a short note still plays the whole rise and then the decay. While the word is above 0 and GATE is on, a note + * that ends during the rise turns the envelope to its decay at once, from the level it reached. GATE off stays stock's: + * the rise and the decay always play out. + * A trig on a track that still sounds: stock's VCA pulls the old note to 0 in the trig's block (0.67 ms) and the next + * block starts at 0, a click that a slow attack lays bare. While the word is above 0 the trig is held back FADE blocks: + * `before` hides it from the machine and the VCA, the old note plays on and the envelope, held, falls to 0 on an S + * curve; then the trig is given back and plays as stock's, from silence. The note starts FADE blocks later. */ +#include +#include "../../../../machines/model-cycles/include/mc/voice.h" +#include "attack_table.h" +#include "attack_pictures.h" + +#define FADE 3 /* blocks of 32 frames: 2.0 ms */ +#define AUDIBLE 0x0020c49bu /* |level| above -60 dB (2^31 / 1000): the old note sounds */ +#define TRIG 0x34 +#define LEVEL 0x230 +#define STAGE 0x23c +#define END_SEEN 0x244 +#define STEP_AT 0x248 +#define GATE_ON 0x24c +#define V32(v, o) (*(volatile int32_t *)((v) + (o))) + +/* 1 - (3x^2 - 2x^3) at x = 1/3, 2/3, 1: the share of the old level at the end of each fade block, Q15 */ +static const int16_t FALL[FADE] = { 24272, 8496, 0 }; + +static struct { uint32_t machine, ours; int32_t from; uint8_t set, fading, held; } trk[6]; + +static void attack_before(uint32_t t, char *voice, const char *params) +{ + int32_t level; + if (t >= 6) + return; + if (trk[t].held) { /* the fade is over: the trig plays now, as stock's */ + trk[t].held = 0; + V32(voice, TRIG) = 1; + return; + } + if (trk[t].fading) { /* a trig during the fade joins the one held back */ + V32(voice, TRIG) = 0; + return; + } + if (!V32(voice, TRIG) || mw_sound_word_of(params) <= 0) + return; + level = V32(voice, LEVEL); + if ((uint32_t)(level < 0 ? -level : level) <= AUDIBLE) + return; /* silent: no click to hide, no delay */ + V32(voice, TRIG) = 0; + trk[t].from = level; + trk[t].fading = FADE; +} + +static void attack_updated(uint32_t t, char *voice, const char *params) +{ + volatile uint32_t *step = (volatile uint32_t *)(voice + STEP_AT); + int32_t v = mw_sound_word_of(params); + if (t >= 6) + return; + if (v > 0) { + uint32_t ours = ATTACK_STEP[v > 127 ? 127 : v]; + if (!trk[t].set || *step != trk[t].ours) + trk[t].machine = *step; /* the machine's own, or its newest */ + *step = ours; + trk[t].ours = ours; + trk[t].set = 1; + if (!trk[t].fading && V32(voice, GATE_ON) && V32(voice, STAGE) == 0 && V32(voice, END_SEEN)) { + V32(voice, STAGE) = 1; /* the note ended during the rise: decay from here */ + V32(voice, END_SEEN) = 0; + } + } else if (trk[t].set) { + if (*step == trk[t].ours) + *step = trk[t].machine; + trk[t].set = 0; + } + if (trk[t].fading) { /* held: the VCA ramps to this block's share of the old level */ + unsigned i = FADE - trk[t].fading; + V32(voice, STAGE) = 2; + V32(voice, END_SEEN) = 0; + V32(voice, LEVEL) = (trk[t].from >> 15) * FALL[i]; /* no 64-bit product: |from >> 15| <= 65536 */ + if (--trk[t].fading == 0) + trk[t].held = 1; + } +} + +const struct mw_voice_hook attack_hook = { MW_VOICE_HOOK_ABI, { 0 }, attack_before, attack_updated }; +/* "Amp Attack" on two lines, as stock's "Amp Decay"; the base shows the value 0 .. 127 and the picture for it + * (gen_pictures.py). */ +const struct mw_sound_word attack_word = { MW_SOUND_WORD_ABI, 0, 127, "Amp Attack", "ATK", 0, ATTACK_PICTURES, + ATTACK_FRAMES, { 0 } }; diff --git a/sdk/model-cycles/modules/attack/src/attack_pictures.h b/sdk/model-cycles/modules/attack/src/attack_pictures.h new file mode 100644 index 0000000000..27835499b6 --- /dev/null +++ b/sdk/model-cycles/modules/attack/src/attack_pictures.h @@ -0,0 +1,185 @@ +/* Generated by gen_pictures.py: do not edit. */ +#define ATTACK_FRAMES 14 +static const uint32_t ATTACK_MASK[50] = { + 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, + 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, + 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, + 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, + 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, + 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, + 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, + 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, + 0xfffffc00u, 0xfffffc00u, +}; +static const uint32_t ATTACK_PIXELS[14][50] = { + { + 0x00000000u, 0x7ffff800u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, 0xfffffc00u, + 0x7ffffc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0001fc00u, 0x0001fc00u, + 0x0007f800u, 0x001ff800u, 0x007ff000u, 0x01ffe000u, 0x07ff8000u, 0x1ffe0000u, + 0x7ff80000u, 0xffe00000u, 0xff800000u, 0xfe000000u, 0xf8000000u, 0x60000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0x7c000000u, 0xffff0000u, 0xfffff800u, 0xfffffc00u, 0xfffffc00u, + 0x7ffffc00u, 0x03fffc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0001fc00u, 0x0001fc00u, 0x0007f800u, 0x001ff800u, 0x007ff000u, 0x01ffe000u, + 0x07ff8000u, 0x1ffe0000u, 0x7ff80000u, 0xffe00000u, 0xff800000u, 0xfe000000u, + 0xf8000000u, 0x60000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0x60000000u, 0xff800000u, 0xfffc0000u, 0xffffe000u, 0xfffff800u, + 0x7ffffc00u, 0x1ffffc00u, 0x00fffc00u, 0x0007fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0001fc00u, 0x0001fc00u, 0x0007f800u, 0x001ff800u, + 0x007ff000u, 0x01ffe000u, 0x07ff8000u, 0x1ffe0000u, 0x7ff80000u, 0xffe00000u, + 0xff800000u, 0xfe000000u, 0xf8000000u, 0x60000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0x60000000u, 0xfc000000u, 0xffc00000u, 0xfff80000u, 0xffff8000u, + 0x7ffff000u, 0x3ffff800u, 0x07fffc00u, 0x007ffc00u, 0x000ffc00u, 0x0000fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0001fc00u, 0x0001fc00u, + 0x0007f800u, 0x001ff800u, 0x007ff000u, 0x01ffe000u, 0x07ff8000u, 0x1ffe0000u, + 0x7ff80000u, 0xffe00000u, 0xff800000u, 0xfe000000u, 0xf8000000u, 0x60000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0x40000000u, 0xf8000000u, 0xfe000000u, 0xffc00000u, 0xfff80000u, + 0x7ffe0000u, 0x7fffc000u, 0x0ffff800u, 0x01fff800u, 0x007ffc00u, 0x000ffc00u, + 0x0001fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0001fc00u, 0x0001fc00u, 0x0007f800u, 0x001ff800u, 0x007ff000u, 0x01ffe000u, + 0x07ff8000u, 0x1ffe0000u, 0x7ff80000u, 0xffe00000u, 0xff800000u, 0xfe000000u, + 0xf8000000u, 0x60000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0x40000000u, 0xf0000000u, 0xfc000000u, 0xff000000u, 0xffc00000u, + 0x7ff80000u, 0x7ffe0000u, 0x1fff8000u, 0x07ffe000u, 0x01fff800u, 0x007ff800u, + 0x000ffc00u, 0x0003fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0001fc00u, 0x0001fc00u, 0x0007f800u, 0x001ff800u, + 0x007ff000u, 0x01ffe000u, 0x07ff8000u, 0x1ffe0000u, 0x7ff80000u, 0xffe00000u, + 0xff800000u, 0xfe000000u, 0xf8000000u, 0x60000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0x40000000u, 0xf0000000u, 0xf8000000u, 0xfe000000u, 0xff800000u, + 0x7fe00000u, 0x7ff00000u, 0x1ffc0000u, 0x0fff0000u, 0x03ffc000u, 0x00ffe000u, + 0x003ff800u, 0x001ff800u, 0x0007fc00u, 0x0001fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0001fc00u, 0x0001fc00u, + 0x0007f800u, 0x001ff800u, 0x007ff000u, 0x01ffe000u, 0x07ff8000u, 0x1ffe0000u, + 0x7ff80000u, 0xffe00000u, 0xff800000u, 0xfe000000u, 0xf8000000u, 0x60000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0x40000000u, 0xf0000000u, 0xf8000000u, 0xfe000000u, 0xff000000u, + 0x7fc00000u, 0x7ff00000u, 0x3ff80000u, 0x0ffe0000u, 0x03ff0000u, 0x01ffc000u, + 0x007ff000u, 0x003ff800u, 0x000ff800u, 0x0003fc00u, 0x0001fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0001fc00u, + 0x0001fc00u, 0x0007f800u, 0x001ff800u, 0x007ff000u, 0x01ffe000u, 0x07ff8000u, + 0x1ffe0000u, 0x7ff80000u, 0xffe00000u, 0xff800000u, 0xfe000000u, 0xf8000000u, + 0x60000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0x40000000u, 0xe0000000u, 0xf8000000u, 0xfc000000u, 0xfe000000u, + 0x7f800000u, 0x7fc00000u, 0x3ff00000u, 0x1ff80000u, 0x07fc0000u, 0x03ff0000u, + 0x00ff8000u, 0x007fe000u, 0x003ff000u, 0x000ff800u, 0x0007f800u, 0x0001fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0001fc00u, 0x0001fc00u, 0x0007f800u, 0x001ff800u, 0x007ff000u, + 0x01ffe000u, 0x07ff8000u, 0x1ffe0000u, 0x7ff80000u, 0xffe00000u, 0xff800000u, + 0xfe000000u, 0xf8000000u, 0x60000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0xc0000000u, 0xe0000000u, 0xf0000000u, 0xfc000000u, 0xfe000000u, + 0xff000000u, 0x7f800000u, 0x3fe00000u, 0x1ff00000u, 0x0ff80000u, 0x07fc0000u, + 0x01fe0000u, 0x00ff8000u, 0x007fc000u, 0x003fe000u, 0x001ff000u, 0x0007f800u, + 0x0003fc00u, 0x0001fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0001fc00u, 0x0001fc00u, 0x0007f800u, + 0x001ff800u, 0x007ff000u, 0x01ffe000u, 0x07ff8000u, 0x1ffe0000u, 0x7ff80000u, + 0xffe00000u, 0xff800000u, 0xfe000000u, 0xf8000000u, 0x60000000u, 0x00000000u, + 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0xc0000000u, 0xe0000000u, 0xf0000000u, 0xf8000000u, 0xfc000000u, + 0xfe000000u, 0x7f800000u, 0x7fc00000u, 0x3fe00000u, 0x0ff00000u, 0x07f80000u, + 0x03fc0000u, 0x01fe0000u, 0x00ff0000u, 0x007f8000u, 0x003fc000u, 0x001ff000u, + 0x000ff800u, 0x0007f800u, 0x0001fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0001fc00u, + 0x0001fc00u, 0x0007f800u, 0x001ff800u, 0x007ff000u, 0x01ffe000u, 0x07ff8000u, + 0x1ffe0000u, 0x7ff80000u, 0xffe00000u, 0xff800000u, 0xfe000000u, 0xf8000000u, + 0x60000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0xc0000000u, 0xe0000000u, 0xf0000000u, 0xf8000000u, 0xfc000000u, + 0xfe000000u, 0x7f000000u, 0x7f800000u, 0x3fc00000u, 0x1fe00000u, 0x0ff00000u, + 0x07f80000u, 0x03fc0000u, 0x01fe0000u, 0x00ff0000u, 0x007f8000u, 0x003fc000u, + 0x001fe000u, 0x000ff000u, 0x0007f800u, 0x0003f800u, 0x0001fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0001fc00u, 0x0001fc00u, 0x0007f800u, 0x001ff800u, 0x007ff000u, + 0x01ffe000u, 0x07ff8000u, 0x1ffe0000u, 0x7ff80000u, 0xffe00000u, 0xff800000u, + 0xfe000000u, 0xf8000000u, 0x60000000u, 0x00000000u, 0x00000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0xc0000000u, 0xe0000000u, 0xf0000000u, 0xf8000000u, 0xfc000000u, + 0xfc000000u, 0x7e000000u, 0x7f000000u, 0x3f800000u, 0x1fc00000u, 0x0fe00000u, + 0x07f00000u, 0x07f80000u, 0x03fc0000u, 0x01fe0000u, 0x00ff0000u, 0x007f8000u, + 0x003f8000u, 0x001fc000u, 0x000fe000u, 0x0007f000u, 0x0003f800u, 0x0001f800u, + 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0001fc00u, 0x0001fc00u, 0x0007f800u, + 0x001ff800u, 0x007ff000u, 0x01ffe000u, 0x07ff8000u, 0x1ffe0000u, 0x7ff80000u, + 0xffe00000u, 0xff800000u, 0xfe000000u, 0xf8000000u, 0x60000000u, 0x00000000u, + 0x00000000u, 0x00000000u, + }, + { + 0x00000000u, 0xc0000000u, 0xe0000000u, 0xf0000000u, 0xf0000000u, 0xf8000000u, + 0xfc000000u, 0x7e000000u, 0x7f000000u, 0x3f800000u, 0x3fc00000u, 0x1fc00000u, + 0x0fe00000u, 0x07f00000u, 0x03f80000u, 0x01fc0000u, 0x01fe0000u, 0x00fe0000u, + 0x007f0000u, 0x003f8000u, 0x001fc000u, 0x000fe000u, 0x000ff000u, 0x0007f000u, + 0x0003f800u, 0x0001f800u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, + 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0000fc00u, 0x0001fc00u, + 0x0001fc00u, 0x0007f800u, 0x001ff800u, 0x007ff000u, 0x01ffe000u, 0x07ff8000u, + 0x1ffe0000u, 0x7ff80000u, 0xffe00000u, 0xff800000u, 0xfe000000u, 0xf8000000u, + 0x60000000u, 0x00000000u, + }, +}; +static const struct mw_bitmap ATTACK_PICTURES[14] = { + { 0, 50, 22, 1, ATTACK_PIXELS[0], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[1], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[2], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[3], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[4], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[5], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[6], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[7], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[8], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[9], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[10], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[11], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[12], ATTACK_MASK, 0 }, + { 0, 50, 22, 1, ATTACK_PIXELS[13], ATTACK_MASK, 0 }, +}; diff --git a/sdk/model-cycles/modules/attack/src/attack_table.h b/sdk/model-cycles/modules/attack/src/attack_table.h new file mode 100644 index 0000000000..81000e277f --- /dev/null +++ b/sdk/model-cycles/modules/attack/src/attack_table.h @@ -0,0 +1,25 @@ +/* Generated by gen_table.py: do not edit. */ +static const uint32_t ATTACK_STEP[128] = { + 0x00000000u, 0x80000001u, 0xc0000000u, 0xd5555555u, 0xe0000000u, 0xe6666666u, + 0xeaaaaaabu, 0xedb6db6eu, 0xf0000000u, 0xf1c71c72u, 0xf3333333u, 0xf45d1746u, + 0xf657f693u, 0xf8136b0du, 0xf966bd93u, 0xfa6f6b38u, 0xfb4155f3u, 0xfbea4287u, + 0xfc73f354u, 0xfce577e4u, 0xfd4403edu, 0xfd937ca6u, 0xfdd6d7c0u, 0xfe105c99u, + 0xfe41d1b9u, 0xfe6c9d31u, 0xfe91dbe3u, 0xfeb27294u, 0xfecf1a87u, 0xfee86af3u, + 0xfefee02eu, 0xff12e122u, 0xff24c38cu, 0xff34cf42u, 0xff4340cfu, 0xff504b7au, + 0xff5c1ae8u, 0xff66d46cu, 0xff709815u, 0xff798187u, 0xff81a8b2u, 0xff892263u, + 0xff9000bdu, 0xff96539fu, 0xff9c28f7u, 0xffa18d0au, 0xffa68aabu, 0xffab2b73u, + 0xffaf77e4u, 0xffb37792u, 0xffb73141u, 0xffbaaafcu, 0xffbdea2fu, 0xffc0f3b7u, + 0xffc3cbf7u, 0xffc676e2u, 0xffc8f80au, 0xffcb52abu, 0xffcd89b3u, 0xffcf9fccu, + 0xffd19762u, 0xffd372abu, 0xffd533acu, 0xffd6dc3bu, 0xffd86e08u, 0xffd9eaa1u, + 0xffdb5370u, 0xffdca9c4u, 0xffddeed0u, 0xffdf23b0u, 0xffe0496au, 0xffe160eeu, + 0xffe26b1eu, 0xffe368c6u, 0xffe45aa8u, 0xffe54175u, 0xffe61dd3u, 0xffe6f05au, + 0xffe7b99bu, 0xffe87a19u, 0xffe93252u, 0xffe9e2b9u, 0xffea8bb9u, 0xffeb2db9u, + 0xffebc917u, 0xffec5e2bu, 0xffeced49u, 0xffed76bdu, 0xffedfad2u, 0xffee79cbu, + 0xffeef3e9u, 0xffef6969u, 0xffefda83u, 0xfff0476eu, 0xfff0b05bu, 0xfff1157au, + 0xfff176fau, 0xfff1d502u, 0xfff22fbdu, 0xfff28750u, 0xfff2dbdfu, 0xfff32d8cu, + 0xfff37c76u, 0xfff3c8bcu, 0xfff4127cu, 0xfff459d0u, 0xfff49ed2u, 0xfff4e19cu, + 0xfff52244u, 0xfff560e0u, 0xfff59d86u, 0xfff5d84au, 0xfff6113fu, 0xfff64878u, + 0xfff67e04u, 0xfff6b1f6u, 0xfff6e45cu, 0xfff71547u, 0xfff744c3u, 0xfff772dfu, + 0xfff79fa7u, 0xfff7cb29u, 0xfff7f570u, 0xfff81e88u, 0xfff8467bu, 0xfff86d53u, + 0xfff8931cu, 0xfff8b7ddu, +}; diff --git a/sdk/model-cycles/modules/attack/src/gen_pictures.py b/sdk/model-cycles/modules/attack/src/gen_pictures.py new file mode 100644 index 0000000000..9d398f997d --- /dev/null +++ b/sdk/model-cycles/modules/attack/src/gen_pictures.py @@ -0,0 +1,85 @@ +#!/usr/bin/env python3 +# SPDX-License-Identifier: GPL-3.0-or-later +"""Writes attack_pictures.h: the knob's 14 pictures, 50 x 22, drawn here (no stock pixels). An envelope in the weight +of the amp envelope's pictures: the attack rises from the bottom left, upright at 0 and slanting further the higher +the value; a short sustain; a steep release, 6 px wide, its turn and its end as the user drew them. Sustain and release are the same pixels in every frame and +move right with the attack. + python3 -B gen_pictures.py (--show K ... prints frames as text)""" +import math +import sys +from pathlib import Path + +W, H, N = 50, 22, 14 +X0 = 3.5 # the attack's foot: columns 1 .. 6 at 0 +RX, RY = 3.0, 2.5 # half of 6 px across (the upright attack), 5 rows high (the sustain) +AMAX = 25 # the attack's width at the top value, in whole columns +SUS = 8 # from the attack's top to the sustain's right end, in the top row +KNEE = (0, 2, 3, 4, 4, 5) # the sustain's right edge, rows 0 .. 5: the turn into the release (the user's drawing) +REL = 6 # the release: 6 columns wide, one column right every two rows + + +def frame(k): + """Rows from the top, 1 lit. The attack grows by whole columns, so the sustain and the release are the same + pixels in every frame, moved right. The attack keeps the weight of a 6 x 5 ellipse moved along it; its foot is + cut flat at the bottom row and loses its corner pixels, as stock's bar; the release ends the same way.""" + a = round(AMAX * k / (N - 1)) + ha = math.sqrt(RX * RX + (RY * a / (H - 1)) ** 2) + end = int(X0) + a + SUS # the sustain's right end in the top row + g = [[0] * W for _ in range(H)] + for r in range(H): + ca = X0 + a * (H - 1 - r) / (H - 1) # attack: foot at the bottom, top at the sustain + for x in range(W): + if abs(x - ca) < ha: + g[r][x] = 1 + if r < len(KNEE): # the sustain, from the attack to the knee + for x in range(int(ca), end + KNEE[r] + 1): + g[r][x] = 1 + elif r < H - 1: # the release; its first row fills the inner corner by one + right = end + KNEE[-1] + (r - len(KNEE) + 1) // 2 + for x in range(right - REL + 1 - (r == len(KNEE)), right + 1): + g[r][x] = 1 + else: # its end: the row above, one pixel shorter at each end + right = end + KNEE[-1] + (r - len(KNEE)) // 2 + for x in range(right - REL + 2, right): + g[r][x] = 1 + first = g[0].index(1) # rounded corners: the top row's left end ... + g[0][first] = 0 + row = g[H - 1] # ... and the attack's foot loses its ends + x = row.index(1) + e = x + while e + 1 < W and row[e + 1]: + e += 1 + row[x] = row[e] = 0 + return g + + +def columns(g): + """The OS's layout: a 32-bit word a column, the bottom row in bit 31, the top row (22 rows) in bit 10.""" + return [sum(g[r][x] << (31 - (H - 1 - r)) for r in range(H)) for x in range(W)] + + +def main(): + if sys.argv[1:2] == ['--show']: + for k in map(int, sys.argv[2:]): + print('--', k) + print('\n'.join(''.join('#' if v else '.' for v in row) for row in frame(k))) + return + out = ['/* Generated by gen_pictures.py: do not edit. */', + '#define ATTACK_FRAMES %d' % N, + 'static const uint32_t ATTACK_MASK[%d] = {' % W] + mask = (0xffffffff << (32 - H)) & 0xffffffff + out += [' ' + ', '.join('0x%08xu' % mask for _ in range(i, min(i + 6, W))) + ',' for i in range(0, W, 6)] + out += ['};', 'static const uint32_t ATTACK_PIXELS[%d][%d] = {' % (N, W)] + for k in range(N): + words = columns(frame(k)) + out.append(' {') + out += [' ' + ', '.join('0x%08xu' % w for w in words[i:i + 6]) + ',' for i in range(0, W, 6)] + out.append(' },') + out += ['};', 'static const struct mw_bitmap ATTACK_PICTURES[%d] = {' % N] + out += [' { 0, %d, %d, 1, ATTACK_PIXELS[%d], ATTACK_MASK, 0 },' % (W, H, k) for k in range(N)] + out.append('};') + Path(__file__).with_name('attack_pictures.h').write_text('\n'.join(out) + '\n') + + +if __name__ == '__main__': + main() diff --git a/sdk/model-cycles/modules/attack/src/gen_table.py b/sdk/model-cycles/modules/attack/src/gen_table.py new file mode 100644 index 0000000000..9bdb50b845 --- /dev/null +++ b/sdk/model-cycles/modules/attack/src/gen_table.py @@ -0,0 +1,19 @@ +#!/usr/bin/env python3 +# SPDX-License-Identifier: GPL-3.0-or-later +"""Writes attack_table.h: for each value 1 .. 127 the amp envelope's step a block (Voice +0x248) (the knob shows 0 .. 127). Time(v) = max(3 s * (v / 127) ** 2.47, v blocks); a block is 32 frames at 48 kHz. The envelope's +level runs from 0 down to 0x80000000 (full), so a step is negative: -(2^31) / blocks, never 0x80000000 itself, which +the stock chain reads as "full at once".""" +BLOCK = 32 / 48000 +rows = [] +for v in range(128): + if v == 0: + rows.append((0, 0)); continue + t = max(3.0 * (v / 127) ** 2.47, v * BLOCK) + step = max(-(2 ** 31 - 1), -round(2 ** 31 / (t / BLOCK))) + rows.append((step & 0xffffffff, round(t * 1000 * 10))) # tenths of a millisecond +with open(__import__('pathlib').Path(__file__).with_name('attack_table.h'), 'w') as f: + f.write('/* Generated by gen_table.py: do not edit. */\n') + f.write('static const uint32_t ATTACK_STEP[128] = {\n') + for i in range(0, 128, 6): + f.write(' ' + ', '.join('0x%08xu' % s for s, _ in rows[i:i + 6]) + ',\n') + f.write('};\n') diff --git a/src/community/module-changelogs/model-cycles-attack.json b/src/community/module-changelogs/model-cycles-attack.json new file mode 100644 index 0000000000..c3e344fbe7 --- /dev/null +++ b/src/community/module-changelogs/model-cycles-attack.json @@ -0,0 +1,13 @@ +[ + { + "version": "0.1.0-experimental", + "date": "2026-12-01", + "changes": [ + "First release for Model:Cycles OS 1.13: adds Attack to every track, up to 3 seconds.", + "Hold MACHINES and turn DECAY to set it from 0 to 127; 0 plays as before. The display shows Amp Attack with its envelope.", + "Parameter locks, the LFO, velocity and Control All reach it, and the sound saves it.", + "Retriggering a track that still sounds fades the old note out over 2 ms instead of clicking. With GATE on, a short note decays from where its rise got to.", + "MIDI CC 73 sets it too." + ] + } +] diff --git a/vendor/elekloader/catalog/attack-0.1.0-experimental-os1.13.elemod b/vendor/elekloader/catalog/attack-0.1.0-experimental-os1.13.elemod new file mode 100644 index 0000000000..f82031a0fc --- /dev/null +++ b/vendor/elekloader/catalog/attack-0.1.0-experimental-os1.13.elemod @@ -0,0 +1,393 @@ +{ + "elemod": 2, + "id": "attack", + "version": "0.1.0-experimental", + "title": "Attack", + "description": "A rise time for every track's sound, whatever its machine: hold MACHINES and turn DECAY.", + "category": "playback", + "author": "durchgemacht", + "license": "GPL-3.0-or-later", + "target": { + "device": "model-cycles", + "product": "Model:Cycles", + "os": "1.13", + "syx_sha256": "44fe586269631a0ca7da25a3383fc6733c314809505fc3cc52f1e0ed9800640c", + "section3_sha256": "cc99d4f0175d34d1e91d046e6ec85a5e8ab58ab9edbb3c24406acd48cb99ee98", + "section3_len": 1744192 + }, + "sections": { + ".run": { + "align": 4, + "len": 4429, + "parts": [ + [ + "hex", + "518f2f0a72052f02202f0014b280657ae988206f001c7328003e41f90000000043f008001429000c1f4200084a416f6245f90000000022321c002f41000c4a02660000cc226f001845e902482192080074011230080d246f00181182080c242f000c21820804254202484a0166464aaa024c67164aaa023c66104aaa0244670a70012540023c42aa0244241f245f508f4e754a2f0008671622690004246f0018b3ea02486700008842011181080c1230080d67d67581d1c0202800085381226f00182f420008740fe4a0740394af00081141000d2f42000c74022342023c242f000c42a9024443f90000000075712a00226f00184c002800234202304a01668a70011140000e241f245f508f4e7522690004246f0018b3ea02486700ff34226f001845e90248219208006000ff24420143f00800255102481181080c6000ff702f027205202f0008b280655ce9882040d1fc000000004a28000e66504a28000d6666206f000c4aa80034673c206f00107328003e4a416f30226f000c2229023020414a816d3ab1fc0020c49b6f1a2040d1fc000000007003226f000c2141000842a900341140000d241f4e75420270011142000e206f000c21400034241f4e7524014482204260be226f000c241f42a900344e750002007f000000000000000000000000000000000e0000000001000000000000000000005ed0213000000000000000000032000000160000000100000000000000000000000000000000000000320000001600000001000000000000000000000000000000000000003200000016000000010000000000000000000000000000000000000032000000160000000100000000000000000000000000000000000000320000001600000001000000000000000000000000000000000000003200000016000000010000000000000000000000000000000000000032000000160000000100000000000000000000000000000000000000320000001600000001000000000000000000000000000000000000003200000016000000010000000000000000000000000000000000000032000000160000000100000000000000000000000000000000000000320000001600000001000000000000000000000000000000000000003200000016000000010000000000000000000000000000000000000032000000160000000100000000000000000000000000000000000000320000001600000001000000000000000000000000000000007ffff800fffffc00fffffc00fffffc00fffffc007ffffc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f8000000600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000007c000000ffff0000fffff800fffffc00fffffc007ffffc0003fffc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f8000000600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000060000000ff800000fffc0000ffffe000fffff8007ffffc001ffffc0000fffc000007fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f800000060000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000060000000fc000000ffc00000fff80000ffff80007ffff0003ffff80007fffc00007ffc00000ffc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f80000006000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000f8000000fe000000ffc00000fff800007ffe00007fffc0000ffff80001fff800007ffc00000ffc000001fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f8000000600000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000f0000000fc000000ff000000ffc000007ff800007ffe00001fff800007ffe00001fff800007ff800000ffc000003fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f800000060000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000f0000000f8000000fe000000ff8000007fe000007ff000001ffc00000fff000003ffc00000ffe000003ff800001ff8000007fc000001fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f80000006000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000f0000000f8000000fe000000ff0000007fc000007ff000003ff800000ffe000003ff000001ffc000007ff000003ff800000ff8000003fc000001fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f800000060000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000040000000e0000000f8000000fc000000fe0000007f8000007fc000003ff000001ff8000007fc000003ff000000ff8000007fe000003ff000000ff8000007f8000001fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f800000060000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000e0000000f0000000fc000000fe000000ff0000007f8000003fe000001ff000000ff8000007fc000001fe000000ff8000007fc000003fe000001ff0000007f8000003fc000001fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f80000006000000000000000000000000000000000000000000000000000000000000000000000000000000000000000c0000000e0000000f0000000f8000000fc000000fe0000007f8000007fc000003fe000000ff0000007f8000003fc000001fe000000ff0000007f8000003fc000001ff000000ff8000007f8000001fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f8000000600000000000000000000000000000000000000000000000000000000000000000000000c0000000e0000000f0000000f8000000fc000000fe0000007f0000007f8000003fc000001fe000000ff0000007f8000003fc000001fe000000ff0000007f8000003fc000001fe000000ff0000007f8000003f8000001fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f800000060000000000000000000000000000000000000000000000000000000c0000000e0000000f0000000f8000000fc000000fc0000007e0000007f0000003f8000001fc000000fe0000007f0000007f8000003fc000001fe000000ff0000007f8000003f8000001fc000000fe0000007f0000003f8000001f8000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f80000006000000000000000000000000000000000000000c0000000e0000000f0000000f0000000f8000000fc0000007e0000007f0000003f8000003fc000001fc000000fe0000007f0000003f8000001fc000001fe000000fe0000007f0000003f8000001fc000000fe000000ff0000007f0000003f8000001f8000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000000fc000001fc000001fc000007f800001ff800007ff00001ffe00007ff80001ffe00007ff80000ffe00000ff800000fe000000f80000006000000000000000fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc00fffffc000000000080000001c0000000d5555555e0000000e6666666eaaaaaabedb6db6ef0000000f1c71c72f3333333f45d1746f657f693f8136b0df966bd93fa6f6b38fb4155f3fbea4287fc73f354fce577e4fd4403edfd937ca6fdd6d7c0fe105c99fe41d1b9fe6c9d31fe91dbe3feb27294fecf1a87fee86af3fefee02eff12e122ff24c38cff34cf42ff4340cfff504b7aff5c1ae8ff66d46cff709815ff798187ff81a8b2ff892263ff9000bdff96539fff9c28f7ffa18d0affa68aabffab2b73ffaf77e4ffb37792ffb73141ffbaaafcffbdea2fffc0f3b7ffc3cbf7ffc676e2ffc8f80affcb52abffcd89b3ffcf9fccffd19762ffd372abffd533acffd6dc3bffd86e08ffd9eaa1ffdb5370ffdca9c4ffddeed0ffdf23b0ffe0496affe160eeffe26b1effe368c6ffe45aa8ffe54175ffe61dd3ffe6f05affe7b99bffe87a19ffe93252ffe9e2b9ffea8bb9ffeb2db9ffebc917ffec5e2bffeced49ffed76bdffedfad2ffee79cbffeef3e9ffef6969ffefda83fff0476efff0b05bfff1157afff176fafff1d502fff22fbdfff28750fff2dbdffff32d8cfff37c76fff3c8bcfff4127cfff459d0fff49ed2fff4e19cfff52244fff560e0fff59d86fff5d84afff6113ffff64878fff67e04fff6b1f6fff6e45cfff71547fff744c3fff772dffff79fa7fff7cb29fff7f570fff81e88fff8467bfff86d53fff8931cfff8b7dd416d702041747461636b0041544b00" + ] + ] + }, + ".bss": { + "align": 4, + "size": 96 + } + }, + "symbols": { + "attack_updated": [ + ".run", + 0 + ], + "trk": [ + ".bss", + 0 + ], + "ATTACK_STEP": [ + ".run", + 3902 + ], + "FALL": [ + ".run", + 504 + ], + "attack_before": [ + ".run", + 320 + ], + "ATTACK_PICTURES": [ + ".run", + 510 + ], + "ATTACK_PIXELS": [ + ".run", + 902 + ], + "ATTACK_MASK": [ + ".run", + 3702 + ], + "attack_word": [ + ".run", + 468 + ], + "attack_hook": [ + ".run", + 492 + ] + }, + "exports": [ + "attack_hook", + "attack_word" + ], + "imports": [], + "weak": [], + "relocs": [ + [ + ".run", + 28, + "abs32", + "sec:.bss", + 0 + ], + [ + ".run", + 50, + "abs32", + "sec:.run", + 3902 + ], + [ + ".run", + 232, + "abs32", + "sec:.run", + 504 + ], + [ + ".run", + 338, + "abs32", + "sec:.bss", + 0 + ], + [ + ".run", + 402, + "abs32", + "sec:.bss", + 0 + ], + [ + ".run", + 472, + "abs32", + "sec:.run", + 4414 + ], + [ + ".run", + 476, + "abs32", + "sec:.run", + 4425 + ], + [ + ".run", + 484, + "abs32", + "sec:.run", + 510 + ], + [ + ".run", + 496, + "abs32", + "sec:.run", + 320 + ], + [ + ".run", + 500, + "abs32", + "sec:.run", + 0 + ], + [ + ".run", + 526, + "abs32", + "sec:.run", + 902 + ], + [ + ".run", + 530, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 554, + "abs32", + "sec:.run", + 1102 + ], + [ + ".run", + 558, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 582, + "abs32", + "sec:.run", + 1302 + ], + [ + ".run", + 586, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 610, + "abs32", + "sec:.run", + 1502 + ], + [ + ".run", + 614, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 638, + "abs32", + "sec:.run", + 1702 + ], + [ + ".run", + 642, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 666, + "abs32", + "sec:.run", + 1902 + ], + [ + ".run", + 670, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 694, + "abs32", + "sec:.run", + 2102 + ], + [ + ".run", + 698, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 722, + "abs32", + "sec:.run", + 2302 + ], + [ + ".run", + 726, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 750, + "abs32", + "sec:.run", + 2502 + ], + [ + ".run", + 754, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 778, + "abs32", + "sec:.run", + 2702 + ], + [ + ".run", + 782, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 806, + "abs32", + "sec:.run", + 2902 + ], + [ + ".run", + 810, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 834, + "abs32", + "sec:.run", + 3102 + ], + [ + ".run", + 838, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 862, + "abs32", + "sec:.run", + 3302 + ], + [ + ".run", + 866, + "abs32", + "sec:.run", + 3702 + ], + [ + ".run", + 890, + "abs32", + "sec:.run", + 3502 + ], + [ + ".run", + 894, + "abs32", + "sec:.run", + 3702 + ] + ], + "sites": [], + "collections": {}, + "contribute": [ + { + "to": "mw_voice_hooks", + "order": 50, + "data": "00000000", + "relocs": [ + [ + 0, + "abs32", + "sym:attack_hook", + 0 + ] + ], + "claims": [] + }, + { + "to": "mw_sound_word", + "order": 50, + "data": "00000000", + "relocs": [ + [ + 0, + "abs32", + "sym:attack_word", + 0 + ] + ], + "claims": [] + } + ], + "copied": [], + "resources": { + "regions": [], + "names": [], + "core": "0.3" + }, + "requires": [ + "core" + ], + "conflicts": [], + "signature": null +} From 0434e39c20d6fce29439ca0c09bce3e2f9694ef6 Mon Sep 17 00:00:00 2001 From: repeat98 Date: Thu, 3 Dec 2026 16:15:33 +0100 Subject: [PATCH 2/3] Tests: the All machines library offers a Model:Cycles build with Attack Co-Authored-By: Claude Opus 5.5 --- src/devices/library-parity.test.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/devices/library-parity.test.ts b/src/devices/library-parity.test.ts index 032d349bdd..e586a8b7bf 100644 --- a/src/devices/library-parity.test.ts +++ b/src/devices/library-parity.test.ts @@ -110,11 +110,12 @@ describe('All machines library parity', () => { expect(html).toContain(count('—', 'downloads')) expect(html).not.toContain(count('0', 'downloads')) expect(html).toContain('Popularity counts are currently unavailable.') - expect(html.match(/aria-label="Build firmware for/g)).toHaveLength(5) + expect(html.match(/aria-label="Build firmware for/g)).toHaveLength(6) expect(html).toContain('href="#digitakt/configuration"') expect(html).toContain('href="#digitakt-ii/configuration"') expect(html).toContain('href="#digitone/configuration"') expect(html).toContain('href="#analog-rytm-mkii/configuration"') + expect(html).toContain('href="#model-cycles/configuration"') }) it('applies type and alphabetical sorting to the Digi groups', () => { From e2b4ced92a9cb54e88273895d036637c9edcfaf8 Mon Sep 17 00:00:00 2001 From: repeat98 Date: Thu, 3 Dec 2026 16:44:21 +0100 Subject: [PATCH 3/3] Tests: module release notes cover the Model:Cycles' first module Co-Authored-By: Claude Opus 5.5 --- src/community/module-changelogs.test.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/community/module-changelogs.test.ts b/src/community/module-changelogs.test.ts index ad711c9f07..755b6a4308 100644 --- a/src/community/module-changelogs.test.ts +++ b/src/community/module-changelogs.test.ts @@ -22,7 +22,7 @@ describe('module release notes', () => { it('covers every current catalog release across every instrument', () => { const notes = parseModuleChangelogs(data, COMMUNITY_MODULES) expect(Object.keys(notes).length).toBe(COMMUNITY_MODULES.length) - const expected = new Set(['octatrack', 'digitakt', 'digitakt-ii', 'digitone', 'analog-rytm-mkii', 'zoom-ms-70cdr']) + const expected = new Set(['octatrack', 'digitakt', 'digitakt-ii', 'digitone', 'analog-rytm-mkii', 'model-cycles', 'zoom-ms-70cdr']) if (COMMUNITY_MODULES.some(module => module.id === 'analog-four-mkii-euclid-notes')) expected.add('analog-four-mkii') expect(new Set(COMMUNITY_MODULES.map(module => module.machine))).toEqual(expected) })