> From: Philip Pemberton > There's a decently-written startup procedure in the Renesas > MultimediaCard > product manual (most of what's said in the MMC manual still > holds for SD Cards > too, BTW). Basically: > > 1. Send 80 clocks with /CS inactive (high) Check, although the SD spec says with /CS low, I've tried it both ways. > 2. Make /CS active (low), transmit a CMD0 command -- note > that the card is in > MMC mode with CRCs enabled, so send the sequence > 40,00,00,00,00,95 [hex] Check. I can see it on the scope. Clocking data on the positive clock transition. > 3. Now the card is in SPI mode. Wait for an R1 response from the card. Ok, now what exactly does that mean? As I read the spec and the sample programs, after that CMD0 string is finished, you have to clock out one full byte (8 clocks) and then another byte, where the last clock should get a high from the card. E.g. it should return 0x00, 0x01 after the CMD0. > 4. If the R1 response is 0x01, proceed. If any other response > is received, > assume there's no card in the slot and either restart the > init sequence from > scratch, or display an error message on the device's LCD. I don't get past this point. I never see the 0x01. Further, I can pull the SDO line from the card high or low with a 100k resistor. I.e. it is never being driven. At all. No matter what. > You need to get the sequence right, otherwise the card will > just sit and play > dead. I wish I could get you a screen shot but his old unit doesn't do that except via an HPIB printer which I don't have. I am sending EXACTLY the right sequence. The only thing I can think of is that I need to send CMD0 more than once or that I need to keep clocking until it grabs the SDO line. > > -- > Phil. | (\_/) This is Bunny. Copy and paste Bunny > piclist@philpem.me.uk | (='.'=) into your signature to help him gain > http://www.philpem.me.uk/ | (")_(") world domination. I would add bunny to my sig line if he helped me solve this... --- James Newton: PICList webmaster/Admin mailto:jamesnewton@piclist.com 1-619-652-0593 phone http://www.piclist.com/member/JMN-EFP-786 PIC/PICList FAQ: http://www.piclist.com -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist