Skip to content

ADR-6FYT4Z4T: SNES music plays on a driver of our own in Krautrecker - #92

Merged
skerkewitz-agent[bot] merged 1 commit into
developfrom
adr-music-driver
Nov 29, 2026
Merged

skerkewitz-agent[bot] merged 1 commit into
developfrom
adr-music-driver

Conversation

@skerkewitz-agent

Copy link
Copy Markdown
Contributor

What

Records the decision about music on the SNES: it plays on a driver of our own, written in SPC700 code and kept in the Krautrecker repository next to the compiler whose songs it plays (ADR-6FYT4Z4T). superdevkit uses a pinned release of the driver and reads the songs as the zips Krautrecker exports. Nothing is built yet; this pull request adds only the record and links to it.

How

  • docs/adr/6FYT4Z4T-…md, the record. It covers:
    • Krautrecker's IR at register level, played by its own S-DSP model.
    • The survey of the open-source drivers on the SNESdev wiki. Only the Terrific Audio Driver (TAD) is maintained and covers the features Krautrecker uses.
    • The decision, with the driver's two interfaces versioned apart. The song format is Krautrecker's. The port commands are upload, play/stop and a pass-through DSP write for the voices the song leaves to the effects.
    • Why not TAD: its own vibrato and portamento, 2 effect voices, a data format that changes between versions, no dampf API.
    • Why not the older tracker-format drivers.
    • Why the driver doesn't live in superdevkit or in a repository of its own: a music feature would change the format in one place and its player in another, and Krautrecker needs the driver without a game.
    • What follows for both projects.
  • It amends the record that brought in the sound effects (ADR-6F60ZC7C): in a game with music, the music driver takes the place of the 21-byte forwarding driver, and the effects' DSP writes pass through it. The choice of the voice stays in lib/sound/sfx_voices.h. The status column of docs/ADR.md says so for both records.
  • docs/roadmap.md ("Not scheduled") and the Music section of docs/sound.md say where the driver comes from and link the record.

Verified

./gradlew build passed: 1,269 tests, 0 failed, 13 skipped. That includes AdrTest, which checks the table, the file and the citations.

What follows

  • Generated code, the C guide and its StyleGuideTest rules: unchanged.
  • The game: no change, and no entry in docs/game-findings.md.
  • Documents: the new record, docs/ADR.md, docs/roadmap.md, docs/sound.md.
  • Book: no page goes stale, since nothing a user can run has changed.

Open

The record leaves two questions to be decided with the driver:

  • Does the driver play every tick's events as they are, or compute vibrato and slides itself? The size of the demo songs' events decides that.
  • What does the desktop play until Rachael runs the driver?

The record also states where superdevkit is heading: a complete SPC700 in dampf's emulator, Rachael playing the real driver, one audio RAM check for music and effects together, and the faster loader becoming more pressing. Please check that this matches your view.

🤖 Generated with Claude Code

The driver is SPC700 code of our own, kept in the Krautrecker
repository next to the compiler whose songs it plays. superdevkit
pins a release, reads Krautrecker's exported zip, and passes the
effects' DSP writes through the driver, so the choice of the voice
stays in lib/sound/sfx_voices.h. Amends ADR-6F60ZC7C. The roadmap and
docs/sound.md link the record.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@skerkewitz-agent
skerkewitz-agent Bot merged commit 165ecf1 into develop Nov 29, 2026
1 check passed
@skerkewitz-agent
skerkewitz-agent Bot deleted the adr-music-driver branch November 29, 2026 16:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant