[sdiy] MIDI parser
rsdio at audiobanshee.com
rsdio at audiobanshee.com
Wed Nov 15 00:37:04 CET 2017
I second Jay’s interest in seeing a (complete) list of available MIDI parsers. That would be quite interesting. We could even review them to see whether some have advantages or disadvantages.
The MIDI protocol is nowhere near as complex as USB. You won’t even find a single diagram that shows all of the USB protocol because it’s spread across several layers and is defined differently for different devices. USB-MIDI is actually different from USB Audio, for example. The one nice thing about USB is that you can ignore the many lower levels once they’re implemented, and then focus only on the top layer that you’re dealing with.
As far as USB libraries, you pretty much only have one choice for each chip, because the USB peripherals are not standardized - they are quite different for each kind of processor. So, you have to use the stack provided by the chip maker. I don’t really see it as a “choice.” At least I’m not aware of anyone providing an alternative USB stack that competes with the manufacturer’s own.
In contrast, the venerable UART peripheral is pretty generic. After setting up interrupt handlers for receive and transmit, you can pretty much run the same MIDI parser on every processor. Here’s where latency can be improved by customizing the parser to make the most of your hardware. And, since interrupts take time away from all other running code, writing your MIDI interrupt handlers in assembly can seriously optimize available CPU.
Brian
On Nov 14, 2017, at 3:34 AM, Jay Vaughan <ibisum at gmail.com> wrote:
> Complex State Machines are a *good* thing, if you're a software person .. ;) Paula is a hardware person .. don't pay any attention to her grumpy software claims!
>
> I'm yet to see anything that the very-well-written miby library can't handle, parser-wise, and I've tested it on tons of gear. Including most of the synths in my studio that Paula had anything to do with, lol .. ;P. (Vacoloco stuff, Monowave SYSEX dumps, etc.)
>
> (PS - it would be pretty interesting to have a complete list of available MIDI parsers from this group .. Neil J's might be my favourite, but I wonder how else one might do it..)
>
> j.
More information about the Synth-diy
mailing list