MOTOROLA
INITIALIZATION AND PROGRAMMING EXAMPLES
M68HC16 Z SERIES
E-6
USER’S MANUAL
E.1.2 ORG00000.ASM
*
Title : ORG00000
*
Description : This file is included to set up the reset
*
vector ($00000 - $00006).
*
****************************************************************************
ORG
$0000
;put the following reset vector
;information
;at address $00000 of the memory map
DC.W
$0010
;zk=0, sk=1, pk=0
DC.W
$0200
;pc=200 -- initial program counter
DC.W
$03FE
;sp=03fe -- initial stack pointer
DC.W
$0000
;iz=0 -- direct page pointer
E.1.3 ORG00008.ASM
*
Title : ORG00008
*
Description : This file initializes the interrupt/
*
exception vectors ($0008 - $01fe).
*
If an interrupt occurs requiring the use of
*
any of these vectors, program flow will
*
continue at the label “bdm” which must be
*
added by the programmer to his/her code to
*
put the program into background debug mode
*
or some other appropriate routine.
*
*********************************************************************
ORG $0008
;put the following code in memory
;starting at address $0008 of the map
;(after the reset vector).
;there is a total of 252 of these
;”DC.W BDM” lines
;Vector Number (in base 10)
;and Vector Description
DC.W
BDM
;4
Breakpoint (BKPT)
DC.W
BDM
;5
Bus Error (BERR)
DC.W
BDM
;6
Software Interrupt (SWI)
DC.W
BDM
;7
Illegal Instruction
DC.W
BDM
;8
Divide by Zero
DC.W
BDM
;9
(Unassigned Reserved)
DC.W
BDM
;10
(Unassigned Reserved)
DC.W
BDM
;11
(Unassigned Reserved)
DC.W
BDM
;12
(Unassigned Reserved)
DC.W
BDM
;13
(Unassigned Reserved)
DC.W
BDM
;14
(Unassigned Reserved)
DC.W
BDM
;15
Uninitialized Interrupt
DC.W
BDM
;16
(Unassigned Reserved)
DC.W
BDM
;17
Level 1 Interrupt Autovector
DC.W
BDM
;18
Level 2 Interrupt Autovector
DC.W
BDM
;19
Level 3 Interrupt Autovector
DC.W
BDM
;20
Level 4 Interrupt Autovector