USB MIDI, am I headed down the right path?
Posted: Mon Sep 29, 2014 1:14 am
I took all the SerialIUSB code out of the example, modified by board.h for using the pins I am using, used the define to tell it not to look for sense (using A9 for something else) and was able to successfully see the Serial device and usbmodem.
Second step was I found a device configuration example that defines and audio/midi interface. Used that instead and sure enough, shows up as a class compliant MIDI device.
HOWEVER,
After looking through the MIDI spec on USB, it looks like I have to arrange my messages into 32-bit packets whereas I think the SerialUSB system might be sending it as 8-bits at a time?
It would seem to me that I need to abandon the SerialUSB code and work on the regular USB driver. Does this sound correct? Also, any pointers on example code to get me going down this path?
As in the subject, I am trying to use the STM32 to send and receive MIDI data over USB as a class compliant device.
Thanks!
Rick
Second step was I found a device configuration example that defines and audio/midi interface. Used that instead and sure enough, shows up as a class compliant MIDI device.
HOWEVER,
After looking through the MIDI spec on USB, it looks like I have to arrange my messages into 32-bit packets whereas I think the SerialUSB system might be sending it as 8-bits at a time?
It would seem to me that I need to abandon the SerialUSB code and work on the regular USB driver. Does this sound correct? Also, any pointers on example code to get me going down this path?
As in the subject, I am trying to use the STM32 to send and receive MIDI data over USB as a class compliant device.
Thanks!
Rick