30Mar98@15:00h
Semiconductor Group
99
Version 1.2, 12.97
C166 Family Instruction Set
Instruction Description
RETI
Return from Interrupt Routine
RETI
Syntax
RETI
Operation
(IP)
←
((SP))
(SP)
←
(SP) + 2
IF (SYSCON.SGTDIS=0) THEN
(CSP)
←
((SP))
(SP)
←
(SP) + 2
END IF
(PSW)
←
((SP))
(SP)
←
(SP) + 2
Description
Returns from an interrupt routine. The PSW, IP, and CSP are popped off
the system stack. Execution resumes at the instruction which had been
interrupted. The previous system state is restored after the PSW has been
popped. The CSP is only popped if segmentation is enabled. This is indi-
cated by the SGTDIS bit in the SYSCON register.
E Restored from the PSW popped from stack.
Z Restored from the PSW popped from stack.
V Restored from the PSW popped from stack.
C Restored from the PSW popped from stack.
N Restored from the PSW popped from stack.
Addressing Modes
Mnemonic
Format
Bytes
RETI
FB 88
2
Condition Flags
E
Z
V
C
N
S
S
S
S
S