Hello, I’ve recently received 5 sample PCBs based on the Fez Cerb design but with only 2 of the Boards is the Micro SD socket recognised, the other 3 I get an error when trying this line of code "
", I don't know whether it's a fault with the board or whether my code could be better, I've formatted the Micro SD as FAT32 - 4KB, see photos for more. I'm hoping it's a software issue as I'll not have to send the boards back
Yes, I suspected that, I had the board made in China but had the MCU installed with a local company, is it likely that the MCU installation maybe the issue as I can’t imagine that installing an SD Socket would be complicated
Have you try to enhance power supply? it seems you are powering the board using USB. Try a powered USB hub or cut a usb cable to inject 5VDC from a power enough source (7805 or better as recom r78B innoline series). The cap can also do the trick, it’s a good design tip to add pads for such caps in your design .
Okay, I’ve done a continuity check, all SD pins that I can access seem to be correctly connected to the associated MCU pins, the only thing I could see was that R10 which is shown as 4.7K is actually 800Ohms
As Gus said, you have don’t appear to have any supply decoupling close to the VCC and GND pins on the SD card. This is a must. Try somehow adding a 0.1uF across the VDD and GND pins close to the SD card and it should work.
Is this not already taken care of, on another location on the Schematic there are Capacitors connected between VCC and GND, or would an extra Capacitor connected close to the SD VCC/GND pins make the difference, see attached to see what I mean
Thanks but this post link if I’m correct in thinking is referring to the importance of using a Capacitor for SD of certain classes, I get the code exception as shown earlier even without an SD Card inserted??
I’ve sent the troubled boards to my engineer abroad, as the code is throwing an exception at the sdCard.Mount() code call, he wants to know what exactly is happening inside the Mount method in order to help us figure out what the issue is. I’ve tried looking at this methods implementation but it’s part of a dll, I had a trial version of .Net Reflector but it’s expired now. Does anyone have any snippet of code which I can run which does what Mount() is doing, it should help me get closer to determining the root cause.
public void Mount()
throw new ObjectDisposedException();
throw new InvalidOperationException("The device is already mounted.");
this.mounted = true;
And as you probably know, native calls = black magic
Yea that looks like black magic for sure, I was hoping that it was just some setting of a Pin to Hi/Low that would latch onto the SD Card thus mounting it, for my project the SD Card will always be inserted.