Commodore 128 Programmer's Reference Manual page 232

Hide thumbs Also See for 128:
Table of Contents

Advertisement

222
COMMODORE 128
0
C64 BASIC-CHARACTER MODES
u
In standard character mode in C64 BASIC, the lower four bits of location 53272 control
where character memory is placed. As in C128 mode, the character ROM is actually
\ j
mapped into memory between 53248 ($D000) and 57343 ($DFFF). The ROM image
^
appears in RAM in the range 4096-8191 (in video bank 0) and 36864-40959 in bank 2,
since it must be accessible to the VIC chip in a 16K range in video banks 0 and 2. The
j j
character sets are not accessible in video banks 1 and 3. This ROM imaging in RAM
^
applies only to character data as seen by the VIC chip. These memory ranges are still
usable for data and programs and have no effect on the contents of RAM as far as your
's
programs are concerned.
[^
In C64 mode, the ROM image overlays the RAM underneath. A write operation
"bleeds through" to the RAM underneath, while a read returns a ROM value depending
on which memory configuration is currently in context. Since the VIC chip accesses
J
16K at a time, the character set images must appear in the 16K which the VIC chip is
^
currently addressing in video banks 0 and 2. Remember, in C128 mode, the character
sets are available in all video banks according to the value of the CHAREN bit in
j j
location 1.
LJ
You can change the location of character memory with the following command:
POKE 53272, (PEEK(53272) AND 240) OR Z
(j
where Z is a decimal value in the table in Figure 8-9.
The breakdown of the character sets is the same as in the C128 for the character
\ J
ROM (see Figure 8-8).
'
\j
C64 BASIC BIT MAP MODE
j
In bit map mode, bit 3 of location 53272 specifies the start of the bit map either at
(J
$0000 or $2000 depending whether the value of bit 3 is 0 or 1, respectively. Use the
following command:
,
,
POKE 53272 (PEEK (53272) AND 240) OR Z
U
where Z is zero if you want the bit map to start at $0000 in each bank, or Z = 8 if you
,
want to place the bit map starting at 8192 ($2000) in each video bank.
|
See Figure 8-10 for the arrangement of the bit map in each of the four 16K video
banks within the two RAM banks. If you switch video banks, don't forget to add the
$4000 (hex) offset for each bank above 0. See the Character Memory section under
j
C128 Bit Map Mode in the last section for more detail on the arrangement of bit maps in
^
memory.
u

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents