auav3 MPLAB8 trunk has build error

110 views
Skip to first unread message

William Premerlani

unread,
Jan 15, 2015, 9:18:24 PM1/15/15
to Robert Dickenson, uavdevboard-dev
Robert,
I note that the auav3 MPLAB8 trunk project has a build error, using everything straight out of the repository. The auav3 MPLABX trunk project builds just fine. I noticed the same pattern in my helical controls branch, the MPLAB8 version for auav3 has a build error, the MPLABX is fine. There is some issue with the A/D firmware. The error messages are below. I would appreciate it if you can tell me how to fix it. I will take care of the helical turns branch.
Best regards,
Bill

Make: The target "C:\Users\bill\Desktop\MatrixPilot_trunk\MatrixPilot\build\AUAV3\analog2digital_auav3.o" is out of date.
Executing: "C:\Program Files (x86)\Microchip\MPLAB C30\bin\pic30-gcc.exe" -mcpu=33FJ256GP710A -x c -c   "..\libUDB\analog2digital_auav3.c" -o"build/AUAV3\analog2digital_auav3.o" -I"../Config" -I"..\MAVLink\include" -I"..\Microchip" -I"..\Microchip\Include" -D__DEBUG -g -Wall -DAUAV3 -mlarge-code -mlarge-data -legacy-libc
Microchip MPLAB C30 License Manager Version v3_30 (Build Date Jun 21 2011).
Copyright (c) 2008 Microchip Technology Inc. All rights reserved.
The MPLAB C30 license has expired.
Options have been disabled due to expired license
Visit http://www.microchip.com/ to purchase a new key.
..\libUDB\analog2digital_auav3.c: In function 'udb_init_ADC':
..\libUDB\analog2digital_auav3.c:157: error: 'AD1CON4BITS' has no member named 'ADDMAEN'
..\libUDB\analog2digital_auav3.c:163: error: 'ANSELA' undeclared (first use in this function)
..\libUDB\analog2digital_auav3.c:163: error: (Each undeclared identifier is reported only once
..\libUDB\analog2digital_auav3.c:163: error: for each function it appears in.)
..\libUDB\analog2digital_auav3.c:164: error: 'ANSELC' undeclared (first use in this function)
..\libUDB\analog2digital_auav3.c:165: error: 'ANSELD' undeclared (first use in this function)
..\libUDB\analog2digital_auav3.c:166: error: 'ANSELE' undeclared (first use in this function)
..\libUDB\analog2digital_auav3.c:167: error: 'ANSELG' undeclared (first use in this function)
..\libUDB\analog2digital_auav3.c:173: error: 'ANSELB' undeclared (first use in this function)
..\libUDB\analog2digital_auav3.c:201: error: 'DMA0STAH' undeclared (first use in this function)
..\libUDB\analog2digital_auav3.c:202: error: 'DMA0STAL' undeclared (first use in this function)
..\libUDB\analog2digital_auav3.c:203: error: 'DMA0STBH' undeclared (first use in this function)
..\libUDB\analog2digital_auav3.c:204: error: 'DMA0STBL' undeclared (first use in this function)
Halting build on first failure as requested.
----------------------------------------------------------------------
Debug build of project `C:\Users\bill\Desktop\MatrixPilot_trunk\MatrixPilot\MatrixPilot-auav3.mcp' failed.
Language tool versions: pic30-as.exe v3.30, pic30-gcc.exe v3.30, pic30-ld.exe v3.30, pic30-ar.exe v3.30
Preprocessor symbol `__DEBUG' is defined.
Thu Jan 15 21:11:39 2015
----------------------------------------------------------------------
BUILD FAILED



William Premerlani

unread,
Jan 15, 2015, 9:22:43 PM1/15/15
to Robert Dickenson, uavdevboard-dev
Team,
Ignore my last email on this subject. I figured out what the problem is. I appears that I will have to manually set the device type for the AUAV3 when I use MPLAB8.
Best regards,
Bill

Tom Pittenger

unread,
Jan 15, 2015, 10:35:16 PM1/15/15
to uavdevb...@googlegroups.com

Bill,
the solution is to delete the mplab8 project and press the commit button. Then use MPLABX and never look back.

Our/Robert's time is better spent helping you migrate to mplabX rather than keep up with maintaining mplab8 project.

It's time Bill. X has been out for ~5 years.

--
You received this message because you are subscribed to the Google Groups "uavdevboard-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to uavdevboard-d...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Robert Dickenson

unread,
Jan 16, 2015, 6:03:55 AM1/16/15
to William Premerlani, uavdevboard-dev
Hi Bill,

Thanks for the report (-:

There should be no requirement to change the device type - so i shall investigate further.

I notice you are using generated project files which is great to see. On my machine the 'device' field correctly identifies the mcu in all the mplab-8 projects, however i'll have to fire up my other machine with mplab-8 installed to test properly.

Best wishes, R.



William Premerlani

unread,
Jan 16, 2015, 8:25:22 AM1/16/15
to uavdevboard-dev
Tom,
According to Peter Hollands, MPLABX is still not reliable in debug mode.
Bill

Peter Hollands

unread,
Jan 16, 2015, 9:22:20 AM1/16/15
to uavdevb...@googlegroups.com
Bill,

I just ran some more test on my issue with debug in MPLAB-X for Helical Turns.

For the UDB5, I ask MPLAB-X to "Clean and Build Project for Debugging".
That works. Build Succeeded and "Load Completed"

But:
For the UDB4, I ask for the same thing "Clean and Build Project for Debugging"
That does not work. I get Build Succeeded and then "The program could not be Loaded: Null"

That could be an issue with MPLAB-X in trunk or Helical Turns, as much as an issue with MPLAB-X for debugging.
It does mean that out of the box, one cannot debug on the UDB4 with Helical Turns.

I wonder if anyone else can compile the Helical Turns Branch with Debugging in MPLAB-X ?

Best wishes, Pete

...[Edited out main compile]...

build/default/debug/_ext/1472/config.o build/default/debug/_ext/1472/MAVFlexiFunctions.o build/default/debug/_ext/1472/MAVMission.o build/default/debug/_ext/1472/MAVParams.o build/default/debug/_ext/1472/MAVUDBExtra.o build/default/debug/_ext/1472/helicalTurnCntrl.o      -mcpu=33FJ256GP710A        -D__DEBUG -D__MPLAB_DEBUGGER_PK3=1  -omf=coff -legacy-libc -Wl,,--defsym=__MPLAB_BUILD=1,--defsym=__ICD2RAM=1,--defsym=__MPLAB_DEBUG=1,--defsym=__DEBUG=1,--defsym=__MPLAB_DEBUGGER_PK3=1,,--script=p33FJ256GP710A.gld,--heap=200,--stack=16,--check-sections,--data-init,--pack-data,--handles,--isr,--no-gc-sections,--fill-upper=0,--stackguard=16,--no-force-link,--smart-io,-Map="dist/default/debug/MatrixPilot-udb4.X.debug.map",--report-mem 

...[Edited out some lines]...

make[2]: Leaving directory '/Users/phollands/Desktop/development/helicalTurns/MatrixPilot/MatrixPilot-udb4.X'
make[1]: Leaving directory '/Users/phollands/Desktop/development/helicalTurns/MatrixPilot/MatrixPilot-udb4.X'

BUILD SUCCESSFUL (total time: 9s)
Loading symbols from /Users/phollands/Desktop/development/helicalTurns/MatrixPilot/MatrixPilot-udb4.X/dist/default/debug/MatrixPilot-udb4.X.debug.cof...
Loading code from /Users/phollands/Desktop/development/helicalTurns/MatrixPilot/MatrixPilot-udb4.X/dist/default/debug/MatrixPilot-udb4.X.debug.cof...
The program file could not be loaded: null


Mark Whitehorn

unread,
Jan 16, 2015, 9:48:51 AM1/16/15
to uavdevboard-dev
Peter,

Have you tried output format "ELF/DWARF" in the XC16 global options?
I vaguely recall problems with the COFF format a few years ago.
If that's still a problem, it's too bad Microchip doesn't fix bugs in a timely manner.

73, Mark
Mark Whitehorn
kd0...@gmail.com

Mark Whitehorn

unread,
Jan 16, 2015, 9:54:11 AM1/16/15
to uavdevboard-dev
Peter,

OTOH, it could be this: http://www.microchip.com/forums/m747874.aspx
--
Mark Whitehorn
kd0...@gmail.com

Peter Hollands

unread,
Jan 16, 2015, 10:20:57 AM1/16/15
to uavdevb...@googlegroups.com
Mark,

Thanks very much. Changing the output format to ELF/DWARF has fixed the build, and the load now completes correctly.

I will now move on and test more of the actual debug functionality.

Screenshots for anyone following of where I made the change are enclosed below.

My UDB5 project for Helical Turns was already using ELF/DWARF and that is why it worked.

Best wishes, Pete


Screen Shot 2015-01-16 at 15.16.45.png
Screen Shot 2015-01-16 at 15.17.29.png

William Premerlani

unread,
Jan 16, 2015, 10:32:36 AM1/16/15
to uavdevboard-dev
Peter and Mark,
Thank you for digging into this.
So far, so good. But I seem to recall that someone (Ben?) reported that the debugger did not work correctly under MPLABX. I think the problem was either that breakpoints did not work, and/or when the dsPIC halted, the debugging information was not correct.
Best regards,
Bill

Peter Hollands

unread,
Jan 16, 2015, 10:36:24 AM1/16/15
to uavdevb...@googlegroups.com
Bill,

I have rechecked out a fresh version of Helical Turns, and I can confirm that the output format is set as COFF for the UDB4. For the UDB5 it is already set to ELF.

I updated my latest trunk, and that is not using COFF format output files. Only ELF.

I will update the repository version of Helical Turns to use ELF for the UDB4 project.

I will check some initial functionality in the debugger, and then give you an update.

Best wishes, Pete

Peter Hollands

unread,
Jan 16, 2015, 5:08:27 PM1/16/15
to uavdevb...@googlegroups.com
Folks,

My Initial testing of the debugger tonight with MPLAB-X and a Pickit 3 shows that the breakpoints are working as expected.

Can anyone that has used the MPLAB-X debugger extensively with success please chip in with your positive / negative experiences.

Best wishes,  Pete

Product Version: MPLAB X IDE v2.26

Java: 1.6.0_65; Java HotSpot(TM) 64-Bit Server VM 20.65-b04-466.1

System: Mac OS X version 10.10.1 running on x86_64; MacRoman; en_US (mplab)       


Tom Pittenger

unread,
Jan 16, 2015, 5:16:02 PM1/16/15
to uavdevb...@googlegroups.com
I've been hearing all these horror stories about the debugger but I've never had any problems other than getting into and out of debug mode. Microchip could REALLY use a better debug scheme. Anyway, I run MPLABX with Win7 on pickit3. I debug a lot on PIC32 for my dfOSD project (setup video by me, flight video by PhilG) but admit I haven't done it much at all for UDBx.

-TomP

Phillip Kocmoud

unread,
Jan 16, 2015, 6:14:29 PM1/16/15
to uavdevboard-dev

Hi Tom,

Are you sure those links work correctly to outsiders?

Tom Pittenger

unread,
Jan 16, 2015, 6:21:28 PM1/16/15
to uavdevb...@googlegroups.com
They should. Is the dynamic dns not working for you? Can you ping it? It should resolve to 98.252.67.45.

Mark Whitehorn

unread,
Jan 16, 2015, 6:24:38 PM1/16/15
to uavdevboard-dev
works for me :) nice baby pictures, too.

Nikolay Arsov

unread,
Jan 17, 2015, 4:28:44 AM1/17/15
to uavdevb...@googlegroups.com
Hi Tom,
....user name and password?

Tom Pittenger

unread,
Jan 17, 2015, 4:40:34 AM1/17/15
to uavdevb...@googlegroups.com
Had to shut the access down on the server. Sorry guys!

On Sat, Jan 17, 2015 at 1:28 AM, Nikolay Arsov <nick...@gmail.com> wrote:
Hi Tom,
....user name and password?

--

Riccardo Kuebler

unread,
Jan 17, 2015, 5:27:54 AM1/17/15
to uavdevb...@googlegroups.com
Tom,

I was able to go in before, but did not find the videos (by cellular phone).
Now a login is required =:(
Ric
Reply all
Reply to author
Forward
0 new messages