4

On a Commodore 64, if I Load "*",8,1 and the file's address (first two bytes on disk) is $D000, will it load to the RAM under the I/O space?

In other words, does the KERNAL loader properly adjust the memory configuration during a load?

What about an 8K file loaded into $C000 - $DFFF?

0

2 Answers 2

4

No it doesn't adjust the memory configuration - which is why loading an 'executable' file (i.e. start address of $0800) bigger than 202 blocks (about 50 KB) using a standard kernal will crash a C64. Same for your 8 KB/$C000 example.

5

The standard load routine will not handle this.

If you need to load under $D000-$DFFF you will have to handle it yourself; you can still use kernal routines (such as OPEN, CHKIN and CHRIN) to do it but will have to buffer and transfer or set the bank configuration for each byte stored.

Loading under BASIC ($A000-$BFFF), $C000-$CFFF or KERNAL space ($E000-$FFFF) is no problem with the standard loader, except if it crosses the I/O space on the way (so separate files that go into these areas can be loaded).

When putting together a C64 production, you'd typically use a packer/cruncher (such as Exomizer) to compress data - a feature of these tools is typically also to handle transfer under I/O space during decompression.

Not the answer you're looking for? Browse other questions tagged .