Page 1 of 1

error message when trying to build the project

PostPosted: Wed Oct 27, 2010 3:31 am
by TheBoD
I am trying to build the rtos pilot with gluon srce ver 0.5. When I run the build it always fails with the message shown below. I have included MPLAB C30 lib in the library path and even move the spi.h file into the same directory as the gluon pilot header files but without success. Would appreciate any help. Thanks in advance.

I assume I can download the output into the gluonpilot module directly using the DS30 bootloader ?

"tmp\dataflash.o(.text+0xc4): In function `dataflash_open':
E:\Gluonpilot downloads\Gluonpilot_src_v0.5\Firmware\rtos_pilot\..\lib\dataflash\dataflash.c:61: undefined reference to `OpenSPI2'
tmp\scp1000.o(.text+0x52): In function `scp1000_init':
E:\Gluonpilot downloads\Gluonpilot_src_v0.5\Firmware\rtos_pilot\..\lib\scp1000\scp1000.c:37: undefined reference to `OpenSPI2'
Link step failed."

Re: error message when trying to build the project

PostPosted: Wed Oct 27, 2010 11:24 am
by Mitch
I'm getting clean builds using both the v.5 zip download and with svn r75. You shouldn't have to move any files around in the default directory structure. OpenSpi2 is a C30 library function. It's not being found by the linker. Check your library default search path with Project->Set Language Tool Locations. By default C30 libraries are installed at C:\Program Files\Microchip\MPLAB C30\lib.

What version of mplab and c30 are you using? There were some library changes from earlier versions. I'm at MPLAB v8.56 and C30 3.24.

Try a Project->Clean to get rid of object code and rebuild.
Did you change anything in project->build options?
Redownload the zip and drag the whole firmware folder to your desktop and retry the build.

You can use the boot loader and it works but I've had less than sterling performance with it (it usually takes a few attempts). I usually use an ICD2 to download built firmware from MPLAB to avoid the difficulties.

Re: error message when trying to build the project

PostPosted: Thu Oct 28, 2010 2:31 am
by TheBoD
Thanks for the suggestions. I checked the library paths and all looked OK.

It finally worked when I added the OpenSPI2.c source file to the lib folder in the rtos_pilot.mcp. I am runnibf IDE v8.36 and compiler MPLAB C30 License Manager Version v3.00.


Thanks for your advice on the bootloader tool. I have an ICD3 which came with an explorer 16 board that I have. I can see the Gluonpilot module has connectors for an ICD connection but I don't know how to connect the ICD3 to these. There seem to be more connections on the cable from the ICD3 than there are pins on the gluonpilot module.

How did you connect up the ICD2 ?

Thanks.

Re: error message when trying to build the project

PostPosted: Thu Oct 28, 2010 12:09 pm
by Mitch
I'm referencing ICD2. It has a 6 pin sip connector. In order

white vpp
black vcc = vdd+
red gnd = vss-
green pgd
yellow pgc
blue pgm

White is vpp, the others are in order and the blue isn't used (hangs over the end of the 5 pin header on the gluonboard).

I've had some other problems with rtos pilot using an early version of mplab c30. About a month ago, had clean builds but bizzare interrupts that conflicted with what Tom was getting. Upgrading the compiler resolved the problem. Upgrade is free from microchip.

Re: error message when trying to build the project

PostPosted: Thu Oct 28, 2010 12:30 pm
by Rico21
Hi,
I'm using ICD3 and I do not have any problem. Please find below the connection you have to do according to the signals of the interface discribed in ICD3 documentation:

ICD3 connector ICSP connecteur on Gluonpilot
pin # pin#
1 MCLR/VPP -------------- 5 VPP
2 VDD ---------------- 4 3.3V
3 VSS ground --------------- 3 grd
4 PGD icspad --------------- 2 PGD
5 PGC icspcl --------------- 1 PGC
6 LVP (not connected)

Re: error message when trying to build the project

PostPosted: Thu Oct 28, 2010 12:33 pm
by Mitch
I just edited my post with the descriptions - looks like the same connector!

Re: error message when trying to build the project

PostPosted: Sun Oct 31, 2010 2:08 am
by TheBoD
I finally got around to testing the ICD3 link today. Worked well .... thanks to everyone for all your help. Hope to get to connecting up the RC gear tomorrow and moving along with the benchtesting.

Re: error message when trying to build the project

PostPosted: Sun Oct 31, 2010 9:52 am
by Tom
Alright! Good luck!