9 Axes IMU

MPU9250
Driver
git clone https://github.com/bithollow/BH
cd BH/driver
Demo

Move to folder BH/demo/imu, compile and run the example

cd BH/demos/imu
make
./imu -h

You should immediately see 9 values, updated in real time. Try to move the device around and see them change. They include Accelerometer, Gyroscope and Magnetometer data, three axis each. The main function loop is pretty straightforward: read the data, print the data.

You can find additional information about MPU9250 in the datasheet.

Another examples for BH emonstrates the work of Mahony AHRS with the data from an onboard MPU9250 sensor. We’ve also made a simple but cool visualizer for it that you can run on your PC\Mac. Here’s the instruction how to run AHRS and visualizer:

git clone https://github.com/bithollow/BH
cd BH/demo/ahrs
./ahrs -h