Discussion forum for UAVDevBoard, Sparkfun's 3-axis IMU-based autopilot board

This is the place to discuss the new open source IMU-based autopilot board by Bill Premerlani.

Views: 11383

Reply to This

Replies to This Discussion

I just ordered a udb4 board. I've installed mplab along with the c30 compiler evaluatation version on two differents computers. When I try to compile the matrixpilotV3.2 for udb4 I get the same error on both computers :

"../libDCM/../libUDB/libUDB_defines.h:60:22: error: p30f4011.h: No such file or directory"

I have tried to manually include the p30f4011.h file to the project, no success ?

Has anyone experience this problem ?

Hi Dave,

Go into the options.h file in the MatrixPilot subdirectory and change the following line from:




We use the same options.h file for all four board types. The default is UDB3.

Best regards,



Thanks Bill !

@Dave, Hi. Yes, I had that problem once. In MPLAB under "Configure / Select Device", select "dsPIC33FJ256GP710A". Be careful to select the right one ! .
It will then load the correct libraries for the UDB4.


Best wishes, Pete

Im interested in the UAVDevBoard solely for a camera tracker. Im running a full autopilot on a helicopter and I would like to use the UAVDevBoard as a stand alone unit to track. Can anyone tell me what I'll need to implement it?





There are many possible permutations to your question. Could you please provide some more detail ?

  • Is this a ground based camera tracker that is going to film the helicopter
  • Or is this a helicopter based camera, that is going to track
    a) a ground based GPS coordinate ?
    b) a moving target that is broadcasting it's GPS coordinates ?


Best wishes, Pete






Sorry, was a little vague. My goal is to track, from a helicopter or fixed wing, a fixed point on the ground (ground-based GPS coord).

I saw that Ardupilot Mega has this function but I want to explore my options. The size of the UAVDevBoard is also appealing.

UAV Devboard currently will stabilize and track on pitch and yaw. Not Roll. You would need a GPS unit for the UAV DevBoard (4 different models supported, see main page).

Will you want to overide the camera servos from an RC transmitter ? That is supported as standard.

More complex control of the GPS location to track not yet supported (i.e. move GPS location by using an RC transmitter roll and elevator controls).

If not using RC transmitter, might need to make some small code changes, so that the GPS tracking of the camera works in all three mode of the UAV DevBoard (manual, stabilized and waypoint). Default code setup is for camera tracking of GPS coordinates to only work in autonomous mode.


Choice of servos is crucial. Resolution. Maths for minimum movment required (determined by field of view angle, and resolution of picture).


Pulling back from that, the entire concept of camera stabilisation needs different type of servos.

Not RC hobby servos driven by PWM. But computer controlled servos (say I2C or something similar) where UDB can control, position, velocity, and acceleration of servos. But that is for the future.


Best wishes, Pete



Hi everyone,

     I recently got a UDB4 and am trying to program it for the first time using a Pickit3. I have been following the "UAV DevBoard: Getting Started with PIC Programming" guide but have run into problems when trying to build..... First off I hadn't changed the #define in the options.h which was giving me a failed build. Now however I am getting the following error:

c:\program files\microchip\mplab c30\bin\bin\..\bin/pic30-coff-ld.exe: cannot find -legacy-libc Link step failed. ---------------------------------------------------------------------- Release build of project `C:\Documents and Settings\Rich\Desktop\MatrixPilot_3_2_1\MatrixPilot\MatrixPilot-udb4.mcp' failed. Language tool versions: pic30-as.exe v3.31, pic30-gcc.exe v3.31, pic30-ld.exe v3.31, pic30-ar.exe v3.31 Thu Jan 19 10:05:00 2012 ---------------------------------------------------------------------- BUILD FAILED

Any recomendations? 

Thanks in advance for any help!


I suggest switching off the -legacy-libc option and seeing if the code then compiles.

I enclose a link to a of the screenshot of the window where you can change that option.

Click on "Inherit Global Setting", which you will see is identical to "Use aleternate settings" except that it does not have the -legacy-libc.

Depending on the MPLAB version and Compiler Version, some combinations need the legacy-libc and some do not.

Best wishes, Pete

Thanks Pete!

That worked we are now up and running!


i don't understand the purpose of the filtering statement

         xaccel.value = xaccel.value + (( (xaccel.input>>1) - (xaccel.value>>1) )>> FILTERSHIFT ) ;
        xrate.value = xrate.value + (( (xrate.input>>1) - (xrate.value>>1) )>> FILTERSHIFT ) ;
        yaccel.value = yaccel.value + (( ( yaccel.input>>1) - (yaccel.value>>1) )>> FILTERSHIFT ) ;
        yrate.value = yrate.value + (( (yrate.input>>1) - (yrate.value>>1) )>> FILTERSHIFT ) ;
        zaccel.value = zaccel.value + (( (zaccel.input>>1) - (zaccel.value>>1) )>> FILTERSHIFT ) ;
        zrate.value = zrate.value + ((( zrate.input>>1) - (zrate.value>>1) )>> FILTERSHIFT ) ;

and what is filtershift?



© 2015   Created by Chris Anderson.

Badges  |  Report an Issue  |  Terms of Service