|
|
|
@ -67,9 +67,9 @@ USBHub hub3(usb_host); |
|
|
|
|
#elif NUM_HUBS_MIDI_DEVICE_USB_HOST_SERIAL < 5 |
|
|
|
|
USBHub hub4(usb_host); |
|
|
|
|
#endif |
|
|
|
|
USBSerial_BigBuffer userial(usb_host,1); |
|
|
|
|
USBSerial_BigBuffer userial(usb_host, 1); |
|
|
|
|
MIDI_NAMESPACE::SerialMIDI<USBSerial_BigBuffer, CustomBaudRateSettings> serialMIDI(userial); |
|
|
|
|
MIDI_NAMESPACE::MidiInterface<MIDI_NAMESPACE::SerialMIDI<USBSerial_BigBuffer, CustomBaudRateSettings>> usbhost_midi_serial((MIDI_NAMESPACE::SerialMIDI<USBSerial_BigBuffer, CustomBaudRateSettings>&)serialMIDI); |
|
|
|
|
MIDI_NAMESPACE::MidiInterface<MIDI_NAMESPACE::SerialMIDI<USBSerial_BigBuffer, CustomBaudRateSettings>> usbhost_midi_serial((MIDI_NAMESPACE::SerialMIDI<USBSerial_BigBuffer, CustomBaudRateSettings> &)serialMIDI); |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
void handleNoteOn(byte inChannel, byte inNumber, byte inVelocity); |
|
|
|
@ -1100,12 +1100,20 @@ FLASHMEM void setup_midi_devices(void) { |
|
|
|
|
usbhost_midi_serial.setHandleStop(handleStop_MIDI_DEVICE_USB_HOST_SERIAL); |
|
|
|
|
usbhost_midi_serial.setHandleActiveSensing(handleActiveSensing_MIDI_DEVICE_USB_HOST_SERIAL); |
|
|
|
|
usbhost_midi_serial.setHandleSystemReset(handleSystemReset_MIDI_DEVICE_USB_HOST_SERIAL); |
|
|
|
|
//usbhost_midi_serial.setHandleRealTimeSystem(handleRealTimeSystem_MIDI_DEVICE_USB_HOST_SERIAL);
|
|
|
|
|
//usbhost_midi_serial.setHandleRealTimeSystem(handleRealTimeSystem_MIDI_DEVICE_USB_HOST_SERIAL);
|
|
|
|
|
|
|
|
|
|
usbhost_midi_serial.begin(MIDI_CHANNEL_OMNI); |
|
|
|
|
usbhost_midi_serial.begin(DEFAULT_MIDI_CHANNEL); |
|
|
|
|
|
|
|
|
|
#ifdef DEBUG |
|
|
|
|
Serial.println(F("MIDI_DEVICE_USB_HOST_SERIAL enabled.")); |
|
|
|
|
Serial.print(F("MIDI_DEVICE_USB_HOST_SERIAL enabled")); |
|
|
|
|
if (userial.idVendor() > 0 && userial.idProduct() > 0) { |
|
|
|
|
Serial.print(F("(0x")); |
|
|
|
|
Serial.print(userial.idVendor()); |
|
|
|
|
Serial.print(F("/0x")); |
|
|
|
|
Serial.print(userial.idProduct()); |
|
|
|
|
Serial.print(F(")")); |
|
|
|
|
} |
|
|
|
|
Serial.println(F(".")); |
|
|
|
|
#endif |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|