O'Reilly logo

Robot Operating System Cookbook by Kumar Bipin

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

How it works…

First of all, we will learn how to record some data as an example—we will use our program4 node, which was discussed in the previous section  Inspecting and diagnosing the ROS system . We will first launch the node as follows:

$ roslaunch chapter4_tutorials program4.launch

At the moment, we have two options: first, to record all the topics, and second, to record selective topics as follows, respectively:

$ rosbag record -a $ rosbag record /temperature

Once the experiment is completed, we can terminate the recording by hitting Ctrl + C in the running terminal.

We can explore more options with the rosbag help record, which includes the bag file size, the duration of the recording, options to split the files into several smaller ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required