I read a bit about the SPIFFS but I'm not sure that's what I'm looking for. All I want to do is write one file. I don't need anything special to use it afterward, that stuff is already taken care of. I just want to dump the binary data onto the flash chip so I can read what I need using spi_flash_read() to use with my LCD library. I know not to write in the last 5 blocks but I'm not entirely sure how to find at which offset I can start writing and how much space is available. I also have no clue how to actually write the file.
I'm using VS Code with PlatformIO and the non-os SDK as framework. The ESP8266 board is a NodeMCU V1.0 with a 4MB chip and I also have a flash memory programmer if writing directly using the GPIO pins is an option.
Thank you.