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

Help with foreign_relay subscription

asked 2012-04-16 09:54:44 -0600

Hey,

I'm having difficulties using foreign_relay. I find that I can use it in advertise mode, to push a topic from my local master to the remote master, ie:

rosrun foreign_relay foreign_relay adv http://other-machine:11311/ /from_other/test /test

However, I can't seem to get it working in subscribe mode, ie:

rosrun foreign_relay foreign_relay sub http://other-machine:11311/ /test /from_other/test

By adding some debug shouts, I can see that the foreign_subscribe() function completes successfully, but in_cb() never gets called and the /from_other/test topic is never created on my local master.

In all cases, I am able to set my ROS_MASTER_URI to the other machine and publish/subscribe with the foreign master using rostopic. So I believe that indicates that my network and environment setup is correct. I can even successfully get a remote subscription by doing this:

export ROS_MASTER_URI=http://other-machine:11311
rosrun foreign_relay foreign_relay adv http://my-machine.local:11311 /other/test /test

This seems like a really awkward hack, though.

Has anyone else had luck getting bidirectional foreign relay working?

I'm using ROS Electric, with the current apt version of multimaster_experimental on a Lucid box, and the current source (r16648) on an Oneiric box. The apt packaged version does not work on my Oneiric machine due to a shared library mismatch issue.

edit retag flag offensive close merge delete

Comments

Oh wow, thanks. This seems much more complete and polished than multimaster_experimental. I've added a note to the foreign_relay page directing visitors on to multimaster.

mikepurvis gravatar image mikepurvis  ( 2012-04-18 08:55:16 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2012-04-17 20:12:03 -0600

weiin gravatar image

Not exactly an answer, but I find the multimaster http://ros.org/wiki/multimaster easier to use in publishing/subscribing on another master. It's bidirectional and only the config file requires updating.

edit flag offensive delete link more

Question Tools

Stats

Asked: 2012-04-16 09:54:44 -0600

Seen: 543 times

Last updated: Apr 16 '12