Saturday 20 October 2018

memory - SDHC card, a microSD shield, and Arduino Duemilanove


I got a new microSD shield from LittleBird and am having some troubles with it.


I downloaded the sample library that it said to used, threw in a microSD card and expected it to work... It won't initialise for some reason, and I have done a bit of googling and can't see how to get it working. Everyone just say use this library, use that one.


Hardware




Is the SDHC card part of the problem?


I work off a Mac and even formatted the card on a Windows XP machine to fat 16, but still no luck.



Answer



I am adding a microSD card to my new '644 board to make a low-cost data logger. All my boards are 3.3 V, so I won't have the 5 V issues. I have tried three different libraries and none of these initialize the cards :( I have also tried three different SD and SDHC cards from two different manufacturers (all large capacity) and none initialize.


I have my logic analyzer on the board now, and I am reviewing the specification. It looks like the initialization procedure is different for the newer card. I am almost certain that the SDHC is different. There is no response to the initialization routine.


From a lot of googling I have found out the following:


NB: (I have not verified this information, only found it ;)





  • Using the resistor dividers to translate from 5 V to 3.3 V can be problematic due to loss of edge speed due to the series resistance. I am not sure how much edge speed is lost or how sensitive different cards are to this. Since this is not an issue for my 3.3 V board I wasn't worried.




  • If the I/O pins are not at 0 V when power is applied to the card the card may be startup in an unknown state. Unfortunately the datasheet does not mention if there is a software initialization procedure that can be used to reset the card to a known state.




  • In version 2.00 of the SD specification the initialization procedure changed. I am not sure if the libraries support these changes.




  • Some people have reported success changing to low-capacity cards. I was hoping to find a low capacity at the office supply store, but the smallest they had in stock was 2 GB. I am suspecting that it may not be the size of the card, but the age (since most smaller cards are also older cards).





  • SPI support is optional for microSD. I would be surprised if cards didn't support SPI since if is required for the other formats. I was hoping to find a list of cards that were known to support SPI, but I could not find it.




That is where I am at. Unfortunately I probably won't have much time to work on this during the week. My next step is to go through the specification and write a simple initialization function and verify the output on the logic analyzer.


No comments:

Post a Comment

arduino - Can I use TI's cc2541 BLE as micro controller to perform operations/ processing instead of ATmega328P AU to save cost?

I am using arduino pro mini (which contains Atmega328p AU ) along with cc2541(HM-10) to process and transfer data over BLE to smartphone. I...