IMU 9DOF v2.0 (MPU-9250)

The IMU 9DOF v2.0 is a high-performance 9-axis motion tracking module based on MPU-9250 and supports both I2C and SPI interface. In this tutorial, you'll learn how to run an application with the I2C interface, which is the default setting of the module. For details, refer to the official WiKi page of this component.

You can see how to download and install the driver by referring to:

After the installation is done, follow the steps below to use this component.

Setup and Execution

  1. Connect the module to the I2C header of the LinkIt 7697 breakout board.

  2. Select the File / Examples / Grove_IMU_9DOF_9250 / IMU9DOF_Demo_Compass_Calibrated menu.

  3. Click the Upload icon to compile and upload the sketch file to the board.

  4. Open the serial monitor (with baud rate 38,400) and reset the board to execute the application. You should be able to see the output as shown below:

Reference

If you're using sources from the repositories of module vendors:

Please follow the steps to modify the codes for making it available to the LinkIt 7697:

  1. Open the IMU_10DOF-master/MPU9250.h file from the library folder.

  2. Comment out line 41:

    #ifndef _MPU9250_H_
    #define _MPU9250_H_ 
     
    #include "I2Cdev.h" 
    //#include <avr/pgmspace.h>
     
    //Magnetometer Registers
    #define MPU9150_RA_MAG_ADDRESS 0x0C
  3. Save the file.

Last updated