Sporadic SDMMC_ERROR_CMD_RSP_TIMEOUT using FatFS + SDIO + DMA
Hi all,
I am trying to write to SD Card through SDIO interface with DMA (1 data line) on a STM32F4 MCU on a custom made board. Configuration is done by CubeMX.
When writing to one file at a rate of 200kBytes every 10 seconds, after some time (one minute to ten minutes), the driver fails in SDMMC_GetCmdResp1() (file stm32f4xx_II_sd.h) with error code SDMMC_ERROR_CMD_RSP_TIMEOUT.
Following fixes have been tried out without success:
- Lowering the clock speed from 45MHz down to 1.4 MHz
- Increase the timeout in SDMMC_GetCmdResp1() from 1ms to 100ms
- Enable SDIO HW flow control
Has anyone experienced this issue? Is there a workaround?
Thanks and best!
