EasyManua.ls Logo

Commodore Plus 4 - Page 275

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
6502
Microprocessor
263
The
speed
of
the
flashing
can
be
changed
by
changing
which
bit
of
the
jiffy
clock
is
examined
at
$200C
and
$2012.
INC—Increment
Memory
"by
1
The
value
currently
in
the
operand
is
incremented
by
1.
Operation:
M
+
1
Addressing
Mode
Zero
page
Zero
page,
X
Absolute
Absolute,
X
-
M
Syntax
INC
$hh
INC
$hh,X
INC
$hhhh
INC
$hhhh,X
Op
E6
F6
EE
FE
Flags
Affected:
N,
Z
>de
Bytes
Cycles
2
2
3
3
5
6
6
7
The
value
stored
in
the
operand
is
increased
by
1.
If
the
result
is
negative,
the
N
flag
is
set
to
1;
otherwise
it
is
cleared
to
0.
If
the
result
is
zero,
the
Z
flag
is
set
to
1;
otherwise
it
is
cleared
to
0.
It
should
be noted
that
the
carry
flag
is
NOT
affected.
That
is,
an
increment
from
$FF
to
$00
does
NOT
result
in
the
carry
flag
being
set.
Example:
The
upper
left
screen
location
is
cycled
through
all
of
the
available
screen
codes.
The
INC
instruction
is
used
to
update
the
character.
2000
A2
00
LDX
#$00
2002
EE
00
OC
INC
#0000
2005
A5
A5
LDA
$A5
2007
29
02
2009
DO
FA
200B
A5
A5
200D
29
02
200P
FO
FA
2011
CA
2012
DO
EE
2014
00
AND
#102
BNE
12005
LDA
$A5
AND
#$02
BEQ
I200B
DEX
BNE
$2002
BRK
.X
counts
the
256
screen
codes.
Increment
the
upper
left
screen
code
by
1.
Now
wait.
Get
the
value
in
the
jiffy
clock.
Look
at bit
1.
Wait
until
it
is
off.
Get
the
value
in
the
jiffy
clock.
Look
at
bit
1.
Wait
until
it
is
on.
Decrement
the
counter.
If
not done,
continue.
Stop
processing.
The
speed
of
the
updating
can
be
changed
by
changing
which
bit
of
the
jiffy
clock
is
examined
at
$2007
and
$200D.

Other manuals for Commodore Plus 4

Related product manuals