DMA microSD

30 Oct 2014

Hi,

I'm new with the mbed platform. I need to write on my microsd card really fast and writing block by block is not fast enough. So I'm thinking about using DMA and trying to write bytes. I'm really lost, so if anyone could initiate me with DMA or join me... I'm looking for information on how DMA works, useful libraries, any helpful information you consider...

Thanks.

30 Oct 2014

HI,

please use search funcitonality, there is DMA specific library for LPC1768 for example, which you might use. Officially there's no DMA support in the mbed lib, neither interrupt driven SPI. But there are user's libraries which you can leverage.

Regards,
0xc0170

30 Oct 2014

There is both SimpleDMA and MODDMA which can do DMA on the LPC1768.

However while DMA is great to be able to do other things while DMA is for example running SPI in the background, it will never be actually faster than just software driven SPI.

30 Oct 2014

well, first of all do you know how fast could I write?

I used Timers to measure times and right now every block of 512 bytes takes 1500 us. I need to be around 10us/byte.

03 Nov 2014

The SD filesystem SPI clock rate can also be increased (with or without DMA) , See http://developer.mbed.org/forum/repo-49299-SDFileSystem-community/topic/5243/ for more info about this idea. Not sure what the max is and it also depends a bit on the SD card type.

http://developer.mbed.org/users/neilt6/code/SDFileSystem/ has another version that seems to be faster than the one in the handbook.