Can I record the data of the latest several seconds to a .bag?

asked 2017-03-16 21:38:18 -0500

Xiang gravatar image

Hi,

I would like to record the data of the latest several seconds, but do not find any way to do that.

I think that what I need is a queue. Say, a topic of 1 hz, and I want to record the latest three seconds. The first three seconds are pushed to the queue. When the time stamp is larger than three, the data in the head is pulled, and the new data is pushed.

t0-t1-t2 -> t1-t2-t3 -> t2-t3-t4

I do not know if I am right. Or, is there any easy way to do that? Many thanks.

edit retag flag offensive close merge delete

Comments

Why display 'This post is awaiting moderation'?

Xiang gravatar image Xiang  ( 2017-03-16 21:39:35 -0500 )edit