cancel
Showing results for 
Search instead for 
Did you mean: 

Fatfs f_mount and f_getfree

yang hong
Associate II

I am using NUCLEO H743ZI2 with Fatfs and FreeRTOS V2. The program is working now, but I have one issue on free size of SD card. After I use f_mount to mount my SD Card, In structure FATFS variables, last cluster and free cluster are not correct. If I use f_getfree, I am able to get correct free cluster, but after FATFS variable passing through f_getfree is updated inside function f_getfree, I can't use f_open function. However, after I use function f_open, then I use f_getfree to get free cluster, everything is working fine.

Does anybody know what is happen? how can I get correct free size when I use f_mount to update correct free cluster?

2 REPLIES 2

Are you using a current version of FatFs?

Tips, Buy me a coffee, or three.. PayPal Venmo
Up vote any posts that you find helpful, it shows what's working..
yang hong
Associate II

FATFS VERSION IS R0.12C