This is just for info and probably mainly directed at Roy Vegard Ovesen but it might also interest other people interested in setting up autopilot systems.
As I've mentioned previously, I've had some problems tuning PID controllers, specifically controllers that maintain a specified pitch i.e. input is a target pitch and the output is an elevator-trim deflection. The problem is that the controller needs to be fairly 'brutal' in it's control at low speeds during take-off, to initiate rotation and prevent over-rotation, but this brutality tends to lead to oscillation at higher speeds. However, switching between controllers that have different gains etc, according to flight conditions results in an undesirable 'kick' when the new controller is activated. It seemed to me that the answer to this would be to use a higher bandwidth controller, giving a higher effective resolution, so that deviations can be corrected when they are smaller. The problem with this though, is that the upper bandwidth is limited by the frame-rate and so specifying a higher bandwidth could cause the controller to become unstable on lower specced h/w (such as mine). Anyway, it occurred to me (while walking to a friends for a few beers;) that perhaps I could effectively achieve a higher bandwidth by replicating the controllers and clamping their min & max outputs and then summing them. Well, rather than try to get my head around the maths, which isn't my best subject, I've just started experimenting with it, with some encouraging results. Atm, I'm playing with using four identical controllers to output elevator-trim, with each individual controller output clamped to -0.25/0.25, combined with four input-axis controls in the YASim config and using YASim's summing feature combine the four inputs. Having said that, with the tunings I'm using atm I'm still getting oscillation problems at high speed but because I'm running each output through a pass filter I can switch off the output from one or more of the controllers without switching the actual controllers off. The result of this is that there seems to be very little 'kick' when I re-enable the output. I haven't yet looked into using dissimilar tunings on the controller groups - could be a bit of a nightmare to tune - but it could give some useful results. Also, having had a quick look at the 'pass' filter type, I may have a go at making a 'gain' filter type, the gain being tied to a property tree node. Of course, I'm not at all sure that my original premise was correct in the first place, especially in view of the continued high-speed oscillation, despite some other encouraging initial results (pitch-hold now seems quite a bit 'tighter'), but any comments are welcome:) LeeE ------------------------------------------------------------------------- This SF.net email is sponsored by: Microsoft Defy all challenges. Microsoft(R) Visual Studio 2008. http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ _______________________________________________ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel