Flash memoryMPC5644A Microcontroller Reference Manual, Rev. 6Freescale Semiconductor 255Figure 12-22. Erase sequence12.4.7 Flash shadow blockThe flash shadow block is a memory-mapped block in the flash memory map. Program and erase of theshadow block are enabled when MCR[PEAS] = 1 only. After the user has begun an erase operation on theshadow block, the operation cannot be suspended to program the main address space and vice-versa. Theuser must terminate the shadow erase operation to program or erase the main address space.User mode read stateWrite MCRERS = 1Select blocksErase interlock writeStep 1Step 2Step 3Write MCREHV = 1High voltage activeAccess MCRDONE?Step 4WRITEESUS = 1 Read MCR DONE = 1Erase suspendERS = 0 User mode read statePEG = 0Read MCRDONE = 1DONE = 0Write MCRESUS = 0EHV = 1AbortWRITEEHV = 0Step 5Step 6PEG?SuccessPEG = 1Write MCRFailurePEG = 0Step 7EHV = 0Erasemore blocksStep 8?NoYesWrite MCRERS = 0User mode read stateStep 9EHV = 0Write MCRPGM = 1Program, Step 2Go to Step 2Note: PEG will remain valid under thiscondition until EHV is set high orERS is cleared.Note: ESUS cannot be cleared whileEHV = 0. ESUS and EHV cannotbe changed in a singlewrite operation.PEG Valid Period