Ardu-IMU-Pilot Flys - First successful test flight made today!

Today the weather finally cooperated and I dashed off to my local flying field for a long lunch.

My Ardu-IMU-Pilot had two successful flights! Performance was quite poor, but considering that I changed all the control laws and picked gains out of the air I am satisfied that the UAV was able to complete the prescribed circuit (multiple times in fact).

It is funny to see this track on google earth because in fact most of the ground today was covered in snow. I'll have to remember to see how snow cover affects the thermopiles some time.

What I did:
I converted my current UAV (Superstar EP airframe, Brushless/lipo power system, Thermopile based ArduPilot autopilot) to a IMU based system. To do this I used ArduIMU. I connect the GPS to ArduIMU and connect the serial output of ArduIMU to ArduPilot. I have modified V2.4 of the ArduPilot code significantly to use data from ArduIMU rather than the thermopiles. I have also modified the ArduIMU code to provide a binary data message to ArduPilot.

My test flights today proved out the architecture. The new autopilot system successfully provided stabilization and navigation. However, performance was quite poor and I need to do some tuning of both the code and the gains.

I chose to completely change the control laws. I did this for two reasons. First, because this is open source and I can! Second, because I wanted to try out some ideas for the turn-rate limiter workgroup. Briefly, I added a cross track error component to the roll control loop (zero gain today), I changed the elevator control loop so that elevator is used to maintain constant airspeed, and the throttle control loop is used to maintain desired altitude.

Trying out the new elevator and throttle control laws simultaneously with poor gain choices was a disaster. So, I quickly rewrote the elevator control to just hold zero pitch. With this change things went better.

What went poorly:
Well, my roll gains need adjusting. Rolling into a turn would produce bank angles in excess of the desired maximum, and there was a lot of wing wagging going on at times.

Also, my quick patch to hold zero pitch I believe in fact was holding some amount of up pitch relative to the wing. When the UAV was below target altitude and the throttle setting was relatively high things went well. However when the UAV got above target altitude the throttle was reduced to a low level things did not go so well. The elevator continued to hold zero pitch, which was actually some amount of positive pitch, and the airframe slowed until it stalled. I found that it (my SuperStar) does not stall nicely, with a very pronounced tip stall. This produced a couple of unwanted circles during the mission.

Going forward:
I think my next step will be to do some manual flying with data logging to get some data on throttle settings versus pitch & airspeed. With that data I should be able to rework the elevator and throttle controls. I would also like to log some data during some manually flown aerobatics and see how my ArduIMU results compare with those being gathered by Jose Julio.

Views: 705

Comment by Thomas J Coyle III on December 15, 2009 at 4:54pm
Congratulations Doug!! A nice bit of flight testing. Glad that you did not crash while collecting valuable performance data.

Looking forward to the results of your path forward.


Comment by Ryan Beall on December 15, 2009 at 4:55pm
add an integrator on airspeed to elev and it solves the "out of trim/alignment" problem

Comment by Morli on December 15, 2009 at 6:20pm
Is that a WP inside each of circle or how is WP laid out? looking forward to see more tests and finally nailing the optimum gains and setting. Wish someone can try it with a nitro powered system with some sort rpm counter to give feedback for required throttle gain/control. Good work and good luck for next set of tests. Just want to know what type of latency is felt/noted when taking the controls back (is it instantaneous or is there a bit of lag) to RC mode from AP mode when you want to recover from undesirable attitude or want to do manual landing.

Comment by Jason Short on December 15, 2009 at 7:12pm
Looking forward to working with your code and getting it into 2.5!

Comment by Doug Weibel on December 15, 2009 at 10:20pm
@Morli - sorry, I haven't figured out how to edit the gps track, so what you see is everything from takeoff through landing. The WP mission is kind of an oval around 5 points. You can see the 3 southerly points where the track wiggles around them. The two north are not so obvious. There are a couple of tight circles not associated with the waypoints where tip stalls occured. I expect to have much better performance with a couple sessions tuning the code and gains. Just need schedule and weather to cooperate.

I'm not sure what your point is about a nitro powered system. Throttle central points and gains will vary between airframes and power systems, be they electric, nitro, or gas. What works for one nitro airframe/power system will not be appropriate for others.
Also, to your question I notice very little latency when switching back to manual control.

@Jason - I'll be talking with you about that. Not much point in making a lot of improvements to my code when it differs so much from the current standard. I have a couple things I want to play with first, but probably will want to incorporate what I have done into 2.5.1....
Comment by Earl on December 15, 2009 at 10:58pm
How about an UPLINK command set to be able to change pid's in flight ? It has been done when the TX buffer is empty and the RX buffer on the XBee has something. I fergot what post it is in...
I have a sparkfun 6dof unit that spits out data serially but not in the format you use. Maybe I could change it.
Anyone want to trade an auduIMU for a Sparkfun 6DOF unit ?
Messing with the gains and stuff while in flight would be exciting! See results immediately.Make sure the plane is kept up high enough tho!
I can see we are going into a new relhm here with 6 or 9 DOF Sensors and an ability to uplink data to the plane in flight.
I am available for testing with a FPF 900mhz camera pan and tilt ardupilot with ir sensors, xbee transcivers, ground station,2 kinds, hardware and software.9ch tx/rx for flight control,camera, and other stuff,all in an apprentice 15 airframe. Also has Remzibi's OSD system on board with Ublox GPS. I will get the arduIMU if necessary for testing.
I am having an open fly in on my 160 acres in the spring for EZ* and Autonomous aircraft.
Lots of camping space and several reasonable priced hotels in a 4 mi area.
2 big crossed runways and power grader to make more if needed.
Plenty of wood for campfires to land by or drink....whatever.
Central NM area.

Comment by Doug Weibel on December 16, 2009 at 8:00am
Earl, are your runways big enough that I could fly in to your fly in? About 1600 feet is comfortable at 5000 ft elevation in my Citabria.

I think uploading gains is an excellent idea. However, it would be a bit more difficult with the architecture I'm using. I route the gps into the ArduIMU and the ArduPilot recevies data from the ArduIMU. This happens at a 20Hz rate, so there is less available dead time. I will probably just wait for ArduPilot Mega for that functionality.
Comment by Benjamin Lanehart on December 16, 2009 at 8:47am
Good to hear she flew Doug... I'm working on my setup right now, and awaiting for my shield to arrive... :)
Comment by Pbreed on December 16, 2009 at 9:20am
When I was developing my helicopter I put remote gains on an aux slider of the RC transmitter
Then I had a UI on the computer that let me assign the stick to specific gain variables and set the range asociated with the stick movement.
Comment by JC on December 18, 2009 at 1:32pm
Do you have any pictures of the board mounted in your Superstar


You need to be a member of DIY Drones to add comments!

Join DIY Drones

© 2017   Created by Chris Anderson.   Powered by

Badges  |  Report an Issue  |  Terms of Service