SN8P1600
8-bit micro-controller
JmpSub0:
; Subroutine 1
jmp
JmpExit
JmpSub1:
; Subroutine 2
jmp
JmpSub2:
jmp
JmpExit
; Subroutine 3
JmpExit
JmpExit:
ret
;Return Main
;-------------------------------------------------------------------------------
; Isr (Interrupt Service Routine)
; Arguments :
; Returns
:
; Reg Change:
;-------------------------------------------------------------------------------
Isr:
;-----------------------------------
; Save ACC
;-----------------------------------
b0xch
A,AccBuf
;B0xch instruction do not change C,Z flag
b0mov
b0mov
A,PFLAG
PflagBuf,A
;-----------------------------------
; Interrupt service routine
;-----------------------------------
b0bts0
jmp
b0bts0
jmp
FP00IRQ
INT0isr
FTC0IRQ
TC0isr
;-----------------------------------
; Exit interrupt service routine
;-----------------------------------
IsrExit:
b0mov
b0mov
b0xch
A, PflagBuf
PFLAG, A
A,AccBuf
;Restore the PFlag
;Restore the Reg. A
;B0xch instruction do not change C,Z flag
;Exit the interrupt routine
reti
SONiX TECHNOLOGY CO., LTD
Page 81
Revision 1.94