Accelerometer & Magnetometer UNITS

I use the library Sodaq_LSM303AGR to get accelerometer and magnetometer values of the sensor.
I have the Sodaq Sara R410M.
Does anyone knows the units of that values?
In the void loop() i use these functions to get the sensor values :

SerialUSB.println("Print accel X Y Z");

SerialUSB.print(accel.getX());
SerialUSB.print(" ");
SerialUSB.print(accel.getY());
SerialUSB.print(" ");
SerialUSB.println(accel.getZ());

SerialUSB.println("-------------------");

SerialUSB.println("Print Mag X Y Z");

SerialUSB.print(accel.getMagX());
SerialUSB.print(" ");
SerialUSB.print(accel.getMagY());
SerialUSB.print(" ");
SerialUSB.println(accel.getMagZ());

delay(5000);

}

The values i get are like this :

Print accel X Y Z
0.24 -0.03 0.97

Print Mag X Y Z
-384.00 -58.50 -472.50

but i cant find anywhere what units are represent these values…

Hi,

The unit for the Accelerometer is in G (Gravitational constant)

The Magnetometer values are in Gauss
Here is an explanation how to convert it to compass values.

Best regards,
Jan

Thank you very much Jan. You really help me.

1 Like