Go Down

Topic: Can I Read/Write a standard SDcard(in a card reader)via the DUE Native USB port? (Read 1 time) previous topic - next topic


If so, how?
I wouldn't need to add a shield then....
- Thanks


Sep 15, 2013, 12:42 am Last Edit: Sep 15, 2013, 12:45 am by jtw11 Reason: 1
Not really, no - SD cards don't use USB for communication. <--- this is the important bit.

They use either SPI (a 3 +n wire data bus [where n = the number of SPI nodes on the bus]) or the full number of data pins on the card.

The SAM3X8E chip has a dedicated memory interface to deal with SD cards, that uses the data pins on a card. Or of course you can just use SPI - there are libraries for this, although I'm not sure they're supported by the Due yet.


Actually, this was poorly phrased.
I can buy a whole host of SD card reader/writers to connect an SD card via USB my Mac for cheap.
So some sort of USB/SDcard interface is going on there.
And I see that the Due has a USB interface as well.
can I make the DUE<->USB<->USB/SDcardReader<->SDcard path work via software, or do I need an SDcard shield?


Hello paseman,
You can read/write from/to a SDcard via the Due Native USB port. I've done that using the Atmel AS6 ASF example called "USB Host MSC FatFS", with a card reader and a 1.0GB SDcard (FAT).

It also worked with a Flash pen drive:

I believe that it doesn't matter the SDcard or Flash card you use. I have tested the code only with one memory device at a time. The only problem with this application is that, AFAIK, there is no ported code from Atmel Studio to Arduino. It is not hard to do it.

I started a thread some time ago:
I hope this help. Regards!


Ah, I see what you mean now - yes, as Palliser has said, this is possible.

Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131