EEprom part sketch?

Hello i do not know if this is a storage question mix with a programing question. But here goes. I'm running a attiny85 project. I just found out that i can run recently with the help on the forum that i can run a oled on a attiny85 and it works. But doing this I'm running out of memory because I have a small menu on the oled. That is said I'm using 90% of the memory. Is it possible to put part of the sketch or library within a external eeprom chip to free up some memory? Because also I'm trying to add a Sleep mode for the attiny85 and in this case it will go over what the memory has.

Joseph

There are some working attempts to rewrite FLASH runtime, but you better buy a larger chip.

Or you can post your code as there are often optimizations possible that use less memory.

You don’t specifically say which memory. If it’s RAM, you can move non-changing variables (e.g. your menu) to PROGMEM, internal EEPROM or to external EEPROM.

If it’s flash memory instead of RAM, see Rob’s answer. Please be aware that re-flashing parts of the flash will reduce the life of the flash memory.

Hello I'm sorry i thought i put that part in the post i have a whole bunch of AT24C256 eeprom chips. I only need to write to it once and never rewrite it to again. So a one time write to the eeprom to put things on it then that is it.

check my EEPROM lib - https://github.com/RobTillaart/Arduino/tree/master/libraries/I2C_EEPROM The examples contain all the code you need.