0
$\begingroup$

Rosanswers logo

Hi!

I just want to share with you some issue I have detected and might be a bug, but probably it's just that I'm missing something. BTW, I'm using diamondback.

I have a couple of nodes: (A) publisher and (B) subscriber. Actually, I'm using image_transport publishers/subscribers. This is how to reproduce the issue given to nodes like above (of course, B subscribes to a topic that A publishes):

run A + run B + stop (Ctrl+C) A + run A

After that, B doesn't receive any msgs from A.

However, if you do:

run B + run A + stop (Ctrl+C) A + run A

it works ---and, of course, you can repeat the last two steps any number of times.

I just wonder why the first "sequence" doesn't work. Is it because it must be done the second way? ---i.e. run subscribers before publishers.

Thanks,

Enrique


Originally posted by Enrique on ROS Answers with karma: 834 on 2011-10-08

Post score: 0


Original comments

Comment by Enrique on 2011-10-08:
I think you've just find the problem, because I'm roslaunching each node (instead of rosrunning). Now I see why I should always do roscore separately; I used to rely on the roscore automatically launched with the first launch file. Thank you!

Comment by joq on 2011-10-08:
Is roscore running continuously throughout these tests?

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

This is a side-effect of the fact that roslaunch only starts roscore if it was not already running.

In either case, starting roscore first should eliminate the problem:

  • roscore + run A + run B + stop (Ctrl+C) A + run A

  • roscore + run B + run A + stop (Ctrl+C) A + run A


Originally posted by joq with karma: 25443 on 2011-10-08

This answer was ACCEPTED on the original site

Post score: 1

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.