Jump to content
Sign in to follow this  
trossin

New Project Sd Card Interface And Web Sited Moved

Recommended Posts

My free website company killed off my site (after 2 years) so I have a new address:

 

http://www.tedrossin...cs/Pic/Pic.html

 

I uploaded my latest project which reinvents the wheel by interfacing a 5V PIC to 3.3V MMC, SD or SDHC cards and providing access to FAT12, FAT16 and FAT32 file systems with long filenames. I used BoostC version 7.05 with the large memory model (worth the upgrade!) so that I could implement a sector cache with simple C code. I also want to say that the type casting in BoostC worked very well so that I could cast sector data into 8,16 and 32 bit variables without it generating lots of shifting and data copying.

 

The section on the project has more details:

 

http://www.tedrossin...SDCardInterface

 

The example project is lacking some major features like being able to write the the card but if you have an application that just needs to read large files (<4GB) , what I have seems to work good enough. For example, if you are building an MP3 player or if you want to read a large list of screen coordinates to control a LASER vector display.

 

The example that I have on the web implements a tiny unix like shell that lets you examine the files on an SD card using the following commands entered through a RS-232 terminal.

 

 

ls will list the current directory (the attributes are listed as 3 letters drw. d is - for plain files and d for directories)

cd path will change the current directory to that given in path. For example: cd Zero 7/Simple Things

pwd will display the current directory path

cat filename will echo the file to the terminal window. Not a real good idea to do on binary files. For example: cat ../../TedDir/CBSDfileSystem.c

Share this post


Link to post
Share on other sites

Hi Ted, I did this almost 2 yrs ago using the first release of version 7. Might have been the beta release. There were still some type casting bugs back then and a few other problems, but I managed to get it working quite reliably, reading and writing very fast using SPI. The SB code was fast enough that only hardware limitations determined the top speed. 3 - 5v was tricky! I ultimately gave up supporting FAT 12 and 16 and just did FAT32 because none of my SD cards were that small anymore. It was kind of funny I learned that certain bugs can kill the card with no way to bring it back! I killed 2 cards that way! I'm overwhelmed with a work deadline right now but I would have fun sharing code with you in about 3 weeks.

Share this post


Link to post
Share on other sites

Join the conversation

You are posting as a guest. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...