SD max size

I have run into an issue writing files to an SD card that is 32 GB. Works fine with a 2 GB.
The module doc says it should work but it doesn’t.

Is there a limit to the size of the SD?

No limit on SD or SDHC

Ok, if I use a 32 GB and write a file when I close it the spider will reboot. If I replace it with a 2 GB then it will work fine.

@ Gus - I should also say that I can read from it all day long. Its just writing and when I close the file it resets and I don’t see any error displayed in the debugger or on the t35.

it’s the card…

@ Brett - It works fine on windows.

How is your board powered?

Hooked up to ac power.

Doesn’t mean it’s not the card :slight_smile:

99% of issues ever mentioned here with SD cards is about power sensitivity of the card, usually they are drawing too much current and they hiccup. A different card is a different card, and behaves differently. Writing it elsewhere (where you have oodles of power at your disposal, like on a PC) also doesn’t really show anything. Gus will probably mention, if you want to send the card to GHI they will verify, but honestly, I’d just find a card that works and go with it…

@ Brett - I will find another card but what this tells me is that there is a design error in the sd interface.

Thanks for the heads up. I am going to look into this further and see if I can spot the actual cause. We shouldn’t have something flaky like this.

We’ve seen many problems in circuits where the EMX supplies power to the SD card, in the current design we supply the SD card directly from the 3.3V rail instead.
I have seen comments where adding a capacitor to the supply line from EMX to SD helped, did a little testing but nothing definitive from this.

@ C-Born - That was going to be my first try. Thanks for the input.

@ Cowboy - Well, I formatted the SD and the problem went away. So there is a bug in the driver somewhere that is blowing up. Before someone says anything, I agree checking the format is the right thing but the driver shouldn’t just blow up if the format isn’t right. An exception is the way to handle it. I’m sure it will show up again.