Re: [cc65] Creating a Cartridge Program with cc65

From: Ullrich von Bassewitz <uz1musoftware.de>
Date: 2007-05-01 23:40:40
Hi!

On Tue, May 01, 2007 at 08:04:39AM -0400, Bill Katsak wrote:
> I have changed around the linker configuration to try to get something
> that works. If I compile a hello world program into a binary, load it
> like a prg file and do a SYS command to start the code from the $8000
> range location, it runs fine. However, if I change the headers around,
> adjust the offsets, and load the same program as a cartridge ROM, it
> just comes back to READY and never runs.

If I remember correctly, you need to add a header to the generated binary,
something like "CBM80" + a warm and a cold start vector.

> Am I going about this all wrong? Has anyone had some experience with
> this? I also know that I will have a problem once I get my real program
> going because I will need to copy my DATA segment from ROM to RAM, and I
> am not sure how to modify my startup code to do this.

If you're using the standard segments, all you need to do is to call a routine
named "copydata" from your startup code. It exists in the copydata.s module in
the lib/common directory.

Regards


        Uz


-- 
Ullrich von Bassewitz                                  uz@musoftware.de
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Tue May 1 23:40:55 2007

This archive was generated by hypermail 2.1.8 : 2007-05-01 23:40:59 CEST