Installing Razor IMU ROS library

In order to install the Razor IMU library for ROS, we have to install visual python with the following command:

    $ sudo apt-get install python-visual
  

Then, we have to go to our workspace /src folder and clone from GitHub the razor_imu_9dof repository from Kristof Robot and compile it:

    $ cd ~/dev/catkin_ws/src
    $ git clone https://github.com/KristofRobot/razor_imu_9dof.git
    $ cd ..
    $ catkin_make
  

You need to have Arduino IDE installed; this is explained previously in the Arduino section of this chapter. Open your Arduino IDE-/dev/catkin_ws/src/Razor_AHRS/Razor_AHRS.ino. Now, you have to select your hardware options. Search in the code this section and uncomment the right line for you:

/*****************************************************************/ ...

Get ROS Programming: Building Powerful Robots now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.