PaxInstruments / labwiz-board

A development board based on the STM32 series processors specifically targeting the STM32F103RxT series.
4 stars 2 forks source link

SD card resistors and inductor #24

Closed charlespax closed 7 years ago

charlespax commented 8 years ago

Are the resistors on the SD card the correct values? We use 10k resistors. screen shot 2016-07-15 at 14 03 13

The Olimexino board uses 100k resistors. They also use an inductor. Should we have an inductor? screen shot 2016-07-15 at 14 04 02

electrokean commented 8 years ago

The SD card physical layer specification doesn't seem to require any pull-ups, but they're clearly a good idea to avoid floating inputs on the STM32. I've used the Olimexino resistor configuration on my some of own designs without issue. Interestingly I just realised I think I left them off on a recent prototype based on the STM32F103, and didn't notice any issue. The inductor on the SD card power supply and bulk capacitance is a good idea to reduce fluctuations on the 3.3V rail during SD card operations, which can draw surges of current for short periods (write or erase). This provides filtering for the upstream 3.3V (e.g. ADC reference) as much as for the SD card itself. An 0805 ferrite and lower value capacitor may be OK when there is a sufficiently low impedance path from the power source, but could introduce problems when the battery is getting low, or device is powered off USB without a battery inserted, leading to data corruption or even card failure.

charlespax commented 8 years ago

From http://www.mikrocontroller.net/attachment/21920/SDHC_SDM04G7B7_08G7B7.pdf: screen shot 2016-08-23 at 13 31 00

From https://www.kingston.com/datasheets/SDCIT-specsheet-64gb_us.pdf: screen shot 2016-08-23 at 14 00 26

From http://www.nxp.com/documents/application_note/AN10911.pdf: screen shot 2016-08-23 at 13 41 31

From http://downloads.amilda.org/MODs/SDCard/SD.pdf: screen shot 2016-08-23 at 13 44 23

From http://www.digitalspirit.org/file/index.php/obj-download/docs/sd/SdCard-MMC-Controller_From_Intel.pdf: screen shot 2016-08-23 at 14 01 57

From https://www.renesas.com/en-in/products/software-tools/software-os-middleware-driver/dsp-numerical-software/wireless-lan--rtk5563000f00000sr.html: screen shot 2016-08-23 at 14 02 33

From http://www.analog.com/media/en/technical-documentation/application-notes/EE335_rev1.pdf: screen shot 2016-08-23 at 14 10 36

From http://learn.parallax.com/tutorials/language/spin/propeller-board-education-project-builders/sd-card-data-storage: screen shot 2016-08-23 at 14 12 59

From http://www.lydiard.plus.com/hardware_pages/sd_card.htm: screen shot 2016-08-23 at 14 14 47

From http://justanotherlanguage.org/content/tutorial_sd_card: screen shot 2016-08-23 at 14 15 18

See also

charlespax commented 8 years ago

Here is another reference design (http://electronics.stackexchange.com/questions/83263/micro-sd-card-power-circuit-failure). abv6x

Since things are working now I'm not going to implement this in revision 0.3, but will in a future rev.

charlespax commented 7 years ago

I've added 10k pullups to the CMD and data lines. Caps don't seem to be very popular, so I'll just skip those. screen shot 2017-01-28 at 13 26 16 screen shot 2017-01-28 at 13 26 22