gnupic@linuxhacker.org

gnupic@linuxhacker.org


Subject: Re: PIC18 __CONFIG directive
From: Vangelis Rokas
Date: Fri, 18 Apr 2003 14:58:20 +0300

----- Original Message -----
From: "Craig Franklin" <craigfranklin@attbi.com>
To: "Vangelis Rokas" <vrokas@otenet.gr>
Cc: "GNUPIC" <gnupic@linuxhacker.org>
Sent: Saturday, May 17, 2003 10:12 PM
Subject: Re: PIC18 __CONFIG directive


> I little clarification for those that are listening.  The only missing
> support is for COFF outputs.  Absolute output works.  I ran out of time
> and never went back to finish it.  IDLOCS for 18xx devices also isn't
> supported for COFF.

    I guess that if we manage to make CONFIG to work, IDLOCS will be a piece
of cake!

> I did have a semi-functional hack that did just that.  There were other
> problems.  The user could skip some of the settings leaving holes in the
> data.  The user can place the directives in a strange order.  The user
> could interleave other sections within the config directives.  My hack
> wasn't nearly bullet proof so I elected not to commit it.

    What is the problem with this? When I read the sources I saw that when
directive.c was about to emit a configuration byte, it acquired the byte
from the coff_xxxx functions and then it emitted the data. This in fact
happens twice (as I can remember) one the first and on the second pass. So
memory is initialized and marked as allocated. There is no problem if
configuration directives are spread in the source (or am I wrong?!!!!)

> Maybe the data could be stored until the end of assembly.  Then one
> config section created.  Just an idea.  Let me know if you find
> something that works.  If you need this soon and don't have a solution,
> I can work it.  Just let me know.

    That's another good idea. The only problem is that I do not know yet
much about coff and the rest. So it would be very difficult for to cope with
it. I'll try later this week to see what can I do.
    No, I do not need it now, I just wanted to see why gpasm complaints when
I compile programs with SDCC and I thought it would be a good test (for me)
to fix the problem. Do not bother if you wouldn't anyway.

Regards,
Vangelis




gnupic@linuxhacker.org