This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MPU-9150 3-axis accelerometer on Tiva C EK-TM4C1294XL Launchpad

Hello,

I have an MPU-9150 breakout board from Sparkfun and I want to use it in a data logger that I build. At first, in order to ensure that the sensor works fine, I made a small CCS project that only reads the data from the accelerometer and prints them on a serial monitor, before integrating this functionality into my main project. When I run the small project, everything works fine and I can see the sensor sending data on my screen. But, when I copied and paste the code from the small project to the main data logger project, it stopped to work properly. The sensor generates interrupts and sends data for about a minute and then it stops to generate interrupts or sometimes reports and "arbitration lost" error. What can I do to solve it? in order to use the MPU-9150 sensor I used the code from the qs-logger example provided with Tivaware. Attached below are the two projects I mentioned:

Small project that only reads accelerometer data: mpu9150_test.zip

Main data logger project: 2553.art-logger_final.zip

  • Hello Vaggelis,

    Are there other devices that use the same peripheral? That could be one reason you get the "arbitration lost" error. Is one device starving other devices from access to the bus?

    Thanks,
    Sai
  • Hi Stellaris Sai,

    The I2C3 (PK4/PK5 pins) peripheral is used only for communication with the MPU9150 sensor. But, I have some analog inputs on the GPIO Port K peripheral. Also, I use the PB2 pin as the interrupt pin of the MPU9150 sensor, and on the GPIO Port B peripheral I have two analog inputs and I use PB0/PB1 pins for CAN communication.

    Do you think any of these is to blame for the "arbitration lost" error or the fact that it stops to generate interrupts?

  • Also, I use a GUI application (made in GUI Composer) to configure some variables of the program. Can this create such a problem?
  • Hello Vaggelis,

    If a dedicated I2C is used, and those pins are not being interfered with, then I don't think it would cause the "arbitration lost" error. Can you hook up a logic analyzer and see if those lines are being interfered with? Have you made any changes to the hardware that worked with the simple code?

    Alternatively, you can disable the modules (or sections of code) that you suspect would be interfering with this communication with MPU9150.

    Thanks,
    Sai