Throttle tuning saga

Some improvements in calming down my throttle in auto throttle modes but it’s like wack-a-mole, something will pop up somewhere else. I’ve adjusted numerous parameters but think it could still be improved.

My usual cruise speed is 18m/s which is about 45% throttle. My trim_thr was previously at 60% but throttle response was spiky. It’s now 45% but at different higher speeds I’m getting a 6 second cycle, power vs speed. Any advice appreciated. It would be good if there was an auto tune for TECS.

Set the throttle slew rate as low as possible, I have it at 22 (meaning it changes power by 22 % per second, going from idle to full in about 5 seconds).

Possibly for cruise it should be set to even lower value, but this could be dangerous for low altitude flights.

One could make a very simple lua script for changing this value depending on flight needs (and turbulance).

I have flown before using Pitlab autopilot, and it has a mode where you set the power manually, but it keeps course and altitude. That is the best mode for long range flying.

Ardupilot lacks this mode, and I think this is the way to go.

I probably will implement it in Lua script, taking FBWA mode as the basis.

Setting throttle slew to such a low value seems like an extremely crude filter, and it’s probably not the right answer.

1 Like

You see, for calm wind maybe this is not the answer, but for instance last flight I had turbulance and severe updrafts and downdrafts which sometimes were in the range of ± 4 m/s and mostly above 1.5 m/s. If you set a high slew rate the FC starts pushing and pulling the throttle like a beginner, trying to fight, and that results in extremely high power consumption.

I am not sure if there is a time constant parameter in ardupilot which would gradually (i.e. like several seconds to dozens of seconds) creep the throttle to the correct power setting, filtering turbulance and short upsets.

When you fly an airplane (with pilot inside), you set the power, establish horizontal flight and observe the speed. If it is OK, you do not touch it. If you want a higher or lower speed, than you adjust the throttle, and leave it there. Constant pulling and pushing is very counterproductive. You do it during the first training hours, and even then unless the instructor cuts you off.

I have several thousand high performance fixed wing hours. I understand the concept, and I do agree that the manual throttle mode you suggested in your first post might be kind of useful.

Though I have a lot of practical real-world experience with fixed wing platforms (manned and unmanned), I’ve dealt least with ArduPilot’s fixed wing branch, mostly focusing on Rover and Copter platforms.

That said, I don’t think I can get onboard with the throttle slew “fix” for anything - too great a disturbance could be catastrophic with such a slow response. I think the more relevant parameters to handle such oscillation/phugoid modes as shown in the graph are: TECS_SPDWEIGHT, TECS_PTCH_DAMP, TECS_THR_DAMP, and to a slightly lesser degree, TECS_INTEG_GAIN and TECS_TIME_CONST. Exactly how to manipulate them for best results is likely left to someone a bit more experienced than me with TECS tuning.

I also recommend, based on some brief feedback from another dev, that you tune the basics (pitch, in particular) very well before having a go at TECS. I have asked others to weigh in and help refine my response.

@Vince_Hogg, a log would be helpful, of course.

3 Likes

I adjusted the slew rate a small amount to start with but I saw a few occasions when it got within 1m/s of stall speed. I dare not reduce it further.

I think I have tweaked most of those other TECS parameters but perhaps not enough.

Here is the latest file. It’s an auto speed ramp up course with a glide test at the end.

I’ve just taken a look at Kite3_Flight1.BIN. Here’s a short segment of the straight flight path:

The phugoid, with a frequency of around 0.16 Hz, is fascinating to observe. I don’t think the magnitude is bad at all. The pitch amplitude is about ±3°. The airspeed fluctuation is a maximum of ±1 m/s (airspeed is plotted 20 m/s lower so that the curves overlap.). Throttle fluctuations are ±5%, with a period of around 6 seconds.

Even with optimally tuned PIDs — a prerequisite for a well-functioning TECS system — and the best possible configuration of TECS parameters, such a phugoid can only be minimised, not prevented. Its magnitude can also increase significantly solely due to random common periods of the inherently nose-heavy aircrafts phugoid and the TECS system acting as a resonance amplifier.

The problem with increasing the slew rate is that, during intentionally initiated climbs or descents, the thrust control can become dangerously sluggish.

Therefore, I would set TECS_SPDWEIGHT to less than 1.

To avoid amplifying the phugoid amplitude via TECS, thrust should be kept constant during horizontal cruise flight, as in a large aircraft. No pilot would think of periodically adding and then reducing throttle during cruise flight. TECS would need to know the pilot’s intentions and the aircraft’s performance data in order to set the thrust initially rather than constantly readjusting it.

Rolf

1 Like

Hello! Thanks for the log.

I would suggest you revisit your pitch rate tuning. IMO it’s not normal for a typical plane not being able to match these pitch rate targets within 1s or so:

When it takes longer, your pitch angle goes out of phase:

and the TECS controller gives pitch targets that aren’t served as expected.

4 Likes