LM3S3768 Luminary Micro, Inc, LM3S3768 Datasheet - Page 162

no-image

LM3S3768

Manufacturer Part Number
LM3S3768
Description
Lm3s3768 Arm Microcontroller
Manufacturer
Luminary Micro, Inc
Datasheet
Internal Memory
8.2.3.2
8.3
8.3.1
8.3.1.1
162
Flash Memory Protection
The user is provided two forms of flash protection per 2-KB flash blocks in two pairs of 32-bit wide
registers. The protection policy for each form is controlled by individual bits (per policy per block)
in the FMPPEn and FMPREn registers.
The policies may be combined as shown in Table 8-1 on page 162.
Table 8-1. Flash Protection Policy Combinations
An access that attempts to program or erase a PE-protected block is prohibited. A controller interrupt
may be optionally generated (by setting the AMASK bit in the FIM register) to alert software developers
of poorly behaving software during the development and debug phases.
An access that attempts to read an RE-protected block is prohibited. Such accesses return data
filled with all 0s. A controller interrupt may be optionally generated to alert software developers of
poorly behaving software during the development and debug phases.
The factory settings for the FMPREn and FMPPEn registers are a value of 1 for all implemented
banks. This implements a policy of open access and programmability. The register bits may be
changed by writing the specific register bit. The changes are not permanent until the register is
committed (saved), at which point the bit change is permanent. If a bit is changed from a 1 to a 0
and not committed, it may be restored by executing a power-on reset sequence. Details on
programming these bits are discussed in “Nonvolatile Register Programming” on page 163.
Flash Memory Initialization and Configuration
Flash Programming
The Stellaris
operations are handled via three registers: FMA, FMD, and FMC.
To program a 32-bit word
1.
2.
3.
FMPPEn
Flash Memory Protection Program Enable (FMPPEn): If set, the block may be programmed
(written) or erased. If cleared, the block may not be changed.
Flash Memory Protection Read Enable (FMPREn): If set, the block may be executed or read
by software or debuggers. If cleared, the block may only be executed and contents of the memory
block are prohibited from being accessed as data.
0
1
0
1
Write source data to the FMD register.
Write the target address to the FMA register.
Write the flash write key and the WRITE bit (a value of 0xA442.0001) to the FMC register.
FMPREn
0
0
1
1
®
devices provide a user-friendly interface for flash programming. All erase/program
Protection
Execute-only protection. The block may only be executed and may not be written or erased. This mode
is used to protect code.
The block may be written, erased or executed, but not read. This combination is unlikely to be used.
Read-only protection. The block may be read or executed but may not be written or erased. This mode
is used to lock the block from further modification while allowing any read or execute access.
No protection. The block may be written, erased, executed or read.
Preliminary
June 02, 2008

Related parts for LM3S3768