SD card adapter bought on ebay

I bought an SD card adapter on ebay but could not get it to communicate with my Arduino Mega2560 using the Arduino IDE 1.0.1 "CardInfo" sketch. The adapter has "http://www.lcsoft.net" and "LC STUDIO" printed on the back.

I made an accidental breakthrough. To make a long story short, there is apparently something wrong with the labeling and/or wiring of the voltage supply pins on the adapter. The pin labeled "+3.3v" on the adapter must be jumpered to Arduino pin "+5v".

From top to bottom on the adapter:

adapter pin <--> Arduino pin
GND GND
+3.3v +5v
+5v *nothing
CS pin 53
MOSI pin 51
SCK pin 52
MISO pin 50
GND *nothing

So far, I have only tried two older SD cards (no SDHC cards) and both work. One is a 512MB SanDisk card, the other is a 512MB SanDisk Ultra II card.

I get one of the following outputs in the Serial window with the three other supply voltage combinations (+3.3v <--> +3.3v, +5v <--> +3.3v, +5v <--> +5v):

Initializing SD card...Wiring is correct and a card is present.
Card type: SD1
Could not find FAT16/FAT32 partition.
Make sure you've formatted the card

Initializing SD card...initialization failed. Things to check:

  • is a card is inserted?
  • Is your wiring correct?
  • did you change the chipSelect pin to match your shield or module?

You can not feed 5V to an SD card, you will fry it. Nothing above 3.6V max. You need to add a level converter, or a hex converter between all the signal lines since on the Arduino side they're all 5V, but on the SDcard side they're 3.3V. I use SFE's logic level converter to pass the signals through:

DO -> TXI (CH1) on LV side -> TXO (CH1) on HV side -> MISO
GND -> GND
SCK <- TXI (ch2) on LV side <- TXO (ch2) on HV side <- SCK
VCC <- 3.3V
DI <- RXO (CH1) on LV side <- RXI (CH1) on HV side <- MOSI
CS <- RXO (ch2) on LV side <- RXI (ch2) on HV side <- pin 4

The card itself won't like 5V but my guess is that the 5V pin on the adapter is the 5V input to a 3.3V regulator on the adapter card and that the 3.3V pin is an output. There does appear to be a regulator on the board.
Wire the 5V adapter pin to the Arduino 5V and leave the 3.3V pin unconnected.
If this doesn't work, it may be because you've fried the card while you were playing around with the voltages so try a card that you know is good.
Also, if it fails, use a meter to measure the voltage on the 3V3 pin. If it's 3V3 you've still got a working board.

Pete

If the card has both a 5V as well as a 3V3 pin, they are generally both inputs the 5V is input only, the 3V3 can be either: an output when you're feeding 5V, or an input when you're feeding 3V3. If you only have 5V, then you feed it to the 5V pin. If you have 3V3 available, then you feed it to the 3V3 pin. However, you still need to protect the signal lines between the Arduino and the card reader itself. A better option is Adafruit's breakout which incorporated a hex buffer on the signal lines.

Hey !
i was the same problems, and i have solve it with a CD4050 :

a basic interface for 5v -> 3.3V conversion and work perfectly :wink:

we can find 10 CD4050 for 3$ with ebay

timiti29

Thanks for all of the responses. FWIW,

  1. I've attached a photo of the board; I purchased it from "TxHang Electronic" on ebay - http://stores.ebay.com/TxHang-Electronic/_i.html?_nkw=170895501953&submit=Search&LH_TitleDesc=1&_sid=1103958046.
  2. Here is a copy/paste from the ebay product listing:

Description: (We only provide high qulity products,please choose us.)

1.Brand new and high quality.

2.SD Card module can make your SD application more easier and simple.

3.It is easily interfaced as a peripheral to your arduino sensor shield module.

4.Through programming, you can read and write to the SD card using your arduino.

5.Can be used for SD Card more eaisly, such as for MP3 Player, MCU/ARM system control.

6.All SD SPI pins output, MOSI, SCK, MISO and CS.

7.Support 5V/3.3V input.

8.Size:5.1cm x 3.1cm - 2.01inch x 1.22inc

Yeah, it supports 5V or 3V3 for power, but the signal lines are not 5V tolerant ... there's nothing on there that corrects that. You need a level converter on all the signal lines. Something like a TXB0104 (or TXB0108). Earlier I suggested this level converter as well, however after more testing I found out it's really slow and hinders fast SPI communications. In order for that to work on an SD card, I had to slow down the SPI data transfer rate considerably. I've since switched to an TXB0108 and can now run SPI at full speed reading/writing to an SD card.

Thanks, KirAsh4. I'll put a TXB0108 board on my next Adafruit order.

This is how i have mine connected. As you can see I'm only using 4 channels and have the other 4 for future use.

I too have 1 or 2 of these "old" Full size SD adapters ..... from LC studios. Never used because of the 3.3V issue =(
Feel cheatet as it needs level converter. I bought one, but it had only 2 channels :frowning: - so perhaps I should use 6 resistors?

Well, guess its more easy to go for the new one with level converter on it - as they cost only $2 on ebay.

I have one of those, and it works fine with 5V supply and 5V on the signal lines.

I have one of those, and it works fine with 5V supply and 5V on the signal lines.

The LC Studio modules do work with some SD cards. I have checked several cases where cards work. The card draws a lot of current on the 5V signal lines which may not good for the card or the Arduino The Arduino can only supply enough current to reach about 4 V on the signal lines.

The card input lines should not draw current so I think the excess current is due to input protection devices in the card.

Not a desirable condition.

fat16lib:

I have one of those, and it works fine with 5V supply and 5V on the signal lines.

The LC Studio modules do work with some SD cards. I have checked several cases where cards work. The card draws a lot of current on the 5V signal lines which may not good for the card or the Arduino The Arduino can only supply enough current to reach about 4 V on the signal lines.

The card input lines should not draw current so I think the excess current is due to input protection devices in the card.

Not a desirable condition.

Mine is an SD breakout board bought from China on ebay for £1. Spent several hours trying to resolve the problem.

There is no need for any level converters. If the Arduino sees the card connected properly but you get the error "Could not find FAT16/FAT32 partition, simply connect the 5V Arduino supply to the 3.3V input pin on the SD board and the problem is solved.

Also, the MISO and MOSI labels on the SD breakout are labels for the Arduino board not the SD Card.
So, MOSI on SD board goes to MOSI on Arduino; MISO on SD Board goes to MISO on Arduino NOT the other way.

Just had my breakthrough a couple of minutes ago and I've written multiple data to my SD Card and successfully retrieved it.

:slight_smile:

@kreativ: If your Arduino is the same device as in your other post, you are using a Due. The Due is a 3.3v device. Most Arduinos are 5 volt signal, and do require a level converter.

edit: My bad. The other post does not say you are using a Due. Some cards are more sensitive to 5 volts on the data lines.

kreativ:
There is no need for any level converters. If the Arduino sees the card connected properly but you get the error "Could not find FAT16/FAT32 partition, simply connect the 5V Arduino supply to the 3.3V input pin on the SD board and the problem is solved.

Do NOT do that!

kreativ:
Also, the MISO and MOSI labels on the SD breakout are labels for the Arduino board not the SD Card.
So, MOSI on SD board goes to MOSI on Arduino; MISO on SD Board goes to MISO on Arduino NOT the other way.

The labels are correct - for the Arduino AND for the SD card module. MOSI/MISO is not like TX/RX where you must connect the opposite pins. MOSI is Master Out - Slave In and MISO is Master In - Slave Out so you must connect MOSI to MOSI and MISO to MISO. µC is a master and an SD card module is a slave.

kreativ:
Just had my breakthrough a couple of minutes ago and I've written multiple data to my SD Card and successfully retrieved it.

:slight_smile:

You were lucky but you you did it wrong because you connected 5V to some of the SD card pins. The simplest solution for these modules without level shifters is to connect SCK, MOSI and CS through the reverse polarized diode as shown here. That is possible because there are pull-up resistor connected to the output of the 3.3V regulator on these modules. When Arduino sends 5V the diode is off and the SD card gets 3.3V from the regulator. When Arduino sends LOW, the diode is on and the SD card gets LOW. Or you can use the 3.3V output to power the level shifter (e.g. 74HC4050).

I am aware this thread is old but the info is misleading and could cause damage to the SD card connected to 5V.