EasyManua.ls Logo

Apple IIe - Page 162

Apple IIe
320 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
162
Apple
lie
Users
Handbook
Configuration
TRACE
TRACE can
be
turned
off
by
executing
NO
TRACE.
US
fl
Applesoft
o
Integer
USR
passes
program
control
to
a
machine
language
subroutine
.
USR
's
argument
is
evaluated
and
then
placed in
the
floating
poin
t
accumulator
(9DH and A3H). A
USR
is
then
undertaken
to
OAH
,
which
is
the
subroutine's
starting address.
Addresses
OAH
to
OCH
must
contain
a
JMP
to
the
starting address
of
the
machine
language
subroutine.
Since
USR
is
a
function,
it
returns
a
numeric
value.
The
value
in
the
accumulator
is
returned
when
an
RTS
instruction
is
executed
.
Example
10
POKE
10,76 :
POKE
11,0 : POKE
12,32
20
FOR X
=
8192
TO
8198
30
READ
V
40
POKE X,V
50
NEXT
X
60
FOR X = 1
TO
4
70
PRINT
X, USR(X)
80
NEXT
X
90
DATA
165,157,
105
,3,133,157,
96
100 END
In
the
preceding
example,
line
10
pokes
the
location
of
the
machine
language
program
to
be
executed.
Lines
20
to
40
place
the
program
in
memory
. Lines
60
to
80
then
make
use
of
the
machine
language
program.
The
USR
in
this
example
multiplies
the
argument
by
16.

Other manuals for Apple IIe

Related product manuals