Commodore 128 Programmer's Reference Manual page 313

Hide thumbs Also See for 128:
Table of Contents

Advertisement

PROGRAMMING THE 80-COLUMN (8563) CHIP
303
n
n
20 and 21 for each character attribute to the right of the HOME position. To address the
character attribute directly below the HOME position (row 2, column 1), add an offset
of 80 to the contents of registers 20 and 21. To address the character attribute of the
character in the lower-left corner of the 80 by 25 frame, add a decimal offset of 1920
(24 x 80).
DISABLING CHARACTER ATTRIBUTES
Many applications programs for the 8563 chip do not need to assign the character
attributes. The 8563 has a bit that allows attributes to be disabled, saving a considerable
amount of RAM. Bit 6 of register 25 determines whether or not attributes are enabled. If
bit 6 is set (1), attributes are enabled: if the value of bit 6 is 0, attributes are disabled.
"1
When attributes are disabled, the attribute portion of 8563 RAM may be used for other
I
purposes. If attributes are disabled, only one set of 256 characters is available, and
underlined, blinking and reverse video attributes are not available. In addition, all
p
characters are displayed in the same foreground color as determined by bit 4 through 7
j |
of register 26. The background color is still determined by the lower four bits (3-0) of
register 26, regardless of whether attributes are enabled or not. The screen border and
Rthe vertical and horizontal intercharacter spaces default to the background color.
Display memory may contain more memory locations and attributes than can be
displayed at a single time in an 80 by 25 frame. This portion of display memory may be
displayed by changing the contents of registers 12 and 13, the Display Start address, and
-"1
registers 20 and 21, the Attribute Start address, to reflect a new start of display memory
and attribute storage. The screen (frame) may be scrolled vertically by incrementing of
decrementing the values of the display memory pointer and attribute start addresses.
«-*
This provides a way to vertically scroll forward or backward through display memory.
! I
In addition to scrolling vertically through display memory, the 8563 has a feature
that allows scrolling through display memory in the horizontal direction. Both of these
topics are covered later in this chapter.
CHARACTER DEFINITIONS
The character definitions residing in 8563 RAM specify the character patterns you see
on the 80-column screen. The character patterns in memory define the pixel formation
of each member of the character set visually represented on the screen. The character
definitions can be redefined by your application program.
The default memory range for the character definitions is locations $2000 through
$3FFF in 8563 RAM. This range is a total of 8K (8192 bytes). This is enough memory
to represent two character sets of 256 characters each. The attribute bit 7 of each
attribute byte selects either of the character sets for each character position within a
frame.
The 8563 characters are represented by either 16 or 32 bytes, depending on the
value of the lower five bits (4-0) of register 9. If the value of the lower five bits of
n

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents