English
Language : 

S912XHZ512F1VAG Datasheet, PDF (182/978 Pages) Freescale Semiconductor, Inc – Covers MC9S12XHZ384, MC9S12XHZ256
Chapter 4 4 Kbyte EEPROM Module (S12XEETX4KV2)
4.3.2.5 EEPROM Protection Register (EPROT)
The EPROT register defines which EEPROM sectors are protected against program or erase operations.
Module Base + 0x0004
7
R
EPOPEN
W
6
RNV6
5
RNV5
4
RNV4
3
EPDIS
2
EPS2
Reset
F
F
F
F
F
F
= Unimplemented or Reserved
Figure 4-8. EEPROM Protection Register (EPROT)
1
EPS1
F
0
EPS0
F
During the reset sequence, the EPROT register is loaded from the EEPROM Protection byte at address
offset 0x0FFD (see Table 4-1).All bits in the EPROT register are readable and writable except for
RNV[6:4] which are only readable. The EPOPEN and EPDIS bits can only be written to the protected
state. The EPS bits can be written anytime until bit EPDIS is cleared. If the EPOPEN bit is cleared, the
state of the EPDIS and EPS bits is irrelevant.
To change the EEPROM protection that will be loaded during the reset sequence, the EEPROM memory
must be unprotected, then the EEPROM Protection byte must be reprogrammed. Trying to alter data in any
protected area in the EEPROM memory will result in a protection violation error and the PVIOL flag will
be set in the ESTAT register. The mass erase of an EEPROM block is possible only when protection is
fully disabled by setting the EPOPEN and EPDIS bits.
Table 4-4. EPROT Field Descriptions
Field
Description
7
EPOPEN
6:4
RNV[6:4]
3
EPDIS
2:0
EPS[2:0]
Opens the EEPROM for Program or Erase
0 The entire EEPROM memory is protected from program and erase.
1 The EEPROM sectors not protected are enabled for program or erase.
Reserved Nonvolatile Bits — The RNV[6:4] bits should remain in the erased state “1” for future enhancements.
EEPROM Protection Address Range Disable — The EPDIS bit determines whether there is a protected area
in a specific region of the EEPROM memory ending with address offset 0x0FFF.
0 Protection enabled.
1 Protection disabled.
EEPROM Protection Address Size — The EPS[2:0] bits determine the size of the protected area as shown
inTable 4-5. The EPS bits can only be written to while the EPDIS bit is set.
MC9S12XHZ512 Data Sheet, Rev. 1.06
182
Freescale Semiconductor