Chapter 2 128 Kbyte Flash Module (FTS128K1V1)
MC9S12E128 Data Sheet, Rev. 1.07
98
Freescale Semiconductor
2.3.2.7
Flash Command Register (FCMD)
The FCMD register denes the Flash commands.
Bits CMDB6, CMDB5, CMDB2, and CMDB0 are readable and writable during a command write
sequence while bits 7, 4, 3, and 1 read 0 and are not writable.
5
PVIOL
Protection Violation — The PVIOL ag indicates an attempt was made to program or erase an address in a
protected Flash array memory area. The PVIOL ag is cleared by writing a 1 to PVIOL. Writing a 0 to the PVIOL
ag has no effect on PVIOL. While PVIOL is set, it is not possible to launch another command.
0 No protection violation detected
1 Protection violation has occurred
4
ACCERR
Access Error — The ACCERR ag indicates an illegal access to the Flash array caused by either a violation of
the command write sequence, issuing an illegal command (illegal combination of the CMDBx bits in the FCMD
register) or the execution of a CPU STOP instruction while a command is executing (CCIF=0). The ACCERR ag
is cleared by writing a 1 to ACCERR. Writing a 0 to the ACCERR ag has no effect on ACCERR. While ACCERR
is set, it is not possible to launch another command.
0 No access error detected
1 Access error has occurred
2
BLANK
Flash Array Has Been Veried as Erased — The BLANK ag indicates that an erase verify command has
checked the Flash array and found it to be erased. The BLANK ag is cleared by hardware when CBEIF is
cleared as part of a new valid command write sequence. Writing to the BLANK ag has no effect on BLANK.
0 If an erase verify command has been requested, and the CCIF ag is set, then a 0 in BLANK indicates the
array is not erased
1 Flash array veries as erased
1
FAIL
Flag Indicating a Failed Flash Operation — In special modes, the FAIL ag will set if the erase verify operation
fails (Flash array veried as not erased). Writing a 0 to the FAIL ag has no effect on FAIL. The FAIL ag is cleared
by writing a 1 to FAIL. While FAIL is set, it is not possible to launch another command.
0 Flash operation completed without error
1 Flash operation failed
0
DONE
Flag Indicating a Failed Operation is not Active — In special modes, the DONE ag will clear if a program,
erase, or erase verify operation is active.
0 Flash operation is active
1 Flash operation is not active
Module Base + 0x0006
76543210
R0
CMDB6
CMDB5
00
CMDB2
0
CMDB0
W
Reset
00000000
= Unimplemented or Reserved
Figure 2-11. Flash Command Register (FCMD)
Table 2-13. FSTAT Field Descriptions
Field
Description