2023-04-10 12:22 PM
Dear everyone,
I'm not able to know is it possible to add an external flash (SPI) to a MCU for saving data (FATFS) AND get the data available on USB Mass Storage.
A lot of library exist for SPI flash, the most knowed >"https://github.com/nimaltd/w25qxx/blob/master/w25qxx.c
But... what about the Mass Storage ?
2023-04-10 12:36 PM
Concurrent usage tends to be a problem due to the file system structures, and host side caching.
Yes, Winbond W25Qxx devices can be used for this application, generally you'd want to use the 4KB sector size. The NOR Flash devices are not particularly fast. FATFS doesn't manage wear-leveling, etc.
2023-04-10 12:48 PM
Thanks for your rapid reply.
My need does not require High speed, no big space.
i would like just memory faster than an EEProm, and stop using SDcard ( Manipulation and human errors, compatibility).
Do you is you have ever seen an example ?
My only source is a Chinesse page...
2023-04-10 01:44 PM
>>Do you is you have ever seen an example ?
I'm a software engineer, I've written one, although in the most recent case it was QSPI on an STM32F7
For FATFS you have to implement the block read/write function in the DISKIO layer.
For USB you'd need to implement READ, WRITE, GET CAPACITY, READ MODE-PAGE type functionality.