Reti (Return From Interrupt) - Fujitsu FR Family Instruction Manual

32-bit microcontroller
Hide thumbs Also See for FR Family:
Table of Contents

Advertisement

CHAPTER 7 DETAILED EXECUTION INSTRUCTIONS
7.93

RETI (Return from Interrupt)

Loads data from the stack indicated by "R15" to the program counter (PC) and program
status (PS), and retakes control from the interrupt handler.
This instruction requires the S flag in the register (CCR) to be executed in a state of "0".
Do not manipulate the S flag in the normal interrupt handler; use it in a state of 0 as it is.
This instruction has no delay slot.
At the time this instruction is executed, if the value of the interrupt level mask register
(ILM) is in the range 16 to 31, only new "ILM" settings between 16 and 31 can be
entered. If data in the range 0 to 15 is loaded in memory, the value 16 will be added to
that data before being transferred to the "ILM". If the original "ILM" value is in the range
0 to 15, then any value between 0 and 31 can be transferred to the "ILM".
■ RETI (Return from Interrupt)
Assembler format:
RETI
(R15) → PC
Operation:
R15 + 4 → R15
(R15) → PS
R15 + 4 →R15
Flag change:
S, I, N, Z, V, and C: Change according to values retrieved from the stack.
Execution cycles:
2 + 2a cycles
Instruction format:
192
S
I
N
Z
C
C
C
C
MSB
1
0
0
1
V
C
C
C
0
1
1
1
0
0
LSB
1
1
0
0
0
0

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Fr series

Table of Contents