Magnetometer Hard Iron Calibration

By ymhsieh , 21 October 2013

I am using the MPU-9150 and am having problems with heading accuracy after hard iron calibration, soft iron calibration, and roll & tilt correction. I am seeing errors of +/- 15 degrees in the form of a single SIN cycle per full rotation.
I think this is down to the hard iron calibration. I am calibrating it by requsting about 500 X, Y and Z values whilst rotating the sensor in all three axis. These are plotted on three graphs Y/Z, Z/Y and X/Z. Both the Z/Y and Z/Z are giving values speading over about 250 to give an ellipse. However the Y/Z graph produces an ellipse, but values only spread over a range of about 120. This graph then does not plot as an ellipse. The average of the X, Y and Z values are then applied to the magnetometer raw values.

Any help or suggestions would be appreciated.

phpbb Topic ID
15711