widdly Posted November 10, 2011 Report Share Posted November 10, 2011 Is it possible to add USB host support on the LPC17? I've seen some other LPC based projects on the web that have midi usb host features. I think the seq4lite would be great with one of those usb only mini keyboards like the akai lpk25. Quote Link to comment Share on other sites More sharing options...
TK. Posted November 10, 2011 Report Share Posted November 10, 2011 Do you have a link to an open source project which uses the USB host function for USB-MIDI? Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
philetaylor Posted November 10, 2011 Report Share Posted November 10, 2011 Not exactly free but there is the USBHostLite for LPC17xx http://ics.nxp.com/support/software/usb.host.msc/ The license seems to be a bit ambiguous. It says free to NXP customers for unlimited use with NXP LPC2000 and LPC3000 families but includes an LPX1768 example.... Phil Quote Link to comment Share on other sites More sharing options...
TK. Posted November 10, 2011 Report Share Posted November 10, 2011 It doesn't contain a USB-MIDI example - so, no "low hanging fruit" ;) Best Regards, Thorsten. Quote Link to comment Share on other sites More sharing options...
philetaylor Posted November 11, 2011 Report Share Posted November 11, 2011 Ah yes I missed the MIDI bit from your post TK! I'm not sure how USB Host MIDI would work though as it would need to support a number of different USB MIDI devices to be useful? I seem to remember this was discussed a few months ago as somebody was looking to do a commercial project with USB Host support.... Phil Quote Link to comment Share on other sites More sharing options...
widdly Posted November 11, 2011 Author Report Share Posted November 11, 2011 (edited) Unfortunately it's in japanese but this site is the one I was thinking of. It's based of the USBhostlite examples. http://www.rjblog.net/archives/2009/e000331.php translated... http://translate.google.com.sg/translate?hl=en&sl=ja&u=http://www.rjblog.net/archives/2009/e000331.php&ei=K5S8TtuDMKWH4gTO_ISABA&sa=X&oi=translate&ct=result&resnum=1&ved=0CB8Q7gEwAA&prev=/search%3Fq%3Dhttp://www.rjblog.net/archives/2009/e000331.php%26hl%3Den%26biw%3D1366%26bih%3D704%26prmd%3Dimvns There is source code included. The source code has a parser for the usb descriptors, checking if they are audio devices with midi streaming. Usbhostlite has an interrupt and a blocking function Host_ProcessTD that fills a buffer from the USB port. Other than the first byte, the buffer is written straight to a serial midi port. The example doesn't have any hotplugging implementation other than exiting if the midi usb is disconnected. There is a description of the first byte content in the USB midi spec, on page 16... http://www.usb.org/developers/devclass_docs/midi10.pdf I'm not sure on the hardware side but perhaps this post might be helpful in setting up the physical USB host port on the LPC1768... http://knowledgebase.nxp.com/showthread.php?t=2064 I would think class compliant USB-midi support would be the way to go. I imagine support for custom stuff would be a nightmare. Although support for the novation launchpad would be a neat way to add a BLM without all the soldering. edit.. Actually looking more closely at the code from the japanese site, it doesn't look quite right. The MIDI_ParseConfiguration function is never called. I'm guessing he must have modified the usbhostlite function Host_EnumDev to call MIDI_ParseConfiguration instead of MS_ParseConfiguration. Edited November 11, 2011 by widdly Quote Link to comment Share on other sites More sharing options...
flip Posted November 14, 2011 Report Share Posted November 14, 2011 I would think class compliant USB-midi support would be the way to go. I imagine support for custom stuff would be a nightmare. Although support for the novation launchpad would be a neat way to add a BLM without all the soldering. Oh wow, this would be the perfect use for my Novation Launchpad. It has only been collecting dust so far :) Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.