EasyManua.ls Logo

Commodore Plus 4 - Page 279

Commodore Plus 4
464 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...
The
6508
Microprocessor
267
None
of
the
flags
is
affected.
Hence,
they
may
be
used
to
transfer
information
between
the
main
program
and
the
subroutine.
Example:
This
program
cycles
the
two
upper
left
character
locations
on
the
screen
through
all
possible
values.
They
are
changed
alternately,
with
a
brief
wait
in
between.
The
wait
routine
is
a
subroutine
and
is
called
using
the
JSR
instruction.
.
2000
AS
00
LDX
#$00
.
2002
EE
00
OC
INC
$0000
.
2005
20
12
20
JSR
$2012
.
2008
EE
01
OC
IUC
$0001
.
200B
20
12
20
JSR
$2012
.
200E
CA
DEX
.
200P
DO
Fl
BITE
$2002
.
2011
00
BRK
.
2012
A5
A5
LDA
$A5
2014
29
08
2016
DO
FA
2018
A5
A5
201A
29
08
201C
FO
FA
201E
60
AJKTD
#$08
BITE
$2012
LDA
$A5
AKTD
#$08
BEQ
$2018
RTS
.X
counts
all
the
possible
values.
Next
character
for
the
first
location.
Call
the
wait
subroutine.
Next
character
for
the
second
location.
Call
the
wait
subroutine.
Decrement
the
counter.
If
not
done,
go
back.
Stop
processing.
Start
of
subroutine.
Load
the
jiffy
clock.
Look
at
bit
3.
Wait
until
it
is
off.
Load
the
value
of
the
jiffy
clock.
Look
at
bit
3.
Wait
until
it
is
on.
Return
from
the
subroutine.
LDA—Load
Accumulator
with
Value
from
Memory
The
value
currently
in
the
location
specified
by
the
operand
is
placed
in
the
accumulator.
Operation:
M
A
Addressing
Mode
Syntax
Flags
Affected:
N,
Z
Opcode
Bytes
Cycles
Immediate
Zero page
Zero
page,
X
Absolute
Absolute,
X
Absolute,
Y
(Indirect,
X)
(Indirect),
Y
LDA
#$hh
LDA
$hh
LDA
$hh,X
LDA
$hhhh
LDA
$hhhh,X
LDA
$hhhh,Y
LDA
($hh,X)
LDA
($hh),Y
A9
A5
B5
AD
BD
B9
Al
Bl
2
2
2
3
3
3
2
2
2
3
4
4
4*
4*
6
5*
*
Add
1
when
a
page
boundary
is
crossed.

Other manuals for Commodore Plus 4

Related product manuals