Re: [cc65] CA65 Relocatable code?

Date view Thread view Subject view

From: Ullrich von Bassewitz (uz_at_musoftware.de)
Date: 2003-10-31 12:01:04


Hi!

On Fri, Oct 31, 2003 at 02:52:51PM +1030, Todd Elliott wrote:
> It seems that the .reloc command really doesn't work. I expected the PC
> counter to go back to the value as set by the first .org directive working
> downwards. The PC value seems to be a little bit off.

Since the absolute code is placed in the same segment, the PC will have the
value before the absolute code + the size of the absolute code. If you don't
want this, you will have to put the absolute code into its own segment and
place it, using the linker.

> Am I missing something? I need to load in special code along with the main
> program, and then put it somewhere else, like inside the disk drive's RAM,
> etc. The code that follows the special code doesn't have their PC values
> lined up.

This sounds like you want to use a separate segment for the special code. See
MagerValps very helpful comments for more information.

Regards


        Uz


-- 
Ullrich von Bassewitz                                  uz_at_musoftware.de
----------------------------------------------------------------------
To unsubscribe from the list send mail to majordomo_at_musoftware.de with
the string "unsubscribe cc65" in the body(!) of the mail.


Date view Thread view Subject view

This archive was generated by hypermail 2.1.3 : 2003-10-31 12:01:26 CET