Announcement

Collapse
No announcement yet.

How we got the REV internal IMU to work

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • How we got the REV internal IMU to work

    Hello, I am here to tell you all about a problem I had and how I fixed it so that I might save you all some of the trouble that I had
    I was trying to use the internal IMU sensor of the REV expansion hub and I was having rouble getting it with the hardware map.
    When i first looked at REVs pdf about their internal sensors they said that it could be accessed on I2C port 0 at address 0x28.
    But i had no idea how to get a sensor using its address and there didnt seem to be any methods to get an a sensor by its address.
    I looked at the example code that was provided in the Java classes and their comments in the code confused me because it said
    that it was expecting the sensor to be attached to an I2C port and configured to a certain name. This confused me even more because I thought
    they were expecting an external gyro to be attached and so I left the example thinking that it was not for the internal sensor.
    But later after lots of experimenting I found out how to do it.

    You need to go into the Robot Configuration on the Robot's Phone. Then go to the I2C Bus 0. Set the sensor class to Adafruit IMU and set the device name to "imu"
    this should retrieve the internal gyro sensor. I hope this helps anyone who was confused as I was, and good luck in this year's competition.

    IMVERT 5920
Working...
X