Lesson finished
Unlock all 43 lessons of Introduction to ROS/GitHub/LinuxFull course ₹40,000 · paid
What ROS Is: Messaging, TF, Visualization Tools and Drawbacks
A free lesson from Skill-Lync's Introduction to ROS/GitHub/Linux course, on Grow by Skill-Lync · Last updated 16 Nov 2026 · Session: “Week 1 Session 3”
What will you learn in this free Introduction to ROS/GitHub/Linux lesson?
The instructor introduces the Robot Operating System as an open source framework created at Willow Garage in 2007. It covers publish-subscribe messaging, recording and playback, services, parameters, standard messages, the TF library, tools such as RViz and RQT, and drawbacks including dependence on a single component and open source risks.
- Publish-subscribe messaging and services in ROS
- Standard messages and the TF transform library
- RViz, RQT graph, RQT plot and RQT bag
- Disadvantages of ROS for self-driving cars
What comes after lesson 3?
Later in Skill-Lync's Introduction to ROS/GitHub/Linux course (paid): lesson 4, Week 1 Session 4; lesson 5, Week 1 Session 5; lesson 6, Week 2 Session 1. The full course has 43 lessons (18 h 39 min of video); see the course overview or its price and syllabus.
Lesson transcript
Machine transcript of the lesson audio (lightly cleaned). Technical terms may contain errors; the video is the reference.
So, now that we have established that what autonomous driving is and how we can use ROS to drive an autonomous car, let's see what exactly is ROS or Robot Operating System. So, before we use ROS, we need to learn about what ROS exactly is and how we can use ROS for our task of autonomous driving. So, ROS or Robot Operating System is a set of software libraries and tools that help you to build robot applications. Now, ROS is an open source framework which has a lot of state-of-the-art algorithms with powerful computational abilities.
So, what does exactly open source framework mean? Open source framework means that you can easily use ROS for your own personal projects or even if they are commercial applications, you can use ROS out of the box without having to pay any licensing fees or any other legal fees that might be the case for using any other libraries. So, with ROS, you can easily download ROS from the ROS website or from the GitHub Repository and start using it by integrating it in your existing software. So, as you might understand by now that being open source helps ROS to integrate it into easily in your lot of projects, even for commercial companies, even for commercial purposes.
Hence, ROS is a great tool for doing various kinds of projects for prototyping your robot or for building a commercial autonomous driving application as well. So, what exactly does ROS help the user with? It enables the user to write flexible autonomous software using a flexible framework. Along with that, ROS consists of tools that simplify complex tasks for self-driving cars. So, now let's look at the history of ROS. So, ROS was first created in Willow Garage in 2007 by a lot of robotics engineers who started working there.
Since it's an open source framework, it led to many researchers and engineers being slowly interested in ROS. All of them started contributing to ROS and making the library bigger and better, along with bigger and newer and more efficient algorithms. The first official distribution of ROS was the ROS box turtle, which was introduced in 2010. And a lot of major companies currently use ROS for their projects, both commercial and open source. For example, NASA, Amazon, Microsoft, Volkswagen, Baidu, all of them uses ROS. So, why ROS? Now, let's look.
In this book, I'll provide a bit of background for ROS and explain to you and justify you that ROS is the best solution for using in autonomous or self-driving cars. Since I have already mentioned that ROS provides a flexible framework for creating software for robots. Why? Because it has a lot of set of libraries and APIs and software tools, which help a robotics engineer to create complex robot behavior. The main advantage of ROS is that it can be easily ported to different robot platforms, but the behavior is preserved.
Let's say you have built a robotic application for a four-wheeled robot. So, if you write your software using ROS, you can easily port the same software to the six-wheeled robots, and you just need to change a small configuration file, where instead of four wheels, you need to change the parameter so that it can accommodate six wheels. So, as you might understand, instead of rewriting or having to rewrite the entire code for your six-wheeled robot, you can just do it very easily just by changing a small parameter.
The next thing we need to know is that it is very difficult to automate any task which might be trivial to a human being. For example, we human beings might do some tasks like picking a cup up or like taking a left turn quite easily without having second thoughts about it. Like all of these things that we do, we do it intuitively. But to just merely have this behavior or to demonstrate this behavior in a robot, we need to write a lot of lines of code for the robot to demonstrate this behavior.
Similarly, just a mere change in the environment and conditions can cause a robot to completely fail. Hence, ROS was developed to allow many robotic engineers to collaborate and develop a joint solution, which can be both robust and general purpose. Thus, by using ROS, robotic software can be developed collaboratively by many software developers working together in a single robotic project. Now, let's look at some of the core components of ROS. ROS offers a message passing interface that provides inter-process communication and hence it is known as a middleware.
The ROS middleware has the following key concept message passing. ROS allows communication between various components of a robot, which is the first step towards building and operating a robot. For example, the camera of a robot needs to send the images it captures to the computer of the robot so that the computer of the robot can capture the image. And based on the information from the image, it can determine whether the robot should move in a certain direction, stop or avoid a collision and find an alternative path.
The image from the camera can also be used by the robot to determine if it should pick a certain object up or place an object down in a certain location and so on. From software development point of view, a message passing system can really help us keep each module separated and not get entangled with each other, thus making the software follow object-oriented programming approach. For this purpose, ROS provides an anonymous publish-subscribe model for passing messages. What is recording and playback of messages? If we are building a system which is dependent on sensor and input data from another system, we might need to repeatedly access this data to ensure that the system that we build function properly.
For example, let's say we are building a system for determining an obstacle based on a sensor data from a radar. Remember, do you guys remember radar, right? The thing that we covered a few slides ago, right? So for radar, what we do is we get the data from this radar sensor and we fill it to the computer of the robot to determine if there is an obstacle in the path the robot is currently moving on. But unfortunately, it might be, it's not the case that once we write the software, it just starts working.
We may need to write and rewrite the software and constantly test it and to fine tune the algorithm so that we can have a complete robot system at the end. Because it's very difficult to have the sensor always with the software developer, so what we can do is we can just record the sensor data using a sensor at one time and then use this similar, the same data to play it back when we are developing the software to get a very accurate and robust software. This actually provides a lot of flexibility for the user to develop a robotic system and reduce development efforts.
The next thing ROS provides is known as remote procedure calls. So, like the publisher subscriber model that I mentioned earlier, that model is a synchronous system. What do I mean by asynchronous is that when a publisher or subscriber sends or receives a message, it can do it at any time without waiting for feedback from the other end of the system. This can be useful in a lot of cases, but sometimes we need a feedback from the system, whether it has received the message or not. For example, for critical applications like collision avoidance, we need to ensure that the robot stops when it sees a collision and it becomes necessary for the robot to give a validation or an acknowledgement that it has received a sensor data, which provides the information about the collision object.
In these cases, remote procedure calls becomes very important and ROS provides this functionality using something known as a request and response interaction. For processes. With the help of services, ROS can provide this service using something called services between various processes with a simple message IDL or Interactive Description Language. Next, we cover distributed parameter system. ROS provides a way to share configurations through global key value store. This system allows configuration settings to be modified and allows tasks to modify other configuration settings as well. This can be very useful when porting the ROS developed software from one robot to another where we can just run the same software just by tweaking some configuration settings and not having to rewrite the entire software.
The next thing that ROS provides is something called distributed parameter system. ROS provides a way to share configurations through global key value store. This allows the system configuration to be modified and allow tasks to modify other configuration settings as well. ROS also provides robot specific features. So, as you might imagine, various kinds of robots have different kinds of requirements or different specific features. For example, the specific features of a wheeled robot will be completely different from the features of a bipedal robot or a legged robot.
So, what does ROS provide in that case is various tools to help set up the robots quickly and run them. It does this by providing a standard message definition for robots. Robots geometry library. It provides a robot description language. A preemptible robot procedure calls. It provides diagnostic tool for the robot. It provides pose estimation. It provides localization, mapping and navigation. Now, what is a standard robot message? Information like definition for geometric concepts like poses, transforms and vectors for sensors and cameras, IMUs or inertial motion units and lasers or LIDARs can be same.
So, these datas are exactly same for all different kinds of robots. These datas are used for tasks like navigation, for odometry, for path planning and maps and standard encoding. Hence, ROS provides a uniform way of expressing this information, which in turn allows for code interoperability. It basically means that since the data from a sensor like camera is same, it is immaterial whether the camera is installed on an autonomous driving car or the camera is installed on a UAV, the data provided by the camera is basically the same.
It's an image data. So, instead of having to write the software for cameras for an autonomous driving car or a UAV, if we have the camera and the data it provides as a software module, we can just copy and paste this software code in various robots and we can get the same kind of data with the same standard message identifiers and use this data directly in our software. This is what standard robot message means. Next, ROS also provides a robot geometry library. This provides a common way to keep track of different parts of a robot.
So, let's say you have a laser scanner mounted on a robot and you receive data from it. You need to know the exact place where it is mounted so that you can utilize the data to determine the exact position of the robot. As I told you previously that for critical tasks like collision avoidance, it becomes very necessary to know the exact position of the robot as well as the exact position of the collision object. Even an error of a couple of centimeters can be fatal robot and the autonomous driving car as well as for the object.
So, in this case, it becomes necessary to know the exact position where the laser scanner data is mounted so that we can obtain the correct transformation between the laser scanner device and the robot and use this data to ensure that the autonomous driving car avoids the collision objects clearly. So, similarly, if you have an arm mounted on the robot which is used for tasks like pick and place, you need to know its relative position on top of the robot so that when you want to pick an object and place an item, you can position the robot correctly in relative to the object that you need to pick or place so that you can capture the object with high accuracy.
All of these facilities are provided under the TF or the transform library of ROS. Apart from this, ROS also provides various out-of-the-box features for pose estimation, localization and navigation. So, these are critical components or let's say very common components of all robots or autonomous driving vehicles. Any autonomous driving car or vehicle or any other robot will always need to navigate autonomously from point A to point B and also need to localize itself in terms of its world. So, because these are such common features, ROS has algorithms which does exactly this task and you can just install ROS and import these algorithms and run these algorithms on your autonomous driving vehicle or robot and start working with them out of the box.
Along with that, ROS also provides a set of tools which are quite useful for robotic software development. One of the strongest features of ROS is that it provides tools for helping in debugging, plotting and visualizing what is being built using the following things. So, ARVIS. So, ARVIS. The first one is ARVIS. ARVIS is a lightweight simulation environment with which you can visualize your DF data for the robot. You can visualize the various ROS messages and information that are being sent from one component of the robot, for example the camera, to the wheels of the robot using the TF library and so on.
ROS also provides something called RQT which is a QT based framework for ROS and this RQT can help you actually create GUIs for the robots quite easily. With RQT and with GUIs you can visualize what exactly the robot is doing and you can also control the robot using the GUI. For example, you can create buttons and tasks directly in the GUI with which you can control the robot. So, along with this RQT it has two other tools RQT graph and RQT plot. With RQT graph you can visualize how each component of a robot is connected to one another and how information is flowing from one component of a robot to another.
With RQT plot it helps us to actually visualize this graph quite easily for the robot software developer. And last but not the least ROS also provides something called RQT bag. This actually helps us to record the various messages which are present in ROS and play them back later. So, here in this image you can see that we have visualized ARVIS. So, in ARVIS we are visualizing current data from a leader sensor. As you can see it's written here as well, the Velodyne points. Velodyne is a company which makes a type of leader sensor and this blue and green data represents the points or the laser point clouds directly from the Velodyne sensor.
So, this information is color coded based on the distance from distance of the leader to respect to the various objects. So, let's move on. So, ROS as I mentioned it provides various type of logging errors and handlers for handling errors. It provides a simple interface for communication between the vehicle and its various sensors that are mounted on the vehicle. It provides algorithms which can work out of the box for navigation, perception and path planning. It also provides a lot of tools to help us visualize the sensory data along with inbuilt simulation for self-driving cars.
So, what exactly does ROS provide for self-driving cars? So, as I mentioned in the last two slides that there are different packages available in ROS to convert data from the incoming sensors. For example, the ROS driver package allows us to convert Velodyne data to point cloud data. So, Velodyne data is actually the raw data points from the Velodyne leader scanner which is not suitable to be imported directly into the software. So, ROS already provides a package which converts it into a uniform point cloud data which can be actually used by the robot to do something useful.
For example, perception of the environment. It also suits to record the sensor data for future debugging purposes using the ROS RQT bag tool that I mentioned. And it also provides this algorithm in build as an in-built feature, hence we can directly use them in our self-driving car. And along with that, ROS also provides with the help of its messaging tools so that we can fuse all of the data from different kinds of sensors and which actually makes the system, makes the perception stack of the autonomous driving car quite robust.
However, ROS does have certain disadvantages. And one of the biggest disadvantages is that it is dependent on a single software component. Hence, it risks the application in running mode. So let's say if your robot or your autonomous driving car is running everything using ROS and due to some error or some bug in the system, ROS suddenly crashes, then your entire system will crash as well. So you won't be able to work with your autonomous driving car anymore. That one of the biggest advantage and disadvantage of ROS is that it's open source.
So even though open source makes it very easy for you to integrate ROS in your own system, even commercial application, the development of ROS actually depends on the contributions coming from the developers who are not paid to develop software for ROS. So as long as they are doing this task out of their own interest and they keep on working, you are lucky and you will be able to use ROS along with all the latest updates that you get. But because it is not controlled and it's not monitored, so if some developer makes some unintentional error in the system and it gets overlooked, then your system or your robotic system or autonomous driving car will also have these errors automatically.
And you need to find out the error by yourself. So because it is open source, it also makes it easy for hackers to target ROS in real time. So it might happen that some hacker might maliciously implement some backdoor in the ROS development environment and later exploit this very backdoor to hack inside your autonomous driving vehicle and use it for malicious purposes. So these are the few disadvantages of ROS that we need to keep in mind while using the ROS for our autonomous driving cars.