Connecting an SD card to the daisy seed


I’ve asked a few questions on Discord already, but despite all great advise, I have not gotten the SDMMC example to work yet. I already bought a new SD breakout board and a STLINK-V3MINIE to troubleshoot, and got some more info now. While trying to get this work, I’m documenting the steps i’m taking so that this could maybe be included in the Daisy wiki. I think many people will benefit from a ‘how to’ guide on connecting a SD card.

I’m currently testing using a SanDisk Extreme 128GB V30 U3 A2 microSD. Not sure if there are any requirements on a specific card type or max. storage. If anyone knows this, please let me know.

I’m using the SDMMC example from the DaisyExamples repository as a starting point. I’ve added a line to the example to slow down the SD card, as I’m using breadboard wires. This line is as follows;

sd_cfg.speed = daisy::SdmmcHandler::Speed::SLOW;

I’ve also added a breakpoint at the line that is as follows;


When the executer is at this line, I step into and step over until I reach the line that is as follows;

if (res == FR_OK)

When I hover over “res”, I get the following statusses;

FR_DISK_ERR: probably “SD card was not found” (I get this as soon as I eject the SD card from the breakout board, so I think this is a good sign that the SD card is at least detected)

FR_NO_FILESYSTEM: according to some internet docs I believe this means “SD card was found, but appears not to be formatted correctly”. I had this with both FAT and ExFAT, formatted using Mac.

I’m formatting the SD card using a mac, and i’ve tried both ‘FAT’ and ‘ExFAT’. Both result in the “FR_NO_FILESYSTEM” errormessage.

Any guidance would be amazing, and I will continue to document my steps until I hopefully get it working :slight_smile:

Update; now I’m unsure if the ‘slow’ configuration of sdcard is necessary. In both configurations I seem to get the “FR_NO_FILESYSTEM” error.

Hi Laurens!

This was posted as a response to your post on Discord:

“So ive done this a while back. And you can check my code out at: GitHub - nopjne/DaisyDrive64
I have at some point also updated the ffs-lib in lib daisy as the old version had issues understanding non mbr fat partitions.
That all aside I see you are running a single wire sdio, I think you need the correct setup selection for that. I see your pullups, which will just introduce ringing. You may want to use internal pullups but will need to change lib daisy. Slow mode should be good, as an initial step. You are also missing a key tool in all this: a logic analyzer. It was invaluable when I did this.”

Let me know if you’re still running into issue, and I would be happy to have a closer look :slight_smile: