lpcware

SD card interfacing with LPC2364

Discussion created by lpcware Employee on Jun 15, 2016
Latest reply on Jun 15, 2016 by lpcware
Content originally posted in LPCWare by pratik_pimparkar on Wed May 27 23:24:58 MST 2015
Hi,
I am trying to interface an SDHC Sandisk 4GB card with my LPC 2364 processor.

I have detected the card and it goes into IDLE_STATE but I cannot get it out of it. The card does not take any instruction after CMD0. According to page 11 flowchart of "SDIO simplified specifications" from sdcard.org, I am writing CMD8 after CMD0. But this gives me a response of 0x05. i.e. it is in IDLE_STATE and the next instruction gives an ILLEGAL_COMMAND. I am sure the SD card is working properly in other devices. But according to this flowchart my SD card is unusable.

Could you please help me with this?

I have read all different forums and have read elm-chan's blog post but there does not seem to be good documentation for SDHC cards.

Please help me with this initialization.

Note: I am using SPI mode at 400khz and my hardware does not have any issues, I am getting all the signals on a Digital Oscilloscope.

Outcomes