Lapis ML610Q111 User Manual page 79

Table of Contents

Advertisement

State B: Non-maskable interrupt is being processed
B-1: When a subroutine is not called
• Processing immediately after the start of interrupt routine execution
Specify the RTI instruction to return the contents of the ELR register to PC and those of the EPSW register to PSW.
B-2: When a subroutine is called
B-2-1: When a subroutine is not called for an interruption routine to a run time by a program
• Processing immediately after the start of interrupt routine execution
"PUSH ELR, EPSW" are specified and the return address of an interruption and the status of EPSW are evacuated to
a stack.
• Processing at the end of interrupt routine execution
Specifying "POP PC, PSW" instead of a RTI supervisor call, the save data of EPSW returns the save data of the
return address of an interruption to PC at PSW. B-2-2: When a subroutine is called for an interruption routine to a run
time by a program
• Processing immediately after the start of interrupt routine execution
"PUSH LR, ELR, EPSW" are specified and the return address of an interruption, the return address of a subroutine,
and the status of EPSW are evacuated to a stack.
• Processing at the end of interrupt routine execution
Specifying "POP PC, PSW, LR" instead of a RTI supervisor call, as for the save data of the return address of an
interruption, the save data of EPSW returns the save data of LR to LR to PC to PSW.
Example of description: State B-1
Intrpt_B-1;
RTI
Example of description: B-2-2
Intrpt_B-2-2;
PUSH ELR, EPSW,
LR
:
:
:
BL Sub_1
:
POP PC, PSW, LR
FEUL610Q111
; B-1 state
; Return PC from ELR
; Return PSW form EPSW
; End
; Start
; Save ELR, EPSW, LR at
the beginning
; Call subroutine Sub_1
; Return PC from the stack
; Return PSW from the
stack
ML610Q111/ML610Q112 User's Manual
Example of description: State B-2-1
Intrpt_B-2-2;
; Start
; Save ELR and EPSW at the
PUSH ELR, EPSW
:
:
:
POP PC, PSW
; Return PC from the stack
; Return PSW from the stack
; End
Sub_1;
:
:
:
RT
; Return PC from LR
; End of subroutine
Chapter 5 Interrupts (INTs)
beginning
5-26

Advertisement

Table of Contents
loading

Related Products for Lapis ML610Q111

This manual is also suitable for:

Ml610q112

Table of Contents