From 9e2cd93b2d4ef195aa0ea8f3652bea10ea7e83ee Mon Sep 17 00:00:00 2001 From: Randy Mackay Date: Tue, 15 Jul 2014 10:54:59 +0900 Subject: [PATCH] AP_InertialNav: init members to reduce compiler warnings --- libraries/AP_InertialNav/AP_InertialNav.h | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/libraries/AP_InertialNav/AP_InertialNav.h b/libraries/AP_InertialNav/AP_InertialNav.h index f4dfea0754..a81577c91a 100644 --- a/libraries/AP_InertialNav/AP_InertialNav.h +++ b/libraries/AP_InertialNav/AP_InertialNav.h @@ -38,9 +38,16 @@ public: _ahrs(ahrs), _baro(baro), _xy_enabled(false), + _k1_xy(0.0f), + _k2_xy(0.0f), + _k3_xy(0.0f), _gps_last_update(0), _gps_last_time(0), _historic_xy_counter(0), + _lon_to_cm_scaling(LATLON_TO_CM), + _k1_z(0.0f), + _k2_z(0.0f), + _k3_z(0.0f), _baro_last_update(0), _glitch_detector(gps_glitch), _error_count(0) @@ -274,9 +281,12 @@ protected: AP_AHRS &_ahrs; // reference to ahrs object AP_Baro &_baro; // reference to barometer + // parameters + AP_Float _time_constant_xy; // time constant for horizontal corrections in s + AP_Float _time_constant_z; // time constant for vertical corrections in s + // XY Axis specific variables bool _xy_enabled; // xy position estimates enabled - AP_Float _time_constant_xy; // time constant for horizontal corrections in s float _k1_xy; // gain for horizontal position correction float _k2_xy; // gain for horizontal velocity correction float _k3_xy; // gain for horizontal accelerometer offset correction @@ -288,7 +298,6 @@ protected: float _lon_to_cm_scaling; // conversion of longitude to centimeters // Z Axis specific variables - AP_Float _time_constant_z; // time constant for vertical corrections in s float _k1_z; // gain for vertical position correction float _k2_z; // gain for vertical velocity correction float _k3_z; // gain for vertical accelerometer offset correction