244 Commits

Author SHA1 Message Date
Daniel Agar
850b1ad6a7 EKF2 split output predictor and publish attitude immediately (#9832)
* EKF2 split output predictor and publish attitude immediately

* ecl: incorporate magic number tidy up
2018-07-09 08:11:24 +10:00
Daniel Agar
9ce83f2208 fix all sign-compare warnings 2018-07-01 09:36:55 +00:00
Paul Riseborough
a04468ba9f ekf2: Fix EKF preflight check fail false positives
Uses a relaxed yaw innovation check threshold for fixed wing vehicle that can recover from larger yaw errors after takeoff.
Replaces the peak hold with decay filtering applied to the magnetic yaw innovations with a conventional lowpass filter. This prevents mag heading innovation transients caused by preflight handling from failing the check, but catches persistent errors. Sign swapping of innovations due to angle wrapping is not a problem due to the way that innovations are calculated inside the EKF, so a simple LPF sufficient.
2018-06-29 16:36:38 +00:00
Daniel Agar
96f47d4772
EKF2 add perf counters (#9795) 2018-06-28 17:28:03 -04:00
Mohammed Kabir
8f5ceac936 ekf2 : use INFINITY when altitude limiting is not needed 2018-06-09 13:38:04 +02:00
Mohammed Kabir
6a9377846f ekf2 : update to use new navigation limits architechture 2018-06-09 13:38:04 +02:00
Paul Riseborough
cbb4559c15 ecl : update to version that fixes wind relative dead reckoning bug 2018-04-24 00:02:48 -04:00
Daniel Agar
35cb2d0a9e EKF2 fix airspeed orb_copy check 2018-04-24 00:02:48 -04:00
Paul Riseborough
477a42e6f6 ekf2: Enable adjustment of nav validity timeout 2018-04-24 00:02:48 -04:00
Daniel Agar
1ecfb22dbc EKF2 move all orb_subscribe/unsubsribe to the constructor/destructor 2018-04-11 23:26:58 -04:00
Daniel Agar
2a58c7a28c EKF2 and replay add all consumed messages to ekf2_timestamps and refactor 2018-04-11 23:26:58 -04:00
Daniel Agar
3b5b12e1d1 move baro and magnetometer data out of sensor_combined 2018-04-11 23:26:58 -04:00
Daniel Agar
5dc23def2a move pressure altitude from baros to sensors module 2018-04-11 23:26:58 -04:00
Roman
d9fbf85c20 ekf2: remove early advertising of wind estimate topic
- if it's not estimating wind it won't publish it below (was fixed)

Signed-off-by: Roman <bapstroman@gmail.com>
2018-03-21 18:46:58 +01:00
Roman
d2ebb0c7a2 ekf2: advertise wind topic early to make sure ekf2 get the first instance
Signed-off-by: Roman <bapstroman@gmail.com>
2018-03-21 18:46:58 +01:00
Daniel Agar
1abf90c6d4 EKF2 only publish wind_estimate if wind velocity is being estimated
- refactor body wind velocity calculation
2018-03-15 07:18:58 +01:00
Beat Küng
279b66bfbd ekf2: use new Param class
reduces RAM usage by 1.3KB
2018-03-13 17:35:15 +01:00
Daniel Agar
458db2e508 vehicle_global_position remove redundant evh and evv
- vehicle_status_flags condition_global_velocity_valid is also unnecessary
2018-03-05 13:20:28 -05:00
Daniel Agar
b9081fb0ab vehicle_global_position delete unused pos_d_deriv 2018-03-05 01:41:18 -05:00
Daniel Agar
4c4f990b3b EKF2 remove FW_ARSP_MODE check 2018-03-02 08:58:08 +01:00
Paul Riseborough
b117fddb21 ekf2: publish estimator position control limits 2018-01-29 22:30:34 +01:00
ChristophTobler
66c67f89e6 ekf2: check if vision_position pos/vel are valid before using them 2018-01-15 11:11:56 +01:00
ChristophTobler
c7cf442e16 ekf2: use ev eph/v for noise parameter if bigger than noise param 2018-01-15 11:11:56 +01:00
Nicolas de Palezieux
d9b9b4407a ekf2 : add support for precision landing measurement fusion 2018-01-15 10:27:23 +01:00
Daniel Agar
7b1b255158 EKF2 set zero unused estimator_status fields 2018-01-12 23:19:46 +01:00
CarlOlsson
84d7eb2900 ekf2: added beta test ratio to estimator_status
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2018-01-02 22:36:42 +01:00
CarlOlsson
925c65b4d5 ekf2: add beta innovation gate to parameters
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
2017-12-21 04:02:10 +08:00
Paul Riseborough
324c5151e7 ekf2: use local scope for control mask variable 2017-12-08 07:43:13 +00:00
Paul Riseborough
b812f95a77 ekf2: Adjust pre-flight check level
Reduce max yaw error when not using global frame aiding data to prevent large yaw yaw changes after takeoff.
2017-12-08 07:43:13 +00:00
Paul Riseborough
ded9ca13e4 ekf2: Reduce sensitivity of preflight yaw check when not doing absolute aiding
When the EKF is not fusing in observations from the NE global reference frame, the tolerance to yaw errors is much higher. This changes will prevent false triggering of the preflight fail check when operating indoors without GPS where mag field errors can be high.
2017-12-08 07:43:13 +00:00
Paul Riseborough
fc80be0917 ekf2: improve preflight checks and publish status
Separate the vertical and horizontal checks for use by local position validity reporting
Add checking of yaw using a decaying envelope filter to the horizontal checks.
Publish the check result to estimator_status topic.
2017-12-04 09:09:54 +00:00
Paul Riseborough
a410893080 ecl: Update ekf2 to version that addresses known vulnerabilities
See:

https://github.com/PX4/ecl/pull/350
https://github.com/PX4/ecl/pull/354

Note the amount of stack allocation has had to be increased to accomodate pr350
2017-11-13 22:50:12 +01:00
Daniel Agar
0a58bd309c EKF2 always publish status message (#8234)
* EKF2 always publish status message

* EKF2 fix comment typo

* EKF2 time slip use signed int and consolidate

* EKF2 minor readability improvements
2017-11-08 07:55:50 +11:00
Paul Riseborough
589d58ce87 ekf2: Fix bug preventing first IMU failover bias reset 2017-10-30 08:21:09 +01:00
Paul Riseborough
0c9e07c95a ekf2: repeat IMU bias reset until successful 2017-10-30 08:21:09 +01:00
Daniel Agar
e5ead354f0 EKF2 reset IMU bias if the accel or gyro changes 2017-10-29 16:24:31 +01:00
Paul Riseborough
3fc7aba178 TECS: Use version in ECL library
This change updates a number of interfaces to use the new TECS implementation from the ECL library.
2017-10-22 21:56:06 +02:00
ChristophTobler
d7c8d53489 use get() for BlockParam 2017-10-18 11:08:58 +02:00
ChristophTobler
40b8d8bd48 use distance to ground if on ground an distance is out of range 2017-10-18 11:08:58 +02:00
Paul Riseborough
ed950d70ce ekf2: Add missing documentation 2017-10-09 08:58:01 +02:00
Paul Riseborough
6cfee65060 ekf2: Add parameters to tune accelerometer bias learning
These parameters enable the accel bias limiting and learning inhibit logic in the ecl EKF to be easily tuned during testing and replay.
2017-10-09 08:58:01 +02:00
ChristophTobler
ec61ae0003 ekf2: add some comments 2017-10-04 13:11:11 +02:00
Lorenz Meier
f9c9890a49 EKF2: Add minimal stack for M7 targets 2017-09-29 10:13:51 -04:00
ChristophTobler
ee82e80517 ekf2: subscribe to multi dist instances and check orientation 2017-09-25 08:52:21 +02:00
Daniel Agar
b4755297ec delete control_state and cleanup vehicle_attitude (#7882) 2017-09-21 16:24:53 -04:00
Matthias Grob
5bea264a5f Matrix Quaternions: Apply simpler call for constructor and copying to all remaining modules 2017-09-21 17:44:57 +02:00
Daniel Agar
3498fe0c6f delete sdlog2 EKF2 replay (#7982) 2017-09-19 10:20:41 -04:00
Daniel Agar
545ce9ae24 modules remove extra semicolons 2017-09-16 21:29:52 +01:00
Daniel Agar
dc18112697 EKF2 limit map reprojection (#7900) 2017-09-05 12:56:53 -04:00
Daniel Agar
b70b8288b9 px4_includes cleanup incomplete list 2017-08-20 20:42:42 +02:00