Pi 4 as a MIDI hub thing!

Discussion of all things Raspberry Pi / Raspberry Pi 2 related

Moderators: khz, MattKingUSA

Post Reply
Posts: 1
Joined: Sun Oct 25, 2020 4:07 pm

Pi 4 as a MIDI hub thing!

Post by bendy »


I would love to be able to have a Pi 4 managing all my midi stuff, and seamlessly transferring/routing MIDI traffic over 5 PIN midi cables, USB, Bluetooth, WIFI, etc.

Does anyone know if this possible? A stupid idea as its impossible. Or somewhere in between.

Thanks for looking
Established Member
Posts: 167
Joined: Fri Jul 31, 2015 11:28 pm
Has thanked: 1 time

Re: Pi 4 as a MIDI hub thing!

Post by Baggypants »

Have a look at https://zynthian.org they have a kit which includes DIN midi, or you can build your own thing that uses the OS image which can do some midi routing and has qmidinet and rtp-midi. I used it only last week to route a DIN Midi keyboard to my new NTS-1 that uses a microusb connector.
Established Member
Posts: 8
Joined: Mon Mar 01, 2021 6:46 pm
Has thanked: 1 time
Been thanked: 1 time

Re: Pi 4 as a MIDI hub thing!

Post by rtmusic »



Auto Midi Connect
Auto connection of MIDI Devices (something like this is used in Patchbox OS)

*I have not tried this yet on Raspberry Pi - but it sounds close to what you might want to try:

Wireless MIDI:
CME Widi
Recently I picked up a CME WIDI Bud (USB) and CME Widi Master (Wireless MIDI Dongle) which work with Raspberry Pi. The WIDI Master is new and allows groups and connections with 4 devices.

RTP via Ravelox MIDI
RTP MIDI can be used to connect Windows, iOS, and linux devices over Wifi. I had success using my Raspberry PI to broadcast MIDI coming from an iConnectMIDI USB interface (connected to PI and a MIDI device) wirelessly to an iPad and a Windows DAW simulataneously for playback on different synths.

Here's a project for Raspberry Pi as a USB host/hub.


Patchbox OS
While Patchbox OS does not have direct features for a MIDI hub, it's a great image to explore any audio/midi project:
Established Member
Posts: 8
Joined: Thu Apr 23, 2020 5:43 am
Been thanked: 2 times

Re: Pi 4 as a MIDI hub thing!

Post by handsomegenius »

It's definitely possible. Raspberry Pi OS has a MIDI layer right in the kernel as part of ALSA so that bit is really easy. There are all sorts of tools that help you manage it.. I like Mido, though maybe something graphical is better if you're going to change it a lot.

Adding the MIDI port is a bit jankier. A DIN MIDI port is basically just some UART pins with a couple of bits soldered on, and you definitely have UART on the GPIO. The difficulty seems to be in setting it to the right baud rate.

If it were me, I'd just use the cheapest microcontroller I could find with UART pins at the correct board rate and just use it kind of as an interface, but it depends what you're comfortable with. There are folks who seem to know how to hack the UART clock in Linux directly but I am out of my depth with that.

The even easier thing to do would be to plug a MIDI interface into a USB port. The thing to be wary of is that when USB gets busy it can buffer MIDI messages. USB knows not to buffer audio streams, but MIDI doesn't get this special treatment.

My guess is that this might only come into play if you have audio and MIDI running over USB together, but even a very small amount of added latency can be annoying in music, especially if it's inconsistent. I'm not sure which models of Pi also run the Ethernet port over USB.

I realise I'm replying to an old post here, but maybe it's still helpful..
Post Reply