Re: [cc65] Running C program in a cart

From: Groepaz <groepaz1gmx.net>
Date: 2012-05-25 23:36:47
On Friday 25 May 2012, Ullrich von Bassewitz wrote:
> Good evening!
> 
> On Fri, May 25, 2012 at 03:28:38PM -0500, Payton Byrd wrote:
> >    Now, the cart compiles and loads into VICE, and when it's loaded as a
> >    Cart the screen and border turn white which is as expected based on
> >    the code in the header.  The compiled binary then drops straight into
> >    the CC65 initialization code that is normally at 2061 as you would
> >    expect.  The problem is that somewhere during initialization the
> >    system goes into an infinite loop of displaying garbage on the
> >    screen.
> 
> I don't know much about C64 carts, but aren't they enabled by modifying
> $01? If so, the startup code will probably disable the cart from where the
> code is loaded because it modifies $01 to switch off the BASIC ROM.

yes, if the crt0 changes $01 to bank out basic, then it would also bank out 
the cartridge - so what has to be done is writing a slightly adapted crt0 
(which probably should also copy the DATA segment into ram, i guess).
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo@musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.
Received on Fri May 25 23:36:48 2012

This archive was generated by hypermail 2.1.8 : 2012-05-25 23:36:51 CEST