21 / 148 page

CPU Architecture
September 5, 2002
Document #: 38-12010 CY Rev. ** CMS Rev. 3.20
21
2.2.3
Index Register
2.2.4
Stack Pointer Register
2.2.5
Program Counter Register
2.3
Addressing Modes
2.3.1
Source Immediate
The result of an instruction using this addressing mode is
placed in the A register, the F register, the SP register, or
the X register, which is specified as part of the instruction
opcode. Operand 1 is an immediate value that serves as
a source for the instruction. Arithmetic instructions
require two sources. Instructions using this addressing
mode are two bytes in length.
Table 10:
Index Register (CPU_X)
Bit #
7
6
5
4
3
2
1
0
POR
0
0
0
0
0
0
0
0
Read/
Write
System1
System1
System1
System1
System1
System1
System1
System1
Bit Name
Data [7]
Data [6]
Data [5]
Data [4]
Data [3]
Data [2]
Data [1]
Data [0]
Bit [7:0]
: Data [7:0] 8-bit data value holds an index for any instruction that uses an indexed addressing mode
1.
System - not directly accessible by the user
Table 11:
Stack Pointer Register (CPU_SP)
Bit #
7
6
5
4
3
2
1
0
POR
0
0
0
0
0
0
0
0
Read/
Write
System1
System1
System1
System1
System1
System1
System1
System1
Bit Name
Data [7]
Data [6]
Data [5]
Data [4]
Data [3]
Data [2]
Data [1]
Data [0]
Bit [7:0]
: Data [7:0] 8-bit data value holds a pointer to the current top-of-stack
1.
System - not directly accessible by the user
Table 12:
Program Counter Register (CPU_PC)
Bit #
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
0
POR
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
Read/
Write
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
1
Bit
Name
Data
[15]
Data
[14]
Data
[13]
Data
[12]
Data
[11]
Data
[10]
Data
[9]
Data
[8]
Data
[7]
Data
[6]
Data
[5]
Data
[4]
Data
[3]
Data
[2]
Data
[1]
Data
[0]
Bit [15:0]
: Data [15:0] 16-bit data value is the low-order/high-order byte of the Program Counter
1.
System - not directly accessible by the user
Table 13:
Source Immediate
Opcode
Operand 1
Instruction
Immediate Value