A method and system for drift mitigation of a six-axis sensor
By using Allan variance analysis and temperature correlation to determine the cause of six-axis sensor drift, a zero-bias compensation model was established, which solved the problem of insufficient measurement accuracy of the sensor under temperature change environment, improved stability and fault diagnosis efficiency, and reduced maintenance costs.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- HARBIN INST OF TECH (SHENYANG) INTELLIGENT IND TECH CO LTD
- Filing Date
- 2026-04-28
- Publication Date
- 2026-07-07
AI Technical Summary
In practical work, six-axis sensors are easily affected by factors such as temperature changes and noise interference, resulting in drift. Existing technologies cannot effectively distinguish the causes of drift, leading to insufficient measurement accuracy and high equipment maintenance costs, which limits their application in high-precision scenarios.
Allan variance analysis was used to assess the risk of sensor drift. The causes of drift were determined by trend consistency analysis and temperature data correlation. A zero-bias compensation model was established for real-time correction. The Allan variance curve was plotted using the Python allantools library, and the temperature compensation model was fitted by the least squares method.
This improves the measurement accuracy and stability of the sensor under varying temperature conditions, shortens fault diagnosis time, and reduces equipment maintenance costs.
Smart Images

Figure CN122108079B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of sensor signal processing technology, specifically a drift suppression method and system for a six-axis sensor. Background Technology
[0002] A six-axis sensor is a combined motion sensor that integrates a three-axis gyroscope and a three-axis accelerometer. It can simultaneously acquire angular and linear motion data of an object in three-dimensional space. Due to its small size, fast response, and low cost, it has been widely used in drones, industrial robots, wearable devices and other fields. Its measurement accuracy directly determines the control performance and operational stability of the terminal equipment.
[0003] However, six-axis sensors are susceptible to drift due to factors such as temperature changes and noise interference in practical operation, severely limiting the improvement of their measurement accuracy. Existing drift suppression methods for six-axis sensors have several shortcomings: it is difficult to effectively distinguish whether the drift is caused by common environmental factors such as temperature and vibration, or by device-specific factors such as MEMS structure aging and circuit failure, resulting in a broad and inefficient troubleshooting scope; for drift caused by common factors such as temperature, existing compensation schemes are mostly static compensation modes, which are difficult to dynamically adapt to real-time temperature changes and cannot achieve accurate real-time correction. This leads to insufficient measurement accuracy and stability of the sensor in temperature fluctuation environments, frequent sensor replacements due to excessive drift, significantly increasing equipment maintenance costs and limiting the application of six-axis sensors in high-precision scenarios.
[0004] Therefore, the present invention provides a drift suppression method and system for a six-axis sensor. Summary of the Invention
[0005] In order to overcome the shortcomings of the prior art, at least one technical problem raised in the background art is solved.
[0006] In a first aspect, the present invention provides a drift suppression method for a six-axis sensor, comprising the following steps:
[0007] Acquire actual operating data of the six-axis sensor, use Allan variance analysis to perform cumulative analysis on the drift of any axis during the acquisition period, and assess the drift risk of the six-axis sensor.
[0008] If the six-axis sensor has a high drift risk, extract the instantaneous zero bias of the accelerometer and the instantaneous zero bias of the gyroscope, and analyze whether the zero bias drift trends of the accelerometer and the gyroscope are consistent within the acquisition period.
[0009] If they match, extract the temperature data within the acquisition period and perform timestamp matching to determine whether the accelerometer drift and gyroscope drift are caused by temperature.
[0010] If so, establish a zero-bias compensation model for each axis, input real-time temperature data into the zero-bias compensation model for each axis, output the zero-bias compensation value for each axis corresponding to the real-time temperature, and correct the six-axis sensor drift caused by temperature changes in real time based on the zero-bias compensation value for each axis.
[0011] As a further aspect of the present invention: the process for assessing the drift risk of the six-axis sensor is as follows:
[0012] The actual operating data of the six-axis sensor includes the three-axis angular rate of the gyroscope and the three-axis acceleration of the accelerometer; the sampling frequency and acquisition period are set.
[0013] The actual operating data of the acquired six-axis sensor is preprocessed and then subtracted from the preset initial zero bias data to obtain the original zero bias data.
[0014] The raw zero-bias data is analyzed and processed to determine the instantaneous zero-bias of the axis;
[0015] Based on the instantaneous zero bias of the axis, the drift of any axis during the acquisition period is cumulatively analyzed to obtain the cumulative drift of the axis during the acquisition period.
[0016] If the cumulative drift of an axis within the acquisition period is greater than or equal to the standard value of cumulative drift, then the corresponding axis is recorded as the drift axis.
[0017] Calculate the percentage of drift axes among all axes. If the percentage of drift axes is greater than the threshold, it indicates that the six-axis sensor has a high drift risk; otherwise, it indicates that the six-axis sensor has a low drift risk.
[0018] As a further aspect of the present invention: the instantaneous zero offset determination process of the shaft is as follows:
[0019] The original zero-bias data after detrending any axis is integrated into a single-axis zero-bias dataset. The collection period is divided into multiple collection periods according to equal time intervals. The single-axis zero-bias dataset is divided into several data groups to be analyzed according to the time intervals of the collection periods.
[0020] For any given data collection period, sum and average all raw zero-biased data in the dataset to be analyzed to obtain the zero-biased mean of the dataset. These zero-biased means are then integrated into a zero-biased mean sequence in chronological order. The Allan variance of the zero-biased mean sequence is calculated using Allan variance, and the standard deviation of the sequence is obtained by taking its square root. Plot the Allen variance curve to... The horizontal axis is... The vertical axis is used as the reference axis.
[0021] Using the Python allantools library, call allantools.adev After the function calculation, plot the graph using the allantools.plot() function, and automatically add labels. The minimum value is the instantaneous zero bias of the axis.
[0022] As a further aspect of the present invention: the process of cumulatively analyzing the drift of any axis within the acquisition period is as follows:
[0023] Extract the maximum and minimum instantaneous zero offset values of the axis for all acquisition periods within the acquisition period, and denot them as the maximum instantaneous zero offset and the minimum instantaneous zero offset, respectively. Subtract the maximum instantaneous zero offset from the minimum instantaneous zero offset to obtain the cumulative drift of the axis within the acquisition period.
[0024] As a further aspect of the present invention: the process of analyzing whether the accelerometer zero-bias drift trend and the gyroscope zero-bias drift trend are consistent within the data acquisition period is as follows:
[0025] Align the instantaneous zero biases of the accelerometer and gyroscope according to their timestamps. Then, integrate the instantaneous zero biases of the accelerometer into an accelerometer zero bias sequence and the instantaneous zero biases of the gyroscope into a gyroscope zero bias sequence, all in chronological order.
[0026] The zero-biased acceleration sequence and the zero-biased gyroscope sequence are smoothed by moving average. The smoothed zero-biased acceleration sequence and the zero-biased gyroscope sequence are then linearly regressed using the least squares method to output the trend equation.
[0027] Based on the trend equation, determine the trend characterization value; if the trend characterization value is greater than or equal to the trend characterization threshold, it indicates that the accelerometer zero-bias drift trend and the gyroscope zero-bias drift trend are consistent within the acquisition period; otherwise, it indicates that the accelerometer zero-bias drift trend and the gyroscope zero-bias drift trend are inconsistent within the acquisition period.
[0028] As a further aspect of the present invention: the process for determining the trend characterization value is as follows:
[0029] The accelerometer x-axis and the gyroscope x-axis are considered as a pair of axes, the accelerometer y-axis and the gyroscope y-axis are considered as a pair of axes, and the accelerometer z-axis and the gyroscope z-axis are considered as a pair of axes. If the trend slopes of the paired axes of the accelerometer and the gyroscope have the same sign, then the paired axes are denoted as paired axes with the same direction.
[0030] Calculate the percentage of pairs of axes that are aligned in the same direction among all paired axes;
[0031] Extract the trend slopes of all axes of the accelerometer and integrate them into an accelerometer slope set; extract the trend slopes of all axes of the gyroscope and integrate them into a gyroscope slope set; calculate the correlation coefficient between the accelerometer slope set and the gyroscope slope set using the absolute value of the Pearson correlation coefficient, then subtract it from 1 and take the absolute value, which is recorded as the rate correlation value;
[0032] The trend characterization value is obtained by comparing the proportion of pairs of axes with the same direction among all paired axes with the rate correlation value.
[0033] As a further aspect of the present invention: the process of determining whether the accelerometer drift and gyroscope drift are caused by temperature is as follows:
[0034] The data in the acceleration zero-bias sequence and the gyroscope zero-bias sequence are recorded as zero-bias trend data. The temperature data is perfectly matched with the timestamp of the zero-bias trend data by linear interpolation.
[0035] Based on the zero bias trend data and temperature data of any axis, the absolute value of the Pearson correlation coefficient formula is used to calculate the correlation coefficient between the zero bias trend and temperature of the corresponding axis, which is denoted as the temperature correlation value.
[0036] Based on the temperature correlation values, determine the temperature correlation axis and calculate the percentage of temperature correlation axes among all axes;
[0037] If the proportion of temperature-dependent axes among all axes is greater than or equal to the threshold for the proportion of temperature-dependent axes, it indicates that the accelerometer drift and gyroscope drift are caused only by temperature; otherwise, it indicates that the accelerometer drift and gyroscope drift are caused not only by temperature.
[0038] As a further aspect of the present invention: the process for determining the temperature-dependent axis is as follows:
[0039] If the temperature correlation value is greater than or equal to the temperature correlation standard value, then the corresponding axis is recorded as the temperature correlation axis.
[0040] As a further aspect of the present invention: the process for determining the zero-offset compensation value of each axis is as follows:
[0041] Based on the zero-bias trend data and temperature data within the acquisition period, the temperature value at each time point is associated with the zero-bias trend value of the corresponding axis to form 6 sets of training sample pairs. A temperature zero-bias compensation model is constructed using polynomial fitting. The least squares method is used to fit the sample pairs to minimize the sum of squared errors between the model prediction value and the actual zero-bias trend value. The model coefficients of each axis are calculated. Based on the model coefficients of each axis, the zero-bias compensation models of each axis of the accelerometer and the gyroscope are determined.
[0042] Temperature data is collected in real time by a temperature sensor, and the real-time temperature data is input into the zero-bias compensation model of each axis, and the zero-bias compensation value of each axis is output.
[0043] Secondly, the present invention also provides a drift suppression system for a six-axis sensor, the system comprising:
[0044] Drift Risk Assessment Module: Acquires actual operating data of the six-axis sensor, uses Allan variance analysis on the actual operating data of the six-axis sensor, performs cumulative analysis on the drift of any axis within the acquisition period, and assesses the drift risk of the six-axis sensor;
[0045] Trend Consistency Analysis Module: If the drift risk of the six-axis sensor is high, extract the instantaneous zero bias of the accelerometer and the instantaneous zero bias of the gyroscope, and analyze whether the zero bias drift trends of the accelerometer and the gyroscope are consistent within the acquisition period.
[0046] Temperature-induced cause determination module: If consistent, extract temperature data within the acquisition period and perform timestamp matching to determine whether the accelerometer drift and gyroscope drift are caused by temperature.
[0047] Compensation and Correction Module: If so, establish a zero-bias compensation model for each axis, input real-time temperature data into the zero-bias compensation model for each axis, output the zero-bias compensation value for each axis corresponding to the real-time temperature, and correct the six-axis sensor drift caused by temperature changes in real time based on the zero-bias compensation value for each axis.
[0048] The beneficial effects of this invention are as follows:
[0049] 1. This invention employs Allan variance analysis to identify zero-bias characteristics, reflecting the inherent drift characteristics of sensors and improving the scientific rigor of zero-bias assessment. By assessing sensor drift risk, it scientifically determines the consistency of drift trends between accelerometers and gyroscopes, effectively distinguishing between common factors and device-independent factors. First, it uses trend consistency analysis to determine whether the drift is a common or independent factor, narrowing down the scope of investigation. Then, for common factors, it uses temperature data correlation analysis to pinpoint whether the drift is caused by temperature, accurately identifying the core influencing factors and improving the efficiency of fault diagnosis.
[0050] 2. For temperature-induced drift, this invention establishes a zero-bias compensation model based on polynomial fitting and least squares method. It can output compensation values using real-time temperature data to achieve dynamic correction of temperature drift, improve the measurement accuracy and stability of the sensor in temperature-changing environments, extend the effective service life of the sensor, reduce the need for replacement due to excessive drift, and reduce equipment maintenance costs. Attached Figure Description
[0051] The invention will now be further described with reference to the accompanying drawings.
[0052] Figure 1 This is a flowchart illustrating the steps of a drift suppression method for a six-axis sensor according to an embodiment of the present invention;
[0053] Figure 2 This is a system block diagram of a drift suppression system for a six-axis sensor according to an embodiment of the present invention. Detailed Implementation
[0054] To make the technical means, creative features, objectives and effects of this invention easier to understand, the invention will be further described below in conjunction with specific embodiments.
[0055] Example 1
[0056] Please see Figure 1 As shown in the embodiment of the present invention, a drift suppression method for a six-axis sensor includes the following steps:
[0057] Step 1: Obtain the actual operating data of the six-axis sensor, and use Allan variance analysis to perform cumulative analysis on the drift of any axis during the acquisition period to assess the drift risk of the six-axis sensor.
[0058] The actual operating data of the six-axis sensor includes the three-axis angular rate of the gyroscope and the three-axis acceleration of the accelerometer.
[0059] It should be noted that the gyroscope's three-axis angular rate includes the gyroscope's x-axis angular rate, gyroscope's y-axis angular rate, and gyroscope's z-axis angular rate; the accelerometer's three-axis acceleration includes the accelerometer's x-axis acceleration, accelerometer's y-axis acceleration, and accelerometer's z-axis acceleration.
[0060] Collect three-axis angular rate data from the gyroscope and three-axis acceleration data from the accelerometer, and set the sampling frequency and acquisition period;
[0061] The actual operating data of the acquired six-axis sensor is preprocessed. The actual operating data of the acquired six-axis sensor is subtracted from the preset initial zero bias data to obtain the original zero bias data. The data preprocessing includes: subtracting the initial zero bias, removing outliers, and detrending.
[0062] The original zero-bias data after detrending any axis is integrated into a single-axis zero-bias dataset. The collection period is divided into multiple collection periods according to equal time intervals. The single-axis zero-bias dataset is divided into several data groups to be analyzed according to the time intervals of the collection periods.
[0063] For any given data collection period, the summation and mean of all raw zero-biased data in the dataset to be analyzed are performed to obtain the zero-biased mean of the dataset. These zero-biased means are then integrated into a zero-biased mean sequence in chronological order. The Allan variance of the zero-biased mean sequence is calculated using Allan variance, and the arithmetic square root of the Allan variance is taken to obtain the standard deviation of the zero-biased mean sequence. Plot the Allen variance curve to... The horizontal axis is... The vertical axis is used as the reference axis.
[0064] Using the Python allantools library, call allantools.adev After the function calculation, plot the graph using the allantools.plot() function, and automatically add labels. The minimum value of is the instantaneous zero bias of the axis;
[0065] The drift of any axis during the acquisition period is cumulatively analyzed, specifically:
[0066] Extract the maximum and minimum instantaneous zero offset of the axis for all acquisition periods within the acquisition period, and record them as the maximum instantaneous zero offset and the minimum instantaneous zero offset, respectively. Subtract the maximum instantaneous zero offset from the minimum instantaneous zero offset to obtain the cumulative drift of the axis within the acquisition period.
[0067] The cumulative drift standard value of the axis is set by a person skilled in the art based on the characteristics of the six-axis sensor and historical experience. If the cumulative drift of the axis within the acquisition period is greater than or equal to the cumulative drift standard value, the corresponding axis is recorded as a drift axis; if the cumulative drift of the axis within the acquisition period is less than the cumulative drift standard value, the corresponding axis is recorded as a normal axis.
[0068] Calculate the percentage of drift axes among all axes. If the percentage of drift axes is greater than the threshold, it indicates that the six-axis sensor has a high drift risk; if the percentage of drift axes is less than or equal to the threshold, it indicates that the six-axis sensor has a low drift risk.
[0069] Step 2: If the drift risk of the six-axis sensor is high, extract the instantaneous zero bias of the accelerometer and the instantaneous zero bias of the gyroscope, and analyze whether the zero bias drift trends of the accelerometer and the gyroscope are consistent within the acquisition period.
[0070] Align the instantaneous zero biases of the accelerometer and gyroscope according to their timestamps. Then, integrate the instantaneous zero biases of the accelerometer into an accelerometer zero bias sequence and the instantaneous zero biases of the gyroscope into a gyroscope zero bias sequence, all in chronological order.
[0071] The acceleration zero-bias sequence and the gyroscope zero-bias sequence are smoothed by moving average to remove high-frequency fluctuations (random noise) in the instantaneous zero bias and retain the slowly changing drift trend.
[0072] The acceleration zero-bias sequence and the gyroscope zero-bias sequence, after being smoothed by moving average using the least squares method, are subjected to linear regression to output a trend equation. Specifically:
[0073] Trend equation of the accelerometer i-axis The trend slope of the accelerometer's i-axis, Let t be the intercept of the accelerometer axis i, and t represent time.
[0074] Trend equation of the i-axis of the gyroscope Let be the trend slope of the gyroscope's i-axis. Let be the intercept of the gyroscope axis i;
[0075] Using the accelerometer x-axis and gyroscope x-axis as a pair of axes, the accelerometer y-axis and gyroscope y-axis as a pair of axes, and the accelerometer z-axis and gyroscope z-axis as a pair of axes, compare the signs of the trend slopes of the accelerometer and gyroscope pair of axes:
[0076] If the trend slopes of the paired axes of the accelerometer and gyroscope have the same sign, then the paired axes are denoted as paired axes with the same direction.
[0077] If the signs of the trend slopes of the paired axes of the accelerometer and gyroscope are different, the paired axes are recorded as pairs of axes with inconsistent directions.
[0078] It should be noted that the cases where the trend slope signs of the paired axes of the accelerometer and gyroscope are the same include: the trend slope signs of the paired axes of the accelerometer and gyroscope are both positive, and the trend slope signs of the paired axes of the accelerometer and gyroscope are both negative.
[0079] Cases where the signs of the trend slopes of the paired axes of the accelerometer and gyroscope are different include: the signs of the trend slopes of the paired axes of the accelerometer and gyroscope are one positive and one negative;
[0080] Count the number of pairs of axes with the same direction, and calculate the percentage of pairs of axes with the same direction among all pairs of axes;
[0081] Extract the trend slopes of all axes of the accelerometer and integrate them into an accelerometer slope set; extract the trend slopes of all axes of the gyroscope and integrate them into a gyroscope slope set.
[0082] The absolute value of the Pearson correlation coefficient is used to calculate the correlation coefficient between the accelerometer slope set and the gyroscope slope set. The absolute value of the difference between the Pearson correlation coefficient and 1 is then taken as the rate correlation value.
[0083] The trend characterization value is obtained by comparing the proportion of pairs of axes with the same direction among all paired axes with the rate correlation value.
[0084] It should be noted that the proportion of pairs of axes with the same direction among all paired axes reflects whether the overall directional trend is consistent. The rate correlation value characterizes the overall trend comparison between the accelerometer and the gyroscope. Calculating the Pearson correlation coefficient between the accelerometer slope set and the gyroscope slope set essentially quantifies the degree of linear correlation between the drift rates of the accelerometer and the gyroscope through the slope data of paired axes. The closer the absolute value of the correlation coefficient is to 1, the stronger the trend consistency, providing key quantitative basis for judging the root cause of drift, common or independent factors.
[0085] If the trend characterization value is greater than or equal to the trend characterization threshold, it indicates that the accelerometer zero-bias drift trend and the gyroscope zero-bias drift trend are consistent within the acquisition period.
[0086] If the trend characterization value is less than the trend characterization threshold, it indicates that the zero-bias drift trend of the accelerometer and the zero-bias drift trend of the gyroscope are inconsistent within the acquisition period, which means that the drift is caused by independent factors of each device, such as MEMS structure aging or circuit failure.
[0087] Step 3: If they match, extract the temperature data within the acquisition period and perform timestamp matching to determine whether the accelerometer drift and gyroscope drift are caused by temperature.
[0088] The data in the acceleration zero-bias sequence and the gyroscope zero-bias sequence are recorded as zero-bias trend data. The temperature data is completely matched with the timestamp of the zero-bias trend data by linear interpolation to ensure that each zero-bias data point corresponds to a unique temperature value.
[0089] Based on the zero bias trend data and temperature data of any axis, the absolute value of the Pearson correlation coefficient formula is used to calculate the correlation coefficient between the zero bias trend and temperature of the corresponding axis, which is denoted as the temperature correlation value.
[0090] Temperature-related standard values are set by those skilled in the art based on historical experience. If the temperature-related value is greater than or equal to the temperature-related standard value, it indicates that temperature causes the corresponding axis to drift, and the corresponding axis is recorded as the temperature-related axis.
[0091] If the temperature correlation value is less than the temperature correlation standard value, it means that the drift of the corresponding axis is not caused by temperature. The corresponding axis is recorded as a non-temperature-correlated axis, and further analysis of other influencing factors is needed, such as vibration interference, power supply stability, and electromagnetic interference.
[0092] Count the number of temperature-related axes among all axes, and calculate the percentage of temperature-related axes among all axes;
[0093] If the proportion of temperature-related axes among all axes is greater than or equal to the threshold for the proportion of temperature-related axes, it indicates that the accelerometer drift and gyroscope drift are caused only by temperature.
[0094] If the proportion of temperature-related axes among all axes is less than the threshold for the proportion of temperature-related axes, it indicates that the accelerometer drift and gyroscope drift are not only caused by temperature.
[0095] Step 4: If so, establish a zero-bias compensation model for each axis, input the real-time temperature data into the zero-bias compensation model for each axis, output the zero-bias compensation value for each axis corresponding to the real-time temperature, and correct the six-axis sensor drift caused by temperature changes in real time based on the zero-bias compensation value for each axis.
[0096] Based on the zero-bias trend data and temperature data within the acquisition period, the temperature value at each time point is associated with the zero-bias trend value of the corresponding axis, forming 6 training sample pairs (3-axis accelerometer + 3-axis gyroscope). A temperature zero-bias compensation model is constructed using polynomial fitting. The least squares method is used to fit the sample pairs to minimize the sum of squared errors between the model prediction value and the actual zero-bias trend value. The model coefficients for each axis are calculated. Based on the model coefficients for each axis, the zero-bias compensation models for each axis of the accelerometer and the gyroscope are determined.
[0097] Temperature data is collected in real time by a temperature sensor. The real-time temperature data is input into the zero-bias compensation model of each axis, and the zero-bias compensation value of each axis is output. Based on the zero-bias compensation value of each axis, the drift of the six-axis sensor caused by temperature changes is corrected in real time.
[0098] The technical solution of this invention is as follows: Acquire actual operating data of a six-axis sensor; utilize Allan variance analysis of the actual operating data of the six-axis sensor to perform cumulative analysis of the drift of any axis within the acquisition period, and assess the drift risk of the six-axis sensor; if the drift risk of the six-axis sensor is high, extract the instantaneous zero bias of the accelerometer and the instantaneous zero bias of the gyroscope, and analyze whether the zero bias drift trends of the accelerometer and the gyroscope are consistent within the acquisition period; if consistent, extract temperature data within the acquisition period and perform timestamp matching to determine whether the accelerometer drift and gyroscope drift are caused by temperature; if so, establish a zero bias compensation model for each axis, input real-time temperature data into the zero bias compensation model for each axis, output the zero bias compensation value for each axis corresponding to the real-time temperature, and correct the six-axis sensor drift caused by temperature changes in real time based on the zero bias compensation value for each axis; this invention uses Allan variance analysis of zero bias... The bias characteristic reflects the inherent drift characteristics of the sensor, improving the scientific rigor of zero-bias assessment. By assessing sensor drift risk, the consistency of drift trends between accelerometers and gyroscopes is scientifically determined, effectively distinguishing between common factors and device-independent factors. First, trend consistency analysis determines whether the drift is a common or independent factor, narrowing down the scope of investigation. Then, for common factors, temperature data correlation analysis is used to pinpoint whether the drift is temperature-induced, accurately identifying the core influencing factors and improving the efficiency of fault diagnosis. For temperature-induced drift, a zero-bias compensation model is established based on polynomial fitting and least squares method, which can output compensation values using real-time temperature data to achieve dynamic correction of temperature drift. This improves the measurement accuracy and stability of the sensor in temperature-changing environments, extends the effective service life of the sensor, reduces the need for replacement due to excessive drift, and lowers equipment maintenance costs.
[0099] Example 2
[0100] Based on the same inventive concept as the drift suppression method for a six-axis sensor in the foregoing embodiments, such as Figure 2 As shown, this application provides a drift suppression system for a six-axis sensor, wherein the system specifically includes:
[0101] Drift Risk Assessment Module: Acquires actual operating data of the six-axis sensor, uses Allan variance analysis on the actual operating data of the six-axis sensor, performs cumulative analysis on the drift of any axis within the acquisition period, and assesses the drift risk of the six-axis sensor;
[0102] Trend Consistency Analysis Module: If the drift risk of the six-axis sensor is high, extract the instantaneous zero bias of the accelerometer and the instantaneous zero bias of the gyroscope, and analyze whether the zero bias drift trends of the accelerometer and the gyroscope are consistent within the acquisition period.
[0103] Temperature-induced cause determination module: If consistent, extract temperature data within the acquisition period and perform timestamp matching to determine whether the accelerometer drift and gyroscope drift are caused by temperature.
[0104] Compensation and Correction Module: If so, establish a zero-bias compensation model for each axis, input real-time temperature data into the zero-bias compensation model for each axis, output the zero-bias compensation value for each axis corresponding to the real-time temperature, and correct the six-axis sensor drift caused by temperature changes in real time based on the zero-bias compensation value for each axis.
[0105] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely illustrative of the principles of the invention. Various changes and modifications can be made to the invention without departing from its spirit and scope, and all such changes and modifications fall within the scope of the present invention as claimed. The scope of protection of the present invention is defined by the appended claims and their equivalents.
Claims
1. A drift suppression method for a six-axis sensor, characterized in that: Includes the following steps: Acquire actual operating data of the six-axis sensor, use Allan variance analysis to perform cumulative analysis on the drift of any axis during the acquisition period, and assess the drift risk of the six-axis sensor. If the six-axis sensor has a high drift risk, extract the instantaneous zero bias of the accelerometer and the instantaneous zero bias of the gyroscope, and analyze whether the zero bias drift trends of the accelerometer and the gyroscope are consistent within the acquisition period. If they match, extract the temperature data within the acquisition period and perform timestamp matching to determine whether the accelerometer drift and gyroscope drift are caused by temperature. If so, establish a zero-bias compensation model for each axis, input real-time temperature data into the zero-bias compensation model for each axis, output the zero-bias compensation value for each axis corresponding to the real-time temperature, and correct the six-axis sensor drift caused by temperature changes in real time based on the zero-bias compensation value for each axis.
2. The drift suppression method for a six-axis sensor according to claim 1, characterized in that: The process for assessing the drift risk of the six-axis sensor is as follows: The actual operating data of the six-axis sensor includes the three-axis angular rate of the gyroscope and the three-axis acceleration of the accelerometer; the sampling frequency and acquisition period are set. The actual operating data of the collected six-axis sensor is preprocessed and then subtracted from the preset initial zero bias data to obtain the original zero bias data. The raw zero-bias data is analyzed and processed to determine the instantaneous zero-bias of the axis; Based on the instantaneous zero bias of the axis, the drift of any axis during the acquisition period is cumulatively analyzed to obtain the cumulative drift of the axis during the acquisition period. If the cumulative drift of an axis within the acquisition period is greater than or equal to the standard value of cumulative drift, then the corresponding axis is recorded as the drift axis. Calculate the percentage of drift axes among all axes. If the percentage of drift axes is greater than the threshold, it indicates that the six-axis sensor has a high drift risk; otherwise, it indicates that the six-axis sensor has a low drift risk.
3. The drift suppression method for a six-axis sensor according to claim 2, characterized in that: The instantaneous zero-offset determination process of the shaft is as follows: The original zero-bias data after detrending any axis is integrated into a single-axis zero-bias dataset. The collection period is divided into multiple collection periods according to equal time intervals. The single-axis zero-bias dataset is divided into several data groups to be analyzed according to the time intervals of the collection periods. For any given data collection period, sum and average all raw zero-biased data in the dataset to be analyzed to obtain the zero-biased mean of the dataset. These zero-biased means are then integrated into a zero-biased mean sequence in chronological order. The Allan variance of the zero-biased mean sequence is calculated using Allan variance, and the standard deviation of the sequence is obtained by taking its square root. Plot the Allen variance curve to... The horizontal axis is... The vertical axis is used as the reference axis. Using the Python allantools library, the allantools.adev() function performs calculations, and the allantools.plot() function plots the results and automatically labels them. The minimum value of is the instantaneous zero bias of the axis.
4. The drift suppression method for a six-axis sensor according to claim 3, characterized in that: The process of cumulatively analyzing the drift of any axis during the acquisition period is as follows: Extract the maximum and minimum instantaneous zero offset values of the axis for all acquisition periods within the acquisition period, and denot them as the maximum instantaneous zero offset and the minimum instantaneous zero offset, respectively. Subtract the maximum instantaneous zero offset from the minimum instantaneous zero offset to obtain the cumulative drift of the axis within the acquisition period.
5. The drift suppression method for a six-axis sensor according to claim 3, characterized in that: The process of determining whether the accelerometer zero-bias drift trend and the gyroscope zero-bias drift trend are consistent during the analysis and acquisition period is as follows: Align the instantaneous zero biases of the accelerometer and gyroscope according to their timestamps. Then, integrate the instantaneous zero biases of the accelerometer into an accelerometer zero bias sequence and the instantaneous zero biases of the gyroscope into a gyroscope zero bias sequence, all in chronological order. The zero-biased acceleration sequence and the zero-biased gyroscope sequence are smoothed by moving average. The smoothed zero-biased acceleration sequence and the zero-biased gyroscope sequence are then linearly regressed using the least squares method to output the trend equation. Determine the trend representation value based on the trend equation; If the trend characterization value is greater than or equal to the trend characterization threshold, it indicates that the accelerometer zero-bias drift trend and the gyroscope zero-bias drift trend are consistent within the acquisition period. Otherwise, it indicates that the zero-bias drift trends of the accelerometer and the gyroscope are inconsistent during the acquisition period.
6. The drift suppression method for a six-axis sensor according to claim 5, characterized in that: The process for determining the trend characterization value is as follows: The accelerometer x-axis and the gyroscope x-axis are considered as a pair of axes, the accelerometer y-axis and the gyroscope y-axis are considered as a pair of axes, and the accelerometer z-axis and the gyroscope z-axis are considered as a pair of axes. If the trend slopes of the paired axes of the accelerometer and gyroscope have the same sign, then the paired axes are denoted as paired axes with the same direction. Calculate the percentage of pairs of axes that are aligned in the same direction among all paired axes; Extract the trend slopes of all axes of the accelerometer and the trend slopes of all axes of the gyroscope, and integrate them into the accelerometer slope set and the gyroscope slope set, respectively. The absolute value of the Pearson correlation coefficient is used to calculate the correlation coefficient between the accelerometer slope set and the gyroscope slope set. The absolute value of the difference between the Pearson correlation coefficient and 1 is then taken as the rate correlation value. The trend characterization value is obtained by comparing the proportion of pairs of axes with the same direction among all paired axes with the rate correlation value.
7. The drift suppression method for a six-axis sensor according to claim 5, characterized in that: The process for determining whether accelerometer drift and gyroscope drift are caused by temperature is as follows: The data in the acceleration zero-bias sequence and the gyroscope zero-bias sequence are recorded as zero-bias trend data. The temperature data is perfectly matched with the timestamp of the zero-bias trend data by linear interpolation. Based on the zero bias trend data and temperature data of any axis, the absolute value of the Pearson correlation coefficient formula is used to calculate the correlation coefficient between the zero bias trend and temperature of the corresponding axis, which is denoted as the temperature correlation value. Based on the temperature correlation values, determine the temperature correlation axis and calculate the percentage of temperature correlation axes among all axes; If the proportion of temperature-dependent axes among all axes is greater than or equal to the threshold for the proportion of temperature-dependent axes, it indicates that the accelerometer drift and gyroscope drift are caused only by temperature; otherwise, it indicates that the accelerometer drift and gyroscope drift are caused not only by temperature.
8. The drift suppression method for a six-axis sensor according to claim 7, characterized in that: The process for determining the temperature-dependent axis is as follows: If the temperature correlation value is greater than or equal to the temperature correlation standard value, then the corresponding axis is recorded as the temperature correlation axis.
9. The drift suppression method for a six-axis sensor according to claim 7, characterized in that: The process for determining the zero-offset compensation values for each axis is as follows: Based on the zero-bias trend data and temperature data within the acquisition period, the temperature value at each time point is associated with the zero-bias trend value of the corresponding axis to form 6 sets of training sample pairs. A temperature zero-bias compensation model is constructed using polynomial fitting. The least squares method is used to fit the sample pairs to minimize the sum of squared errors between the model prediction value and the actual zero-bias trend value. The model coefficients of each axis are calculated. Based on the model coefficients of each axis, the zero-bias compensation models of each axis of the accelerometer and the gyroscope are determined. Temperature data is collected in real time by a temperature sensor, and the real-time temperature data is input into the zero-bias compensation model of each axis, and the zero-bias compensation value of each axis is output.
10. A drift suppression system for a six-axis sensor, characterized in that, The system is used to perform the method according to any one of claims 1-9, the system comprising: Drift Risk Assessment Module: Acquires actual operating data of the six-axis sensor, uses Allan variance analysis on the actual operating data of the six-axis sensor, performs cumulative analysis on the drift of any axis within the acquisition period, and assesses the drift risk of the six-axis sensor; Trend Consistency Analysis Module: If the drift risk of the six-axis sensor is high, extract the instantaneous zero bias of the accelerometer and the instantaneous zero bias of the gyroscope, and analyze whether the zero bias drift trends of the accelerometer and the gyroscope are consistent within the acquisition period. Temperature-induced cause determination module: If consistent, extract temperature data within the acquisition period and perform timestamp matching to determine whether the accelerometer drift and gyroscope drift are caused by temperature. Compensation and Correction Module: If so, establish a zero-bias compensation model for each axis, input real-time temperature data into the zero-bias compensation model for each axis, output the zero-bias compensation value for each axis corresponding to the real-time temperature, and correct the six-axis sensor drift caused by temperature changes in real time based on the zero-bias compensation value for each axis.