Chapter 13

EEPROM Data Memory

In previous examples we have stored data in user files called variables such as TEMPERATURE. The reading of the temperature would have been lost if the power was switched off to the circuit. However if we store the data in the EEPROM Data Memory then the information is retained in the micro when the power is switched off or lost.

The 18F1220 has 256 bytes of EEPROM data memory and the 18(L)F26K22 has 1024 bytes.

Access enabling Reading and Writing to and from the EEPROM is via the four registers:

ent EECON1

ent EECON2

 

Get PIC Projects and Applications using C now with the O’Reilly learning platform.

O’Reilly members experience live online training, plus books, videos, and digital content from nearly 200 publishers.