EKF angle constants in degrees for readability (#465)
* EKF angle constants in degrees for readability
* EKF make FILTER_UPDATE_PERIOD_MS static constexpr and add FILTER_UPDATE_PERIOD_S
* EKF controlOpticalFlowFusion() use constants and update comments
* EKF controlMagFusion() use angle in degrees
* EKF move earth spin rate to geo and update usage
* EKF: Fix numerical constant error and clean up comments
Comments do not need to contain numerical values when the code makes these clear.
master
Daniel Agar7 years agocommitted byPaul Riseborough
Quatfquat_change;///< quaternion delta due to last reset - multiply pre-reset quaternion by this to get post-reset quaternion
}_state_reset_status{};///< reset event monitoring structure containing velocity, position, height and yaw reset information
float_dt_ekf_avg{0.001f*FILTER_UPDATE_PERIOD_MS};///< average update rate of the ekf
float_dt_ekf_avg{FILTER_UPDATE_PERIOD_S};///< average update rate of the ekf
float_dt_update{0.01f};///< delta time since last ekf update. This time can be used for filters which run at the same rate as the Ekf::update() function. (sec)
stateSample_state{};///< state struct of the ekf running at the delayed time horizon
staticconstunsignedFILTER_UPDATE_PERIOD_MS=8;// ekf prediction period in milliseconds - this should ideally be an integer multiple of the IMU time delta
staticconstexprunsignedFILTER_UPDATE_PERIOD_MS{8};// ekf prediction period in milliseconds - this should ideally be an integer multiple of the IMU time delta