Due Quadrotor code

Hey guys. I'm building a quadrotor as part of my university project, but I'm having a couple of problems with the code, I was hoping someone might be able to help. My hardware is as follows..

Arduino Due
accelerometer and gyro - MPU6050
magnetomoter - HMC5883
barometer - BMP085
wireless comms - XBee

As it stands i'm also in the process of building a controller, so for the testing process i've been using an Uno with a potentiometer to set the throttle speed, and sending the value over XBee to the quad.

So far the quad reads all necessary values from all sensors without any errors, and the speed of all four motors can be controlled using the throttle. My problem arises when I try to use the sensor data to calculate how much to vary the motor speeds.

Ideally i'd like to take advantage of someone else's stabilisation algorithms to handle the sensor data, and had hoped to use part of the AeroQuad code or similar. I would use the AeroQuad code in its entirety, and remove the functions I do not need, but it relies on too many libraries that don't run on the Due (please correct me if I'm wrong here.)

Has anyone managed to write/port quadrotor code for the DUE?

Or has anyone managed to use only the stabilisation algorithms from one of these open source projects in their own quadrotors?

I dont mind having to write my own code but I hope to develop the quad much further and don't want to waste too much time re-inventing the wheel.

Thanks in advanced for any help or advice.
Phil Downie.

Hi nice to know i have a colleague, i'm trying to build a quadrotor with just an Arduino UNO and an old 4ch RC set, i've got the first parts of the hard job almost done, i connected the RC with the UNO and managet to work them together then i wrote the skeleton for the software and a basic open loop trial version
now i'm stuck with the MPU9150 (inertial measurement) but i'll leave it away just to have time to purchase motors and props

i pressed the wrong key, still had something to tell..... :frowning:
well don't be frightened by the code, it's only a matter of PID stabilization and then you'll have to build a good state manager to keep a minimum level of security, how are your pilot skills? quads are difficult to fly if the stabilizer is not correctly set up
last but not least, the DUE is overpowered IMO for what you have to do, i am OT here 'cos i am building my quad with an UNO but i own a DUE also and im doing some tests to be able to exchange the controller when i will try building the autopilot
as far as now, just to fly it safe under RC control 16 MHz seem enough for me, let's see if i'll manage it