📜 ⬆️ ⬇️

Inertial sensors: cooking recipes for positioning systems

In this post we will talk about inertial sensors. The fact that they measure and how these physical quantities can be used.


Most modern mobile phones have on board a triad of accelerometers, gyroscopes and magnetometers, often in addition to them, an atmospheric pressure sensor is installed.


Everything is very clear with the last sensor: almost every one of us has a barometer hanging at home or in the country and millimeters of its mercury column are firmly connected with the rain, bad weather and general well-being of their beloved grandmother. But what is measured by the accelerometer, gyroscope and magnetometer, and how to use this information to determine the orientation of the device in space?


Accelerometer


Wikipedia says that an accelerometer is a device that measures the projection of apparent acceleration. A typical accelerometer consists of three mutually perpendicular measuring axes that register gravitational and linear accelerations.


Using measurements of a triaxial accelerometer, one can determine its orientation relative to the reference vector, which in this case is gravitational acceleration. Then, however, the orientation will not be fully resolved - there will be uncertainty about the angle of rotation around an axis parallel to the direction of the acceleration of gravity.


This is explained in more detail in the figure below. Imagine that we have a measuring device with an accelerometer that has three X, Y, and Z axes. In the figure, these axes are marked in red, green, and blue and form the left three of vectors. Obviously, if only the gravitational acceleration vector is available for determining the orientation, then there will be an infinite number of possible orientations of the measuring device, in which the Z axis of the accelerometer will measure the gravitational acceleration value, but we cannot resolve the absolute orientation of the device.



Magnetometer


To allow orientation completely, we need a second basis vector that will not be parallel to the first. Such a vector may be, for example, the vector of the magnetic field of our planet. If its direction is known, then the orientation will be resolved unequivocally.


Knowing the orientation of one coordinate system relative to another, it becomes possible to transfer measurements from the device coordinate system to the global one. And knowledge of accelerations in the global coordinate system will allow, by integration, to restore speed and obtain information about the relative location.


Gyroscope


The gyroscope allows you to measure the speed of rotation of the device, respectively, in order to bring the speed to the angle of rotation, we must integrate it. The main orientation problem is connected with this position only with the help of a gyroscope - due to continuous integration of not quite accurate measurements of angular velocities caused by zero displacement or temperature effects, we will get an orientation drift, or, in other words, it will “float” from the true value.


The advantage of using all three sensors in the orientation filter is that:



How else can you use data from inertial sensors?


In addition to the traditional and well-studied task of determining the orientation of the device, inertial sensors can be used for:



In future articles, it is planned to reveal the topics of how to work with inertial sensors — discuss ways of calibrating them (although this has already been discussed in Habré), look at existing ways of restoring the trajectory of a person’s movement, explore approaches to detecting and eliminating magnetic field disturbances, and discuss firmware architecture for timely time stamping and processing of their measurements.


The author - Alexander Mikov.


')

Source: https://habr.com/ru/post/302650/


All Articles