View previous topic :: View next topic |
Author |
Message |
JayKay Guest
|
SD-card -> µC ->USB -> PC |
Posted: Fri Jul 03, 2009 3:59 am |
|
|
Hi everybody!
My problem is the following: My µC (PIC18LF4620) is getting data and writes these on a SD Card (1KB file, FAT). On the board is also a FTDI FT232, which connects the PIC and the mini-USB.
I'd like Windows to use the board via the mini-USB as a mass storage device, to access the file on th SD card.
As I got thrown in at the deep end, I don't have a clue. How do I tackle this problem? Is it very complex or are a few lines of additional code enough?
Maybe anyone of you had a similar problem. I'm using the CCSC compiler... Thank you in advance! |
|
|
andrewg
Joined: 17 Aug 2005 Posts: 316 Location: Perth, Western Australia
|
|
Posted: Sat Jul 04, 2009 11:42 pm |
|
|
The FTDI chip is serial-port only. It cannot do mass storage. You will need a new board design to handle mass storage.
The Vinculum (never used it myself) claims to support both serial port and mass storage.
Microchip have some source code on their web site that implements mass storage. It doesn't work with CCS, though. You'd probably also need to switch to a USB-capable micro. It would be more work to have both mass-storage support and serial port support available at the same time, if you need that. _________________ Andrew |
|
|
Guest
|
|
Posted: Mon Jul 06, 2009 7:45 pm |
|
|
Maxim just came out with a chip specifically for this - a direct SD card to USB bridge chip. MAX14500
Might be something to look into...
HTH - Steve H. |
|
|
FvM
Joined: 27 Aug 2008 Posts: 2337 Location: Germany
|
|
Posted: Tue Jul 07, 2009 12:27 am |
|
|
Quote: | The Vinculum (never used it myself) claims to support both serial port and mass storage. | Vinculum implements a host rather than a device interface.
Quote: | Microchip have some source code on their web site that implements mass storage. It doesn't work with CCS, though. | No C18 code can be expected to work with CCS without modifications. Nevertheless, the code can be ported. Or do you know of particular CCS C limitation that reveal when porting the said code?
Generally, implementing an USB mass storage device interface in an embedded system makes sense, if you intend a functionality, that isn't provided by a standard USB to flash memory or SD card bridge. The Microchip data logger project is a typical example.
But it's a complex project, not just a few additional lines of code. |
|
|
|