How to interface SD card with STM32L5 NUCLEO with SDMMC and FatFS
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2023-03-13 2:17 PM
I am having trouble with getting FatFS to work with SDMMC. When I try to do f_mount, I keep getting an FR_NOT_READY error. It seems to be coming from when initializing the SD card in sd_diskio.c. The tutorials I have found online seem to have the BSP code already generated by the STM32CubeMX, but apparently starting with the L5 series, CubeMX no longer does this. I am wondering if there are any resources or source code that have working BSP code to properly get an SD card to read and write using FatFS.
Thanks for any help
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2023-03-13 2:42 PM
Determine if it's using a GPIO to test for a card in the socket.
L5, port in an example, should materially be able to use the same pins wired to a header
STM32Cube_FW_L5_V1.2.0\Projects\STM32L562E-DK\Applications\FatFs\FatFs_uSD_Standalone
STM32Cube_FW_L5_V1.2.0\Projects\STM32L552E-EV\Applications\FatFs\FatFs_uSD_DMA
Up vote any posts that you find helpful, it shows what's working..
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2023-03-13 3:31 PM
Thanks for your response. The board I am using does not have a SD card socket, so I am using a SD breakout board to connect the SD card to the correct pins. Would I still be able to check if it's using a GPIO to test for a card in socket? And if so, how could I go about doing so?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2023-08-28 7:19 AM
I made SDMMC example for NUCLEO-L552ZE-Q board(need GCC command line build environment).
It supports SDXC and eMMC.
http://nemuisan.blog.bai.ne.jp/?eid=192848#STM32L5
Best regards,
Nemui.
