FBANKWAIT register defaults to a worst-case wait state count and, thus, needs to be initialized for the
appropriate number of wait states to improve performance based on the CPU clock rate and the access time
of the flash. The flash supports 0-wait accesses when the PAGEWAIT bits are set to zero. This assumes
that the CPU speed is low enough to accommodate the access time. To determine the random and paged
access time requirements, refer to the datasheet for your particular device.
3.
OTP Access
Read or fetch accesses to the OTP are controlled by the OTPWAIT bits in the FOTPWAIT register. Accesses
to the OTP take longer than the flash and there is no paged mode. To determine OTP access time
requirements, see the datasheet for your particular device.
Some other points to keep in mind when working with flash:
• CPU writes to the flash or OTP memory map area are ignored. They complete in a single cycle.
• When the Code Security Module (CSM) is secured, reads to the flash/OTP memory map area from outside
the secure zone take the same number of cycles as a normal access. However, the read operation returns a
zero.
• Reads of the CSM password locations are hardwired for 16 wait-states. The PAGEWAIT and RANDOMWAIT
bits have no effect on these locations. See
for more information on the CSM.
1.1.3.2 Flash Pipeline Mode
Flash memory is typically used to store application code. During code execution, instructions are fetched from
sequential memory addresses, except when a discontinuity occurs. Usually the portion of the code that resides
in sequential addresses makes up the majority of the application code and is referred to as linear code. To
improve the performance of linear code execution, a flash pipeline mode has been implemented. The flash
pipeline feature is disabled by default. Setting the ENPIPE bit in the FOPT register enables this mode. The flash
pipeline mode is independent of the CPU pipeline.
An instruction fetch from the flash or OTP reads out 64 bits per access. The starting address of the access from
flash is automatically aligned to a 64-bit boundary such that the instruction location is within the 64 bits to be
fetched. With flash pipeline mode enabled (see
), the 64 bits read from the instruction fetch are stored
in a 64-bit wide by 2-level deep instruction pre-fetch buffer. The contents of this pre-fetch buffer are then sent to
the CPU for processing as required.
Up to two 32-bit instructions or up to four 16-bit instructions can reside within a single 64-bit access. The majority
of C28x instructions are 16 bits, so for every 64-bit instruction fetch from the flash bank it is likely that there
are up to four instructions in the pre-fetch buffer ready to process through the CPU. During the time it takes to
process these instructions, the flash pipeline automatically initiates another access to the flash bank to pre-fetch
the next 64 bits. In this manner, the flash pipeline mode works in the background to keep the instruction pre-fetch
buffers as full as possible. Using this technique, the overall efficiency of sequential code execution from flash or
OTP is improved significantly.
System Control and Interrupts
SPRUH18I – JANUARY 2011 – REVISED JUNE 2022
TMS320x2806x Microcontrollers
43
Copyright © 2022 Texas Instruments Incorporated
Summary of Contents for TMS320 2806 Series
Page 2: ......