9 | P a g e
Making a Recording for Gyroscope Calibration
Note that when the tag is recording without moving, the gyroscope should have values of 0
degrees/second, but there is typically an offset.
Place device in a known orientation for a few seconds when recording starts. Generally a flat surface is a
good idea.
The values for the gyroscope from this offset calibration recording should be averaged for each axis, and
then subtracted from data collection files.
X Gyroscope offset = mean (gyroX)
Y Gyroscope offset = mean (gyroY)
Z Gyroscope offset = mean (gyroZ)
Making a Recording for Magnetometer Offset Calibration
The purpose of the magnetometer calibration is to record data from all possible orientations. This is used
to correct for offsets in the magnetometer due to nearby metals. For the first recording, rotate the device
in all possible orientations (both horizontally and vertically). Put on some LMFAO and do some shufflin'.
These data can be used to determine the offset caused by nearby metals in post-processing.
The values for the magnetometer from this offset calibration recording should be analyzed by finding the
minimum and maximum values for each axis. Subtract these offsets from the X, Y, and Z magnetometer
channels.
X Magnetometer offset = (max(magX) –min(magX)) / 2
Y Magnetometer offset = (max(magY) –min(magY)) / 2
Z Magnetometer offset = (max(magZ) –min(magZ)) / 2