Chapter 3 4 Kbyte EEPROM Module (S12XEETX4KV2)
MC9S12XDP512 Data Sheet, Rev. 2.11
170 Freescale Semiconductor
Figure 3-19. Example Sector Erase Abort Command Flow
Write: Dummy EEPROM Address
Write: ECMD register
Sector Erase Abort Cmd 0x47
Write: ESTAT register
Clear CBEIF 0x80
1.
2.
3.
Read: ESTAT register
and Dummy Data
Bit Polling for
Command
Completion Check
yes
NOTE: command write sequence
aborted by writing 0x00 to
ESTAT register.
NOTE: command write sequence
aborted by writing 0x00 to
ESTAT register.
CCIF
Set?
Execute Sector Erase/Modify Command Flow
no
Bit Polling for
Command
Completion Check
Read: ESTAT register
yes
CCIF
Set? no
yes
Abort
Needed?
Erase
Clear ACCERR 0x10
Write: ESTAT register
yes
no
Access
Error Check
ACCERR
Set?
Sector Erase
or Modify
Sector Erase
or Modify
no
EXIT EXIT
Sector Erase
Completed EXIT
Completed Aborted