Discussion:
[LAU] Advice: solution to hookk up several USB-MIDI devices
Jeanette C.
2018-07-26 14:06:26 UTC
Permalink
Hey hey,
I have several keyboards now, which come with their built-in USB-MIDI
interface (four to be precise) and I have three more synths that need to be
connected to MIDI. For the latter I use USB-MIDI adapter cables. Alas, I also
have other USB devices, which need to be connected, not least my braille
display.

So, what would be the cheapest/best alternative to hook up all those MIDI
devices? A bigger USB-hub? Is it possible to have more than four ports on a
hub anyway?

Due to technical restrictions MIDI-chaining is no option.

All my devices have standard 5pin MIDI DIN sockets, so some kind of USB-MIDI
interface would be possible. Only two of the synth need to be connected as
inuts, all the other would only receive output (being modules).

What would be viable and inexpensive options to get all these device connected
to the computer?

Best wishes,

Jeanette

--------
* Website: http://juliencoder.de - for summer is a state of sound
* SoundCloud: https://soundcloud.com/jeanette_c
* Youtube: https://www.youtube.com/channel/UCMS4rfGrTwz8W7jhC1Jnv7g
* GitHub: https://github.com/jeanette-c
* Twitter: https://twitter.com/jeanette_c_s

Give me a sign...
Hit me Baby one more time <3
(Britney Spears)
David Kastrup
2018-07-26 14:25:54 UTC
Permalink
Post by Jeanette C.
Hey hey,
I have several keyboards now, which come with their built-in USB-MIDI
interface (four to be precise) and I have three more synths that need
to be connected to MIDI. For the latter I use USB-MIDI adapter
cables. Alas, I also have other USB devices, which need to be
connected, not least my braille display.
So, what would be the cheapest/best alternative to hook up all those
MIDI devices? A bigger USB-hub? Is it possible to have more than four
ports on a hub anyway?
Due to technical restrictions MIDI-chaining is no option.
All my devices have standard 5pin MIDI DIN sockets, so some kind of
USB-MIDI interface would be possible. Only two of the synth need to be
connected as inuts, all the other would only receive output (being
modules).
What would be viable and inexpensive options to get all these device
connected to the computer?
I use a Roland UM-4 myself which hooks up 4 Midi devices (actually, 4in,
4out) to one USB port (full-speed, so 12Mbps, USB1.1 speeds). Those are
reasonably cheap to get if you can find them on Ebay. If you want to
hook up several ones of those via a USB hub, make sure that this hub has
a separate "Transaction translator" per port so that a USB1.1
transaction from one Midi interface does not keep other transactions
from happening: the 12Mbps limitation should only be per Midi interface,
not per aggregating hub which can talk at 480Mbps to the computer. That
way you keep latencies limited.

I think that 8-fold Midi interfaces are rather rare, so you are likely
best off looking for the 4-fold ones.

Do not use the cheap Chinese Midi interfaces with a violin clef printed
on them: they garble SysEx messages. I am not sure they are even "full
speed".
--
David Kastrup
Clemens Ladisch
2018-07-26 15:45:02 UTC
Permalink
If you want to hook up several ones of those via a USB hub, make sure
that this hub has a separate "Transaction translator" per port so that
a USB1.1 transaction from one Midi interface does not keep other
transactions from happening: the 12Mbps limitation should only be per
Midi interface, not per aggregating hub which can talk at 480Mbps to
the computer.
MIDI's speed of 0.03 Mbps is less than one percent of the USB 1.1 limit;
the lack of a transaction translator does not matter at all (unless
other, high-speed USB devices are connected to the hub).


Regards,
Clemens
David Kastrup
2018-07-26 16:03:43 UTC
Permalink
Post by Clemens Ladisch
If you want to hook up several ones of those via a USB hub, make sure
that this hub has a separate "Transaction translator" per port so that
a USB1.1 transaction from one Midi interface does not keep other
transactions from happening: the 12Mbps limitation should only be per
Midi interface, not per aggregating hub which can talk at 480Mbps to
the computer.
MIDI's speed of 0.03 Mbps is less than one percent of the USB 1.1 limit;
the lack of a transaction translator does not matter at all (unless
other, high-speed USB devices are connected to the hub).
If we are aggregating 4 4-port interfaces used in two directions (USB
rates are half-duplex), we need 32 times the bandwidth. So we are
already at 1Mbps of raw data rate without any packaging. 90% of the
full-speed bandwidth can be reserved for isochronous transfers which
MIDI isn't.

Queuing theory tells us that independent events close to filling up a
given bandwidth tend to stack up, so in what order is a single
transaction translator going to schedule transfers? What will be the
effect on jitter? And events created by arrangers are not actually
independent: time codes and chord notes and drums are coming out
back-to-back.

You'll be getting to "nobody will ever need more than 640kByte"
territory sooner than you'll think...
--
David Kastrup
Clemens Ladisch
2018-07-26 17:09:36 UTC
Permalink
Post by David Kastrup
Post by Clemens Ladisch
If you want to hook up several ones of those via a USB hub, make sure
that this hub has a separate "Transaction translator" per port so that
a USB1.1 transaction from one Midi interface does not keep other
transactions from happening: the 12Mbps limitation should only be per
Midi interface, not per aggregating hub which can talk at 480Mbps to
the computer.
MIDI's speed of 0.03 Mbps is less than one percent of the USB 1.1 limit;
the lack of a transaction translator does not matter at all (unless
other, high-speed USB devices are connected to the hub).
If we are aggregating 4 4-port interfaces used in two directions (USB
rates are half-duplex), we need 32 times the bandwidth. So we are
already at 1Mbps of raw data rate without any packaging. 90% of the
full-speed bandwidth can be reserved for isochronous transfers which
MIDI isn't.
That would matter only if the isochronous device is connected to the
same hub. (Which might actually happen in case of an audio+MIDI
device.)
Post by David Kastrup
Queuing theory tells us that independent events close to filling up a
given bandwidth tend to stack up, so in what order is a single
transaction translator going to schedule transfers?
In practice, FIFO. Anyway, the delay would be too short to matter
(a single USB MIDI packet takes less time than a MIDI bit).
Post by David Kastrup
What will be the effect on jitter?
Smaller than the effect of having to wait for the next edge of the
31.25 kHz MIDI clock. And certainly much smaller than the effect
of scheduling bulk transfers in the next 1-ms USB frame.
Post by David Kastrup
And events created by arrangers are not actually independent: time
codes and chord notes and drums are coming out back-to-back.
Events for the same device will be merged into a single USB packet
(at least in Linux).


Regards,
Clemens

Ralf Mardorf
2018-07-26 15:07:50 UTC
Permalink
Post by Jeanette C.
Due to technical restrictions MIDI-chaining is no option.
You don't need to chain by MIDI thru from one to the other synth, you
could use a MIDI thru box, perhaps a friend could build one for you,
since it's not hard to do. If you aren't in a hurry, I should still
have a circuit diagram and a PCB layout, but I'm not willing to search
during the summer holidays.

There is just one exception, when a MIDI thru box isn't a good
solution. The latency of a single in to x thru doesn't matter at all,
but if a synth should receive a lot of data in real-time, pitch bend or
sysex (yes, it's not real-time data, but sysex often could be used in
real-time), this particular synth should get it's input from it's own
computer MIDI output. In my experiences one MIDI out should only be
used for a max. of 8 MIDI channels (better less), even, if just a few
events are transmitted, so I wouldn't build a MIDI thru box with more
than 4 outputs. IOW better connect several MIDI thru boxes to several
MIDI outputs of the computer.
Loading...