User avatar
SlowBro
Posts: 164
Joined: Sat Feb 18, 2017 1:30 am

Mount I2C flash filesystem?

Sun Oct 29, 2017 1:56 am

I'm wanting to make my SD card read-only and add an external I2C flash such as one of these for storing a few small config files. My config files are 5-6KB but I want a bit of room to grow hence I want a filesystem with at least 64KB/512KBit of room. OS is Raspbian Stretch Lite.

I know this is typically done with SPI or SDIO but I'm running low on pins.

So my questions:
1.) What kind of filesystem can I use to mount I2C flash?
2.) What is the minimum size I should look at considering filesystem overhead?

I thought of SPIFFS but it looks to be a work in progress, and no mention of I2C support.

User avatar
SlowBro
Posts: 164
Joined: Sat Feb 18, 2017 1:30 am

Re: Mount I2C flash filesystem?

Sun Oct 29, 2017 2:00 am

Update: It hadn't occurred to me to Google Pi I2C EEPROM. Found this. I can write a text string and read it back. So likely what I will do is read my config files into memory as a Python dict, write that out as one large JSON, then when I need to retrieve them I can read them back, write the config files in the overlay filesystem, and viola, back in business.

If you have any better ideas let me know.

Return to “Advanced users”