Loading files…
An LSDJ-inspired music tracker for the Sega Master System and Game Gear, written in pure Z80 assembly. Make music on real hardware (via flashcart) or in an emulator, using just the D-pad and two buttons. Sound is the SN76489 PSG — three square channels and noise — plus 4-bit PCM samples and drawn wavetables via the volume-register DAC trick, a built-in tempo-synced echo, and Game Gear stereo. On a Master System with the FM Sound Unit — or a Game Gear fitted with the GGFM hardware modification — you also get YM2413 FM: melodic voices (15 ROM patches + 8 ROM-baked custom presets, with tables and per-note commands) and a rhythm-mode drum kit, sounding alongside the PSG (off by default).
📺 Video tutorials — a growing playlist walking through how to use SMSGGDJ.
One source tree builds two ROMs:
smsggdj.sms — Master System (full screen).smsggdj.gg — Game Gear / GGDJ (handheld screen, real stereo).Prebuilt ROMs are on the Releases page — download the
version-stamped .sms (Master System) or .gg (Game Gear) ROM; flash to a cart
or open in an emulator, no toolchain needed.
Hardware-verified Game Gear sync: the EXT-port paddle and Chipbridge hardware have been tested in several real-console setups:
- SMSGGDJ on Game Gear ↔ GENMDDJ on Sega Nomad.
- Ableton Live (or another DAW sending MIDI clock) → Chipbridge → Sega 9-pin-to-TRS adapter → Master Link Cable → Game Gear running SMSGGDJ in
SYNC: IN24.- Game Gear running
SYNC: OUT→ EXT paddle → TRS cable → EXT paddle → a second Game Gear runningSYNC: IN.
Needs WLA-DX (wla-z80 + wlalink) and
Python 3. make run launches the bundled Emulicious (needs Java).
make # build both: build/smsggdj.sms and build/smsggdj.gg
make run # build both, launch the SMS ROM
make run-gg # build both, launch the Game Gear ROM
make adapter # universal XIAO RP2040 / Pico USB-MIDI sync UF2
make clean
Both ROMs boot to a blank song, ready to make music (the wavetables come preloaded with the stamp presets, so a fresh song makes sound right away).
Drop a ROM on a flashcart (Master Everdrive etc.) or open it in an emulator, and press play.
Emulator note: all manual emulator testing was done in SMS Plus (Bannister). Other emulators should work, but that's the one this project is exercised against.
.sav,
assemble a cart image (pick 8/16/32 KB), or click a slot to view a song's
notes, commands and instruments — in the browser. Raw and SMS Plus gzip
.sav files are both accepted directly..sav
forward to the current compressed format: it RLE-packs every song into an
SMDJ4 directory + heap image. Drop the old save, download the new one..sms or .gg
ROM and edit its 8 custom FM presets (the YM2413 user patches an FM instrument's
PRST field selects): per-operator MUL/AR/DR/SL/RR/KSL/TL, feedback,
waveforms and names, audition each through a JS port of the emu2413
YM2413 core, then download the patched ROM. No toolchain..als) and get a .smdj song: the first 3 MIDI tracks' Session clips become
phrases/chains on a 16th-note grid (highest note wins, out-of-range folds in,
note-offs ignored). Load the result with savetool.html. No toolchain..sav / .smdj save format.SYNC: IN24) and MIDI note takeover (SYNC: MIDI). It is
hardware-verified with SMSGGDJ on Master System and Game Gear.SYNC: IN from inside the emulator (frame-PLL'd timeline,
bar-quantized launch, HUD). The software counterpart to the ESP32 bridge —
Link-sync the tracker with no hardware.src/ Z80 assembly (main, vdp, input, psg, engine, sample, editor)
adapter/ universal XIAO RP2040 / Pico USB-MIDI sync firmware + wiring
tools/ Python build tools + the browser apps:
makefont / maketables / makelogo (build inputs)
smsggdj_sample.py WAV/pool -> sample bank
patcher.html browser sample patcher
savetool.html browser song/save manager
migrate.html SMDJ3 -> SMDJ4 save migrator
palette.html browser UI-palette recolourer
fmpatch.html browser FM custom-preset editor
samples/ sample sources: one subfolder per kit (up to 8 kits x 8 WAVs);
samples/pool.bin (if present) overrides as a pre-baked bank
art/ the logo art
The pool is built from kit folders under samples/ — up to 8 kits of 8
samples, taken in alphanumeric order (one subfolder per kit, WAVs inside). An
KIT instrument's KIT field picks the kit and the note maps chromatically to
the 8 slots, so one instrument is a whole drum kit. make trims each sample's
trailing silence and applies a gain (make SAMPLE_GAIN=N, default 10) for a
punchier 4-bit DAC. A committed samples/pool.bin (tuned in the patcher) still
overrides as a pre-baked bank if present. The pool is identical in both
flavours, so one bank serves .sms and .gg.
MIT — see LICENSE. Use it, fork it, learn from it.
The bundled Emulicious emulator (tools/emulicious/, not in this repo) has its
own license.
Made by little-scale.
No comments yet. Be the first to ask about this board.