cancel
Showing results for 
Search instead for 
Did you mean: 

SDIO configuration stm32f429

Hello dear engineers,

I have gotten stuck in running SDIO on stm32f429igt6.

No matter how hard I have tried, I wasn't able to successfully use FATFS with SDIO and stm32f429igt6. My code is attached. the f_mount function with immediate force on mounting return fr_no_filesystem. I use SANDISK SD Card with 16GB formatted with FAT32. Any help would be appreciated. Neither KEIL nor CUBEIDE compiler show different behavior.

Furthermore, is it possible to run NTFS on stm32f429?

1 ACCEPTED SOLUTION

Accepted Solutions

hello

Here is the example code. I added DMA to SDIO and relative paths to FATFS. STACK and HEAP is just big , not studied0693W000006HJwgQAG.jpg

View solution in original post

12 REPLIES 12

Hello.

Is HSE crystal 25 MhZ? What board are you using?

.

Yes, the crystal is 25MHZ. I use a custom board.

I ported the code to 32F407VE by changing only the startup file in KEIL MDK (i changed also the device type) Both devices have the same pinout for SDIO)

The result was as expected. The SD 16GB sandisk, 8k cluster formated, mounted with no error.

Maybe is a hardware issue, pinouts, bad soldering, etc0693W000006HJRTQA4.jpg 

@Vangelis Fortounas​ Thank you for your follow up. Would you please check if the USB works simultaneously? I have configured the USB as to be in CDC class in my code, that is if you plug in the USB cable into your board and your PC, you'll see a serial port. If they work simultaneously, then it seems my board has some flaws within.

For some reason the CDC device couldn't enumerated with your code .

I tried with "fresh" produced code from my CubeMX and was OK.

I suggest to solve the problems one by one with special produced code for every issue. Update all cubes and firmwares and check also the errata sheet for possible limitations.

Well in my side every peripheral is working separately, but they dont do their job in cooperation. I wonder if it is possible for you to share your code?

hello

Here is the example code. I added DMA to SDIO and relative paths to FATFS. STACK and HEAP is just big , not studied0693W000006HJwgQAG.jpg

Dear @Vangelis Fortounas​ 

Your help is really really appreciated.

Now I have some more questions.

Have you been able to write on the 16GB Sandisk SD card on your stm32?

I also have been able to mount that, but not able to write on the disk, instead, I have been able to write on a 2GB disk. (I think this is the incomplete part of Chan FATFS library).

Anyway, another question is why didn't you enable using DMA template on FATFS Middleware part?

Hello

I can read an write to 16GB sandisk sd card. (look at the screenshot). FATFS ver=R0.12C Check the format of SD card or reformat it( usualy this solves most problems)

As for the DMA, i forgot to enable the dma version of diskio. But works fin if enabled also.