34
\$\begingroup\$

Is there any reason why people are still using (and implementing in new systems) normal EEPROMs instead of flash memory, nowadays?

From the Flash memory wikipedia:

Flash memory was developed from EEPROM (electrically erasable programmable read-only memory).

Would there be any disadvantages (power consumption, space, speed, etc.) on using flash instead of normal EEPROM?

\$\endgroup\$
  • \$\begingroup\$ I think you might be confused between EPROM (only erasable under UV, mostly obsolete) and EEPROM (electrically eraseable). \$\endgroup\$ – pjc50 Apr 13 '13 at 11:51
  • \$\begingroup\$ @pjc50 I'm not - I quoted the wrong part of the wiki, fixed now - thanks :) \$\endgroup\$ – Keelan Apr 13 '13 at 11:53
  • 2
    \$\begingroup\$ Flash is erased in large chunks, whereas EEPROM can be erased per byte. \$\endgroup\$ – jippie Apr 13 '13 at 13:48
  • 2
    \$\begingroup\$ You'd never know they're the same from reading PIC datasheets...they even have different endurances. But I guess it may be marketing. After all, they've also got "Enhanced Flash". BTW the EEPROM is gone on the PIC 32, and the minimum flash page write is 4k bytes. \$\endgroup\$ – gbarry Apr 14 '13 at 7:27
  • 2
    \$\begingroup\$ @gbarry: They are not the same. Flash is EEPROM, but not all EEPROM is flash. Remember what EEPROM means, which is electrically erasable programmable read-only memory. \$\endgroup\$ – Olin Lathrop Apr 14 '13 at 12:42
26
\$\begingroup\$

To be pedantic, FLASH memory is merely a form of EEPROM: There is a marketing / branding aspect here. Typically, the distinction used today is that EEPROMS are single-byte (or storage word) erasable / rewritable, while FLASH is block-based for erase/write operations.

Relevant to the question:

  • EEPROMs continue to be popular due to maximum erase/write cycle ratings being an order of magnitude or two better than FLASH
  • Due to investments in design typically having been amortized over time, as with any mature technology, the cost of production and testing reduces compared to a newer technology.
\$\endgroup\$
  • 2
    \$\begingroup\$ Everybody talking about erasing a single byte or block-based but what is the theory behind that ?? i can erase any number of bytes for the flash memory as well !!! \$\endgroup\$ – The Beast Apr 25 '16 at 0:51
  • 1
    \$\begingroup\$ @Frankenstein how is that done? \$\endgroup\$ – abdullah kahraman May 13 '16 at 14:26
19
\$\begingroup\$

The number of write cycles most EEPROMs can handle generally far exceeds the number of write cycles most flash memory can handle.

EEPROMS can generally handle ~100,000-1,000,000 writes per cell.
Flash is generally rated to ~1,000-100,000 writes (it varies heavily depending on the type of flash).

Another advantage EEPROM has over flash is that flash generally has to be erased in blocks, so if your write patterns involve sequential single-byte writes, you will use many more write cycles on the flash memory then you would with the equivalent EEPROM, as EEPROM memory can generally be erased on a per-byte basis, rather then the per-block erase cycle flash uses.

Basically, flash generally is erased in blocks of ~64-512 kilobytes. Therefore, for every write anywhere within that block, the controller has to erase the entire block, using a write cycle for the entire block. You can see, if you sequentially performed single-byte writes to each address in a block, you would wind up performing anywhere between 64K to 512K writes to the entire block, which could easily use the entire write endurance of the flash.

As such, EEPROMs are generally used in situations where the local processor is small does not have the ability to buffer writes to each flash page.


A lot of this is becoming less true as flash technology advances. There are flash memory ICs that include the facilities for local write-buffering, as well as the write-endurance on flash memory increasing dramatically.

\$\endgroup\$
  • \$\begingroup\$ The size of an erasing block and a write block are usually not the same. Also for older single-bit-per-cell flash, one could reliably overwrite blocks at least once as long as the write did not require changing a bit value back to the erased state. E.g., if 1 is the erased state, with 16-bit blocks one could write 0bxxxxxxxx11111111 and later write 0bxxxxxxxxyyyyyyyy (or even 0b1010101011111111 and later 0b00000000xxxxxxxx). \$\endgroup\$ – Paul A. Clayton Apr 13 '13 at 15:39
  • \$\begingroup\$ @PaulA.Clayton - Good point. \$\endgroup\$ – Connor Wolf Apr 13 '13 at 23:27
  • \$\begingroup\$ @PaulA.Clayton: One thing I wish flash vendors would document is whether one may legitimately zero out some large portion of an already-written flash block without having to erase it first. Being able to expressly invalidate a page directly without having to keep track elsewhere of the fact that the page was invalidated would be very useful. \$\endgroup\$ – supercat Jun 11 '13 at 19:46

protected by W5VO Apr 13 '13 at 20:54

Thank you for your interest in this question. Because it has attracted low-quality or spam answers that had to be removed, posting an answer now requires 10 reputation on this site (the association bonus does not count).

Would you like to answer one of these unanswered questions instead?

Not the answer you're looking for? Browse other questions tagged or ask your own question.