Skip to main content
Associate
April 2, 2026
Solved

[STM32H573IT] I can't FATFS in CubeMX.

  • April 2, 2026
  • 2 replies
  • 527 views

Hi Everyone,

I need your help.

I use STM32H573VIT but I can't FATFS in CUBEMX.

I checked FILEX, SD interface. But CUBEIDE say fatfs.h : No such file or directory.

 

Please help me out..

Thanks,

kadekade

 

스크린샷 2026-04-02 190445.png스크린샷 2026-04-02 190521.png스크린샷 2026-04-02 190559.png스크린샷 2026-04-02 190628.png

Best answer by Mahmoud Ben Romdhane

Hello @kadekade 

Further to your comment, I tested again with the Ioc.File provided through the attachment and the build was finished without any errors.

I will be waiting for your feedback.

Thanks.

Mahmoud

 

 

2 replies

Technical Moderator
April 2, 2026

Hello @kadekade 

Let me thank you for your posting.

I created a project with STM32CubeMX 6.17 [STM32H573VIT6], and the issue was not reproduced by my side.

The compilation completed without any errors.

For more investigation, I suggest please that you provide your Ioc.File.

Thanks.

Mahmoud

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
kadekadeAuthor
Associate
April 6, 2026

Dear Mahmoud,

I appreciate your help. I'm sorry to reply late.

I attatched my ioc file. My settings is slightly defferent with your settings(SDMMC1_D0)

yours : SDMMC1_D0 PB13

me : SDMMC1_D0 PC8

 

I going to try testing with your ioc file.

Thanks,

kade

 

kadekadeAuthor
Associate
April 7, 2026

I found out why it doesn't work.

I should setting memory bigger than sector sizes(ex:4096).

So. Not unsigned char media_memory[256]

is "unsigned char media_memory[4096 or more]"

 

Thanks,

BR

kade

 

AScha.3
Super User
April 2, 2026

Hi,

>but I can't FATFS

Right, here no fatfs , you have to use filex , as you selected in Cube.

mount drive ->

/* Open the SD disk driver */
 sd_status = fx_media_open(&sdio_disk, FX_SD_VOLUME_NAME, fx_stm32_sd_driver, (VOID *)FX_NULL, (VOID *) fx_sd_media_memory, sizeof(fx_sd_media_memory));

 

"If you feel a post has answered your question, please click ""Accept as Solution""."
kadekadeAuthor
Associate
April 6, 2026

Thank, I'm trying it again.

kade

Technical Moderator
April 6, 2026

Hello @kadekade 

Further to your comment, I tested again with the Ioc.File provided through the attachment and the build was finished without any errors.

I will be waiting for your feedback.

Thanks.

Mahmoud

 

 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.