M58LW032A
Figure 25. Erase Flowchart and Pseudo Code
Start
Write 20h
Write D0h to
Block Address
Read Status
Register
NO
b7 = 1
YES
NO
b3 = 0
YES
NO
b4, b5 = 0
YES
NO
b5 = 0
YES
NO
b1 = 0
YES
End
NO
Suspend
YES
Suspend
Loop
VPP Invalid
Error (1)
Command
Sequence Error
Erase
Error (1)
Erase to Protected
Block Error
Erase command:
– write 20h
– write D0h to Block Address
(A12-A17)
(memory enters read Status
Register after the Erase command)
do:
– read status register
– if Program/Erase Suspend command
given execute suspend erase loop
while b7 = 1
If b3 = 1, VPP invalid error:
– error handler
If b4, b5 = 1, Command Sequence error:
– error handler
If b5 = 1, Erase error:
– error handler
If b1 = 1, Erase to Protected Block Error:
– error handler
AI00613B
Note: 1. If an error is found, the Status Register must be cleared (Clear Status Register Command) before further Program or Erase oper-
ations.
52/61