Datasheet
90
4235K–8051–05/08
AT89C51RD2/ED2
Figure 23-1. Recommended EEPROM Data Write Sequence
23.2 Read Data
The following procedure is used to read the data stored in the EEPROM memory:
• Check EEBUSY flag
• If the user application interrupts routines use XRAM memory space: Save and disable
interrupts.
• Load DPTR with the address to read
• Set bit EEE of EECON register
• Execute a MOVX A, @DPTR
• Clear bit EEE of EECON register
• Restore interrupts.
EEPROM Data Write
Sequence
Data Write
DPTR= Address
ACC= Data
Exec: MOVX @DPTR, A
Last Byte
to Load?
EEPROM Mapping
EECON = 00h (EEE=0)
Save & Disable IT
EA= 0
Restore IT
EEPROM Data Mapping
EECON = 02h (EEE=1)
EEBusy
Cleared?