Robot Operating System(ROS) Driver for IMU IM1R

Robot Operating System Platform

A Comprehensive Open source platform for robot development

The Robot Operating System (or ROS) is an open source operating system for robotics which aims to provide its users with a complete development platform for quickly creating advanced robotic applications.Developing a robot app with ROS is more efficient as it gives the developer a choice of too more tools, libraries and drivers.

Robot Operating System (or ROS)

The Robot Operating System platform can help users achieve the following.

  • Hardware Abstraction: The strength of ROS is that it abstract its hardware interfaces so that developers can work on different hardware platforms. It lets you write code on a single hardware platform and move it to another with little effort.
  • Device Drivers: It provides drivers for a bunch of other devices to simplify the control, and data acquisition on, sensors, actuators, etc.
  • Communication Middleware: Since ROS boats a wide set of communication mechanisms, like message passing and service calls, it provides communication support to data exchange and coordination between nodes. The communication mechanisms that these provide aid in building distributed systems, where individual functional modules can be developed independently and work together closely.
  • Tools and Libraries: There are plenty of tools and libraries there for ROS: rViz for visualization, rqt for debugging and analysis, and Gazebo for simulation. These tools facilitate more efficient development, design, debugging and optimization of systems.
  • Community Support: ROS has an active community where developers can use open-source packages and resources provided by the community to accelerate their development process.

Thanks to its powerful development features, Robot Operating System is widely used in various robotic projects, including but not limited to:

  • Autonomous vehicles
  • Drones
  • Service robots
  • Industrial robots
  • Research and education robotics platforms
IMU IM1R Applications

DAISCH IM1R_ROS_Driver

The ROS driver for IM1R products can be found at the GitHub repository:
https://github.com/DAISCHSensor/IM1R_ROS_Driver

Topics in Robot Operating System

  • In a Robot Operating System, a Topic is an important communication mechanism used for data exchange between nodes. It allows different nodes (functional modules in ROS) to transmit information through a publish/subscribe model.
  • Messages are the data content transmitted through topics. Each topic has its corresponding data format, called the message type. ROS defines various standard message types, and also allows users to customize message types to meet specific needs.

Topics published by IM1R

  • imu/data (sensor_msgs/Imu): Angular velocity and linear acceleration
  • temperature (sensor_msgs/Temperature): Temperature from the device
  • im1r/extra (DAISCH custom topic): Extra parameters from IM1R, such as attitude angles, device status, zero-bias errors, etc.

IM1R Configuration Tool

The output parameters of the IM1R can be easily configured via a serial port. The IM1R_ROS_Driver provides a graphical configuration tool to conveniently modify configuration parameters.

IMU IM1R configuration

User Guide

Let’s walk through the process of configuring the ROS driver for IM1R.

System Requirements

  • Ubuntu 18.04
  • ROS Melodic

Installation Steps

  1. Install ROS
    Refer to the ROS installation guide (http://wiki.ros.org/ROS/Installation) for detailed instructions.
  2. Create a catkin workspace
    Enter the following commands in a terminal window
    mkdir -p ~/catkin_ws/src
  3. Clone the project repository into the src directory
    cd ~/catkin_ws/srcgit clone
    https://github.com/DAISCHSensor/IM1R_ROS_Driver.git
  4. Build the workspace
    cd ~/catkin_ws/catkin_make
  5. Update
    bashrc :echo "source ~/catkin_ws/devel/setup.bash"~/.bashrcsource ~/.bashrc

Usage Instructions

  1. Start the ROS core service
    roscore
  2. Identify the serial port for the IM1R device
    dmesg | grep tty
  3. Set the serial port permissions
    Assuming the IM1R device is connected to /dev/ttyUSB0:
    sudo chmod 666 /dev/ttyUSB0
  4. Launch the configuration tool
    rosrun im1r_ros_driver daisch_im1r_config.py /dev/ttyUSB0
    Ensure the connection is established with IM1R on serial port 2, and that the baud rate is set to 115200.
  5. Start the driver node
    rosrun im1r_ros_driver daisch_im1r_node.py /dev/ttyUSB0 115200
    Ensure the connection is established with IM1R on serial port 1, and the baud rate matches the one set in step 4.
  6. List all topics
    rostopic list
  7. Display the contents of a specific topic
    rostopic echo imu/data
  8. Subscribe to a example topic (Python)
    rosrun im1r_ros_driver subscriber_example.py

Related Articles

Latest Articles