ATmega88PA Automotive Atmel Corporation, ATmega88PA Automotive Datasheet - Page 18

no-image

ATmega88PA Automotive

Manufacturer Part Number
ATmega88PA Automotive
Description
Manufacturer
Atmel Corporation
6.3.4
6.3.5
18
Atmel ATtiny24/44/84 [Preliminary]
Erase
Write
To erase a byte, the address must be written to EEAR. If the EEPMn bits are 0b01, writing the
EEPE (within four cycles after EEMPE is written) will trigger the erase operation only (pro-
gramming time is given in Table 1). The EEPE bit remains set until the erase operation
completes. While the device is busy programming, it is not possible to do any other EEPROM
operations.
To write a location, the user must write the address into EEAR and the data into EEDR. If the
EEPMn bits are 0b10, writing the EEPE (within four cycles after EEMPE is written) will trigger
the write operation only (programming time is given in Table 1). The EEPE bit remains set until
the write operation completes. If the location to be written has not been erased before write,
the data that is stored must be considered as lost. While the device is busy with programming,
it is not possible to do any other EEPROM operations.
The calibrated oscillator is used to time the EEPROM accesses. Make sure the oscillator fre-
quency is within the requirements described in
page
The following code examples show one assembly function and one C function for erase, write,
or atomic write of the EEPROM. The examples assume that interrupts are controlled (e.g., by
disabling interrupts globally) so that no interrupts will occur during execution of these
functions.
32.
“Oscillator Calibration Register – OSCCAL” on
7701E–AVR–02/11

Related parts for ATmega88PA Automotive