rosbag play missing messages [closed]

asked 2013-07-24 08:50:58 -0500

denverdash gravatar image

updated 2013-07-24 20:58:36 -0500

William gravatar image

Hi. I have a rosbag which I can verify has the correct number of messages in it from 4 runs of my system. The rosbag info is:

rosbag info messages_2013-07-24-14-29-11.bag 
path:        messages_2013-07-24-14-29-11.bag
version:     2.0
duration:    2:56s (176s)
start:       Jul 24 2013 14:29:23.19 (1374690563.19)
end:         Jul 24 2013 14:32:19.64 (1374690739.64)
size:        7.8 KB
messages:    20
compression: none [1/1 chunks]
types:       std_msgs/String [992ce8a1687cec8c8bd883ec73ca41d1]
topics:      /faceCommander/output     4 msgs    : std_msgs/String
             /gui/feedback_result      4 msgs    : std_msgs/String
             /retailCommander/output   4 msgs    : std_msgs/String
             /trigger/output           8 msgs    : std_msgs/String

When I run the system, all of these messages get sent exactly 1 time (and the system reproduces its original behavior for that one instance). After that, it seems that all of these messages do not play back. I don't see any evidence of them in my simulation.

Any idea what might be wrong?

edit retag flag offensive reopen merge delete

Closed for the following reason question is not relevant or outdated by tfoote
close date 2014-10-27 19:29:20.039140


Actually, after more debugging: I echo the topics and they are being played, but all the parts of my system seem to stop being subscribed after they receive the first message. For example, I have a logger node that just listens for messages and outputs to a file--that node stops writing.

denverdash gravatar image denverdash  ( 2013-07-24 09:23:02 -0500 )edit

I find it odd that they would get one message and then behave like they are unsubscribed. You should be careful about your roscore, if you are relying on a roslaunch to start the roscore for you it might be getting shutdown. If the roscore is shutdown new subscriptions will not be made.

William gravatar image William  ( 2013-07-24 21:01:34 -0500 )edit

You should try running a roscore, then your nodes, and then rosbag, all separately.

William gravatar image William  ( 2013-07-24 21:02:04 -0500 )edit

Can you provide instructions and a bag file to recreate your problem?

tfoote gravatar image tfoote  ( 2013-08-18 22:33:06 -0500 )edit

Sure. I uploaded two bag files (which should be played together) here: Included there is a main program which implements a logger which should listen to each message and save a record of them to a file. See the readme for more details. Thanks!

denverdash gravatar image denverdash  ( 2013-08-19 07:51:46 -0500 )edit