I am writing this discussion topic illustrate how I used the filter to successfully reduce the instability to increase the P and D gains. I’ve read in the Copter traditional helicopter tuning section about tuning the PID gains and that in most cases helicopters are limited in the P gain for pitch and roll due to aeroelastic instabilities of the airframe. I’d be interested in learning about any work that has already been accomplished in this area.
I am relatively new to the ardupilot community. I have been working on a special project with an electric helicopter modified to fly fast. Basically I took off the tail rotor and added two forward facing variable pitch propellers (tailrotors). I have made several modifications to the AC 3.3.3 software to include adding a new compound heli frame, adding the airspeed sensor from arduplane, and a turn coordination logic. In expanding forward flight speeds, I found that there was a significant pitch oscillation of about +/- 8 deg at around ½ hz frequency. Before expanding the airspeed envelope, I wanted to adjust the flying qualities to remove this oscillation.
In tuning my helicopter, I found my instability to occur at approximately 6.2 hz. So my thought was to use the PID low pass filter to filter out the instability and enable the P-gain and/or the D gain to be increased. So the big concern with using a low pass filter is with degrading the response of the Heli to control inputs. To determine the effect of the filter I performed frequency sweeps while hovering. I used matlab to do a spectral analysis to look at the gain and phase of the input and output. The first thing I did was reduce the filter cutoff frequency. Once I was happy with the filter frequency (I ended up using 4 hz), I increased the P gain and did another frequency sweep. I was able to increase the gain by 80% of my initial value with no issue. If I would have used this gain with the filter set to 20 hz, the instability at 6 hz would have been horrible. Now comparing the frequency response of the higher p gain to the one with the 20 hz filter frequency, it can be seen in the graph below that there is slightly more phase bandwidth but overall there in no loss in aircraft response.
I did another frequency sweep with my baseline with P=0.05, cutoff freqency of 4hz and then increased the D gain to 0.001. Again, if I had done this with the 20 hz cutoff frequency, the instability would be terrible. In the graph above, it can be seen that there is slightly more phase and gain loss however it does help damp the lightly damped oscillation. I think the P gain would also improve damping of the oscillation but I wasn’t able to get the P gain high enough without having the instability start showing up again. With it so close to my cutoff frequency, the low pass filter cannot attenuate it enough. In order to really target this instability, I am planning to implement a notch filter. I think this would be a great improvement and allow higher p gains for the Heli frames. Has anyone done something similar to this? I will post an update once I incorporate the notch filter and test it.