Uncontrollable loss of altitude when entering Auto mode

Hi guys

The following issue has been occurring a number of times, resulting in a lot of quick saves, and unfortunately quite a few crashes.

The problem occurs when entering Auto mode. The plane flies fine in manual and stabilise, but when we switch to auto the plane starts to pitch down uncontrollably, at which point the plane must be switched back into Manual mode to recover, however sometimes this cannot be done in time and the plane crashes.

When we first maidened the plane in Auto mode it worked fine and there was no problem. (It did crash but that was due to a faulty power setup). This was running APM 2.71, (Flight Test #9)

We subsequently rebuilt the plane and tried flying it again. This in when we first experienced the problem. At this point we were running APM 2.60. We thought that maybe because this didn’t have the TECS control system this might have been the cause of the issue (Flight Test #10)

We tried again with a later version of APM that had the TECS controller. But experienced the same issue (Flight Test #11). I have attached the log for this flight (Plane flown from 11:08:20am, switched to stabilise 11:09:09am, switched to auto 11:10:02am and subsequent loss of control and crash). Here the same problem occurred where the plane was flying fine in manual and stabilise but then pitched down uncontrollably in auto mode. It was noted that the offsets for the servo outputs may not have been set properly - relying on a previous radio calibration that was non longer valid. I believe this is the most likely cause of the issue - ie the elevator mid-point was set to pitch the plane downwards, and the auto-loops would not have been able to compensate for this. However not sure if that makes sense given the stabilise behaviour was fine.

We upgraded to APM V3.0.2, and got an experienced friend to help us calibrate the plane. A think a key step here was doing the radio calibration right before the flight. Here the plane was flying fine in auto mode - so I think we solved the problem. We did notice that one some occasions when flying to the first waypoint, the plane would start tracking to a lower altitude, and then correct itself and fly to the correct altitude.

I was curious though to see the post that Tridge put about a bug fix in V3.0.3 regarding the glide slope calc when entering auto mode, and was wondering if perhaps this had anything to do with what we were seeing previously. Is anyone able to provide some more information on this bug, and whether it would have caused the uncontrollable pitching down that we were seeing?

Also if anyone is able to review the logs, and verify whether my conclusions are correct that would be a big help.

I have also attached the flight log from flight test #10 - where the same issue occurred. (11:22:19 take-off, 11:22:40 switched to stabilise, 11:23:34 switched to auto, 11:23:38 recovered in manual mode)

For some reason the previous log did not register that it was switched to auto mode…

Hi Michael,
The problem is not the glide slope bug. That bug only happened if you started above the target altitude of the first waypoint. Also, the firmware you are flying is so ancient that I don’t think we even had the current glide slope code. The firmware is old enough that it doesn’t actually list its firmware version, but based on the parameters I think it must be from late 2012 or early 2013?
So please update to the current release, and restart all your parameters from scratch.
The actual flight problem is your pitch controller is not tuned at all (the roll controller is also not tuned). You have no I or D gain, and incorrect P gains. The plane just fails to put in enough elevator to pitch up. I also suspect your CoG may be too nose heavy, but that is hard to really determine.
I’d strongly suggest you upgrade to a current version then run an autotune, probably at level 6. See the autotune docs:
plane.ardupilot.com/wiki/automat … -autotune/
I’d also suggest you not use STABILISE mode and instead use FBWA mode. Don’t use auto again until FBWA flies very well. Please read the docs on FBWA versus STABILISE mode.
Cheers, Tridge

Hi Tridge - thanks a lot for looking into this.

I think you’re right. We flew the plane again in FBW-A using the previous settings and there was very limited control authority, that coupled with a slightly nose heavy plane, or the RC_trim settings not set right would have meant that the control loops in auto would not have had enough control authority to pull itself out of a dive.

Unfortunately we weren’t able to try out the Autotune function this time because we had V3.0.1 installed. But we will be trying this out next week most likely.

Interesting to note the differences between the FBW-A mode and the STABILISE mode. I will definitely be using FBW-A mode from now on. Is there any documentation that provides a more detailed overview of how the Stabilise mode works?

Stabilize simply adds artificial positive stability to the control. You get full authority but it is constant trying to return to level flight. If you let go of the sticks, the plane quickly rights itself.
FBW is a way to steer the autopilot. It retains all the autopilot’s limitations in attitude and rates.