Skip to main content
Graduate
June 25, 2024
Question

Need to Access External Flash memory as File System

  • June 25, 2024
  • 2 replies
  • 1644 views

Hi STM Team,

I need to access test.wav audio file from External SPI Flash memory.

Is there is any file system library to mount spi flash memory as file system?

I am using Nucleo - G070RB.

Is there is any microcontrollers with library that support external flash memory as file system.

Please provide me the suggestions.

    This topic has been closed for replies.

    2 replies

    Graduate II
    June 25, 2024

    With FATFS you put your Read and Write functionality in the DISKIO layer. For QSPI NOR Flash devices use 4KB sectors, as this matches the Erase size and reduces complications. Write as 16 256-byte pages.

    Routines translate blocks into linear address within the memory.

    rkuma.21Author
    Graduate
    June 26, 2024

    @Tesla DeLorean Thanks for your reply.

     

    Is already have any library to read and write files to SPI flash memory, please suggest any.

    Technical Moderator
    June 26, 2024

    Hello @rkuma.21 

     

    For integrating FatFS with external flash, you would need to write a disk I/O driver specific to your SPI flash, similar to the sd_diskio driver mentioned for SD cards in this example.

    Unfortunately, there is no example provided by ST in the Firmware package. However, you can refer to these threads: