XC68HC05P18A Motorola, XC68HC05P18A Datasheet - Page 88

no-image

XC68HC05P18A

Manufacturer Part Number
XC68HC05P18A
Description
HCMOS Microcontroller Unit
Manufacturer
Motorola
Datasheet
EEPROM
10.4 Programming/Erasing Procedures
Technical Data
88
To program a byte of EEPROM:
Any bit should be erased before it is programmed. However, if
write/erase cycling is a concern, a procedure can be followed to
minimize the cycling of each bit in each EEPROM byte.
Where:
To erase a byte of EEPROM:
To erase a block of EEPROM:
1. Set EELAT = CPEN = 1.
2. Set ER1 = ER0 = 0.
3. Write data to the desired address.
4. Set EEPGM for a time, t
1. Set LATCH = 1, CPEN = 1, ER1 = 0, and ER0 = 1.
2. Write to the address to be erased.
3. Set EEPGM for a time, t
1. Set LATCH = 1, CPEN = 1, ER1 = 1, and ER0 = 0.
2. Write to any address in the block.
3. Set EEPGM for a time, t
Here is the procedure:
PB = Byte data to be programmed
EB = Existing EEPROM byte data
If PB • EB = 0 — Program the new data over the existing data
without erasing it first.
If PB • EB
0 — Erase byte before programming.
EEPROM
EEPGM
EBYT
EBLOCK
.
.
.
MC68HC05P18A
MOTOROLA

Related parts for XC68HC05P18A