diff options
author | Christian Pointner <equinox@helsinki.at> | 2014-06-03 18:21:17 (GMT) |
---|---|---|
committer | Christian Pointner <equinox@helsinki.at> | 2014-06-03 18:21:17 (GMT) |
commit | 045dd433f781c7b564fdb5f54fc75d5e10d53a75 (patch) | |
tree | 58b92c5d8a64584db2a264662b2b3fd809d6e69d /software/rhmixxx | |
parent | 488657188fda872c5d284e8d669ec940346c99e7 (diff) |
further improved midi command mapping
Diffstat (limited to 'software/rhmixxx')
-rw-r--r-- | software/rhmixxx/rhmixxx.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/software/rhmixxx/rhmixxx.c b/software/rhmixxx/rhmixxx.c index fd91361..ad89590 100644 --- a/software/rhmixxx/rhmixxx.c +++ b/software/rhmixxx/rhmixxx.c @@ -90,9 +90,8 @@ static void process_incoming_midi(void) note == KEYPAD_MIDI_NOTE_ALL) {
if(cmd == MIDI_COMMAND_NOTE_ON) {
switch(value) {
- case 0: keypad_led_off(note - KEYPAD_MIDI_NOTE_OFFSET); break;
- case 1: keypad_led_on(note - KEYPAD_MIDI_NOTE_OFFSET); break;
- case 2: keypad_led_toggle(note - KEYPAD_MIDI_NOTE_OFFSET); break;
+ case 0: keypad_led_on(note - KEYPAD_MIDI_NOTE_OFFSET); break;
+ case 1: keypad_led_toggle(note - KEYPAD_MIDI_NOTE_OFFSET); break;
default: keypad_led_blink(note, value); break;
}
} else if(cmd == MIDI_COMMAND_NOTE_OFF)
@@ -102,9 +101,8 @@ static void process_incoming_midi(void) note == GPIO_MIDI_NOTE_ALL_OUTPUTS) {
if(cmd == MIDI_COMMAND_NOTE_ON) {
switch(value) {
- case 0: gpio_out_off(note - GPIO_MIDI_NOTE_OFFSET); break;
- case 1: gpio_out_on(note - GPIO_MIDI_NOTE_OFFSET); break;
- case 2: gpio_out_toggle(note - GPIO_MIDI_NOTE_OFFSET); break;
+ case 0: gpio_out_on(note - GPIO_MIDI_NOTE_OFFSET); break;
+ case 1: gpio_out_toggle(note - GPIO_MIDI_NOTE_OFFSET); break;
}
} else if(cmd == MIDI_COMMAND_NOTE_OFF)
gpio_out_off(note - GPIO_MIDI_NOTE_OFFSET);
|