Skip to main content
NNK
Associate
October 4, 2022
Question

Hi. How can I use FATFS and USB_MSC host with SDIO for STM32F407? Thanks in advance for your reply!

..

This topic has been closed for replies.

6 replies

Tesla DeLorean
Guru
October 4, 2022

Host?

​

Or is the question one of using the SDIO concurrently with FATFS and MSC Device?

​

Being concurrent would be harder. Can one connectivity be Read Only?

Otherwise you might have to tell the PC it's not ready or the media changed. Plus the PC might be caching or deferring writes.​

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
NNK
NNKAuthor
Associate
October 4, 2022

Yes, you noted it right: "Or is the question one of using the SDIO concurrently with FATFS and MSC Device?"

I wanted write data with fatfs into the SD card, and read on the USB_OTG as Mass Storage with usb.

Tesla DeLorean
Guru
October 4, 2022

FATFS can handle multiple volumes, one on SDIO, the other from USB Hosted MSC, the DISKIO layer takes an index as to which drive/logical unit it is working with.​

Tips, Buy me a coffee, or three.. PayPal Venmo (See Profile) Up vote any posts that you find helpful, it shows what's working..
NNK
NNKAuthor
Associate
October 4, 2022

It returns the following error when trying to connect over CubeIDE

0693W00000UnJjcQAF.png

NNK
NNKAuthor
Associate
October 4, 2022

Yes, you noted it right: "Or is the question one of using the SDIO concurrently with FATFS and MSC Device?"

I wanted write data with fatfs into the SD card, and read on the USB_OTG as Mass Storage with usb.