English
Language : 

M166 Datasheet, PDF (121/127 Pages) Siemens Semiconductor Group – C16x Family of Siemens 16-Bit CMOS Single-Chip Microcontrollers
30Mar98@15:00h
C166 Family Instruction Set
Addressing Modes
Constants
The C166 Family instruction set also supports the use of wordwide or bytewide immediate
constants. For an optimum utilization of the available code storage, these constants are
represented in the instruction formats by either 3, 4, 8 or 16 bits. Thus, short constants are always
zero-extended while long constants are truncated if necessary to match the data format required for
the particular operation (see table below):
Mnemonic
#data3
#data4
#data8
#data16
#mask
Word Operation
0000H + data3
0000H + data4
0000H + data8
data16
0000H + mask
Byte Operation
00H + data3
00H + data4
data8
data16 ∧ FFH
mask
Note: Immediate constants are always signified by a leading number sign ’#’.
Instruction Range (#irang2)
The effect of the ATOMIC and EXTended instructions can be defined for the following 1...4
instructions. This instruction range (1...4) is coded in the 2-bit constant #irang2 and is represented
by the values 0...3.
Branch Target Addressing Modes
Different addressing modes are provided to specify the target address and segment of jump or call
instructions. Relative, absolute and indirect modes can be used to update the Instruction Pointer
register (IP), while the Code Segment Pointer register (CSP) can only be updated with an absolute
value. A special mode is provided to address the interrupt and trap jump vector table, which resides
in the lowest portion of code segment 0.
Mnemonic Target Address
caddr
(IP) = caddr
rel
(IP) = (IP) + 2*rel
(IP) = (IP) + 2*(rel+1)
[Rw]
(IP) = ((CP) + 2*Rw)
seg
-
#trap7
(IP) = 0000H + 4*trap7
Target Segment
-
-
-
-
(CSP) = seg
(CSP) = 0000H
Valid Address Range
caddr
rel
rel
Rw
= 0000H...FFFEH
= 00H...7FH
= 80H...FFH
= 0...15
seg = 0...255(3)
trap7 = 00H...7FH
Semiconductor Group
121
Version 1.2, 12.97