User manual

www.ti.com
Tightly-Coupled Memory
The format of the data in the TCM region setup register is shown in Figure 3-2 .
Figure 3-2. TCM Region Setup Register
31 16
ADDRESS
15 12 11 6 5 2 1 0
ADDRESS Reserved (000000) SIZE 0 ENB
Table 3-5. TCM Region Setup Register Field Descriptions
Bit Field Value Description
31-12 ADDRESS 0-FFFFFh Base Address. The value programmed in this field is left-shifted by 12 to represent the physical
base address of the memory block (ITCM or DTCM).
11-6 Reserved 0 Reserved
5-2 SIZE 0-Fh Memory block size. See Table 3-6 .
1 0 0 This bits is always 0.
0 ENB TCM enable.
0 TCM is disabled.
1 TCM is enabled.
Table 3-6. ITCM/DTCM Size Encoding
Binary Code Size
0000 0 KB / absent
0001 and 0010 Reserved
0011 4 KB
0100 8 KB
0101 16 KB
0110 32 KB
0111 64 KB
1000 128 KB
1001 256 KB
1010 512 KB
1011 1 MB
11xx Reserved
The instructions for reading and writing to the ITCM and DTCM are:
MRC p15, #0, Rd, c9, c1, #0 ; read DTCM region register
MCR p15, #0, Rd, c9, c1, #0 ; write DTCM region register
MRC p15, #0, Rd, c9, c1, #1 ; read ITCM region register
MCR p15, #0, Rd, c9, c1, #1 ; write ITCM region register
Where Rd is any register where the data is read or written into the register.
On DM646x devices, the base address of the ITCM is 0000 0000h and the size is 32 KB. Hence, the
address field of the ITCM register c9 should be programmed with 00000h. The memory block size field of
the ITCM register c9 is fixed to the value of 6h. The memory block size field of the ITCM register c9 is
read only and a write has no effect.
On DM646x devices, the base address of the DTCM is 0001 0000h and the size is 32 KB. The DM646x
DTCM includes 32 KB of RAM and 8 KB of ROM. The address field of the DTCM register c9 should be
programmed with 0 0010h. The memory block size field of the DTCM register c9 is fixed to the value of
6h. The memory block size field of the DTCM register c9 is read only and a write has no effect.
SPRUEP9A May 2008 ARM Core 27
Submit Documentation Feedback