ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
1

ERROR: Unable to communicate with master!

asked 2012-08-07 05:48:00 -0500

buma676 gravatar image

I have been trying to set up a turtle bot for the past couple days. So I went through the instructions found here and made it up to 5.4; when i typed in "rostopic list" into the workstation, it is unable to communicate with master.

ON WORKSTATION

echo $ROS_MASTER_URI

http://192.168.1.101:11311

echo $ROS_HOSTNAME

192.168.1.100

ON LAPTOP

echo $ROS_MASTER_URI

http://192.168.1.100:11311

echo $ROS_HOSTNAME

192.168.1.101

Laptop IP=192.168.1.101 Workstation IP=192.168.1.100

Any help with resolving this issue would be appreciated. Thanks!

edit retag flag offensive close merge delete

Comments

thanks, i changed the ROS_MASTER_URI as you said, but it is still unable to contact master. Any other ideas?

buma676 gravatar image buma676  ( 2012-08-07 06:17:34 -0500 )edit

Is the robot running? Did you start roscore? And don't set ROS_HOSTNAME to an ip address. Instead, use the variable ROS_IP.

Lorenz gravatar image Lorenz  ( 2012-08-07 06:27:22 -0500 )edit

when i start roscore i get WARNING: ROS_MASTER_URI [http://192.168.1.101:11311] host is not set to this machine

buma676 gravatar image buma676  ( 2012-08-07 08:06:33 -0500 )edit

Did you set ROS_IP and unset ROS_HOSTNAME?

Lorenz gravatar image Lorenz  ( 2012-08-07 08:33:40 -0500 )edit

i set up the ROS_IP; how do I unset the ROS_HOSTNAME?

buma676 gravatar image buma676  ( 2012-08-07 08:36:15 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
7

answered 2012-08-07 06:09:40 -0500

updated 2012-08-07 08:10:23 -0500

There will only be a single ROS master between the 2 machines, which by the given instructions should be on the turtlebot laptop. You should change your ~/.bashrc file on the laptop from:

export ROS_MASTER_URI=http://192.168.1.100:11311

to:

export ROS_MASTER_URI=http://192.168.1.101:11311

This assumes that your laptop has the IP 192.168.1.101 and your workstation has the IP 192.168.1.100

edit flag offensive delete link more

Question Tools

Stats

Asked: 2012-08-07 05:48:00 -0500

Seen: 7,647 times

Last updated: Aug 07 '12