14 Commits

Author SHA1 Message Date
mcsauder
164e53bad3 Add unit tests and update ekf_helper setEkfGlobalOrigin() method to allow for condition when current position is unitialized. 2021-02-19 08:59:47 -05:00
Mathieu Bresciani
8f3df7a97b
flow: restructure optical flow control logic (#928)
- extract motion checks performed on ground
- move all non-timing check to controlOpticalFlowFusion. This simplifies and standardirzes the setOpticalFlowData function. Furthermore, in some cases (SITL, PX4Flow), the dt is forced to 0 when the quality is 0 (which is usual on ground) so the ekf needs to ignore those values on ground to initialize properly the flow fusion.
- add filter convergence test
- move check for dt time max in setOpticalFlowData
- in the simulator, do not update dt as this is the sensor integration
period.
2020-12-09 11:33:00 +01:00
bresch
62e15cbacf sensor_simulator: set IMU rate to 200Hz as this is the new value
used in the Firmware
2020-06-03 17:09:20 +02:00
bresch
6126c190b2 sensor_simulator: update EKF at IMU rate
This is how it is also done in ekf2_main. Otherwise, this leads to
multiple integration of the same IMU data due to asynchronous sensor
updates triggering a prediction step between IMU updates.

Fix unit tests that broke because of this fix
2020-06-03 17:09:20 +02:00
kritz
fa5a00d871
Refactor velocity reset (#788)
* Refactor velocity reset

* Add unit tests for velocity resets

* Expand updates to vertical buffer to velocity resets outside of resetHeight

* Improve matrix library usage

* Improve naming of vertical output samples

* Fix update of output_vert_new during reset

* Improve naming of vertical output samples 2
2020-04-08 16:39:15 +02:00
kritz
e52e2b88ed
Sensor Replay (#717)
* Add primitive logging for Ekf

* Add python script to extract sensor data from ULog

* Add primitive sensor replay

* Add iris_gps data for sensor replay

* Add CI for functional change indication

* Update sensor replay flow data type

* update iris_gps_change indication

* test: Update EKF replay test documentation

Co-authored-by: Paul Riseborough <priseborough@users.noreply.github.com>
2020-02-01 20:41:12 +11:00
kamilritz
8f70a10565 Added missing variable initializations 2020-01-14 15:16:25 +03:00
kamilritz
7ed6a437c7 Add airspeed sensor to sensor_simulator 2020-01-14 15:16:25 +03:00
kamilritz
1b0e137b8a Test external vision 2020-01-08 14:36:03 +01:00
kamilritz
7d3814b1d8 Add orientation initialization tests 2019-12-18 09:46:32 +01:00
kritz
532c9abd4a Expand test framework and test cases (#685)
* Fix comment

* Ekf wrapper for testing

Add utility function for accessing information in the ekf object

* Add step function for Gps sensor

* Add RangeFinder and Flow to simulated sensors

* Add first fusion logic tests

* Add units to function name

* Use EXPECT_TRUE

* Adding missing qualifiers

* Improve EXPECT_ calls

* Improve naming
2019-12-17 11:35:45 +01:00
kamilritz
1832bedd13 run_seconds 2019-12-16 13:40:01 +01:00
kamilritz
f13f2f8452 use shared pointer 2019-12-16 13:40:01 +01:00
kamilritz
00cd720a66 Change folder name 2019-12-16 13:40:01 +01:00