[sdiy] Techniques for Multiplying MIDI Clock frequency?

Brian Willoughby brianw at audiobanshee.com
Fri Dec 24 01:19:52 CET 2021

On Dec 23, 2021, at 16:00, mskala at northcoastsynthesis.com wrote:
> On Thu, 23 Dec 2021, Brian Willoughby wrote:
>> Speed. So, while it's possible for some devices to "fall back" to Low
>> Speed mode, that should not be allowed for a USB-MIDI device. I looked
>> for this to be spelled out in the USB-MIDI 1.0 spec, but I couldn't find
>> anything quickly - it might boil down to the use of Bulk endpoints,
>> which aren't allowed for Low Speed, or perhaps just that USB-MIDI has
>> too many endpoints beyond what Low Speed allows.
> I think the bulk endpoint thing is sufficient to prevent any "fall back"
> of USB-MIDI to low speed.  Low speed devices only have interrupt and
> control endpoints.  USB-MIDI requires bulk endpoints.  Even if it might be
> easy to imagine ways of exchanging the same packets with an interrupt
> endpoint that would normally be transferred over bulk, there'd be problems
> to solve for which there's no obvious single right way to do it; and the
> resulting homemade protocol would be so far from the standard that you
> couldn't expect any existing hosts or devices other than your own to
> support it.

I think you nailed it, here. I had forgotten that Low Speed only allows Control and Interrupt.

> I don't think number of endpoints is actually a big deal here.  I'm not
> sure low-speed and full-speed actually have different numbers of endpoints
> allowed, and a very basic USB-MIDI implementation doesn't need many
> endpoints anyway.  A Roland UM-ONE in class compliant mode, for instance,
> only has three endpoints:  one bulk in, one bulk out, and the control
> endpoint.  I've certainly seen low-speed devices with that many endpoints
> (because separate endpoints for "boot" and "full HID" protocols), and I
> would expect that some low-speed devices with more exist.

Outside of the USB-MIDI spec, I saw one note that Low Speed allows a maximum of 2 endpoints *plus* endpoint 0, while another section of the same USB spec said that Low Speed allows a maximum of 2 endpoints *including* endpoint 0. So, I'm pretty sure that a device with 4 endpoints cannot be Low Speed.

In any case, there's a big deal in the main USB spec made about how Full Speed allows 16 endpoints compared to the vastly smaller number (2 or 3) for Low Speed. Part of the reasoning behind the design of Low Speed is to allow very cheap electronics with limited resources to be guaranteed to function as Device or Host for Low Speed operations

Your example of "boot" and "full HID" protocols probably involves multiple Interfaces. Although I don't recall whether Low Speed allows for multiple interfaces, it's certainly possible that the total number of endpoints could be greater when including all interfaces versus the number of endpoints in each single interface. I've never designed a Low Speed device, though, so there's a lot of potential restrictions that I could be missing.

I do know that multiple Interfaces are *required* for Isochronous Devices - like USB Audio Class - because there has to be a default Interface that has no active Isochronous endpoints. It's the action of selecting a non-default Interface that starts the Isochronous streams. But my first-hand familiarity with Full Speed Isochronous endpoint streams has perhaps no relation to whether Low Speed even allows for Interfaces.


> -- 
> Matthew Skala
> North Coast Synthesis Ltd.

More information about the Synth-diy mailing list