ROS Network

This section outlines the ROS network setup

The next task is to relay the pose data to the RPi. This can be done using a ROS network; by following the steps in communication which makes reference to the ROS networking guide. These steps are outlined for this system setup:

  1. Ensure the master is running on the RPi

  2. Configure ROS_MASTER_URI on the RPi so that the master on the RPi is used:

    • Set the RPi as the ROS master for this setup.

      sudo nano .bashrc
    • Navigate to the end of the .bashrc file and add the following:

      export ROS_MASTER_URI=http://RPi_ip:11311
  3. Configure ROS_MASTER_URI in the Ubuntu streaming the MoCap data so the master in the RPi is used:

    • Set the RPi as the ROS master for this setup.

      sudo nano .bashrc
    • Navigate to the end of the file and add the following:

      export ROS_MASTER_URI=http://RPi_ip:11311
  4. This is already set in both machines, but as per the reference the hostname must be defined in the .bashrc for both machines.

The RPi_ip was simply determined in section Network Topology.

When the roslaunch command is run to launch the vrpn ROS driver, if it is not connected to the RPi ROS master then the topic will only be connected to the Ubuntu ROS master and can't be accessed on the RPi.

The raspberry Pi now has access to the Clover pose data streamed through Ubuntu on the topic /vrpn_client_node/clover1/pose.

Last updated