Instruction manual

line
1000.
There is a subroutine for each
of
the least significant digit and a
subroutine for the next most digit.
To
develope the
digit
10,
we must use
two
of
the subroutines. This would also
be
the case for any number greater than
10.
The program is separated by
REM
statements. Each module will begin with
a
REM
statement that defines the func-
tion
of
the subroutine, and
if
the reader
analyses each module
he
will get a clear
picture
of
how
the
numbers
are
generated and placed on the
monitor
screen.
The program listing beginning at
line
3500,
gives the object code listing
for the fast screen erase. This
is
the
machine code that is loaded
into
user
memory when the BASIC program inĀ·
itializes the user memory through the
BASIC subroutine at line
2899.
The
BASIC program listing has the fast
screen erase routine loaded at
12264
to
12287
decimal. This was loaded at the
top
of
a 12k memory. If your
C1
P does
not
have this much memory, you will
have to change the program
to
work
with
the amount
of
memory that you may
have in your system. The program listing
gives the necessary changes for either
an 8K
or
4K memory system. These
changes are listed starting at line 3500.
A word of caution must
be
conveyed at
this time. The user must set the memory
size
of
his machine to reflect the size
of
memory
that
will allow the machine
code routine
to
be intered and protected.
That is, the memory size must be set
when bringing up BASIC
to
less than the
beginning
of
the machine code routine.
If
your system has only 4K
of
memory,
set the memory size
to
4050
decimal.
If
your memory has 8K, set the memory
size
to
8160.
If
you should have 12K, as
my memory does, then set the size
to
12263. Be sure
that
you
change
subroutine beginning at 2899 for your
personal system depending on the
amount
of
memory your system has
available.
In conclusion,
I have presented
what I think will help you with the pro-
gramming
techniques
needed
to-
understand the inner workings
of
the
C1
P's graphics capabilities, and the use
of
BASIC as a tool
to
be utilized with the
graphics capabilities
of
the
C1
P,
or
other
Challenger
computers.
The
developement
of
large
graphics
numbers
is
only one example
of
how the
expanded graphics set
of
the
C1
P can be
used. The same techniques used in this
article can be utilized for more complex'
exploration
of
the graphics and BASIC
programming functions
to
develope pro-
grams such as games etc. In a future ar-
ticle, I
will
further expand the example
program here to include a larger number
set and have the
C1
P
function
as a
twelve hour
clock
running unde.r a BASIC
program. Until then, good luck.
19:64
1300
FOR
A=
54000
TO
54064
STEP
32
1310
POKE
A,161:
N~T
A
1320
FOR
A=
54064
TO
54066
1330
POKE
A,161:
NEXT
A
1340
FOR
A=
54002
TO
54130
STEP
32
1350
POU
A,161:
NEXT
A
1360
RETURN
1399
R.iI4
GENERATE
LSD
5
1400
FOR
A=
54000
to
54002
1410
POKB
A,161:
HEXT
A
1420
FOR
A=
54064
TO
54066
1425
POU
A,161:
HnT
A
1430
lOR
A=
54128
TO
54130
1440
POlE
A,161:
HiXT A
1450
POKB
54032,161:
POKE
54098,161
1460
R.B!rollH
1499
R])I
GEN
iliATE
LSD
6
1500
FOR
A=
54000
TO
54002
1510
POKE
A,161:
NEAT
A
1520
FOR
A=
56064
TO
54066
1530
POKE
A,161:
NEXT
A
1540
FOR
A=
54128
to
54130
1550
l'OKE
A,
161:NEXT A
1560
pOKE
54032,161:
POKE
54096,161:
POKE
54098,161
1570
RETURN
1599
hat
GENERATE
LSD
7
1600
FOR
A= 54000
TO
54002
1610
POKE
A,161:
NE:.T
A
1620
FOR
A=
54002
TO
54130
STEP
32
1630
POKE
A,161:
NEXT
A
1640
RETURN
1699
RE;~
GENERATE
LSD
8
1700
FOR
A=
54000
TO
54128
ST~~
32
1710
POIU:
A,161;
NEXT
A
1720
FOR
A=
54002
TO
54130
STEP
32
1730
POKE
A, 161:
NEl>.T
A
1740
FOR
k=
54001
TO
54129
STEP
64
1750
POKE
A,161:
NEXT
A
1760
RETUHN
1799
REItl
GENERATE
LSD
9
1800
FO~
A=
54002
TO
54130
STEP
32
1810
POJ(E
A,1E1:
N&.T A
1820
FOR
A=
54000
TO
54002
1830
POKE
A.161:
UXT
A
1840
FOR
A=
54064
TO
54066
1850
POKE
A, 161:
N~T
A
1860
FOil
A=
5412tl
TO
54130
1870
POKE
A,
161:
HEXT
A
1880
POKE
54032,161
1890
RETURN
1899 RDil
GENERATE
SMD
1
1900
FOB.
A=
53998
TO
54126
STEP
32
1910
POKE
A,
161:
HEU
A
1930
RETURN
1999
REW
GENEKA~E
LSD
0
MICRO
--
The 6502 Journal
December, 1979