SD Card / SPI Assistance Needed

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

SD Card / SPI Assistance Needed

Jump to solution
1,192 Views
Thunder
Contributor III

Hi, I'm using an  HCS08LG32, running at 3.3V to interface with an SD card via SPI.  CLK frequency is at 4M, which is divided by 12 for the SPI SD card init sequence.  Most of the code is borrowed from that provided with the JM60 USB/SDcard demo.  I get thru the init() sequence most (by not all times) and get an error most of the time in writing the SD card.  I seem to be able to read the SD "most" of the time.  In the rare occasions that a write is successful, I can read back the numbers written.   I have the SW code as an attachment here.

Any suggestions welcome.

Labels (1)
0 Kudos
1 Solution
357 Views
Thunder
Contributor III

I finally located my problem, that being a typo in one of the SPI commands (writing SPIS instead of SPID in a line of code).  Everything working fine now.

View solution in original post

0 Kudos
1 Reply
358 Views
Thunder
Contributor III

I finally located my problem, that being a typo in one of the SPI commands (writing SPIS instead of SPID in a line of code).  Everything working fine now.

0 Kudos