mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-26 15:03:33 +08:00
sensors: move voting into sensors module
- voting is now at a central place instead of duplicated within the
estimators
-> this also means that estimators that did not do voting so far,
now have voting, like ekf2
- estimators requiring more than that can still subscribe to the raw
sensors
- allows sensors_combined to be 3 times smaller
- reduces logger, memcpy (cache) & RAM overhead
- all modules requiring only 1 or 2 sensor values now automatically get
the voted result
- this also adds voting to baro
This commit is contained in:
@@ -1231,7 +1231,7 @@ FixedwingPositionControl::control_position(const math::Vector<2> ¤t_positi
|
||||
|
||||
/* filter speed and altitude for controller */
|
||||
math::Vector<3> accel_body;
|
||||
float accel_dt = _sensor_combined.accelerometer_integral_dt[0] / 1.e6f;
|
||||
float accel_dt = _sensor_combined.accelerometer_integral_dt / 1.e6f;
|
||||
accel_body(0) = _sensor_combined.accelerometer_integral_m_s[0] / accel_dt;
|
||||
accel_body(1) = _sensor_combined.accelerometer_integral_m_s[1] / accel_dt;
|
||||
accel_body(2) = _sensor_combined.accelerometer_integral_m_s[2] / accel_dt;
|
||||
|
||||
Reference in New Issue
Block a user