Download Print this page

Motorola EXORdisk II User Manual page 212

Advertisement

PATCH COMMAND
21.2 -- PATCH Command Set
Line
Console Display
01
=PATCH TESTPROG
02
8200'30
03
>0
04
OFFSET=8200
05
:>F7
06
82F7 CE
07
>.
(~MP
$8317 GO TO THE PATCH AREA OF PROGRAM)
08
>8317,Q(LDX #O+$A THE LDX OVERLAYED BY THE JMP
09
=>STX
0+$D2
10
=>SWI THIS IS A SYSTEM FUNCTION CALL)
11
. 110
12
. (BEG *+5 IF NO ERRORS,
CONTINUE
13
=>JMP
0+$113
GO PROCESS ERROR
14
=~LDX
X
PICK
UP
THE
POINTER
15
=>LDAA Q,X GET A CHARACTER
16
=>CMPA
#'1
IS IT UNIT 1?
17
=>BNE *-10 GO PROCESS ERROR
18
=>~MP
$82FD RETURN TO MAIN CODE
19
20
>G
21
=
In
the abo
v. e e x
amp
1 e , l
in
e 03 lila
sus e d t
0
dis
p'
1 a y
the
value of the current offset.
Line
05
was used to display the
contents
OT
location
$F7J
relative to the
beginning
of
the
file.
Line
07
was
used to enter
the
instruction mnemonic
decode
mode to modify the current location
(offset
+
$F7).
Three locations were changed as a result of entering line
07.
Line 08 was used to reenter the instruction
mnemonic
decode
mo
d
e
i
h oute
v
e r
I
t his
time
a
b
sol ute -
1
0
cat i on
$831 7
wa s the
address where a patch was to be placed.
Line
11
was used
to
insert a hexadecimal constant into the location following the
previously entered SWI instruction.
Line
12
was
used
to
return
to
the
instruction
mnemonic
decode
mode
at
the
location following the hexadecimal
constant
inserted
using
line
11.
Line
19
was used to finally exit the
inst~uction
mnemonic decode mode.
Line 20 was used
to
exit
the
PATCH
command
and
return
control
to
MDOS.
Comments
were
used
throughout the instruction mnemonic decode mode
to
document
what-the patCh does.
21.3
Special Considerations
The period symbol
<.)
can be used with any PATCH command
that
requires
an
address
as
an
argument.
The
value
associated
with the period symbol is the absolute address of
the current location minus the value of the
current
offset.
Since
the
offset
is
automatically
added
to
most
Or
the
command parametersl
the resulting value for the period symbol
Page
21-15

Advertisement

loading

This manual is also suitable for:

Exordisk iii