This category of memory can be written to, but under specific situations and with certain limitations. As such, it's usually treated like ROM, but has the distinct advantage that its contents can be updated without having to remove it from the circuit.

Electrically Erasable Programmable ROM

EEPROM is a lot like EPROM, except that it can be erased electrically rather than using UV light. That means it can be erased and reprogrammed in-circuit.  Another advantage is that usually a single word/byte can be erased and reprogrammed rather than the entire chip as with the EPROM.

Many of today's microcontrollers include a small amount of EEPROM to store various small bits of information, such as configuration options. For example, the ATmega328 (used in many maker boards including the Arduino UNO, Pro Mini,  the Adafruit Feather 328P, Metro 328, and Metro Mini 328) contains 1K of EEPROM.


These days we don't often use EPROMs unless we are working with retro CPUs.  Instead we're more likely to use flash memory.

Flash is technically a type of EEPROM, but with some specific characteristics that lend its use to situations where the amount of data being stored is relatively large, and not written often:

  • Whereas EEPROM can erase individual bytes, flash erases regions at a time.
  • Flash has a limited number of erase/write cycles before memory regions wear out and lose integrity. Over time that number has increased to the point where it is generally not an issue any longer. Additionally, the control hardware balances region use to spread writes across regions so that all wear relatively evenly.
  • Access times are relatively slow compared to RAM or ROM. However for MCU applications, clock speeds are relatively low, so this tends not to be a limiting factor.

Since most of us are working with microcontrollers, we should be familiar with flash since that's the memory on the controller where our code is stored. Also SD cards and USB memory sticks are flash based.  Adafruit's CircuitPython blends the two uses, storing the bootloader and python runtime in flash as usual, but also providing access to a filesystem via USB for loading Python code and data files onto the device.

Flash is a primary memory technology and has improved (as things do) drastically over time. The current state of flash make it feasible to use it as the sole secondary storage technology, i.e. Solid State Drive (SSD). Flash is perfect for this since it's much faster than disk (especially the NVMe/M.2 format SSDs) and more reliable since there are no moving parts.

If you have a Raspberry Pi (or the like), you use a microSD card as the "disk"; it's basically an inefficient SSD.  In that context, the computer is slow enough that the slow SD card isn't a huge problem.

This guide was first published on May 02, 2018. It was last updated on Mar 08, 2024.

This page (Read Mostly Memory) was last updated on Mar 08, 2024.

Text editor powered by tinymce.