Android Accelerometer Accuracy (Inertial Navigation)

I was involved in the implementation of an inertial navigation system for an Android phone, which I understand about, it is difficult to get the accuracy of the accelerometer and the constant fluctuations of the readings.

First, I set the phone on a flat surface and tried 1000 accelerometer readings in the X and Y directions (parallel to the table, so there was no gravity in these directions). Then I averaged these readings and used this value to calibrate the phone (subtracting this value from each subsequent reading).

Then I tested the system, again placing it on the table and checking 5000 accelerometer readings in the X and Y directions. I would expect, given the calibration, that these accelerations should be up to 0 (approximately) in each direction. However, this is not so, and the full acceleration of more than 5000 iterations never approaches 0 (averaging about 10 on each axis).

I understand, without seeing my code, it can be difficult to answer, but in a more general sense ...

Is this just an example of how incorrect accelerometer readings are on a mobile phone (HTC Desire S), or is it more likely that I made some mistakes in my encoding?

+98
android accelerometer physics acceleration calibration
Oct 19 '11 at 10:40
source share
6 answers

You gain a position by integrating linear acceleration twice, but the error is terrible. It is useless in practice.

Here's an explanation of why (Google Tech Talk) at 23:20 . I highly recommend this video.

The problem is not with the noise of the accelerometer, but with gyroscopic white noise , see Section 6.2.3 Error propagation. (By the way, you will also need gyroscopes.)

Regarding internal positioning, I found this useful:

RSSI-based internal localization and tracking using Kalman Sigma Point Smoothers

Tracking pedestrians with inertial sensors on shoes

Improving pedometer performance with a single accelerometer

I have no idea how these methods will work in real applications or how to turn them into a good Android application.

A similar question is this .

UPDATE:

Apparently, there is a newer version than the above Dr. Oliver J. Woodman, "Introduction to Inertial Navigation", his Ph.D. thesis:

Localization of pedestrians for the indoor environment

+120
Oct 20 '11 at 12:35
source share

I'm just thinking out loud, and I haven't played with the android accelerometer API yet, so bear with me.

First of all, traditionally for navigation from accelerometers you will need a 6-axis accelerometer. You need accelerations in X, Y and Z, but also rotations of Xr, Yr and Zr. Without rotation data, you don’t have enough data to set the vector, unless you assume that the device never changes its attitude, which would be pretty restrictive. In any case, no one reads TOS.

Oh, and you know that the INS drifts with the rotation of the earth, right? So that too. After an hour, you mysteriously climb a 15 ° slope into space. Suppose you have an INS that can maintain a location for a long time that the phone still cannot do.

The best way to use accelerometers — even with a 3-axis accelerometer — for navigation is to use GPS to calibrate your INS whenever possible. Where GPS drops, INS complements well. GPS can suddenly shoot 3 blocks because you are too close to a tree. INS is not great, but at least it knows that you have not been hit by a meteor.

What you can do is register phone accelerometer data and much more. Like weeks. Compare this to the good (I mean really good) GPS data and use datamining to correlate trends between accelerometer data and known GPS data. (Pro tip: you want to check the GPS almanac for several days with good geometry and lots of satellites. On some days you can only have 4 satellites, and that’s not enough). What you can do is to find when a person is walking with his phone in his pocket, accelerometer data records a very specific pattern. Based on the data, you set the profile for this device with this user and what speed is the model when it has GPS data to go with it. You should be able to detect turns, climb stairs, sit down (calibration to 0 speeds!) And various other tasks. The way the phone is held must be fully processed as separate data. I smell the neural network used for data mining. In other words, something is blind than the input means. The algorithm will only look for trends in patterns and ignore actual INS measurements. All he knew was historically, when this pattern occurs, the device is traveling and 2.72 m/s X, 0.17m/s Y, 0.01m/s Z, so the device must be doing that now. And that would move the piece forward accordingly. It is important that it is completely blind, because just putting the phone in your pocket can be oriented in one of 4 different orientations and 8 if you switch pockets. And there are many ways to hold the phone. We are talking a lot of data here.

You will obviously still have a lot of drift, but I think you will be so lucky because the device will know when you stop walking and the positional drift will not perpetuate. He knows that you are standing on historical data. Traditional INS systems do not have this feature. Drift perpetuates all future dimensions and connections exponentially. Incorrect accuracy or regular checking at regular intervals is absolutely important for traditional INS.

Each device and each person must have their own profile. This is a lot of data and a lot of calculations. Everyone walks at different speeds, with different steps, and put their phones in different pockets, etc. Of course, to implement this in the real world for server-side processing, you need to process the number-crunch.

If you used GPS for the initial baseline, part of the problem is GPS, as a rule, has its own migrations over time, but they are non-repeating errors. Sit in the receiver in one place and register the data. If there are no WAAS corrections, you can easily get location corrections by moving in random directions 100 feet around you. With WAAS, maybe up to 6 feet. In fact, you might be lucky with the RTK system with a submeter on your backpack to at least get the ANN algorithm.

You will still have angular drift using INS using my method. This is problem. But if you went so far as to build ANN, to pour GPS and INS data in a few weeks among Russian users, and in fact it has worked so far, you obviously are not against big data. Continue along this path and use more data to help resolve angular drift: People are habits. To a large extent, we do the same things as walking along the sidewalks, through doors, up stairs and don’t do crazy things, such as motorway walks, through walls or from balconies.

So, let's say you take a page from Big Brother and start storing data about where people are going. You can start mapping where people will walk. This is a pretty confident bet that if the user starts to climb the stairs, she is on the same stairs as in front of her. After 1000 iterations and some least squares settings, your database pretty much knows where these stairs are with great accuracy. Now you can fix the angular drift and location when a person begins to walk. When she hits this staircase or turns off this hall or moves along the sidewalk, any drift can be fixed. Your database will contain sectors weighted by the probability that a person will go there or that this user has gone there in the past. Spatial databases are optimized for this, using divide and conquer to select only those sectors that make sense. It would be like those MIT projects where a laser-equipped robot starts with a black image and draws a labyrinth in memory, making every turn that illuminates where all the walls are.

Areas of high traffic will receive higher weights and areas where no one has ever gained 0 weights. Higher traffic areas have higher resolution. You would essentially have to get the map wherever it is and use it as a forecasting model.

I will not be surprised if you can determine what place a person took in the theater using this method. Given the sufficient number of users going to the theater and the sufficient resolution, you will have data displaying each row of the theater, and how wide each row is. The more people visit the place, the higher the accuracy with which you could predict that this person is.

In addition, I highly recommend that you get a (free) subscription to GPS World magazine if you are interested in ongoing research on these kinds of things. Every month I go out with him.

+17
Dec 28 '13 at 9:09
source share

I'm not sure how big your bias is because you forgot to include units. ("About 10 on each axis" does not say much .: P) However, this is still possible due to inaccuracies in the equipment.

The accelerometer is great for things like determining the orientation of the phone relative to gravity or detecting gestures (shaking or bumping the phone, etc.).

However, trying to do a dead calculation using an accelerometer will expose you to a lot of complex errors. Otherwise, the accelerometer must be insanely accurate, and this is not a common use case, so I doubt that the equipment manufacturers are optimizing it.

+8
Oct. 19 '11 at 23:22
source share

The Android accelerometer is digital, it evokes acceleration using the same number of "buckets", say, there are 256 buckets, and the accelerometer can measure from -2 to +2 g. This means that your result will be quantized in terms of these "buckets" and will jump around some set of values.

To calibrate the android accelerometer, you need to try a lot more than 1000 points and find the "mode" around which the accelerometer oscillates. Then find the number of digital points on how many output oscillations are and uses them to filter.

I recommend Kalman filtering when you get mode and +/- oscillations.

+7
May 31 '12 at 12:31
source share

I understand that this is quite old, but the problem is not resolved in ANY of the answers.

What you see is the linear acceleration of the device, including the effect of gravity. If you put the phone on a flat surface, the sensor will report acceleration due to gravity, which is approximately 9.80665 m/s2 , and therefore will give 10 that you see. Sensors are inaccurate, but they are NOT THAT inaccurate! See here for some useful links and sensor information that you can follow.

+5
Mar 03 '13 at 20:49
source share

You make the assumption that the accelerometer readings in the X and Y directions, which in this case are completely hardware noise, will form a normal distribution around your average value. Apparently, this is not so.

One thing you can try is to plot these values ​​on a graph and see if any pattern appears. If not, then the noise is statistically random and cannot be calibrated - at least for your particular phone hardware.

0
Apr 17 '18 at 4:14
source share



All Articles