Next Article in Journal
Filament Breakage Monitoring in Fused Deposition Modeling Using Acoustic Emission Technique
Previous Article in Journal
LESS: Link Estimation with Sparse Sampling in Intertidal WSNs
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Magnetometer and Gyroscope Calibration Method with Level Rotation

College of Automation, Harbin Engineering University, No. 145 Nantong Street, Harbin 150001, China
*
Author to whom correspondence should be addressed.
Sensors 2018, 18(3), 748; https://doi.org/10.3390/s18030748
Submission received: 18 January 2018 / Revised: 23 February 2018 / Accepted: 23 February 2018 / Published: 1 March 2018
(This article belongs to the Section Physical Sensors)

Abstract

:
Micro electro mechanical system (MEMS) gyroscopes and magnetometers are usually integrated into a sensor module or chip and widely used in a variety of applications. In existing integrated gyroscope and magnetometer calibration methods, rotation in all possible orientations is a necessary condition for a good calibration result. However, rotation around two or more axes is difficult to attain, as it is limited by the range of movement of vehicles such as cars, ships, or planes. To solve this problem, this paper proposes an integrated magnetometer and gyroscope calibration method with level rotation. The proposed method presents a redefined magnetometer output model using level attitude. New gyroscope and magnetometer calibration models are then deduced. In addition, a simplified cubature Kalman filter (CKF) is established to estimate calibration parameters. This method possesses important value for application in actual systems, as it only needs level rotation for real-time calibration of gyroscopes and magnetometers. Theoretical analysis and test results verify the validity and feasibility of this method.

1. Introduction

Micro-electro-mechanical-system inertial measurement units (MEMS-IMUs) commonly include a gyroscope, accelerometer, and magnetometer, and are widely employed in many fields which rely on their small size and low costs. The gyroscope can sense the vehicle angular velocity and calculate the attitude change. The magnetometer and accelerometer measure the local magnetic field and the acceleration of the rigidly-attached platform. However, the precision of MEMS gyroscopes is generally not high and attitude error may accumulate quickly. Therefore, MEMS gyroscopes must be calibrated before use. In general, gyroscope calibration methods need to be supplemented by external information. One of the common methods is based on Global Navigation Satellite System (GNSS)-aided calibration [1,2,3]. In dynamic environments, with the use of the precise positioning and velocity information, a GNSS- or GNSS/MEMS-IMU-integrated navigation system can estimate gyroscope bias in real-time and obtain accurate attitude. However, it is impossible to achieve good performance in a static environment. Furthermore, GNSS signals are not always available on account of occlusions, such as buildings, viaducts, tunnels, and dense forests. To improve the reliability and accuracy of the navigation solution, a magnetometer has been introduced to calibrate the gyroscope.
A magnetometer must be calibrated before use because it is prone to being influenced by electromagnetic disturbance. Many magnetometer calibration methods have been presented in related literature. Ellipsoid fitting is a common technology to calibrate a magnetometer [4,5]. This technology does not need any external information because it fits an ellipsoid locus from a non-calibrated magnetometer to a sphere. The advantages of this technology are ease of use, short run-time, and reduced computational needs. However, it also has the weakness of low precision and poor adaptability. Magnetometers can also be calibrated using external attitude information—especially heading information [6,7]. A common drawback of these methods is that erroneous attitude information may lead to worse calibration results. “Attitude-independent” is a classic magnetometer calibration method [8,9,10,11,12,13,14]. By removing the attitude matrix, this method obtains a model that does not contain any attitude information, and a nonlinear Kalman filter (KF) is used to estimate calibration parameters. Many methods have been presented based on this model. For example, attitude-independent magnetometer calibration with time-varying bias was proposed in Reference [11]. Many types of algorithms have been presented to improve the calibration accuracy and adaptability in nonlinear systems, such as extended Kalman filter (EKF) [12], neural network [13], particle filter (PF), and so on [14]. The EKF approach adapts techniques from calculus—namely multivariate Taylor series expansions—to linearize a model near a working approximation point. If the system model (as described below) is not well-known or is inaccurate, then Monte Carlo methods—especially particle filters—are employed for estimation [15,16,17]. For a sensor’s static bias (additive error) and to represent sensitivity error, a neural network method is used to solve the problem. However, it is difficult to set appropriate initial parameters in PF, neural network, or EKF approaches. A particle swarm optimization algorithm is used to calibrate the magnetometer, as it depends on a more accurate nonlinear model and need not consider the initial estimation parameters [18,19,20]. However, this algorithm has high computational cost, which is difficult to implement. Recently, integrated calibration methods for gyroscopes and magnetometers have been widely developed in the literature [21,22]. These methods calibrate a magnetometer using the angular velocity from the gyroscope, while gyroscope calibration parameters are simultaneously estimated using the calibrated magnetometer readings. Through simulation and testing in the field, it is shown that the method is practical, useful, and adaptable to magnetic disturbance. The major shortcoming of this method is the necessity of the initial attitude information. Recently, a virtual rotation scheme was proposed as an advanced calibration method [23,24]. The response of the gyroscope to virtual rotation can be used to calibrate the bias and scale factor errors [25], but this method has not yet been used to calibrate a magnetometer.
The advantages and disadvantages of the above methods are summarized in Table 1. From the above, the precision magnetometer model and accurate external information are important for the calibration result. On the other hand, most methods require that the sensor be rotated in all possible orientations to guarantee a good result. In many navigation systems on vehicles such as cars, ships or planes, most of rotation orientations cannot be performed, which leads to calibration parameters being incorrectly estimated and may have worse performance than non-calibrated systems. To solve the problem, this paper presents a method to calibrate magnetometers and gyroscopes with level rotation, and without heading information. In this method, the three-dimensional model of calibrating the magnetometer is reduced to a two-dimensional model using the level attitude. Based on this idea, the magnetometer output model is redefined, and then a new gyroscope and magnetometer calibration model is proposed, and finally a simplified cubature Kalman filter (CKF) is designed to complete the calibration.
The rest of this paper is organized as follows. Section 2 demonstrates the redefined magnetometer output model and introduces the derivation process of the new calibration model and the filter algorithm. Simulation tests are performed in Section 3. The test result is shown in Section 4 by applying an actual MEMS-IMU system, and conclusions are given in Section 5.

2. System Modeling and Filter

In this section, the leveled output model of the magnetometer is introduced by analyzing the characteristics of level rotation. Based on this model, the magnetometer and gyroscope calibration models are constructed. Finally, a simplified CKF is designed to estimate the calibration parameters.
The frame definitions are introduced as follows, and a sketch of the coordinate systems is shown in Figure 1.
  • Navigation frame (n-frame): The navigation frame is located on the vehicle. It points to the east, north, and upward.
  • Body frame (b-frame): The body frame is fixed to the vehicle. Its x-axis and y-axis point to the right and forward of the vehicle, and its z-axis follows the right-hand rule.
  • Leveled frame (l-frame): The leveled frame is also located on the vehicle. It is the frame by leveling b-frame such that its z-axis is parallel to the upward vertical and possesses an error angle with respect to the n-frame.

2.1. Magnetometer Model

The magnetometer measurement model can be expressed as [26]:
B m = C s c C n o ( C s i B t + b h i ) + b b + ε m ,
where B m is the measurement from the magnetometer and B t is the true magnetic field. C s c is a scale factor matrix, C n o is a non-orthogonal matrix and C s i is a soft-iron effect matrix. b h i and b b are, respectively, the hard-iron effect vector and bias. ε m is the measurement noise of the magnetometer, which can be modeled as Gaussian white noise. C s c , C n o , and C s i are specifically expressed as follows:
C s c = [ C s c x 0 0 0 C s c y 0 0 0 C s c z ] ,
C n o = [ 0 C n o x y C n o x z C n o y x 0 C n o y z C n o z x C n o z y 0 ] ,
C s i = [ C s i x C s i x y C s i x z C s i y x C s i y C s i y z C s i z x C s i z y C s i z ] .
For the measurement of the magnetometer in the b-frame, Equation (1) can be rewritten as
B m b = C B t b + b m b + ε m ,
in which
C = C s c C n o C s i = [ C 11 C 12 C 13 C 21 C 22 C 23 C 31 C 32 C 33 ] ,
b m b = C s c C n o b h i + b b ,
and B t is in b-frame such that B t b = C n b H n , in which C n b is the n-frame to b-frame rotation matrix and H n is the n-frame geomagnetic field.
When B m is redefined as the leveled magnetometer measurement in l-frame, B t can be changed to equal C n l H n , in which C n l is the n-frame to l-frame rotation matrix and can be calculated by the level attitude. Equation (5) can then be rewritten as
B m l = C C n l H n + b m l + ε m .
Because the bias in the b-frame is a goal of magnetometer calibration, Equation (8) can be transformed to
B m l = C C n l H n + C b l b m b + ε m ,
in which C b l is the b-frame to l-frame rotation matrix provided by the level attitude. For convenience of the next calculation, C is represented as
C = ( I 3 × 3 + C l ) 1 ,
B m l = ( I 3 × 3 + C l ) 1 C n l H n + C b l b m b + ε m ,
where I 3 × 3 is an identity matrix.
In this paper, as the algorithm is designed for level rotation, this situation may lead to lower-quality observation of some calibration parameters. To avoid the error introduced by unobservable parameters, C l is assumed to be a symmetric matrix [11]:
C l = [ C 11 C 12 C 13 C 12 C 22 C 23 C 13 C 23 C 33 ] .
After the leveled magnetometer model is obtained, the calibration model for unknown parameters C and b m b needs to be established. From the above deduction, it is known that B m l are direct magnetometer readings, H n can be acquired from the International Geomagnetic Reference Field (IGRF) model [27] and the norm of H n satisfies
H n 2 = ( C b n B t ) T ( C b n B t ) = ( B t ) T C n b C b n B t = B t 2 = ( C l n B t l ) T ( C l n B t l ) = ( B t l ) T C n l C l n B t l = B t l 2 .
Hence, the relationship between the known H n 2 and calibration parameters can be built. The transformation of Equation (9) can be obtained as:
C n l H n = ( I 3 × 3 + C l ) ( B m l C b l b m b ε m ) .
The normalized H n can be expressed by
H n 2 = ( C n l H n ) T C n l H n = ( ( I 3 × 3 + C l ) ( B m l C b l b m b ε m ) ) T ( ( I 3 × 3 + C l ) ( B m l C b l b m b ε m ) ) = ( B m l ) T ( I 3 × 3 + 2 C l + ( C l ) 2 ) B m l 2 ( B m l ) T ( I 3 × 3 + C l ) C b l b m b + b m b 2 + ε m 2 2 [ ( I 3 × 3 + C l ) B m l C b l b m b ] T ε m .
The measuring equation of the magnetometer calibration model can be given by
H n 2 B m l 2 = ( B m l ) T ( 2 C l + ( C l ) 2 ) B m l 2 ( B m l ) T ( I 3 × 3 + C l ) C b l b m b + b m b 2 + w 1 w 1 = ε m 2 2 [ ( I 3 × 3 + C l ) B m l C b l b m b ] T ε m .

2.2. Gyroscope Model

The common gyroscope output model is given by [21,22]:
ω g b = C g ω t b + b g b + ε g ,
b ˙ g b = ε u ,
C g = C g n o C g s c C g m i s ,
where ω g b is the measured value from the gyroscope and ω t b is the real angular rate. b g b is the gyroscope bias in the b-frame. C g s c and C g n o are, respectively, the scale factor error matrix and non-orthogonal matrix of the gyroscope, C g m i s is a misalignment error matrix between gyroscope and magnetometer, C g is a combination matrix of the above three, and ε g and ε u are independent zero-mean Gaussian white-noise.
In this paper, considering that the method is designed for low-cost MEMS navigation systems, a computationally expensive calibration process cannot be afforded. At the same time, to improve the observability of parameters, the scale factors and the non-orthogonal are considered as the calibrated parameters before leaving the factory. Therefore, only the gyroscope bias is considered and the gyroscope model is simplified as
ω g b = ω t b + b g b + ε g b ˙ g b = ε u .
After establishing the gyroscope model, the relationship between the gyroscope bias and the magnetometer needs to be found. From Equation (9), we can obtain
( I 3 × 3 + C l ) B m l = C n l H n + C b l b m b + ε m .
The derivative of Equation (21) can then be shown by
( I 3 × 3 + C l ) B ˙ m l = C ˙ n l H n + C n l H ˙ n + C ˙ b l b m b + ε ˙ m ,
C ˙ n l = [ ω g b × ] n l C n l ,
C ˙ b l = [ ω g b × ] b l C b l .
As vehicles usually rotate more slowly than the sampling rate, C ˙ n l and C ˙ b l are expressed approximately in Equations (23) and (24). [ ω g b × ] n l and [ ω g b × ] b l are defined as follows:
[ ω g b × ] n l = [ 0 ω g z b 0 ω g z b 0 0 0 0 0 ] ,
[ ω g b × ] b l = [ 0 0 ω g y b 0 0 ω g x b ω g y b ω g x b 0 ] .
Combining Equations (14) and (22), we can obtain
C n l H ˙ n = ( I 3 × 3 + C l ) B ˙ m l C ˙ n l H n C ˙ b l b m b ε ˙ m = ( I 3 × 3 + C l ) B ˙ m l + [ ω g b × ] n l C n l H n + [ ω g b × ] b l C b l b m b ε ˙ m = ( I 3 × 3 + C l ) B ˙ m l + [ ω g b × ] n l ( I 3 × 3 + C l ) ( B m l C b l b m b ) + [ ω g b × ] b l C b l b m b [ ω g b × ] n l ε m ε ˙ m
Some parameters are defined as follows:
t 1 = ( I 3 × 3 + C l ) B ˙ m l ,
t 2 = [ ω g b × ] n l ( I 3 × 3 + C l ) ( B m l C b l b m b ) ,
t 3 = [ ω g b × ] b l C b l b m b ,
t 4 = t 1 + t 2 + t 3 .
From Equations (27) to (31), the norm of H ˙ n can be presented by
H ˙ n 2 = t 1 2 + t 2 2 + t 3 2 + 2 t 1 T t 2 + 2 t 1 T t 3 + 2 t 2 T t 3 + [ ω g b × ] n l ε m 2 + ε ˙ m 2 2 t 4 T [ ω g b × ] n l ε m 2 ( t 4 [ ω g b × ] n l ε m ) T ε ˙ m .
Since H ˙ n 2 = B ˙ m l 2 + ( B ˙ m l ) T ( 2 C l + ( C l ) 2 ) B ˙ m l , the measuring equation of the MEMS gyroscope calibration model can be obtained as:
H ˙ n 2 B ˙ m l 2 = ( B ˙ m l ) T ( 2 C l + ( C l ) 2 ) B ˙ m l + t 2 2 + t 3 2 + 2 t 1 T t 2 + 2 t 1 T t 3 + 2 t 2 T t 3 + w 2 w 2 = [ ω g b × ] n l ε m 2 + ε ˙ m 2 2 t 4 T [ ω g b × ] n l ε m 2 ( t 4 [ ω g b × ] n l ε m ) T ε ˙ m .

2.3. Filter Algorithm

According to the above analysis, the magnetometer and gyroscope calibration problem can be formulated as a state estimation problem. Equations (16) and (33) are taken as the observation model and the state transition model is expressed as follows:
State transition model:
C ˙ l = 0 ,
b ˙ m b = 0 ,
b ˙ g b = 0 .
Observation model:
H n 2 B m l 2 = ( B m l ) T ( 2 C l + ( C l ) 2 ) B m l 2 ( B m l ) T ( I 3 × 3 + C l ) C b l b m b + b m b 2 ,
H ˙ n 2 B ˙ m l 2 = ( B ˙ m l ) T ( 2 C l + ( C l ) 2 ) B ˙ m l + t 2 2 + t 3 2 + 2 t 1 T t 2 + 2 t 1 T t 3 + 2 t 2 T t 3 .
In the above, the calibration parameters of the magnetometer and the gyroscope are constant, such that the rate of change of these parameters is equal to zero in the state transition model. For the observation model, it is known that the calibration system is a nonlinear system and the Jacobian matrix of the observation model is difficult to obtain. Hence, the appropriate filter should be employed for rapid and precise calibration. In this paper, CKF is applied for magnetometer and gyroscope calibration since it has some advantages, including fast convergence and less computational needs [28].
CKF is a filter method based on the cubature transform. The core of CKF is the cubature transformation by a spherical-radial rule [29]. It takes advantage of a set of cubature points to propagate state and covariance matrices of the system. The time update process of the CKF algorithm is expressed as:
S k 1 / k 1 = S V D ( P k 1 / k 1 ) ,
χ k 1 / k 1 = S k 1 / k 1 ξ + x k 1 / k 1 ,
χ k / k 1 * = f ( χ k 1 / k 1 ) ,
x k / k 1 = 1 m i = 1 m χ i , k / k 1 * ,
P k / k 1 = 1 m i = 1 m χ i , k / k 1 * χ i , k / k 1 * T x k / k 1 x k / k 1 T + Q k ,
where S V D ( · ) represents the singular value decomposition of the matrix and f ( · ) is the state transition function. Matrix S k 1 / k 1 is the root mean square of the covariance matrix P , m = 2n (n is the dimensions of the system), ξ = m / 2 [ 1 ] i (For example, when n = 2, [1] = {(1,0)T,(−1,0)T,(0,1)T,(0,−1)T}, [1] i represents the ith column of set [1]). However, because the state vector of the calibration system is constant, the state transfer matrix is a unit matrix, which allows the state transition errors to be ignored; in other words, Q k is a zero matrix. The time update can be simplified as follows:
P k / k 1 P k 1 / k 1 ,
x k / k 1 x k 1 / k 1 .
This solution simplifies the operation of updating time, which also reduces computational needs. The CKF measurement update process is summarized as follows:
S k / k 1 = S V D ( P k / k 1 ) ,
χ k / k 1 = S k / k 1 ξ + x k / k 1 ,
V k / k 1 = h ( χ k / k 1 ) ,
v k / k 1 = 1 m i = 1 m V i , k / k 1 ,
P z z , k / k 1 = 1 m i = 1 m V i , k / k 1 V i , k / k 1 T v k / k 1 v k / k 1 T + R k ,
P x z , k / k 1 = 1 m i = 1 m χ k / k 1 V i , k / k 1 T x k / k 1 v k / k 1 T ,
K k = P x z , k / k 1 P z z , k / k 1 1 ,
x k / k = x k 1 / k 1 + K k ( z k v k / k 1 ) ,
P k / k = P k / k 1 K k P z z , k / k 1 K k T ,
where h ( · ) is the observation function. x k / k and P k / k are the estimated results at step k, and represent the state vector and state covariance matrix separately.

3. Simulation Test

In this section, the feasibility of the proposed method will be verified by simulation testing. In the following, the simulation details will be introduced.

3.1. Reference Algorithm

The proposed method aims to solve the problem that existing calibrations methods do not consider the situation that only level rotation is performed. Existing calibration methods need data in all possible directions and cannot be used with only level rotation. To check the effect of the proposed method, the normal attitude-independent method (NAIM) [8,9] and the magnetometer and gyroscope integrated calibration method (MGICM) are compared in the specified rotation and simulation parameters [21,22]. The NAIM is a classic magnetometer calibration method without any attitude information. This method uses an attitude-independent model for magnetometer calibration by removing the attitude matrix, and CKF is used to estimate calibration parameters. In this algorithm, according to Equation (5), the magnetometer calibration model is set as
B m b = ( I 3 × 3 + C b ) 1 B t b + b m b + ε m ,
C b = [ C 11 b C 12 b C 13 b C 12 b C 22 b C 23 b C 13 b C 23 b C 33 b ] ,
in which the scale factor matrix C b is symmetric. B m b and b m b are located in the b-frame and the attitude matrix C n b is removed by the normalized process of Equation (55). Then, the gyroscope calibration model is deduced. The NAIM calibration system is expressed as follows:
State transition model:
C ˙ b = 0 ,
b ˙ m b = 0 ,
b ˙ g b = 0 .
Observation model:
H n 2 B m b 2 = ( B m b ) T ( 2 C b + ( C b ) 2 ) B m b 2 ( B m b ) T ( I 3 × 3 + C b ) b m b + b m b 2 ,
H ˙ n 2 B ˙ m b 2 = ( B ˙ m b ) T ( 2 C b + ( C b ) 2 ) B ˙ m b + t 2 2 + 2 t 1 T t 2 ,
in which
t 1 = ( I 3 × 3 + C b ) B ˙ m b ,
t 2 = [ ω g b × ] n b ( I 3 × 3 + C b ) ( B m b b m b ) ,
[ ω g b × ] n b = [ 0 ω g z b ω g y b ω g z b 0 ω g x b ω g y b ω g x b 0 ] .
The MGICM calibrates the magnetometer using the angular velocity from the gyroscope, while gyroscope calibration parameters are simultaneously estimated using the calibrated magnetometer readings. The state transition model and observation model are summarized as follows:
State transition model:
C ˙ b n = C b n ( ω g b + b g b ) × ,
C ˙ b = 0 ,
b ˙ m b = 0 ,
b ˙ g b = 0 .
Observation model:
B m b = ( I 3 × 3 + C b ) 1 C n b H n + b m b .
To guarantee fairness, this algorithm will use CKF to estimate parameters.

3.2. Simulation Setting

The proposed method is considered for the situation that the navigation system on many vehicles cannot rotate around two or more axes, such that traditional magnetometer and gyroscope calibration methods may give the wrong results. To check the effectiveness of the proposed method, the rotation model is set to level rotation, where the system rotates only around the z-axis and a limited angular rate may exist on the other two axes. Table 2 provides simulation settings. More detailed rotations are shown in Figure 2. Figure 2a shows the gyroscope output and Figure 2b demonstrates the three-axis magnetometer output. The three-dimensional diagram of magnetometer output is displayed in Figure 2c. The system level attitude is shown in Figure 2d. From Figure 2c, it is clearly observed that the locus of magnetometer data is an approximate ellipse rather than ellipsoid.
The proposed method needs the level attitude of the system to assist calibration. The level attitude can be obtained by any one of the following methods [8]:
  • The level attitude can be gained through accelerometer measures of the orientation of gravity. This method has high precision and stability when static, but cannot guarantee those advantages in dynamic conditions.
  • The gyroscope can update a known attitude by several methods, including quaternions. The advantage is high precision and stability over a short period of time. It is prone to accumulate errors over longer time periods.
  • An integrated navigation system can provide the precision attitude by integrating different sensors with integration algorithms such as KF and EKF, and so on. These sensors may include a gyroscope, accelerometer, odometer, GNSS, Wi-Fi, etc. This method can guarantee high precision and stability over a long time period, and can be applied in any environment if a suitable integration algorithm is chosen.

3.3. Simulation Result

First, to verify the effectiveness of NAIM and MGICM, the data in all possible directions are used to achieve calibration. Figure 3 shows the 3D diagram of data in all possible directions.
The calibration results are summarized in Figure 4, Figure 5 and Figure 6. As shown in Figure 4, Figure 5 and Figure 6, a magnetometer and gyroscope can be calibrated accurately. In other words, the two reference algorithms are effective. Then, without changing any parameters, the level rotation data is used to achieve calibration. With level rotation, the simulation results are as shown in Figure 7, Figure 8 and Figure 9.
The calibration results are summarized in Table 3. In Figure 7, Figure 8 and Figure 9, the red line is the reference value, and the blue, green, and brown lines represent the estimation results of the proposed method, NAIM, and MGICM. Figure 7 and Figure 9 show the estimation result of the magnetometer, from which it is evident that the results of the NAIM and MGICM converge to incorrect values; by contrast, the results of the proposed method gradually converge to the reference. The result of magnetometer calibration is the basis of gyroscope calibration. Figure 8 indicates the simulation results of gyroscope bias. In Figure 8, the estimation results of the proposed method quickly and accurately converge to the reference values. In comparison, the estimation of NAIM and MGICM cannot get close to the reference. In conclusion, when the system only rotates around the z-axis, the NAIM and MGICM cannot calibrate the system because of a lack of sufficient data in that direction. However, the proposed method can complete calibration successfully, which indicates that it boasts better adaptability and important application value in actual systems.

4. Experimental Test

To verify the practical application of the above algorithm, this section will take advantage of an actual MEMS-IMU integrated system to verify the effect of the algorithm.

4.1. Test Condition

This test was performed indoors and in a stable magnetic field environment. In the test, we chose ADIS16488 as the MEMS-IMU integrated system, as indicated in Figure 10. The features of ADIS16488 are shown in Table 4. ADIS16488 rotated around the z-axis with a certain angular velocity by hand and the gyroscope and magnetometer data were collected simultaneously.
Panels a and b of Figure 11 display the three-axis raw output of ADIS16488′s gyroscope and magnetometer. Figure 11c demonstrates the three-dimensional diagram of ADIS16488′s magnetometer output. Figure 11d shows the level attitude of the system. This level attitude was calculated by the accelerometer, and the calculation method is provided in Section 3.2.

4.2. Test Results

The results of the actual experiment are listed in Table 5. In Figure 12, Figure 13 and Figure 14, the red line expresses the reference. The blue, green, and brown lines show the results of the proposed method, NAIM, and MGICM, respectively. Due to the reference values of the magnetometer, parameters are difficult to know, so gyroscope calibration results could be used to verify magnetometer calibration results. From the velocity of convergence, the calibration of the magnetometer was completed first, and then the gyroscope was gradually calibrated. In other words, if the gyroscope is calibrated accurately, the magnetometer is also calibrated precisely. To check the gyroscope calibration results, the approximate bias of the gyroscope can be obtained by letting the system remain stable for a long time. Therefore, it will be applied to verify the calibration results as the reference values. In Figure 13, it is obvious that the result of the proposed method only gets close to the reference and the other results are wrong, which indicates that the proposed method is correct and valid. Moreover, the calibration of the magnetometer can be completed within 200 s, and the calibration of the gyroscope bias is finished in about 600 s. From the above results, the proposed method can be used accurately with level rotation, otherwise the general calibration model may obtain an incorrect result when using only level rotation.

5. Conclusions

Aiming at an actual problem (i.e., that most calibration methods require that the sensors be rotated in all possible orientations to guarantee a good result), it is, however, impossible for the navigation system on vehicles such as cars, ships, or planes. Therefore, a gyroscope and magnetometer integrated with an on-line calibration method is proposed with level rotation. This work mainly provides two contributions: (1) Relying on the level attitude, the magnetometer output model is redefined and the level two-dimensional gyroscope and magnetometer calibration model is deduced. (2) A simple CKF is designed to rapidly and accurately complete calibration. Then, the NAIM and MGICM are introduced to check the simulated effect of the proposed method. With level rotation, the NAIM and MGICM obtain the wrong calibration results, while the calibration result of the proposed method is close to the reference. In the actual test, an ADIS16488 MEMS-IMU integrated system is used to verify the practicability of the proposed method. The test data were obtained by rotating the system around the z-axis with a certain angular velocity by hand. Finally, the proposed method displays good effects, which illustrates that the method possesses strong practicability.

Acknowledgments

This work has been supported in part by the National Natural Science Foundation under Grant 61571148, in part by the Fundamental Research Runs for the Central University under Grant HEUCF041701.

Author Contributions

Zongkai Wu and Wei Wang conceived the idea; Zongkai Wu performed the experiments and wrote the paper.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Fang, J.; Liu, Z. In-flight alignment of POS based on state-transition matrix. IEEE Sens. J. 2015, 15, 3258–3264. [Google Scholar] [CrossRef]
  2. Jiancheng, F.; Sheng, Y. Study on innovation adaptive EKF for in-flight alignment of airborne POS. IEEE Trans. Instrum. Meas. 2011, 60, 1378–1388. [Google Scholar] [CrossRef]
  3. Zihajehzadeh, S.; Loh, D.; Lee, T.J.; Hoskinson, R.; Park, E.J. A cascaded Kalman filter-based GPS/MEMS-IMU integration for sports applications. Measurement 2015, 73, 200–210. [Google Scholar] [CrossRef]
  4. Fang, J.; Sun, H.; Cao, J.; Zhang, X.; Tao, Y. A novel calibration method of magnetic compass based on ellipsoid fitting. IEEE Trans. Instrum. Meas. 2011, 60, 2053–2061. [Google Scholar] [CrossRef]
  5. Olivares, A.; Ruiz-Garcia, G.; Olivares, G.; Górriz, J.M.; Ramirez, J. Automatic determination of validity of input data used in ellipsoid fitting MARG calibration algorithms. Sensors 2013, 13, 11797–11817. [Google Scholar] [CrossRef]
  6. Wahdan, A.; Georgy, J.; Noureldin, A. Three-dimensional magnetometer calibration with small space coverage for pedestrians. IEEE Sens. J. 2015, 15, 598–609. [Google Scholar] [CrossRef]
  7. Gebre-Egziabher, D.; Elkaim, G.H.; David Powell, J.; Bradford, W.P. Calibration of strapdown magnetometers in magnetic field domain. J. Aerosp. Eng. 2006, 19, 87–102. [Google Scholar] [CrossRef]
  8. Crassidis, J.L.; Lai, K.L.; Harman, R.R. Real-time attitude-independent three-axis magnetometer calibration. J. Guid. Control Dyn. 2005, 28, 115–120. [Google Scholar] [CrossRef]
  9. Lai, K.-L.; Crassidis, J.; Harman, R. Real-Time Attitude-Independent Gyro Calibration from Three-Axis Magnetometer Measurements. In Proceedings of the AIAA/AAS Astrodynamics Specialist Conference and Exhibit, Providence, RI, USA, 16–19 August 2004; pp. 1–11. [Google Scholar] [CrossRef]
  10. Huang, L.; Jing, W. Attitude-independent geomagnetic navigation using onboard complete three-axis magnetometer calibration. In Proceedings of the IEEE Aerospace Conference, Big Sky, MT, USA, 1–8 March 2008; pp. 1–7. [Google Scholar] [CrossRef]
  11. Springmann, J.C.; Cutler, J.W. Attitude-Independent Magnetometer Calibration with Time-Varying Bias. J. Guid. Control Dyn. 2012, 35, 1080–1088. [Google Scholar] [CrossRef]
  12. Grandvallet, B.; Zemouche, A.; Boutayeb, M.; Changey, S. Real-Time Attitude-Independent Three-Axis Magnetometer Calibration for Spinning Projectiles: A Sliding Window Approach. IEEE Trans. Control Syst. Technol. 2014, 22, 255–264. [Google Scholar] [CrossRef]
  13. Draganová, K.; Laššák, M.; Praslička, D.; Kán, V. Attitude-independent 3-axis accelerometer calibration based on adaptive neural network. Procedia Eng. 2014, 87, 1255–1258. [Google Scholar] [CrossRef]
  14. Abd Rabbou, M.; El-Rabbany, A. Integration of GPS precise point positioning and MEMS-based INS using unscented particle filter. Sensors 2015, 15, 7228–7245. [Google Scholar] [CrossRef]
  15. Drovandi, C.C.; McGree, J.M.; Pettitt, A.N. A sequential Monte Carlo algorithm to incorporate model uncertainty in Bayesian sequential design. J. Comput. Graph. Stat. 2014, 23, 3–24. [Google Scholar] [CrossRef] [Green Version]
  16. Urteaga, I.; Bugallo, M.F.; Djuric, P.M. Sequential Monte Carlo methods under model uncertainty. In Proceedings of the 2016 IEEE Statistical Signal Processing Workshop (SSP), Palma de Mallorca, Spain, 26–29 June 2016; pp. 1–5. [Google Scholar] [CrossRef]
  17. Martino, L.; Read, J.; Elvira, V.; Louzada, F. Cooperative parallel particle filters for online model selection and applications to urban mobility. Digit. Signal Process. 2017, 60, 172–185. [Google Scholar] [CrossRef]
  18. Wu, Z.; Wu, Y.; Hu, X.; Wu, M. Calibration of three-axis strapdown magnetometers using Particle Swarm Optimization algorithm. In Proceedings of the ROSE 2011—IEEE International Symposium on Robotic and Sensors Environments, Montreal, QC, Canada, 17–18 September 2011; pp. 160–165. [Google Scholar] [CrossRef]
  19. Wu, Z.; Wu, Y.; Hu, X.; Wu, M. Calibration of three-axis magnetometer using stretching particle swarm optimization algorithm. IEEE Trans. Instrum. Meas. 2013, 62, 281–292. [Google Scholar] [CrossRef]
  20. Riwanto, B.A.; Tikka, T.; Kestila, A.; Praks, J. Particle Swarm Optimization with Rotation Axis Fitting for Magnetometer Calibration. IEEE Trans. Aerosp. Electron. Syst. 2017, 53, 1009–1122. [Google Scholar] [CrossRef]
  21. Wu, Y.; Zou, D.; Liu, P.; Yu, W. Dynamic Magnetometer Calibration and Alignment to Inertial Sensors by Kalman Filtering. IEEE Trans. Control Syst. Technol. 2017, 26, 716–723. [Google Scholar] [CrossRef]
  22. Wu, Y.; Pei, L. Gyroscope Calibration via Magnetometer. IEEE Sens. J. 2017, 17, 5269–5275. [Google Scholar] [CrossRef]
  23. Prikhodko, I.P.; Gregory, J.A.; Judy, M.W. Virtually rotated MEMS gyroscope with angle output. In Proceedings of the IEEE International Conference on Micro Electro Mechanical Systems (MEMS), Las Vegas, NV, USA, 22–26 January 2017; pp. 323–326. [Google Scholar] [CrossRef]
  24. Prikhodko, I.P.; Gregory, J.A.; Bugrov, D.I.; Judy, M.W. Overcoming limitations of Rate Integrating Gyroscopes by virtual rotation. In Proceedings of the IEEE 3rd International Symposium on Inertial Sensors and Systems (ISS 2016), Laguna Beach, CA, USA, 22–25 February 2016; pp. 5–8. [Google Scholar] [CrossRef]
  25. Norouzpour-shirazi, A.; Ayazi, F. A Dual-Mode Actuation and Sensing Scheme for In-Run Calibration of Bias and Scale Factor Errors in Axisymmetric Resonant Gyroscopes. IEEE Sens. J. 2018, 18, 1993–2005. [Google Scholar]
  26. Ousaloo, H.S.; Sharifi, G.; Mahdian, J.; Nodeh, M.T. Complete Calibration of Three-Axis Strapdown Magnetometer in Mounting Frame. IEEE Sens. J. 2017, 17, 7886–7893. [Google Scholar] [CrossRef]
  27. Finlay, C.C.; Maus, S.; Beggan, C.D.; Bondar, T.N.; Chambodut, A.; Chernova, T.A.; Zvereva, T.I. International Geomagnetic Reference Field: The eleventh generation. Geophys. J. Int. 2010, 183, 1216–1230. [Google Scholar] [CrossRef] [Green Version]
  28. Haykin, S.; Arasaratnam, I. Cubature Kalman Filters. IEEE Trans. Autom. Control 2009, 54, 1254–1269. [Google Scholar] [CrossRef]
  29. Zhao, Y. Performance Evaluation of Cubature Kalman filter in a GPS/IMU tightly-coupled navigation system. Signal Process. 2016, 119, 67–79. [Google Scholar] [CrossRef]
Figure 1. Sketch of the coordinate systems.
Figure 1. Sketch of the coordinate systems.
Sensors 18 00748 g001
Figure 2. (a) Three-axis gyroscope output; (b) Three-axis magnetometer output; (c) 3D-diagram magnetometer output; (d) Level attitude of system.
Figure 2. (a) Three-axis gyroscope output; (b) Three-axis magnetometer output; (c) 3D-diagram magnetometer output; (d) Level attitude of system.
Sensors 18 00748 g002aSensors 18 00748 g002b
Figure 3. 3D diagram of data in all possible directions.
Figure 3. 3D diagram of data in all possible directions.
Sensors 18 00748 g003
Figure 4. Estimation result of magnetometer bias. MGICM: magnetometer and gyroscope integrated calibration method; NAIM: normal attitude-independent method.
Figure 4. Estimation result of magnetometer bias. MGICM: magnetometer and gyroscope integrated calibration method; NAIM: normal attitude-independent method.
Sensors 18 00748 g004
Figure 5. Estimation result of gyroscope bias.
Figure 5. Estimation result of gyroscope bias.
Sensors 18 00748 g005
Figure 6. Estimation result of magnetometer scale factors.
Figure 6. Estimation result of magnetometer scale factors.
Sensors 18 00748 g006
Figure 7. Estimation result of magnetometer bias.
Figure 7. Estimation result of magnetometer bias.
Sensors 18 00748 g007
Figure 8. Estimation result of gyroscope bias.
Figure 8. Estimation result of gyroscope bias.
Sensors 18 00748 g008
Figure 9. Estimation result of magnetometer scale factors.
Figure 9. Estimation result of magnetometer scale factors.
Sensors 18 00748 g009
Figure 10. ADIS16488 micro-electro-mechanical-system inertial measurement unit (MEMS-IMU) system.
Figure 10. ADIS16488 micro-electro-mechanical-system inertial measurement unit (MEMS-IMU) system.
Sensors 18 00748 g010
Figure 11. (a) Output of the ADIS16488 gyroscope; (b) Output of the ADIS16488 magnetometer; (c) Three-dimensional diagram of ADIS16488′s magnetometer output; (d) Level attitude of the system.
Figure 11. (a) Output of the ADIS16488 gyroscope; (b) Output of the ADIS16488 magnetometer; (c) Three-dimensional diagram of ADIS16488′s magnetometer output; (d) Level attitude of the system.
Sensors 18 00748 g011aSensors 18 00748 g011b
Figure 12. Estimation results of ADIS16488′s magnetometer bias.
Figure 12. Estimation results of ADIS16488′s magnetometer bias.
Sensors 18 00748 g012
Figure 13. Estimation result of ADIS16488′s gyroscope bias.
Figure 13. Estimation result of ADIS16488′s gyroscope bias.
Sensors 18 00748 g013
Figure 14. Estimation results of ADIS16488′s magnetometer scale factors.
Figure 14. Estimation results of ADIS16488′s magnetometer scale factors.
Sensors 18 00748 g014
Table 1. Comparison of magnetometer calibration methods.
Table 1. Comparison of magnetometer calibration methods.
MethodInputsAdvantagesDisadvantages
Ellipsoid fitting [4,5]Magnetic fieldSimple, Short run time, Less calculationLow precision, Bad adaptability, Off-line, Rotation in all possible orientations
Attitude-dependent [6,7]Magnetic field, HeadingData in small space coverage, Model precision, Short run timeCalibration precision, Relies on heading
Attitude-independent [8,9,10,11,12,13]Magnetic fieldModel precision, On-line, Good adaptabilityHard to set initial filter parameter, Rotation in all possible orientations
Particle swarm optimization algorithm [18,19,20]Magnetic fieldNeed not set initial parameters, Model precisionHigh calculation cost, Rotation in all possible orientations, Off-line
Gyroscope integrated calibration [21,22]Magnetic field, Angular ratesModel precision, On-lineRotation in all possible orientations
Virtual rotation scheme [23,24,25]Angular ratesModel precision, Does not require initial situationHigh calculation cost, Has not been used to calibrate magnetometer
Proposed methodMagnetic field, Angular rates, Level attitudeOn-line, Only needs level rotationRelatively obscure model, Relies on level attitude
Table 2. Simulation setting.
Table 2. Simulation setting.
ItemsValues
Device rotation angular rate on z-axisLess than 20 (degree/s) in sine wave with 300 s periods
Device rotation angular rate on x and y-axisLess than 3 (degree/s) in sine wave with 3 s periods
Update frequency200 (Hz)
b m b [−30,60,90]T (mGauss)
C l (Proposed method)
C b (Attitude-independent method)
[ 0.1 0.01 0.03 0.01 0.2 0.05 0.03 0.05 0.3 ]
b g b [0.2,0.3,0.4]T (degree/s)
ε g 0.2 (degree/s)(rms)
ε m 0.45 (mGauss) (rms)
Table 3. Simulation results.
Table 3. Simulation results.
Method b b C b ( C l ) b g b
Reference [ 30 60 90 ] (mGauss) [ 0.1 0.01 0.03 0.01 0.2 0.05 0.03 0.05 0.3 ] [ 0.2 0.4 0.6 ] (degree/s)
NAIM [ 25.79 15.95 268.4 ] (mGauss) [ 0.112 0.007 0.018 0.007 0.034 0.004 0.018 0.004 0.198 ] [ 0.1865 0.3427 0.338 ] (degree/s)
MGICM [ 24.39 69.68 21.54 ] (mGauss) [ 0.0737 0.0094 0.0315 0.0094 0.0102 0.0432 0.0315 0.0432 0.004 ] [ 0.1732 0.5313 0.8376 ] (degree/s)
Proposed method [ 29.24 58.74 96.79 ] (mGauss) [ 0.08 0.009 0.029 0.009 0.178 0.049 0.029 0.049 0.285 ] [ 0.19 0.406 0.6303 ] (degree/s)
Table 4. ADIS16488’s features.
Table 4. ADIS16488’s features.
ItemsADIS16488
Sampling rates205 (Hz)
Gyroscope bias repeatability±0.2 (degree/s)
Gyroscope in-run bias stability6.25 (degree/h)
Gyroscope angular random walk0.3 (degree/√h)
Gyroscope output noise0.16 (degree/s)(rms)
Accelerometer bias repeatability±16 (mg)
Accelerometer in-run bias stability0.1 mg
Accelerometer velocity random walk0.029 m/s/√h
Accelerometer output noise1.5 (mg)(rms)
Magnetometer output noise0.45 (mGauss)(rms)
Table 5. Calibration results.
Table 5. Calibration results.
Method b b C b ( C l ) b g b
Reference--(degree/s)
NAIM [ 161.8 111 18.53 ] (mGauss) [ 0.112 0.109 0.58 0.109 0.034 0.188 0.058 0.188 0.198 ] [ 1.431 1.396 0.345 ] (degree/s)
MGICM [ 51.42 178.9 98.64 ] (mGauss) [ 0.293 0.127 0.064 0.127 0.543 0.223 0.064 0.223 0.485 ] [ 0.5216 0.39 0.456 ] (degree/s)
Proposed method [ 74.27 87 140.2 ] (mGauss) [ 0.3136 0.2374 0.1702 0.2374 0.4998 0.4287 0.1702 0.4287 0.3118 ] [ 0.074 0.27 0.0957 ] (degree/s)

Share and Cite

MDPI and ACS Style

Wu, Z.; Wang, W. Magnetometer and Gyroscope Calibration Method with Level Rotation. Sensors 2018, 18, 748. https://doi.org/10.3390/s18030748

AMA Style

Wu Z, Wang W. Magnetometer and Gyroscope Calibration Method with Level Rotation. Sensors. 2018; 18(3):748. https://doi.org/10.3390/s18030748

Chicago/Turabian Style

Wu, Zongkai, and Wei Wang. 2018. "Magnetometer and Gyroscope Calibration Method with Level Rotation" Sensors 18, no. 3: 748. https://doi.org/10.3390/s18030748

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop