I need to split a usb midi signal (pass through is awful) and I came across this tutorial,
I thought it should be possible to use the arduino usb midi host function and instead of sending output to a midi din 5pin plug, sending the midi to two midi usb converters to act as devices I can connect to.
This is my first arduino project, I’m really not sure how to get the midi from the arduino to the two converters, I’m not sure the arduino even needs to translate the usb midi to din, it might work better if I can just connect the usb side of the converter pcb to the arduino, so they’re receiving signal and can output it. Hopefully this sketch makes it clearer if my description is terrible.
Alternatively if it’s simpler than figuring out how to make the converters work, I also have a couple of usb B ports, so I thought if the arduino can just take a usb midi signal, send it to the two usb ports then its a simple one in two out.
So I have a goal in mind, a kind of vague understanding that the ard can do it, but as to how specifically I need some expertise please
I think the starting point is realising that MIDI is just a serial protocol, originally at about 52KHz, and that each in/out/thru connection is a separate serial connection. Because MIDI is a real time protocol, latency should be avoided, so introducing delays and buffering will adversely affect the final MIDI performance.
Hope this helps.
Yeah so simpler is better, the converters could add latency. Can I connect the two Usb B ports and just tell the arduino to send the signal to both?
Beyond suggesting fewer serial connections to avoid latency I’m not sure what you’re saying needs consideration? Is the issue using an arduino to duplicate a real time serial protocol?
Can I get any further advice on how to do this?
OK so here’s attempt one, both data and reference voltage linked to the midi usb pcb via 220ohm resistors
Though I was just prototyping by wrapping the wires and one came off in the pic.
Basically I have something built,
From here I figure I want to, confirm the arduino is working with my midi device, which I think I’ll do with a multimeter on the tx pin?
Unless there are some obvious lights meant to come on whenever the ard is processing.
I’m going to point you to a project which should cover what you are doing, and help you along a bit.
Thanks Robin, I appreciate your help.
This is probably something I should have put more effort into learning before diving in.
A guy I spoke to on the phone the other day was really helpful too. If worst case the arduino struggles to work with my piano due to the 3.3v logic, I do have midi input stable on the raspberry pi.
As suggested (I don’t remember his name sorry) I could add lines to the midi led control on the pi to output midi serial via GPIO, then do the same circuit into the usb midi pcb. I’ve just gone with the arduino dedicated device idea as my coding knowledge is even less than my circuitry, no clue there either. But I’m learning, so thanks
I guess I’ll close this for now,
The issue was having midi routed to both the laptop and the pi zero, the piano visualiser developer suggested just linking two midi usb converters together, so now I have this frankensteinish cable, I couldn’t get the pi to send midi, but it works on pc sending in.
It’s actually more useful this way as the pc in the middle means I can learn songs from software, whereas using the arduino the pc wouldn’t be sending to the pi.
So now I just have to figure out what I want my arduino usb host to do,so many sketches I’ll find a use for it.