SAME70 HSMCI SD low data throughput

Go To Last Post
5 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello all,

I've been struggling with the SAME70-XPLD board to use the SD card through the HSMCI peripheral. The throughput i reach is about 420 kBps.
I have tried the ASF example code with about the same throughput (it was slightly slower in my memories) though most of my code is based on the example.
Im using FATFS on top of the HSMCI interface software but that doesnt seem to influence the transfer speed that much.

When looking at the signals on a oscilloscope it seems that DAT0 remains low for a while after each written packet thus indicating the card is busy (?) but that seems unlikely to me since this is a quite low write speed for a new 2018 SanDisk SD card. A screenshot of the scope is attached here brown is the clock (50MHz), red is the command line and yellow is DAT0. When DAT0 is high a new packet is being composed so that delay makes sense to me.
The Code is added to the attachments

Hope someone of you can help me, thanks in advance!

Greetings,
Willem

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Try using the demo from Atmel's START aka ASF4 via http://start.atmel.com, specifically the SD MMC Raw Example.  

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

The SD MMC Raw Demo from Atmel START seems to be the same as the ASF Demo that I already tried.

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I'm seeing speeds closer to 3.4 MB/s read, 3.2 MB/s write using the Atmel START raw demo, a SAM E70 Xplained board, and a 8GB SDHC card.

 

 

Download the attached zip file.  Inside is the unmodified START demo plus a new main.c file.  Import the demo project into Atmel Studio and replace the default main.c with the new one.  I added a 1 millisecond SysTick timer to the demo and the transfer rate calculations.

 

 

 

 

 

 

Attachment(s): 

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

I've tried your demo and i get the same results as you, so i will try to figure out the differences between the drivers.
thankyou!