I have a Nano-based project that reads and writes to a micro SD card on a custom board. This project was migrated from a MOD5234-based one on a different custom board that used an SD (not micro) card in SPI mode. The board for the Nano project was designed for 4-bit SD mode. My understanding is that the NNDK (2.6 is what I have) doesn't have a driver for the fast SD mode but it should still operate in SPI mode. I don't believe much (if any) of our file IO code has changed between the two projects.
The problem is that IO appears to be significantly slower on the Nano-based hardware. Calling f_format() on a 4GB Class 4 microSD card takes upwards of 2 minutes, where the same call takes 17 seconds for a 2GB SD card on the MOD5234 hardware. I realize that's a card half as big, but it still doesn't seem like it should take that long. I've also seen consistent writes of a ~40KB file take around 17 seconds on the Nano hardware and 4 seconds on the MOD5234.
Does anyone know why it's so slow, or can suggest what to look at?
Thank you
SPI SD card is very slow with Nano
Re: SPI SD card is very slow with Nano
Have you tried a speed test on the netburner nano dev board? Would be good to rule out any issues on your custom board. Could be noise, coupling, etc.
-
- Posts: 27
- Joined: Thu Jun 27, 2013 8:30 am
Re: SPI SD card is very slow with Nano
Good suggestion. Turns out it works great on the NetBurner board - file write takes about 2 seconds and f_format() about 34, which makes sense given the 17 seconds for the 2GB SD mentioned earlier. Looks like it is the custom board. Thanks!