gnupic: Re: [gnupic] picdem fs usb and sdcc/gputils
Subject:
Re: [gnupic] picdem fs usb and sdcc/gputils
From:
Alessandro Zummo ####@####.####
Date:
3 Aug 2005 20:23:08 +0100
Message-Id: <20050803212230.13684860@inspiron>
On Thu, 14 Jul 2005 00:29:30 +0200
Alessandro Zummo ####@####.#### wrote:
> sdcc -c -mpic16 -p18f2550 crt0i.c
> sdcc -c -mpic16 -p18f2550 toggle.c
> gplink -o toggle.hex -s 18f4550.lkr crt0i.o toggle.o pic18f2550.lib
>
> however, gplink places the reset vector at 0x0000
> because the crt0i.o object specifies a fixed address.
>
> I had to modify crt0i.c adding a
> #pragma code _entry 0x800
> and removing the 0 after the __interrupt qualifier
> of the _entry function.
>
> It seems to work now, but I was wondering
> if this is the correct way to follow...
I've had no answers and so I took some more time to read the docs..
the best way is to recompile the crt like this:
sdcc -c -mpic16 -p18f4455 --ivt-loc=0x800 crt0.c
now I'm searching a way to place static data in program
space.. any clues?
--
Best regards,
Alessandro Zummo,
Tower Technologies - Turin, Italy
http://www.towertech.it