Paul Riseborough
a2dcd5b9b6
EKF: Consolidate no aiding reset logic
7 years ago
Paul Riseborough
929c5c2b37
EKF: enable gps fusion flag to be false while fusing air data
7 years ago
Paul Riseborough
204a218ee6
EKF: Allow dead-reckoning using air data
7 years ago
ChristophTobler
f5fd90533a
fix gps and flow flag handling
...
gps flag was not turning false if there was flow
only reset states if we were relying on that sensor only
7 years ago
CarlOlsson
c81cdfa1ce
EKF: Fix bug when resetting position and velocities for fw due to something else than bad yaw estimate
...
Signed-off-by: CarlOlsson <carlolsson.co@gmail.com>
7 years ago
Paul Riseborough
6f7f05fdc0
EKF: Move MAG_FUSE_TYPE_AUTOFW control to the expected place
7 years ago
Paul Riseborough
7b4c957ad4
ekf2: Add new mag fusion mode
...
Adds a mode where mag fusion is only used update the field estimates
7 years ago
Paul Riseborough
1119a9b0ac
EKF: Enable optical flow reversion to work if flow data is lost
...
Also improve reporting.
7 years ago
ChristophTobler
b7e589b98a
EKF: only fuse optical flow if terrain is valid
7 years ago
CarlOlsson
0a7c3ecbc6
EKF: Parameterize maximum angle for rng fusion
8 years ago
Paul Riseborough
1d3e8edc46
EKF: Fix bug in accumulation of IMU data for flow sensor gyro bias calculation
8 years ago
Paul Riseborough
dd5b8525c3
EKF: Use hamiltonian convention for quaternion product order
8 years ago
Daniel Agar
99ba1c3745
EKF trivial code style cleanup
8 years ago
ChristophTobler
7252284628
Add check for stuck range finder measurements
8 years ago
Paul Riseborough
ce806768b7
EKF: Improve in-flight mag error detection, recovery and isolation for fixed wing
8 years ago
Paul Riseborough
e08da1c599
EKF: Add ability to use EV and GPS data together
...
Fuse external vision data using a relative position odometry method when GPS data is also being used and enable both GPOS and EV data to be fused on the same time step.
8 years ago
Paul Riseborough
e1fe5b2229
Revert "Revert "Split get_terrain_vert_pos() into valid and get_vpos""
8 years ago
Paul Riseborough
c887b02f21
Revert "Split get_terrain_vert_pos() into valid and get_vpos"
8 years ago
ChristophTobler
e429ecab17
check if terrain valid instead of initialized
8 years ago
ChristophTobler
517fe8a71f
rng aid: use hysteresis with lower hagl check
8 years ago
ChristophTobler
8ed61ac052
init rng offset with ground clearance param when on ground to avoid noisy init
8 years ago
Paul Riseborough
9ee35e38df
EKF: Don't fallback when optical flow is lost if external vision data is being used
8 years ago
Paul Riseborough
1bb576c197
EKF: Allow fallback to non-aiding mode if external vision is lost.
8 years ago
Isaac
f96685267e
Fixed vision position fusion bug
8 years ago
Paul Riseborough
ec2b54fde7
EKF: Ensure normal yaw alignment using mag is performed if GPS method is not
8 years ago
Paul Riseborough
d446f66105
EKF: Add a fixed wing mode with setter function
8 years ago
Paul Riseborough
f064915889
EKF: Enable planes to recover from bad mag data at start of flight
...
Adjusts yaw by the amount of the error between GPS and EKF course if innovations are large.
8 years ago
Paul Riseborough
59edccca4a
EKF: Fix bug in wind estimation for fixed wing
8 years ago
Paul Riseborough
ba4a311771
EKF: Update comments for wind estimation logic
8 years ago
ChristophTobler
e1274ad28a
move faultiness check above pop_first_older_than() and check independent of range aid to switch back to original sensor if available
8 years ago
ChristophTobler
0d9e535acb
Use baro if reset to baro from gps and vice versa
8 years ago
ChristophTobler
4a4b0fa604
remove setting rng faulty in ev mode because not checked
8 years ago
ChristophTobler
066c641d61
range aid: switch to baro/gps even if rng aid conditions met and rng faulty
8 years ago
ChristophTobler
2f382c8e0e
if hgt mode is range, switch to baro if range is faulty
8 years ago
ChristophTobler
e4f36215cb
if in range aid mode, check faultiness that otherwise would never change back
8 years ago
ChristophTobler
e800de88b6
remove duplicate
8 years ago
Daniel Agar
c44488fdb8
EKF matrix typedef cleanup
8 years ago
ChristophTobler
1fed209804
fix formatting
8 years ago
Roman
5036967343
barometer does not special height sensor offset because a barometer
...
offset from the local origin is calculated if the primary source for
height is not baro
Signed-off-by: Roman <bapstroman@gmail.com>
8 years ago
Roman
c5d464b821
make range sensor height offset computation more robust
...
- when switching to range finder use the current terrain estimate as
height sensor offset, otherwise spikes in the range measurements could lead
to a wrong offset
Signed-off-by: Roman <bapstroman@gmail.com>
8 years ago
Roman
182ea43445
fixed baro offset calculation
...
- do not subtract the height sensor offset variable when computing the
baro offset from the local origin. The baro height offset is calculated
when baro is not fused and so the height sensor offset used in that case
is associated to another sensor and has nothing to do with the baro.
Signed-off-by: Roman <bapstroman@gmail.com>
8 years ago
Roman
39983a7d55
range aid: added hysteresis for switching in and out of range aid
...
- prevents rapid switching
- added innovation consistency check for using range aid
Signed-off-by: Roman <bapstroman@gmail.com>
8 years ago
Roman
3778f0921a
ekf: enable range finder to be used for estimating height even if it's not
...
the primary height source
- moved height control into single function in order to decide which sensor
should be used for estimating height
- under certain conditions allow to use the range finder to estimate height
even if it's not the primary height source
- fixed a bug where the delta time for the baro offset calculation was always
zero
- use methods to set height control flags to reduce code duplication and
to prevent bugs
Signed-off-by: Roman <bapstroman@gmail.com>
8 years ago
Roman
36bffd2571
ekf: calculate the delta time between consecutive baro measurments
...
(used for calculating filtered baro offset when primary height source
is not baro)
Signed-off-by: Roman <bapstroman@gmail.com>
8 years ago
CarlOlsson
a1308482fd
EKF: Reset the mag states to the field state variance when switching from the inhibit mag mode to standard mode
8 years ago
CarlOlsson
be16406b35
EKF: Add feature to use the mag to only update the mag states
8 years ago
Paul Riseborough
05c3c46f83
ekf2: changes arising from code review
8 years ago
Paul Riseborough
394dd95cba
EKF: Don't do magnetic field estimation without earth frame measurements
...
Use horizontal acceleration to check if yaw is observable independent of the magnetometer.
Use rotation about the vertical to check if mag raises are observable.
If neither yaw of mag biases are observable, save the magnetic field variances and switch to magnetic yaw fusion.
Use the last learned declination when using magnetic yaw fusion so that the yaw reference remains consistent.
When yaw or biases become observable, reinstate the saved variances and switch back to 3D mag fusion.
8 years ago
Paul Riseborough
5ee0ed5a0d
EKF: Increase sensitivity and add tuning of bad accel checks
8 years ago
Paul Riseborough
3758c5a09d
EKF: down-sample drag specific force data
8 years ago