Re: [cc65-devel] Binary loads of overlays on various targets
cc65 - a freeware C compiler for 6502 based systems
Brought to you by:
gpz
|
From: Oliver S. <ol...@we...> - 2013-05-29 09:35:31
|
Hi, >> Okay, so if the overlaydemo and multidemo programs are supposed to be >> more than a proof-of-concept then they should use cbm_load() on the >> C64 - right? > yes, generally _anything_ that accesses files should use LOAD or SAVE if > possible. >> So >> https://github.com/oliverschmidt/cc65/blob/master/cfg/c64-overlay.cfg >> https://github.com/oliverschmidt/cc65/blob/master/cfg/c128-overlay.cfg >> should define 2-byte headers for the overlay files. And as the overlay >> load address is well known at link time the headers should contain the >> correct load address so that cbm_load() can be called with NULL as >> third parameter - correct? > yes again - generally using LOAD implies a loading address and "usually" that > address also contains the actual load address =) (it really contains the > original address of the saved area, which may be different in complex > situations) I changed the linker configs and sample programs as discussed above: https://github.com/oliverschmidt/cc65/commit/7572834ebf5db5f5b0a594863d684a65a97b123d Regards, Oliver |