Just normal flybar to have "AutoLevel" feature..

Hamburger wrote:Which sensor do you use? Some allow explicit filtering internally.
Code: Select all
/* ITG3200 & ITG3205 Low pass filter setting. In case you cannot eliminate all vibrations to the Gyro, you can try
to decrease the LPF frequency, only one step per try. As soon as twitching gone, stick with that setting.
It will not help on feedback wobbles, so change only when copter is randomly twiching and all dampening and
balancing options ran out. Uncomment only one option!
IMPORTANT! Change low pass filter setting changes PID behaviour, so retune your PID's after changing LPF.*/
//#define ITG3200_LPF_256HZ // This is the default setting, no need to uncomment, just for reference
//#define ITG3200_LPF_188HZ
//#define ITG3200_LPF_98HZ
//#define ITG3200_LPF_42HZ
//#define ITG3200_LPF_20HZ
//#define ITG3200_LPF_10HZ // Use this only in extreme cases, rather change motors and/or props
leadfeather wrote: I was shown a section under the imu tab that smooths the yaw gyro. I mimicked this code for roll and pitch and increased the value of the smoothing constants and this seemed to work pretty good.
Code: Select all
#if defined(TRI)
gyroData[YAW] = (gyroYawSmooth*2+gyroData[YAW]+1)/3;
gyroYawSmooth = gyroData[YAW];
#endif
Code: Select all
#if defined(HELICOPTER)
static uint8_t Smoothing[3] = {3,3,2}; // How much to smoothen with per axis
static int16_t gyroSmooth[3] = {0,0,0};
for (axis = 0; axis < 3; axis++) {
gyroData[axis] = (gyroSmooth[axis]*(Smoothing[axis]-1)+gyroData[axis]+1)/Smoothing[axis];
gyroSmooth[axis] = gyroData[axis];
}
#endif
PatrikE wrote:Idid some tests on my crappy Belt CP.
It seems to work god.
I updated the branch with this mod.
http://code.google.com/p/multiwii/source/browse/#svn%2Fbranches%2FPatrikE
The Smoothing settings is placed in MultiWii. tab
/Patrik
leadfeather wrote:I used the code I had written, I had some help with the syntax.
For the helicopter swash servos I had to use a lot of smoothing... a factor of 60 to get it working well. Because of the large numbers involved, it was recommended that some code was added to avoid numeric overflow. If you like, I can post the smoothing code I used in a couple of day after I get home.
caall99 wrote:is this code mature enough for me to use the MultiWii controller on a Blade 400 3D with a flybarless head conversion?
I am hoping for auto level capabilities as well from the accelerometers.