[ros-users] CSV with time from bag files

Jeremy Leibs leibs at willowgarage.com
Wed Jun 9 08:33:50 UTC 2010


Assuming you are still using boxturtle, rosrecord has a rosrecord.py
programmatic API

Take a look at:

http://www.ros.org/wiki/rosrecord#rosrecord.py

It should be fairly straight forward to write a small program which
opens the bag and prints exactly what you want.

On Wed, Jun 9, 2010 at 1:29 AM, Miguel Prada <miguel.register at gmail.com> wrote:
> Hi,
>
> I want to manipulate some data from a bag file with a spreadsheet. I'm exporting from the bag to CSV using 'rostopic echo -p -b BAGFILE TOPIC >> file.csv' but I just realised that the time field you get from doing that is the time corresponding to when rostopic is run, not the time stored in the bag file. That means that if I use this method to output messages in one topic and then repeat for another topic (e.g. controller commands and robot positions) the time fields on both CSV files are of no use at all to merge the data in those two files.
>
> I tried using 'rostopic echo -p -b BAGFILE -a >> file.csv' to print all topics at once, but the output is quite messed up and doesn't clearly state which data corresponds to which topic.
>
> Does anyone have any suggestion on how should I proceed with this?
>
> Miguel.
>
> _______________________________________________
> ros-users mailing list
> ros-users at code.ros.org
> https://code.ros.org/mailman/listinfo/ros-users
>



More information about the ros-users mailing list