Developer

ArduPlane 2.72 released

I'm delighted to announce the release of ArduPlane 2.72 for your flying pleasure.

The big news in this release is the addition of the new L1 navigation controller. The work on the L1 controller library was started by Brandon Jones, and his initial github pull request is a great please to look to understand the new code. As is so often the case with ArduPlane, the documentation still hasn't caught up with the code (though I hope it soon will!).

After Brandon’s initial work Paul Riseborough did a lot of work to add more robustness to the algorithm. The base L1 algorithm suffered from from instability in "path capture", which is how it handles navigation when you are a long way off course (for example, when you enter auto after having flown manually). Paul made some fantastic improvements which have been extensively flight tested by Brandon, Paul, Jon and myself.

I did a final test flight of it this morning in a Bixler2, and it flew very nicely. I found a setting of NAVL1_PERIOD=20 suited the Bixler2 very well. It produced great path tracking, and very nice circles in loiter, despite high wind.

Paul is not finished yet though! He's been working on re-working the APM_Control library started by Jon Challinger, and is getting fantastic results with roll and pitch control, greatly reducing the altitude loss in turns. That isn't in the 2.72 release though as I want to do a bit more testing and tweaking of the code, but I expect to get Paul’s new controllers in the next release.

Before I go into detail on how to tune the new L1 controller, I better list some of the other changes in this release:

  • avoid doing auto radio trim if the resulting trim leaves less than 20% of travel between the trim value and the MAX and MIN for the aileron, elevator or rudder. This prevents auto-trim leaving you with very bad trim if you do it while your transmitter is off
  • removed HIL_MODE_ATTITUDE, we always now use SENSORS HIL, which is much more accurate, and is needed for correct operation of the L1 controller
  • added new LEVEL_ROLL_LIMIT parameter. This replaces both the TKOFF_HEAD_HOLD and RUDDER_STEER options, and instead allows you to specify a roll limit in degrees for auto land and takeoff. The default is 5 degrees, which should be small enough to prevent wings scraping on the runway in most planes.
  • Removed the AHRS_BARO_USE option, as it caused trouble for too many users
  • allow the WP_LOITER_RAD loiter radius to be set negative to mean that a counter clockwise loiter should be performed by default
  • fixed the handling of the LOITER_TURNS and LOITER_TIME commands
  • added new dataflash logging system, with self-describing logging format. See notes below for more info.
  • on auto-takeoff, if we have an airspeed sensor then keep throttle suppressed until we have both 5m/s ground speed and 5m/s airspeed
  • added support for 12 output PWM channels on PX4
  • enable relay in camera library for all APM boards (thanks to SSzilard)
  • cleanup use of const in libraries (thanks to Tobias)
  • lowered default AHRS roll-pitch correction gains from 0.4 to 0.3
  • changed AHRS to lower roll-pitch gains by another 50% when a high X acceleration is detected for a catapult launch, to prevent nose down on fast launch due to GPS velocity lag
  • fixed RC throttle failsafe handling on PX4
  • fixed a bug in returning airspeed estimate from DCM if an airspeed sensor is available (thanks to Jon Challinger for finding this important bug)

As you can see, the dev team has been busy!

A few special notes about the DataFlash logging changes. This is the first release to support 'dataflash' logging on the PX4, and it implements it by writing binary log files to the SD card in an APM/logs sub-directory. Those log files are self-describing, which means the format of the logs is contained in the headers of the log. This makes it possible to add new log messages without having to change MissionPlanner. It also means you can now get logs into MissionPlanner by pulling the SD card out of the PX4 and plugging them into your PC, which is much faster than using the CLI. The new log format is also used for APM1 and APM2, which will mean we no longer have to align the version of MissionPlanner with the ArduPlane log version when analyzing dataflash logs.

Now on to the main thing in this release - the new L1 navigation controller.

The new controller makes a huge difference to navigation in ArduPlane in the following ways:

  • tuning is now much simpler - the only navigation parameter you really have to change is NAVL1_PERIOD
  • much better path tracking, even in high wind
  • loiter now produces a very nice circle even in high wind
  • much less servo flapping! If you tried to tune the old controller for very good path tracking it would end up changing servo position very rapidly, wearing out the servos and drawing more current than it should. The new controller has much smoother servo movement.

The default NAVL1_PERIOD is 25, which should give quite gentle navigation on most airframes. A smaller number means more aggressive navigation (tighter turns). Adjust it by around 5 at a time until you are happy with the performance. Most small RC planes will need a value of between 15 and 20. I need a value of 15 on my Phoenix Tiger60 low wing nitro sports plane, and 20 for my Bixler2. The default is 25 to ensure that we get gentle navigation by default - if the value is too small the plane can snake rapidly, and roll too rapidly, possibly leading to a stall if the aircraft is heavily loaded.

I hope you all enjoy flying this release as much as I do. Happy flying!

Cheers, Tridge

(PDF tuning guide)

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Replies

  • another 2.72 firmware test very accurate

    https://www.youtube.com/watch?v=cB0ZLmJWbSw

  • Hi Andrew,

    Thank you for all your work!

    I tested the L1 yesterday for tuning for mapping and it tracks very well once on the line. 

    I want to try 2.7.3 and I am reading through your detailed "tuning overview" instructions. I just have one question (so far).

    In "Basic Method 1" you specify the plane should be in FBW while doing the tuning but in "Basic Method 2" you don't specify the mode the plane should be in. Should this tuning be done in FBWA as in method 1 or  in auto mode while running a "box" pattern?

    Thank you!

    B

  • I'm still having a problem with the generation of kmz-files from onboard log-files.

    They are all empty since arduplane 2.72

    I verified the log-files and found something strange.

    All the ATT commands in the logging have a trailing comma:

    ATT, 0.15, 0.00, 655.35,

    when I look at the definition of the ATT command it should have only three parameters,

    so the last comma shouldn't be there, I think:

    FMT, 10, 15, ATT, ccC, Roll,Pitch,Yaw

    Could this be the reason that the generation of kmz-files doesn't work?

    Could somebody post his onboard log-files from arduplane 2.72, so I can compare them with mine?

    kind regards,

    Davy

  • Yesterday I had a crash when trying 2.72 with my skywalker and default params. I suposse it was my fault but I´m not sure, so some help is need.

    Mission was programmed to 100 m altitude. With stabilized  I went to 120 m, and then switch to Auto. Motor was turned off, I suposse to reach 100m, after some seconds turn on again, but in no time It crashed to the ground.

    I attach the telemetry logs, if someone is kind enough to give me your opinion. Thanks you.

    2013-05-05 19-29-31.tlog

    villamnan cuevas sky.param

  • Looks interesting. I just would like to confirm if this firmware is applicable on my air frame which is C-17 Globemaster!

    We managed to have successful autonomous flights in low wind, we never risked that in high wind. And all that was done using even much older version, v2.4!!

    I am doing some research in advanced control topics, and using this particular airframe because it suits our purposes.

    We don't have enough experience on the manual flight with such airframe, so we let the Auto-mode take over for the whole flight.

    My question is: do you expect this firmware to act much better even using this airframe?

    Thanks,

    M. Zahana.

  • Actually took 2.72 out for a test drive today in San Diego. The wind was blowing hard with gusts up in the 20's right across the runway. I rolled my PID settings over from the previous firmware and then left the new settings at defaults. I will say you can FEEL a difference in the new firmware. I'm still snaking through waypoints which I'll tune out over the course of the next couple flights. Takeoff was done in Auto mode and totally rocked the wind! 

    Andrew and crew my hat is off to you guys for this firmware! I might have to PayPal you some beer money for this one! 

    3692707766?profile=original

  • When running ArduPlane 2.72 in HIL Simulation mode, I have not been able to get my transmitter to be recognized.  No control is seen on the radio calibration screen within Mission Planner.  I seem to experience this problem frequently with new releases of ArduPlane.  I have resorted to loading earlier versions at times, but eventually the new releases will work.  I'd like to test NAVL1_PERIOD in simulation mode and get a feel for how changing settings affects flight.

    Any ideas as to why I have this issue on occasion?  Any help resolving this will be appreciated.

    Thanks,
    Paul

  • There is a bug in Firmware 2.72

    When running the airpressure test it doesn't work (Figure is attached)

    I downgrade the Firmware to version 2.7 and air pressure test is working well.

    Any idea why?

    airpress.jpg

  • I upgraded my plane to arduplane 2.72 this morning,

    Flies great, But I'm having a problem with the loggings in the plane.

    All .log.gpx files have a filesize of 32 bytes.

    The only contents of this files is

    <gpx><trk><trkseg /></trk></gpx>

    All kmz files are around 4900 bytes (also empty)

    My log-files seem to be correct.

    Mission-planner version is 1.2.48

    I suppose the kmz and .log.gpx files are generated by the mission-planner and the log-files itself is downloaded from the plane.

    Is the mission planner already compatible with the new arduplane 2.72

    as from now the format of the log-file is described in the header if I understood it correctly.

    I import al my flights in google earth, so it's a pity this doesn't work anymore.

    Also since 2.69, the waypoint aren't logged to the kmz-file anymore, while it was the case in 2.68.

    Or is there some setting I missed somewhere.

    Overall it is very good that the number of settings we need to tweak for our plane are going down.

    PS Andrew, could you post the parameter-file you're using on your bixler2?

    I'm also flying a bixler2 (great plane) and I'm kind of curious for your parameters :-). 

    Kind regards,

    Davy

  • Developer

    As I mentioned in the release notes for 2.72, Paul Riseborough has been working with Jon and me on new roll/pitch/yaw controllers. I've just pushed out a new beta for ArduPlane with these new controllers, which you can enable by setting ATT_CONTROLLER=1.

    Paul has written a tuning guide for the new controller. It would be great for a few users to try the new tuning guide with ATT_CONTROLLER=1 and the new beta release and give us some feedback before the 2.73 release.

    If you try it, please report back here!

    Cheers, Tridge

This reply was deleted.

Activity