Is /clock being published?

asked 2019-01-18 02:39:34 -0500

kk2105 gravatar image

updated 2019-01-18 04:30:36 -0500

Delb gravatar image

Hi Guys,

This question has been asked before, however I was not able to fix the issue by using the recommended solutions. Kindly help me in understanding the reason for this prompt and also the steps to fix the issue. Details given below.

I am using Apollo Auto (open source autonomous car project) which uses ros platform for communication between the nodes. Basically Apollo uses docker environment to run the project.

I want to publish some messages from my host system (that is outside the docker) and subscribe the published messages in Apollo (inside the docker).

As an initial step, I have just published a simple message using rostopic pub -r 10 /my_topic std_msgs/String "my topic is published". It was successfully published however when I run rostopic echo /my_topic inside the docker it is giving prompt as below and I am not able to see the messages. user@in_dev_docker:/apollo$ rostopic echo /my_topic WARNING: no messages received and simulated time is active. Is /clock being published?

As suggested in one of the post, I have tried changing the rosparam use_sim_time to false. But I am still not able to see any published messages.

user@in_dev_docker:/apollo$ rostopic echo /my_topic /use_sim_time is not set, will not subscribe to simulated time [/clock] topic

Could you please help me to fix this so that I can see the messages inside the docker.

Thank you, KK

edit retag flag offensive close merge delete

Comments

3

Could you list the different solutions you have already tried ? Is the one from #q298602 one of them ?

Delb gravatar image Delb  ( 2019-01-18 04:29:52 -0500 )edit

@Delb Thanks for pointing me in right direction. And sorry for the delayed response. #q298602 did help me to get the solution for the mentioned issue by updating ROS_IP=127.0.0.1 and ROS_MASTER_URI=http://localhost:11311 and running the subscriber from docker before the publisher from host.

kk2105 gravatar image kk2105  ( 2019-01-21 02:39:40 -0500 )edit