Skip to content

Portenta H7 /GIGA R1– SPI write to SD card stuck at ≈1.3 MB/s. Any easy way to speed it up? #1066

Open
@paji66

Description

@paji66

Hi,
I am storing data to an SD-card over SPI with Portenta H7. Running the SdFat “bench” example I only reach about 1.3 MB/s write speed.
I expected more: e.g. the Arduino Due in the SdFat README shows ≈3.9 MB/s, and a forum post in 2023 reports the same ceiling (1763.56KB/Sec) on the GIGA R1 (link:https://forum.arduino.cc/t/sdfat-tests-on-giga-r1/1198629/1).

Test setup
•Arduino Mbed Portenta Boards 4.3.1
• Arduino IDE 2.3.5
• Library: SdFat 2.3.0 (via Library Manager)
• Sketch  : SdFat → examples → bench (edits in SdFatConfig.h →#define USE_SPI_ARRAY_TRANSFER 1
#define ENABLE_DEDICATED_SPI 1)
• SPI clock : tried 50 MHz and 60 MHz – speed barely changes
• SD card  : 32 GB “Raspberry Pi” (Class 10, U3, V30, A2)

Questions:
Is there a simple configuration change (like enabling DMA) that can improve the SPI write speed?
Is this a documented limitation of Mbed OS's SPI implementation?

As I have limited experience with embedded systems, so step-by-step instructions or links would be greatly appreciated.
Thank you for your time and assistance!
Best regards

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions