This tutorial describes the configuration of the ROS environment on your developer workstation
To communicate with and command your robot, we must establish the connection between your development PC and the robot. Assuming proper network setup, the SDK shell refers to the a configuration of your ROS environment which points your PC to the ROS Master, while registering your IP or Hostname allowing other processes to find you.
The SDK provides a convenient script,
intera.sh , which helps foster the quickest and easiest ROS environment setup to get communicating with Sawyer. This script should have been installed/configured during Workstation Setup Tutorial, and the Hello Robot! Tutorial.
Quick Environment Setup Via intera.sh
$ cd ~/ros_ws $ ./intera.sh
intera.sh ROS Environment Setup
The intera.sh script is a convenient script allowing users to get their ROS environment setup quickly. It should allow for intuitive modification of the core components to get communicating with Sawyer setup quickly. It creates a heredoc which verifies all environment variables expected are provided, with a handy sim argument for local configurations (useful for simulation), and local argument (useful when SSH'd into Sawyer with no need to communicate to external, off-robot processes). This subshell created has the custom prompt modifications (with color) for quick visual checks as well.
Checkout Convenient intera.sh script
Copy the intera.sh file from intera_sdk repo to ros workspace.
Customize the intera.sh script
Please edit the intera.sh shell script making the necessary modifications to describe your development PC.
Using your favorite editor (gedit used for example)
$ cd ~/ros_ws $ gedit intera.sh
Edit the 'robot_hostname' field
Please edit the 'robot_hostname' field:
# Specify robot's hostname **robot_hostname="robot_hostname.local"**
Modifying where 'robot_hostname' is the [Robot_Hostname hostname of your robot]
Edit 'your_ip' OR 'your_hostname' field
Please edit the 'your_ip' field (only if not using 'your_hostname'):
Modifying where 'your_ip' is the IP address of your PC.
Useful command for identifying your IP address:
$ ifconfig # Result will be contained in the 'inet addr' field (Ubuntu) or 'inet' field (Gentoo Robot PC).
Important: Only set either ROS_IP *OR* ROS_HOSTNAME.
Setting of both ROS_IP and ROS_HOSTNAME will result in ROS_HOSTNAME taking priority, resulting in confusing environment setups. Comment out the unused method using the '#' as leading character.
Alternatively, you may choose to use the hostname of your development PC.
Please edit the 'your_hostname' field (only if not using 'your_ip'):
Modifying where 'your_hostname' is the hostname of your PC.
Important: This hostname must be resolvable to Baxter. To test if your hostname is resolvable to Baxter, please visit the development PC Networking page.
Edit 'ros_version' field
Please edit the 'ros_version' field:
Modifying where 'ros_version' is the your chosen ROS release.
Save and Close intera.sh script
Please save and close the intera.sh script.
Initialize your SDK environment
From this point forward, your ROS environment setup should be as simple as running the intera.sh script from the root of your Catkin workspace:
$ cd ~/ros_ws $ ./intera.sh
You will see that your current shell prompt will be prefixed with:
[intera - http://<robot_hostname>:11311]username@machine$
This allows you to quickly view if your shell is configured for intera communication or not, and to which robot you are currently addressing (
Verify RSDK Shell
Test ability to ping robot.
Ping what you have previously set as your
$ ping <robot_hostname> # ex. $ ping 011304P0026.local
If unable to ping the robot visit this page.
Test ability to command the robot
1. Enable the robot
$ rosrun baxter_tools enable_robot.py -e
The robot is now active. You may now grasp Baxter's arms freely by grasping the cuffs at the hands.
2. Disable the robot
$ rosrun baxter_tools enable_robot.py -d
You should visibly see Baxter's arms gently fall and will no longer have the ability to move the arms freely.
If unsuccessful in enabling the robot, please follow the instructions below. This is typically due to a ROS_HOSTNAME being set which is not resolvable to Baxter. Please unset your ROS_HOSTNAME, instead using your ROS_IP. Make sure this is reflected permanently in your
Timeout observed when trying to enable the robot.
Assuming that you are able to
$rostopic echo /rosout during these prerequisite instructions. This error is a sign of the inability to make commands to the robot. This is due to your ROS_HOSTNAME/ROS_IP being set incorrectly.
View the ROS_ENVIRONMENT set for your current shell.
$ env | grep ROS
Verify that ***EITHER*** the ROS_HOSTNAME or ROS_IP is set for your development workstation.
If unsuccessful and the ROS_HOSTNAME is set, please unset this variable and use ROS_IP.
$ unset ROS_HOSTNAME $ export ROS_IP=<your_development_workstation_ip>
Note: You can always view your current development workstation IP address using
If unsuccessful and the ROS_IP is set, verify that this is describes your ip address and not the robot ip address.
# Verify ROS_HOSTNAME is unset $ unset ROS_HOSTNAME # Take note of your IP address $ ifconfig # Export this as your ROS_IP $ export ROS_IP=<your_development_workstation_ip>