Rev. 1.0
115
C8051F80x-83x
unlocked pages, and user firmware executing on locked pages.
Table 19.1 summarizes the Flash security
features of the C8051F80x-83x devices.
19.4. Flash Write and Erase Guidelines
Any system which contains routines which write or erase Flash memory from software involves some risk
that the write or erase routines will execute unintentionally if the CPU is operating outside its specified
operating range of VDD, system clock frequency, or temperature. This accidental execution of Flash modi-
fying code can result in alteration of Flash memory contents causing a system failure that is only recover-
able by re-Flashing the code in the device.
To help prevent the accidental modification of Flash by firmware, the VDD Monitor must be enabled and
enabled as a reset source on C8051F80x-83x devices for the Flash to be successfully modified. If either
Table 19.1. Flash Security Summary
Action
C2 Debug
Interface
User Firmware executing from:
an unlocked page
a locked page
Read, Write or Erase unlocked pages
(except page with Lock Byte)
Permitted
Read, Write or Erase locked pages
(except page with Lock Byte)
Not Permitted FEDR
Permitted
Read or Write page containing Lock Byte
(if no pages are locked)
Permitted
Read or Write page containing Lock Byte
(if any page is locked)
Not Permitted FEDR
Permitted
Read contents of Lock Byte
(if no pages are locked)
Permitted
Read contents of Lock Byte
(if any page is locked)
Not Permitted FEDR
Permitted
Erase page containing Lock Byte
(if no pages are locked)
Permitted
FEDR
Erase page containing Lock Byte—Unlock all
pages (if any page is locked)
Only by C2DE FEDR
FEDR
Lock additional pages
(change 1s to 0s in the Lock Byte)
Not Permitted FEDR
FEDR
Unlock individual pages
(change 0s to 1s in the Lock Byte)
Not Permitted FEDR
FEDR
Read, Write or Erase Reserved Area
Not Permitted FEDR
FEDR
C2DE—C2 Device Erase (Erases all Flash pages including the page containing the Lock Byte)
FEDR—Not permitted; Causes Flash Error Device Reset (FERROR bit in RSTSRC is 1 after reset)
All prohibited operations that are performed via the C2 interface are ignored (do not cause device
reset).
Locking any Flash page also locks the page containing the Lock Byte.
Once written to, the Lock Byte cannot be modified except by performing a C2 Device Erase.
If user code writes to the Lock Byte, the Lock does not take effect until the next device reset.