Registers
C-5
C2xLP and C28x Architectural Differences
ST0/ST1
Status Registers.
The C28x status register bit positions are different
compared to the C2xLP. Figure C
3 shows the differences.
DP
Data Page Pointer.
On the C2xLP the DP is part of status register
ST0. The DP on the C28x is a separate register and is increased
from 9 to 16 bits.
C.2.2 Data Page (DP) Pointer Changes
C.2.2.1 C2xLP DP
The direct addressing mode on the C2xLP can access any data memory loca-
tion in the 64K address range of the device using a 9-bit data page pointer and
a 7-bit offset, supplied by the instruction, which is concatenated with the data
page pointer value to form the 16-bit data address location. An example
C2xLP operation is as follows:
LDP #VarA
; Load DP with page location for VarA
LACL VarA ; Load ACC low with contents of VarA
The first instruction initializes the DP register value with the ”page” location for
the specified variable. Each page is 128 words in size. The assembler/linker
automatically resolve the page value by dividing the absolute address of the
specified location by 128. For example:
If ”VarA” address = 0x3456, then the DP value is:
DP(8:0) = 0x3456/128 = 0x69
The next instruction will then calculate the 7-bit offset of the specified variable
within the 128-word page. This offset value is then embedded in the address
field for that instruction. The assembler/linker automatically resolves the offset
value by taking the first 7 bits of the absolute address of the specified location.
For example:
If ”VarA” address = 0x3456, then the 7bit offset value is:
7-bit offset = 0x3456 & 0x007F = 0x56
C.2.2.2 C28x DP
The C28x also supports the direct addressing mode using the DP register;
however, the following changes and enhancements have been made:
-
Supports 22-bit address reach
-
DP increased from 9 to 16 bits
-
DP is a separate 16-bit register
-
When AMODE == 0, page size is 64 words and DP(15:0) is used
-
When AMODE == 1, page size is 128 words and DP(15:1) is used, bit 0
of DP is ignored
When AMODE == 1, the DP and the direct addressing mode behaves identi-
cally to the C2xLP but are enhanced to 22-bit address reach from 16. When
Summary of Contents for TMS320C28x
Page 30: ...1 12...
Page 80: ...This page intentionally left blank 2 50 This page intentionally left blank...
Page 269: ...IN loc16 PA 6 112 MOV AL 0 AL 0 UOUT IORegC AL IOspace IORegC AL 10...
Page 308: ...MAXCUL P loc32 6 151 Saturate MOVL Var64 2 ACC Store result into Var64 MOVL Var64 P...
Page 509: ...SUBL ACC P PM 6 352 SUBL ACC P PM ACC S B 11 M X 4 MOVH Y ACC 5 Store Q15 result into Y...
Page 585: ...This page intentionally left blank 7 32 This page intentionally left blank...