Functional Description
541
SLAU723A – October 2017 – Revised October 2018
Copyright © 2017–2018, Texas Instruments Incorporated
Internal Memory
3. Use method 1 or 2 (in assembly language) if the compiler does not support either method.
7.2.3.6
Read-Only Protection
Read-only protection prevents the contents of the flash block from being reprogrammed, while still
allowing the content to be read by processor or the debug interface. If a FMPREn bit is cleared, all read
accesses to the flash memory block are disallowed, including any data accesses. Care must be taken not
to store required data in a flash memory block that has the associated FMPREn bit cleared.
The read-only mode does not prevent read access to the stored program, but it does provide protection
against accidental (or malicious) erasure or programming. Read-only is especially useful for utilities like
the bootloader when the debug interface is permanently disabled. In such combinations, the bootloader,
which provides access control to the flash memory, is protected from being erased or modified.
7.2.3.7
Permanently Disabling Debug
For sensitive applications, the debug interface to the processor and peripherals can be permanently
disabled, blocking all accesses to the device through the JTAG or SWD interfaces. With the debug
interface disabled, it is still possible to perform standard IEEE instructions (such as boundary scan
operations), but access to the processor and peripherals is blocked.
The DBG0 and DBG1 bits of the Boot Configuration (BOOTCFG) register control whether the debug
interface is turned on or off.
The debug interface should not be permanently disabled without providing some mechanism, such as the
bootloader, to provide customer-installable updates or bug fixes. Disabling the debug interface is
permanent and cannot be reversed.
7.2.3.8
Interrupts
The flash memory controller can generate interrupts when the following conditions are observed:
•
Programming Interrupt: Signals when a program or erase action is complete (PRIS).
•
Access Interrupt: Signals when a program or erase action has been attempted on a 16-kB block of
memory that is protected by its corresponding FMPPEn bit (ARIS).
•
EEPROM Interrupt
•
Pump Voltage Interrupt: Indicates if the regulated voltage of the pump went out of specification during
a flash operation and the operation was terminated (VOLTRIS).
•
Invalid Data Interrupt: Signals when a bit in flash that was previously programmed as a 0 is now
requested to be programmed as a 1 (INVDRIS).
•
ERASE Operation Interrupt: Indicates an ERASE operation failed (ERRIS).
The interrupt events that can trigger a controller-level interrupt are defined in the Flash Controller Masked
Interrupt Status (FCMIS) register (see
) by setting the corresponding MASK bits. If interrupts
are not used, the raw interrupt status is always visible through the Flash Controller Raw Interrupt Status
(FCRIS) register (see
).
Interrupts are always cleared (for both the FCMIS and FCRIS registers) by writing 1 to the corresponding
bit in the Flash Controller Masked Interrupt Status and Clear (FCMISC) register (see
7.2.3.9
µDMA
The µDMA can be programmed to read from flash. The Flash DMA Address Size (FLASHDMASZ) register
configures 2KB regions of flash that can be accessed by the µDMA. The starting address for this µDMA-
accessible region is defined in the Flash DMA Starting Address (FLASHDMAST) register. When the DFA
bit is set in the FLASHPP register, the µDMA can access the enabled region configured by the
FLASHDMASZ and FLASHDMAST registers. The µDMA checks the Flash Protection Program Enable n
(FMPPEn) registers for masked 2KB flash regions before initiating the transfer. If the access is out of
range, then a bus fault is generated.
NOTE:
The µDMA can only access flash in run mode (not available in low power modes).