Control Surface main
MIDI Control Surface library for Arduino
Loading...
Searching...
No Matches
MIDI_Pipes-Routing.ino

MIDI_Pipes-Routing

MIDI routing using MIDI_Pipes.

Bridges the USB MIDI interface to a Serial MIDI interface, and loops back anything it receives on the USB interface.

You can also use the MIDI pipes to route the input and output of Control Surface itself, not just the input and output of MIDI interfaces. This is demonstrated in the Dual-MIDI-Interface.ino example.

Boards: 🛈
AVR USB, Due, Nano 33 IoT, Nano 33 BLE, UNO R4, Pi Pico, Teensy 3.x, ESP32
void setup() {
midiusb >> pipes >> midiser; // all incoming midi from USB is sent to serial
midiusb << pipes << midiser; // all incoming midi from Serial is sent to USB
midiusb >> pipes >> midiusb; // all incoming midi from USB is looped back
midiusb.begin();
midiser.begin();
}
void loop() {
midiusb.update();
midiser.update();
}
The main header file that includes all Control-Surface header files.
A class for MIDI interfaces sending and receiving MIDI messages over a Hardware Serial port.
A class for MIDI interfaces sending MIDI messages over a USB MIDI connection.
Array< T, N > copyAs(const Array< U, N > &src)
Copy an Array to an Array of a different type.
Class that produces multiple MIDI_Pipes.