[Prev] [Next] [Contents] [Commodore] [New] [Search] [Home]

System Specification for C65Fred BowenMarch 1, 1991

What does this Mean ? Here is what the 64K memory map looks like in various configurations (i.e., as seen by the processor):

C64 mode: $E000-$FFFF Kernel, Editor, BASIC overflow area
$D000-$DFFF I/O and Color Nybbles, Character ROM
$C000-$CFFF Application RAM
$A000-$BFFF BASIC 2.2
$0002-$9FFF RAMLO. VIC screen at $0400-$7FF.
BASIC program & vars from $0800-$9FFF
C65 mode: $E000-$FFFF Kernel, Editor ROM code
$D000-$DFFF I/O and Color Bytes (CHRROM at $29000)
$C000-$CFFF Kernel Interface, DOS ROM overflow area
$8000-$BFFF BASIC 10.0 Graphics & Sprite ROM code
$2000-$7FFF BASIC 10.0 ROM code
$0002-$1FFF RAMLO. Vic screen at $0800-$0FFF
BASIC prgs mapped from $02000-$0FF00
BASIC vars mapped from $12000-$1F7FF
C65 DOS mode: $E000-$FFFF Kernel, Editor ROM code
$D000-$DFFF I/O (CIA's mapped out), Color Bytes
$C800-$CFFF Kernel Interface
$8000-$C3FF DOS ROM code
$2000-$7FFF [don't care]
C65 Monitor: $E000-$FFFF Kernel, Editor ROM code
$D000-$DFFF I/O and Color Bytes
$C000-$CFFF Kernel Interface
$8000-$BFFF [don't care]
$6000-$7FFF Monitor ROM code
$0002-$5FFF RAMLO.

It's done this way for a reason. The CPU MAPPER restricts the programmer to one offset for each 32K-byte half of a 64K-byte segment. For one chuck of ROM to MAP in another chuck with a different offset, it must do so into the other half of memory from which it is executing. The OS does this by never mapping the chunk of ROM at $C000-$DFFF, which allows this chunk to contain the Interface/MAP code and I/O (having I/O in context is usually desireable, and you can't map I/O anyhow). The Interface/MAP ROM can be turned on and off via VIC register $30, bit 5 (ROM@$C000), and therefore does not need to be mapped itself. Generally, OS functions (such as the Kernel, Editor, and DOS) live in the upper 32K half of memory, and applications (such as BASIC or the Monitor) live in the lower 32K half. For example, when Monitor mode is entered, the OS maps out BASIC and maps in the Monitor. Each has ready access to the OS, but no built-in access to each other. When a DOS call is made, the OS overlays itself with the DOS (except for the magical $C000 code) in the upper 32K half of memory, and overlays the application area with DOS RAM in the lower 32K half of memory.

[Prev] [Next] [Contents] [Commodore] [New] [Search] [Home]
This page has been created by Sami Rautiainen.
Read the small print. Last updated May 06, 2002.