MC68HC08AZ60ACFU MOTOROLA [Motorola, Inc], MC68HC08AZ60ACFU Datasheet - Page 135

no-image

MC68HC08AZ60ACFU

Manufacturer Part Number
MC68HC08AZ60ACFU
Description
Microcontrollers
Manufacturer
MOTOROLA [Motorola, Inc]
Datasheet
MC68HC08AZ60A — Rev 0.0
MOTOROLA
;
;
;
;
This code works if the H register has been pushed onto the stack in the break
service routine software. This code should be executed at the end of the
break service routine software.
HIBYTE
LOBYTE
DOLO
RETURN
EQU
EQU
If not BW, do RTI
BRCLR
TST
BNE
DEC
DEC
PULH
RTI
BW — SIM Break WAIT
BW can be read within the break state SWI routine. The user can modify
the return address on the stack by subtracting one from it. The following
code is an example of this.
This status bit is useful in applications requiring a return to WAIT
mode after exiting from a break interrupt. BW can be cleared by
writing a logic ‘0’ to it. Reset clears BW.
5
6
BW,SBSR, RETURN
LOBYTE,SP
DOLO
HIBYTE,SP
LOBYTE,SP
1 = WAIT mode was exited by break interrupt
0 = WAIT mode was not exited by break interrupt
System Integration Module (SIM)
;
;
; If RETURNLO is not ‘0’,
; then just decrement low byte.
; Else deal with high byte, too.
; Point to WAIT opcode.
; Restore H register.
See if WAIT mode was exited by break.
System Integration Module (SIM)
Advance Information
SIM Registers
135

Related parts for MC68HC08AZ60ACFU