192
The VIC 20
User
Guide
How Characters
are
Displayed
First, let's take a brief look at how television works.
If
you look closely
at
your television screen, you'll notice
that
the picture
is
made up
of
individual dots arranged in rows. There are
about
500 dots
on
each row and
about 500 rows
on
the screen. Inside the picture tube, a beam
of
electrons
sweeps back
and
forth, one row
at
a time, lighting up each
dot
as it passes.
The incoming TV signal determines the brightness and color
of
each dot.
Although the process
of
generating and receiving a TV signal involves much
more, all you need to know here
is
that the television picture
is
made up
of
rows
of
dots.
The actual patterns
of
the rows
and
dots to be displayed are stored in
the VIC's memory
at
the locations specified in Figure 6-4. The VIC Chip
reads these locations and generates the signals that are sent to the television.
Character Memory
This leads us to the question
of
how the VIC chip knows which dots to
turn
on. You will recall
that
the characters displayed
on
the screen are stored
in the screen memory area.
As
it "paints" the screen, the VIC chip steps
through screen memory, picking up the characters one at a time. To deter-
mine which dots to
turn
on for a particular character, it looks in a table. This
table was worked out by Commodore,
and
stored in a special memory chip
in the VIC
20.
This chip, called a
ROM
(Read-Only Memory), retains the
information
that
was stored in it
at
the factory, even when power
is
turned
off. The area occupied by this table
is
called character memory. With a
POKE,
your program can tell the VIC chip
to
use a different area for
character
memory-one
that
you can fill with your own table. Finally, the
VIC chip must know what color to make the character. This information
comes from color memory. We've already examined the screen and color
memory areas, so we'll look
at
character memory, then discuss how to use
these areas to create displays.
FORMAT
OF
CHARACTER
MEMORY
Each character
on
the screen
is
made up
of
a matrix
that
is
eight dots
wide
and
eight high. A magnified view
of
the
letter"
A," for example, would
look like this.