Introduction - If you have any usage issues, please Google them yourself
This procedure for the Linux operating system through the I2C bus driver to read the compass sensor LSM303 (This sensor includes an accelerometer and a magnetometer) acceleration sensor readings. This a user space program.