Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ


Choose your language

InfoQ Homepage Podcasts Louise Poubel on the Robot Operating System

Louise Poubel on the Robot Operating System

ROS is the Robot Operating System. It’s been used by thousands of developers to prototype and create robotic applications. ROS can be found on robotics in warehouses, self-driving car companies, and on the International Space Station. Louise Poubel is an engineer working with Open Robotics. Today on the podcast, she talks about what it takes to develop software that moves in physical space, including the Sense-Think-Act Cycle, the developer experience, and architecture of ROS.

Key Takeaways

  • Writing code for robot development, you use the Sense-Think-Act Cycle.
  • ROS is an SDK for robotics. It provides a communication layer that enables data to flow between nodes that handle sensors, logic, and actuation.
  • ROS has two versions and has been around for twelve years. ROS 1 was implemented from scratch in different languages. ROS 2 offers is a common C base layer with implementations in many different languages, including Java, JavaScript, and Rust.
  • Released on a six-month cadence, Dashing was the latest release (May 2019). Previous releases were supported for one year, Dashing is the first LTS release and will be supported for two years.
  • ROS 2 builds on top of the standard Data Distribution Service (DDS) that you find in mission-critical systems like nuclear power and airplanes.
  • Simulation is an important step in robotics. It allows you to prototype a system before deploying to a physical system.
  • RViz is a three-dimensional visualizer used to visualize robots, sensor data, and the environments they work in. It is a highly configurable tool, with many different types of visualizations and plugins. It allows you to put together all your data in one place and see it.


Show Notes

Dolly and The Sense-Think-Act Cycle

  • 01:30 At QCon San Francisco, Louise introduced Dolly, a robotic sheep that can carry people. Dolly is a virtual robot, in a simulator, and is meant to be a "hello world" for learning to program robots.
  • 03:35 When you build a robot, you follow the Sense-Think-Act Cycle. When talking about a physical robot that will act on its environment, first, the robot acts, by moving themselves or other objects. This means it must have actuators and motors.
  • 04:15 The robot takes input that it uses to make decisions about how it will move. This input comes from sensors, such as cameras, LIDAR, or GPS.
  • 04:35 Connecting these two parts is the thinking and logic – what is the robot trying to do? In Dolly, I tried to organize the code to make it very clear how these three parts are working together in the Sense-Think-Act Cycle.
  • 05:00 Put simply, there is an event loop that continually goes through the cycle. In the case of Dolly, a planar LIDAR senses what's in front of it. The Sense part of the application is only responsible for getting this data. The logic is where Dolly determines how to follow, based on the LIDAR scans. It then determines where it needs to go, so it sends the command of where to go to the Act section of code.
  • 05:54 The Think part shouldn't know or care if Dolly has wheels or legs, that's up to the Act code, which understands the kinematics and motors of the robot. Once the robot moves, then the sensing changes, and you have to repeat the cycle.
  • 06:39 The Robotic Operating System (ROS) works as a distributed application, waiting for new events. For Dolly, the new event is updated LIDAR sensor data. This means the rate of LIDAR sensing drives the rate of the entire cycle.

ROS, the Robotic Operating System

  • 08:15 You can think of ROS as the SDK for robotics.
  • 08:25 ROS offers a communication middleware layer between all the different parts of the robot, to handle data from sensors, commands from logic to actuators, etc.
  • 09:00 In Dolly, there are three ROS nodes, one for the sensor, one for the actuation, and one for the logic. The nodes communicate by publishing and subscribing to ROS messages, and are published to ROS topics, following a pub-sub model.
  • 09:50 ROS is multi-language. ROS 1 is mainly implemented in C++ and Python, but your nodes can be implemented in any language.
  • 10:25 For ROS 2, the core is implemented in C. There is a thin layer on top of that, where you can use a different language. At Open Robotics, we're maintaining the C++ and Python layers, which are thin wrappers on top of the C common layer, but many other language implementations exist.
  • 10:52 In ROS 1, the whole stack was custom. In ROS 2, every implementation uses the common, C base layer.
  • 11:14 ROS 2 is on its fourth named release, Dashing. This is the first LTS release, and will be supported for two years. If you don't have any ROS 1 code, and you're looking to get started with ROS, you should start using ROS 2 Dashing.
  • 12:25 ROS 1 has been around since 2007. Development of ROS 2 started in 2014. ROS 2 uses more modern software libraries, such as DDS.
  • 13:00 DDS is Data Distribution Service, a standard for pub-sub communication, maintained by OMG. It has a long history in mission-critical use cases, such as nuclear power plants and airplanes.

Bootstrapping, Simulators, and Testing

  • 13:42 Open Robotics is a company in California that develops open source software for robots. Our two main products are ROS and Gazebo.
  • 14:10 ROS started over a decade ago, mostly at Willow Garage. Since then, it's been used in academia and industry. Most students who study robotics are learning ROS.
  • 14:47 Some companies using ROS in production are Fetch Robotics, Clearpath Robotics, some self-driving car companies, and NASA on the International Space Station.
  • 15:33 Some people prototype their robot in simulation, before creating a physical robot. Just like in the real world, the simulation must take into account dimensions, weight, friction and other programs. The properties can be defined in a couple of format, either SDF, Simulation Description Format, or URDF (Universal Robotic Description Format). You can import parts from a CAD program.
  • 17:34 When developing in a simulation, the process can start with very simple boxes and cylinders connected with joints. Then you can start running your code, and iterate on it. You can apply inputs and see if the robot will behave the way you expect it to.
  • 17:58 This is very similar to how you would test a physical robot. The simulation has several advantages, such as being able to easily reset, and less problems if the robot doesn't do what you expect.
  • 18:36 Your next steps depend on your final goal. If you're still designing the mechanical robot, you may want to iterate on the physical properties. Or you can iterate on the algorithm.
  • 19:39 When software engineers start developing for a robot, they may not realize that the real world is very chaotic, with a lot of unexpected events you can't always simulate.
  • 21:19 You have to be creative when you create your simulation, and vary parameters a lot, to make your algorithms robust to a variety of use cases. Vary small details, such as the center of mass of your robot, and see if it still performs correctly. Taking more feedback from sensors is a great way of overcoming uncertainty.
  • 22:24 ROS gives boilerplate that people developing robotic applications don't want to deal with. There's a lot of work involved setting up drivers and tooling to capture data from your robot, and ROS gives you that for free.
  • 22:46 The flagship product inside ROS is RViz, the Robot Visualization tool. It gives you one 3D scene to visualize all the data flowing into your system, whether you have one robot or several. This makes it really easy to debug.
  • 23:31 The command line tools in ROS are also very powerful and allow introspection of how your robotic system is operating.
  • 24:09 One thing world of robotics can teach the world of software about is uncertainty. When you're used to using an API, you expect to know what the API will do. With a robot, you interact with the real world, so you may tell the robot to go in a straight line, and it rarely goes exactly straight.
  • 24:43 A lot of software engineers get started with robotics through simulation. In simulations, things behave more like you expect them to. But, when you go into physical space, that's when you have to start dealing with uncertainty.

What's next for ROS and Gazebo?

  • 25:10 Open Robotics has been focusing mainly on ROS 2 for the past four years. After the next named release of ROS 1, Noaditc, we won't be doing any more ROS 1 releases. That will be a maintained release, with 5 years of long-term support.
  • 25:39 We will then dedicate all our time on ROS 2, with the next version, Eloquent, due out by the end of 2019. The goal is to make ROS 2 as feature-rich as ROS 1 is right now.
  • 26:00 For the simulation side, we will no longer be working on Gazebo, which will now be known as Gazebo Classic. We're turning our focus on the next version of the simulator, called Ignition. Much like the transition from ROS 1 to ROS 2, the move from Gazebo to Ignition is meant to support more use cases, including running simulations in the cloud.
  • 26:41 The abstraction layer in Ignition will make it easier to plug in a different physics engine, or a different rendering engine. Robot models (.sdf and .urdf files) will be hosted in an online model database, so you won't need to ship them with the simulation.
  • 27:35 If you want to get started with Robotics, check out the source code for Dolly, and read the tutorials available on or Everything is open source, so install it on your computer and start using it.

More about our podcasts

You can keep up-to-date with the podcasts via our RSS Feed, and they are available via SoundCloud, Apple Podcasts, Spotify, Overcast and the Google Podcast. From this page you also have access to our recorded show notes. They all have clickable links that will take you directly to that part of the audio.

Previous podcasts

Rate this Article