insMagnetometer
Description
The insMagnetometer
object models magnetometer readings for sensor
fusion. Passing an insMagnetometer
object to an insEKF
object enables the
insEKF
object to fuse magnetometer data. For details on the magnetometer
model, see Algorithms.
Creation
Syntax
Description
creates an
sensor
= insMagnetometerinsMagnetometer
object. Passing the created sensor
to an
insEKF
object enables the
insEKF
object to fuse magnetometer data. When fusing data with the
fuse
object function of
insEKF
, pass
sensor
as the second argument to identify the data as obtained from
a magnetometer.
Examples
Algorithms
The insMagnetometer
object models the magnetometer reading as the geomagnetic
vector in the sensor frame. The measurement equation is:
where h(x) is the three-dimensional measurement output, gmag is the geomagnetic vector expressed in the sensor frame, and Δ is the three-dimensional bias of the sensor, which is modeled as a constant vector in the sensor frame.
Passing an insMagnetometer
object to an insEKF
filter object
enables the filter object to additionally track the unique geomagnetic vector, as well as the
bias of the magnetometer.
Version History
Introduced in R2022a