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

Rosjava: Problem sending a string to the sample

asked 2012-01-31 23:56:03 -0500

Markus Eich gravatar image

updated 2012-02-13 23:29:27 -0500

Dear all,

I am playing around with the rosjava tutorial. When running the Listener node together with the talker node it works fine and the Hello world is printed out. But if I run

rostopic pub /chatter std_msgs/String "Hello"

It will not work anymore. The listener throws the following exceptions:

01.02.2012 14:52:15 org.ros.internal.node.topic.UpdatePublisherRunnable run
SCHWERWIEGEND: java.lang.RuntimeException: java.net.ConnectException: Connection refused
01.02.2012 14:52:17 org.ros.internal.node.topic.UpdatePublisherRunnable run
SCHWERWIEGEND: org.ros.exception.RosRuntimeException: Connection exception:   eich-ThinkPad/192.168.103.42:39099
01.02.2012 14:52:17 org.ros.internal.transport.ConnectionTrackingHandler exceptionCaught
SCHWERWIEGEND: Channel exception: java.net.NoRouteToHostException: No route to host
01.02.2012 14:52:17 org.ros.internal.transport.ConnectionTrackingHandler exceptionCaught
SCHWERWIEGEND: Channel exception: java.net.NoRouteToHostException: No route to host
edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2012-02-13 22:47:17 -0500

Markus Eich gravatar image

I solved the issue temporarily be setting ROS_IP to 127.0.0.1. How can I tell the Listener Sample node to use the external IP of my machine? Is the Listerner Sample node bound to localhost?

edit flag offensive delete link more

Comments

Something is wrong with your network configuration. You shouldn't get a "no route to host" exception when trying to connect to your own external IP.

Martin Günther gravatar image Martin Günther  ( 2012-02-13 23:27:25 -0500 )edit

Have you tried setting ROS_IP to your external IP? 192.168.103.42 in your example log output.

damonkohler gravatar image damonkohler  ( 2012-02-23 03:17:54 -0500 )edit

Question Tools

Stats

Asked: 2012-01-31 23:56:03 -0500

Seen: 513 times

Last updated: Feb 13 '12