Skip to main content

Full Example Walkthrough

This page ties DMX Files and DMXD Files together into one working example: a .dmxd definition file for a fictional controller, a .dmx sequence that uses it, and the command to compile both into MIDI.

1. Define your controller (obey70.dmxd)

.alias obey70

.defines
blackout:midi_on = 0
strobe:midi_on = 1
s1x/8:midi_on = 10
  • .alias obey70 — the name this file answers to. It must match the .controller value in the .dmx file below.
  • blackout and strobe are exact commands with no argument — good for on/off toggles.
  • s1x/8 is a range command: bank 1, 8 slots starting at note 10. Typing s118 plays note 17 (10 + 8 - 1). See the Roadmap for a known compiler bug affecting this syntax today.

2. Write your sequence (intro.dmx)

.controller obey70
.bpm 120
.channel 1
.commands

strobe ; hit the strobe once
delta 2 ; wait 2 seconds
loop 3
s118 ; scene 1, slot 8 (note 17)
delta 1
end
blackout
  • .controller obey70 matches the .alias obey70 above.
  • .commands is the last section header; everything after it is the actual sequence.
  • loop 3 ... end repeats the enclosed lines 3 times before continuing.

3. Compile it

dmxc intro.dmx obey70.dmxd intro.mid

intro.mid is a standard MIDI file on channel 1 at 120 BPM, ready to open in a DAW or send to your controller.