Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Messages do not get published

I have a node A subscribed to some ROS topic B. When I do rosnode info A, I can see topic B. However, when doing rosecho, nothing appears on the topic. Repeating rosecho does not help. This does not happen all the time. Usually, restarting the robot/the computer helps. Still, my question is: why is this happening?

Messages do not get published

I have a node A subscribed to some ROS topic B. When I do rosnode info A, I can see topic B. However, when doing rosecho, nothing appears on the topic. Repeating rosecho does not help. This does not happen all the time. Usually, restarting the robot/the computer helps. Still, my question is: why is this happening?

EDIT:

I have simplified the problem to having two terminals, one publishing to a topic, and the other one echoing that topic. It seems like there is a large delay. I start with:

> rostopic echo /cba
WARNING: topic [/cba] does not appear to be published yet

Then I do rostopic pub /cba std_msgs/String "A" which gives:

> rostopic echo /cba
WARNING: topic [/cba] does not appear to be published yet
data: A
---

However, a subsequent rostopic pub /cba std_msgs/String "B" is not seen in the terminal that echos the topic cba.