Hi,
Today I tested my latest plane design. Before the first flights I decided to make a short test drive with a car just to test how the APM 2.5 and installed telemetry and other things work. During the test I noticed quite interesting thing...
The plane was inside the car steady and levelled. During forward acceleration artificial horizon in Mission Planner showed positive values (+15°) and during de-acceleration (braking) the horizon showed negative values -15°. This is quite understandable when the orientation is based on accelerometers only. But I don't understand the behaviour with the APM 2.5 because it has gyro sensors that should compensate these accelerometer caused errors...
Does anyone know if this is normal behaviour? Is the APM code more accelerometer oriented so that the gyro information affects a bit slower or something???
-Veikko-
Replies
Hi,
I like that experiment :)
The IMU does work with a gyroscope for each axis whole value is added to a sum at an interval. If there is the slightest offset error, the sum will give the appearance that the plane is constantly (slowly) rotating when actually standing still. The solution is to blend in (low pass) an accelerometer reference as well, which then again has the disadvantage that you have discovered. Especially in a car, which accelerates to a higher speed than most small UAVs and over longer time.
The parameter decides how much acceleromter correction is used, and you can turn it down somewhat on APM2, because its gyros have quite good termal stability.
Regards
Soren
Try reducing the AHRS_RP_P parameter.
Regards
Soren
Did you have airspeed sensor enabled and/or did you have gps attached and working? Sounds like you were not providing appropriate inputs to the autopilot to perform acceleration correction and the linear acceleration was being interpreted as gyro drift - normal behavior in this case...
Orientation is calculated based on the gyro outputs, but the gyro bias is corrected with an estimate of the gravity vector from the accelerometers. The accelerometers, however, do not measure gravity but instead measure specific force. The acceleration force must be removed before the accelerometer outputs can be used to correct the gyros. If you do not have gps lock (and airspeed measurement if the airspeed sensor is enabled) then the acceleration correction cannot do its job and you get the false pitching behavior you witnessed.
Dunno, but pass the popcorn :)
I'm gonna try this tomorrow! You weren't driving a monster truck were you?