EKF: Update comments

This commit is contained in:
Paul Riseborough
2016-01-28 08:11:10 +11:00
parent 4526cb9c4f
commit cc50d26601
2 changed files with 5 additions and 4 deletions
+4 -3
View File
@@ -337,9 +337,10 @@ public:
*time_us = _imu_time_last;
}
uint64_t _last_gps_origin_time_us = 0;
struct map_projection_reference_s _posRef = {};
float _gps_alt_ref = 0.0f;
// Variables used to publish the WGS-84 location of the EKF local NED origin
uint64_t _last_gps_origin_time_us = 0; // time the origin was last set (uSec)
struct map_projection_reference_s _posRef = {}; // Contains WGS-84 position latitude and longitude (radians)
float _gps_alt_ref = 0.0f; // WGS-84 height (m)
bool _vehicleArmed = false; // vehicle arm status used to turn off funtionality used on the ground
+1 -1
View File
@@ -88,7 +88,7 @@ bool EstimatorBase::gps_is_good(struct gps_message *gps)
_gps_alt_ref = gps->alt * 1e-3f;
}
// Calculate time lapsesd since last update, limit to prevent numerical errors and calculate the lowpass filter coefficient
// Calculate time lapsed since last update, limit to prevent numerical errors and calculate the lowpass filter coefficient
const float filtTimeConst = 10.0f;
float dt = fminf(fmaxf(float(_time_last_imu - _last_gps_origin_time_us)*1e-6f,0.001f),filtTimeConst);
float filterCoef = dt/filtTimeConst;