USB Thumb Drive Development

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

USB Thumb Drive Development

694 Views
ericd
Contributor I

Hi all,

 

I've been trying to work with the Freescale USB stack for a thumbdrive application.  I've had decent success and using an example project for the MCF51JM128. I've been able to read and write from/to a thumb drive.  The problem is I want to incorporate the USB application into an existing project that is already at 70kB out of my 128kB limit, and the USB application itself is ~65kB!   I've spent a lot of time trying to break down the USB stack and derive something much more compact and very specific to thumb drive use, but haven't had much luck.  The USB stack is massive and complicated, and provides a lot of architecture that I don't see as necessary.  I was hoping that I would be able to find some guidance here.  Can anyone point me in the right direction to incorporate the USB application in a tighter, smaller, more efficient stack than it is?  Any help, guidance, or insight would be very much appreciated. Thanks!

 

Regards,

Eric

Labels (1)
Tags (3)
0 Kudos
3 Replies

518 Views
Dec
Contributor III

When I wrote our stack I started with the absolute minimum, ie just the ability to send/receive data to/from a usb device and built around that rather than trying to shrink something which was already far too big.

I also limited support to fat16 and fat32 due to license issues on exfat.

Ram use is currently 3K and flash 14K on 5301X.

0 Kudos

518 Views
ericd
Contributor I

Paul, would you be willing to share source code or at least your development method?  I would love to shrink the USB flash size to bare minimum.

I tried to approach from a bottom up method, but spent weeks just spinning tires.  I have about 3 years of embedded experience, but found USB development to be daunting, especially without a USB analyzer.  I read through all the appnotes I could find, but they really didn't help much.

I know a lot of the current freescale USB stack is unnecessary for the sole task of hosting a mass storage device, but trying to find and just the critical parts is a task I found impossible.

0 Kudos

518 Views
TomE
Specialist II

Good luck. I don't have any experience with the stack, but as far as "shrinking code", I've been doing that forever.

I'd suggest generating some memory maps and then sorting them in section size order. Then look for anything that makes you wonder "why is THAT taking that much room"?

Tom

0 Kudos