From df7f261e038aa80b07a91857f2f952280938bfc6 Mon Sep 17 00:00:00 2001 From: Kamil Ritz Date: Sun, 20 Dec 2020 09:51:53 +0100 Subject: [PATCH] Add missing const modifier --- EKF/EKFGSF_yaw.cpp | 4 ++-- EKF/EKFGSF_yaw.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/EKF/EKFGSF_yaw.cpp b/EKF/EKFGSF_yaw.cpp index 6f41e86d90..3d4b0f643d 100644 --- a/EKF/EKFGSF_yaw.cpp +++ b/EKF/EKFGSF_yaw.cpp @@ -470,7 +470,7 @@ float EKFGSF_yaw::gaussianDensity(const uint8_t model_index) const return _m_2pi_inv * sqrtf(_ekf_gsf[model_index].S_det_inverse) * expf(-0.5f * normDist); } -bool EKFGSF_yaw::getLogData(float *yaw_composite, float *yaw_variance, float yaw[N_MODELS_EKFGSF], float innov_VN[N_MODELS_EKFGSF], float innov_VE[N_MODELS_EKFGSF], float weight[N_MODELS_EKFGSF]) +bool EKFGSF_yaw::getLogData(float *yaw_composite, float *yaw_variance, float yaw[N_MODELS_EKFGSF], float innov_VN[N_MODELS_EKFGSF], float innov_VE[N_MODELS_EKFGSF], float weight[N_MODELS_EKFGSF]) const { if (_ekf_gsf_vel_fuse_started) { *yaw_composite = _gsf_yaw; @@ -532,7 +532,7 @@ Matrix3f EKFGSF_yaw::ahrsPredictRotMat(const Matrix3f &R, const Vector3f &g) return ret; } -bool EKFGSF_yaw::getYawData(float *yaw, float *yaw_variance) +bool EKFGSF_yaw::getYawData(float *yaw, float *yaw_variance) const { if(_ekf_gsf_vel_fuse_started) { *yaw = _gsf_yaw; diff --git a/EKF/EKFGSF_yaw.h b/EKF/EKFGSF_yaw.h index 9b07ae6f6d..9e1e6291e4 100644 --- a/EKF/EKFGSF_yaw.h +++ b/EKF/EKFGSF_yaw.h @@ -45,11 +45,11 @@ public: float yaw[N_MODELS_EKFGSF], float innov_VN[N_MODELS_EKFGSF], float innov_VE[N_MODELS_EKFGSF], - float weight[N_MODELS_EKFGSF]); + float weight[N_MODELS_EKFGSF]) const; // get yaw estimate and the corresponding variance // return false if no yaw estimate available - bool getYawData(float *yaw, float *yaw_variance); + bool getYawData(float *yaw, float *yaw_variance) const; private: