This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

RTX with USB to SPI Flash Memory

Hi

I have a board with an STM32F407 plus an SD card interface and a 25Q32 flash memory. I followed examples in the documentation and can access both devices using FlashFS. I also can connect to a PC and "see" the SD card as an external device using the USB port. However can't do the same with the flash memory chip. How should I use USBD_MSC0_SetMediaOwnerUSB() function to use the 25Q32 chip ?

Best Regards

Viktor Bucher

Parents
  • HI Viktor,

    USBD_MSC0_SetMediaOwnerUSB is only used to switch who owns the media (FileSystem or USB at a certain point in time), it is not used to switch media layer.

    If you want to change media at runtime you will have to change the implementation in the USBD_User_MSC.c file.

    Otherwise, you can also change MEDIA_DRIVE define in the USBD_User_MSC.c file to change the media at compile-time.

    Best regards, Milorad

Reply
  • HI Viktor,

    USBD_MSC0_SetMediaOwnerUSB is only used to switch who owns the media (FileSystem or USB at a certain point in time), it is not used to switch media layer.

    If you want to change media at runtime you will have to change the implementation in the USBD_User_MSC.c file.

    Otherwise, you can also change MEDIA_DRIVE define in the USBD_User_MSC.c file to change the media at compile-time.

    Best regards, Milorad

Children