summaryrefslogtreecommitdiff
path: root/software/rhmixxx
diff options
context:
space:
mode:
Diffstat (limited to 'software/rhmixxx')
-rw-r--r--software/rhmixxx/midi-commands.txt177
1 files changed, 177 insertions, 0 deletions
diff --git a/software/rhmixxx/midi-commands.txt b/software/rhmixxx/midi-commands.txt
new file mode 100644
index 0000000..8925770
--- /dev/null
+++ b/software/rhmixxx/midi-commands.txt
@@ -0,0 +1,177 @@
+OUTGOING (commands sent by the controller):
+===========================================
+
+There are 3 possible sources for messages sent by the controller
+
+ - Keypad .. a key/button has been pressed or released (note offset 0x00)
+ - GPIO .. a GPI has changed its state (note offset 0x20)
+ - Analog .. the analog value of an input has changed (note offset 0x40)
+
+
+Keypad:
+-------
+
+ - the 16 buttons are numbered 0-15 (note 0x00-0x0F)
+ - a key press event sends the following command:
+
+ 0x90 <key nr + 0x00> 0x7F
+
+ - a key release event sends the following command:
+
+ 0x80 <key nr + 0x00> 0x00
+
+ Example:
+ Key 14 is pressed and released:
+
+ 0x90 0x0D 0x7F
+ 0x80 0x0D 0x00
+
+
+GPIO:
+-----
+
+ - the 4 inputs are numbered 0-3 (note 0x20-0x23)
+ - a low to high transition sends the following command:
+
+ 0x90 <input nr + 0x20> 0x7F
+
+ - a high to low transition sends the following command:
+
+ 0x80 <input nr + 0x20> 0x00
+
+ Example:
+ input 1 goes from low to high and back to low:
+
+ 0x90 0x20 0x7F
+ 0x80 0x20 0x00
+
+
+Analog:
+-------
+
+ - the 8 analog inputs are numbered 0-7 (note 0x40-0x47)
+ - by default all inputs are disabled. See below to find out how
+ to enable/disable analog inputs
+ - on every change of the value of the analog port the following command
+ is sent:
+
+ 0xB0 <input nr + 0x40> <value>
+
+ (value is between 0x00 and 0x7F -> 0..127)
+
+ Example:
+ input 7 changes its value to 42:
+
+ 0xB0 0x46 0x2A
+
+
+
+
+INCOMING (commands understood by the controller):
+=================================================
+
+There are 3 possible sinks for messages sent to the controller
+
+ - Keypad .. controls the led of a key/button (note offset 0x00)
+ - GPIO .. sets or unsets a GPO (note offset 0x20)
+ - Analog .. enables or disables an analog input (note offset 0x40)
+
+
+Keypad:
+-------
+
+ - the 16 leds are numbered 0-15 (note 0x00-0x0F)
+ - all leds can be changed by the special address 0x1F
+ - switch a led on:
+
+ 0x90 <key nr + 0x00> 0x00
+
+ - toggle a led:
+
+ 0x90 <key nr + 0x00> 0x01
+
+ - led blinking:
+
+ 0x90 <key nr + 0x00> 0x02..0x1F
+
+ the value controls the blinking speed. Smaller values correspond to
+ higher blinking frequencies.
+
+ - switch a led off
+
+ 0x80 <key nr + 0x00> 0x00
+
+ Examples:
+ Turn led 3 on:
+
+ 0x90 0x03 0x7F
+
+ Toggle led 5:
+
+ 0x90 0x05 0x01
+
+ led 6 blinking fast:
+
+ 0x90 0x06 0x03
+
+ led 14 blinking slow:
+
+ 0x90 0x0D 0x40
+
+ turn all leds off:
+
+ 0x80 0x1F 0x00
+
+
+GPIO:
+-----
+
+ - the 4 outputs are numbered 0-3 (note 0x20-0x23)
+ - all outputs can be controlled by the special address 0x3F
+ - for a low to high transition send the following command:
+ (this does nothing if the port is already high)
+
+ 0x90 <output nr + 0x20> 0x00
+
+ - for a high to low transition send the following command:
+ (this does nothing if the port is already low)
+
+ 0x80 <output nr + 0x20> 0x00
+
+ - for a state change send the following command:
+
+ 0x90 <output nr + 0x20> 0x01
+
+ Example:
+ toggle the state of output 3:
+
+ 0x90 0x22 0x01
+
+ set all outputs to high:
+
+ 0x90 0x3F 0x00
+
+
+Analog:
+-------
+
+ - the 8 analog inputs are numbered 0-7 (note 0x40-0x47)
+ - all inputs can be controlled by the special address 0x5F
+ - after a reset all inputs are disabled.
+ - to enable an input send the following command:
+
+ 0x90 <input nr + 0x40> 0x00
+
+ - to disable an input send the following command:
+
+ 0x80 <input nr + 0x40> 0x00
+
+
+ Example:
+ enable input 2:
+
+ 0x90 0x41 0x00
+
+ disable all inputs:
+
+ 0x80 0x5F 0x00