USB device development - Coldfire M5475 - helpful hints?

Can anyone give some helpful hints, starting points, or maybe (one can hope!) sample code, which will be useful in implementing some kind of USB (device) interface on a Coldfire MCF5475EVB?

Currently the device communicates via serial - simple commands sent in and progress/log data returned. Log data can be 1.5MB to 60MB in size (usually the smaller end) and we wish to speed up the data transfer process by using USB. Development is native code, written in C, built with m68k-elf tools, and CodeWarrior.

Someone has suggested using USB CDC (Commucations Device Class) as the PC end (Windows) shouldn't need any custom drivers. What that means in practice with regard to the device end, I'm unsure.

I have the Coldfire reference manual - however not having done any USB development before, only a little embedded experience, and being faced with about 70 USB related registers - it seems a very daunting task.

So - has anyone got any hints as to where to start, what to read, or anything?

Many thanks,

David

Reply to
David Hearn
Loading thread data ...

Well, if you haven't already, you should definitely read the USB specification, at

formatting link
. That page also has a link to the page with all the device class specifications on it.

I'd suggest finding some example code for your MCU which shows how to respond to enumeration and provide device descriptors to the host. (This is the process that happens when the USB device is attached and the host queries it to find out what class of device it is.) Enumeration is pretty much the same for any USB device so it should be a good starting point.

Depending on what your host software looks like, you could use the CDC (serial port emulation) or you could talk directly to your device using something like libusb (or libusb-win32 since it sounds like you're on windows:

formatting link
)

HTH!

--
   Wim Lewis , Seattle, WA, USA. PGP keyID 27F772C1
Reply to
Wim Lewis

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.