![]() |
Forum Index : Microcontroller and PC projects : SD Card Reader ignores some SD cards, works with others
Author | Message | ||||
k2backhoe Regular Member ![]() Joined: 04/12/2021 Location: United StatesPosts: 47 |
Does anyone else have this problem? I have 2 SD micro cards that always work and 3 (or more) that never work. I am using Wishiot SD Card Module from Amazon. I have repeated the problem on 3 of these card readers. I have repeated the problem with PicoMiteV5.07.00.uf2, PicoMiteV5.07.01.uf2, PicoMiteV5.07.03.uf2, and PicoMiteV5.07.04b1.uf2. I have repeated the problem with two different PI PICO cards. Wiring: SD Card RasPi Pico +5 volts VBUS, pin 40 and also repeated with 3V3, pin 36 GND GND, pin 38 CS, Card Enable GP15, pin 20 SCK, Clock GP10, pin 14 MOSI, Card Data In GP11, pin 15 MISO, Card Data Out GP12, pin 16 With a freshly installed MMBasic, I enter the following: > option reset > option system spi gp10,gp11,gp12 > option sdcard gp15 ***** Using a card that works I get > files A:/ 946 Servo Control Example.txt 0 directories, 1 file ***** Using any card that doesn't work I get > files Error : SD Card not found All cards are freshly FAT32 formatted with short text files loaded on them from my PC The 2 cards in the left column work, the three cards in the right column do not. Does anyone know why or can they suggest any tests I haven't tried? ![]() |
||||
phil99![]() Guru ![]() Joined: 11/02/2018 Location: AustraliaPosts: 2642 |
Some cards can be fussy about supply filtering. Your adapter has a 3.3V regulator for the card, identify the output filter cap and solder a bigger one on top of it. 10uF or larger if it will fit. Or perhaps the contacts in the reader don't have enough tension to make proper contact on some cards. Try a bit of sticky tape on the back of a card to get more pressure on the contacts. It's a long shot but easy enough to try. Other cards are just odd. I have one from a Canon camera that gives the same error the first time I type "files" but is fine thereafter. It does this on every type of MicroMite but perfect on computer or camera. |
||||
Volhout Guru ![]() Joined: 05/03/2018 Location: NetherlandsPosts: 5091 |
The SD card interface appears to have a level shifter from 3V to 5V. When operated from 5V it may overdrive the pi pico. I am not sure if this interface will work when powered with 3.3V. The voltage regulator may not supply enough voltage for the card when powered from 3.3V (maybe it outputs only 2.8V or 2.5V). The level shifter logic may not even work correctly when powered from 3.3V. The best SD card interface for the pico is one without any chips on it, just a capacitor (or direct wiring). Volhout PicomiteVGA PETSCII ROBOTS |
||||
Mixtel90![]() Guru ![]() Joined: 05/10/2019 Location: United KingdomPosts: 7938 |
Personally, I'd try a different uSD card adapter - one with "straight through" connections and no regulator. You can make the breadboard version just by soldering a bit of header strip onto a uSD to standard SD converter. The one that everyone has floating round in their junk box because it came free with something. :) If that doesn't work, add a PSU filter to the 3V3 line using 2R2 and 10uF to 100uF, possibly bypassed with 100nF. There are some little uSD breakout boards around on ebay that have a bypassed capacitor of about 33uF and 10k pullups on the data lines. No series resistors. They look promising, I've got some to try. Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
lizby Guru ![]() Joined: 17/05/2016 Location: United StatesPosts: 3378 |
I've had trouble with Lexar micro SD cards before. PicoMite, Armmite F4, SensorKits, MMBasic Hardware, Games, etc. on fruitoftheshed |
||||
al18 Senior Member ![]() Joined: 06/07/2019 Location: United StatesPosts: 228 |
The Wishlot microSD module is unusual because it requires 5v at the Vcc pin and has an onboard 3.3v regulator. None of the microSD modules I have scattered around the house have or need a 3.3v regulator. Get a different microSD module Edited 2022-02-15 04:06 by al18 |
||||
KD5ZXG Regular Member ![]() Joined: 21/01/2022 Location: United StatesPosts: 53 |
Tried this yet? Solder pins to an adapter, not a live card. ![]() There is a slot for microSD here, though can't see it... Edited 2022-02-15 06:32 by KD5ZXG |
||||
k2backhoe Regular Member ![]() Joined: 04/12/2021 Location: United StatesPosts: 47 |
Wow, thanks forum. Many things to try. First is using the SD to SD-micro adapter as in the photo by KD5ZXG. Looking thru the literature I think the wiring I want is (pins labeled 9,1,2,3,4,5,6,7,8 from the notched corner to the write protect slider) pin 9- unused pin 1- unused pin 2- CS [GP15, pin20] pin 3- MOSI [GP11, pin15] pin 4- VDD (3.3V?) [pin36] pin 5- SCK [GP10, pin14] pin 6- Ground [pin38] pin 7- MISO [gp12, pin16] pin 8- unused NO in line resistors, NO filter capacitors. I wired this up twice and neither time did I get anything but "Error : SD Card not found". Am I making a stupid mistake? |
||||
phil99![]() Guru ![]() Joined: 11/02/2018 Location: AustraliaPosts: 2642 |
On the photo in KD5ZXG's post the 7 header pins are, left to right:- _1__2_____3___4____5___6______7 CS, MOSI, Gnd, 3.3V, SCK, unused, MISO Edited 2022-02-15 10:15 by phil99 |
||||
k2backhoe Regular Member ![]() Joined: 04/12/2021 Location: United StatesPosts: 47 |
Aaaaaaaaaaaaaand now everything works!! Using phil99's wiring and KD5ZXG/Mitel90's modified adapter card. Thank you all for the help. 6 of 7 SD cards work, the only one that fails is a 128GB card which should fail as this system supports only up to 32 GB (only FAT formats). Edited 2022-02-15 11:34 by k2backhoe |
||||
Grogster![]() Admin Group ![]() Joined: 31/12/2012 Location: New ZealandPosts: 9610 |
Great news you got it working. ![]() Yes, SOME of those SD or micro-SD cards can be a bit picky about their power supply as you have just found out. I tend to opt for the 'Standard' arrangement for SD cards now on any board I do - the 2R2 series resistor feeding a 10uF + 100nF caps in parallel, that then feeds the SD card. You never seem to have problems or hiccups in the firmware using that arrangement. Without them, SD cards can be unstable. My guess is it is simply the noise factor introduced on the card contacts as it slides in and out of the socket. This can generate enough mechanically-induced noise as the card contacts slide onto and off of the socket contacts, that the card can be powered and disconnected several times during the time it takes you to push the card in or take it out. That can confuse many a card controller chip, so they fail to talk when asked. The little RC filter on the card power supply line, stabilizes that voltage just long enough that you don't have that issue and the power to the card remains 'Clean' during insertion or removal. Just an educated guess - I could well be wrong, but that seems logical to me as a cause. Smoke makes things work. When the smoke gets out, it stops! |
||||
![]() |
![]() |
The Back Shed's forum code is written, and hosted, in Australia. | © JAQ Software 2025 |