Go Down

Topic: Mega: Manually sending Usb-MIDI (Read 312 times) previous topic - next topic


I've got some trouble sending MIDI over USB to communicate with a lightsoftware.

The lighting software only reacts on control change commands (statusByte: 1011CCCC, whereas CCCC = Channel, Data1: Key[Byte], Data2: Value[Byte])

So apperently the USBMIDI library is not compatible with the mega board, so I tried implementing this simple feature myself, but I get only nonesense Data, if at all.

My (simplified) source:
Code: [Select]
void commCC (byte mchannel, byte key, byte val) {
  byte status = 176 + mchannel; // 1011cccc

// Called like this (On Channel 15 pull up the fader 124 to max):
commCC(15, 124, 127);

Thanks for help


So you create a variable called status. Then you write a different variable called statusByte. Seems a little odd.

BTW you may get more MIDI help in the Audio forum. Even if your use is lighting, that's still where most of the MIDI expertise hangs out. https://forum.arduino.cc/index.php?board=8.0


Go Up