Fix imu_health metric
git-svn-id: https://arducopter.googlecode.com/svn/trunk@1728 f9c3cf11-9bcb-44bc-f272-b75c42450872
This commit is contained in:
parent
85672b5ab2
commit
0642e1144d
@ -228,7 +228,7 @@ AP_DCM::drift_correction(void)
|
||||
accel_weight = constrain(1 - 2 * fabs(1 - accel_magnitude), 0, 1); //
|
||||
|
||||
// We monitor the amount that the accelerometer based drift correction is deweighted for performance reporting
|
||||
_health += constrain((0.02 * (accel_weight - .5)), 0, 1);
|
||||
_health = constrain(_health+(0.02 * (accel_weight - .5)), 0, 1);
|
||||
|
||||
// adjust the ground of reference
|
||||
_error_roll_pitch = _dcm_matrix.c % _accel_vector; // Equation 27 *** sign changed from prev implementation???
|
||||
|
@ -29,7 +29,8 @@ public:
|
||||
0, 1, 0,
|
||||
0, 0, 1),
|
||||
_course_over_ground_x(0),
|
||||
_course_over_ground_y(1)
|
||||
_course_over_ground_y(1),
|
||||
_health(1.)
|
||||
{}
|
||||
|
||||
// Accessors
|
||||
|
Loading…
Reference in New Issue
Block a user