Open Source Meets the Special Challenges of Robotics

Open Source Meets the Special Challenges of Robotics

Universal coverage and flexibility are important traits for most software, especially free and open source software. Robots make it even harder to achieve these virtues. The variety of sensors, cameras, controllers, and appendages in different robots constantly stretches the capabilities of robotics software.

Simulators exist (we’ll examine one in this article), but the challenge then becomes how to capture as much of the real world as you can in the simulator.

The field of robotics is one of the most important in technology. For instance, as the world’s population ages, who will staff factories, construction sites, and other workplaces? Who will care for us as we become older and more feeble?

Katherine Scott, developer advocate for the Open Source Robotics Alliance (OSRA), points out that developers have to consider higher order effects in robotics. This concept comes from physics. She offers an example: When you simulate a wheel, a first order effect would be the simple rolling motion. A second order effect would be how the tire’s stickiness changes as it heats up while rolling, or how the wheel deforms when you press on the gas, or the wind resistance on the vehicle as it speeds up.

For this article, I investigated three important free software projects: the Mobile Robot Programming Toolkit (MRPT), the Robot Operating System (ROS), and Gazebo, a robot simulator. I interviewed project leader José Luis Blanco-Claraco for MRPT, and Scott for ROS and Gazebo.

Opening the Door for Robotics

I’m putting MRPT first in this article, even though ROS is more popular, because MRPT started quite a while ago in 2005. For several years it was a very popular framework and powered some big companies in the space. Although its growth is slower now, Blanco tells me it still wins new users.

The big advantage of MRPT, according to Blanco, is its flexibility. Data sets collected 20 years ago can still run on it. Maps developed with it are all compatible. (Maps of buildings or other sites are a key element of robotics, because they help robots localize themselves and know where to go.)

The framework offers portable C++ data structures, making it appropriate for a wide range of robots and architectures. Naturally, it interoperates with ROS.

When MRPT first came out, drivers for various robots, sensors, cameras, and other devices poured in. Blanco said that a typical contributor is a student in a robotics lab. The design of the library, combined with the provision of ample examples makes it easy to write a driver or extension.

Quality control starts with the typical tools used by other projects: unit tests and integration tests. But with robotics, testing on a simulator is never enough to ensure that software will work out in the field. Whenever possible, changes are tested on the actual robot.

But even with the actual device in hand, there are extra factors to consider. It’s hard to determine whether software for a camera or sensor works, for instance, without a human viewing the results.

Blanco says that testers who have devices often capture data sets that can be used to test new software by developers who lack access to the devices. For instance, software that reads a map and moves a robot can check whether a simulator reports ending up in the same position as the real robot in the recorded data set. The test can check the number of steps taken or how much the wheels moved in any direction.

For sensors, a data set may record what was captured, which can then be used to verify software without access to the sensor.

Today’s Industry Standard

In 2007 or 2008, a few years after MRPT was created, a leading research group called Willow Garage decided to create a new framework, ROS, to overcome fragmentation in robotics software. It’s now the standard framework, with enormous projects hanging off of it. Notably, ROS-Industrial creates software for the large, powerful robots used in factories, while Autoware works on autonomous vehicles.

Around 2014, Willow Garage created the nonprofit Open Source Robotics Foundation (OSRF) to shepherd ROS. To generate income for the projects, the OSRF formed a for-profit company named the Open Source Robotics Corporation (OSRC), eventually purchased by Intrinsic in 2022. Then, in 2024, the foundation created the OSRA as a membership organization made up of supporters and contributors.

Like many large projects, such as programming languages, ROS consists of a core maintained by the OSRF and packages developed by other organizations, such as ROS-Industrial and Autoware. Unlike MRPT, ROS defines data types.

Scott said that version 1 of ROS (at its end of life since May 2024) wrote all of the communication protocols from the ground up. This was not only a tremendous burden for maintainers, but limited the framework’s flexibility. As explained earlier in this article, the enormous variation in robots requires a more adaptable system.

Thus, ROS 2 creates an abstraction layer for basic functions such as publish/subscribe, allowing middleware solutions to be plugged in. The first publish/subscribe protocol used in ROS 2 was the OMG Data-Distribution Service (DDS). They later added support for Eclipse Zenoh and others.

ROS holds seven or eight conferences annually, in many parts of the world. The next one will be in Singapore.

Replaced by an Exact Replica

Gazebo is continually working to represent all the elements in a robot’s environment that could affect its operation, such as wind. To show the role a simulator can play in development, Scott told me about a DARPA challenge using ROS and Gazebo.

For the challenge, DARPA created a map and specifications for an unfinished, abandoned nuclear power plant in Washington state. The goal of the challenge was to navigate its rooms and locate objects that might need to be removed.

First, people wrote code to run on Gazebo. Successful competitors then got funding from DARPA to create an actual robot and test it in the power plant.

In summary, robotics combines many of the most resistant problems in technology: sensing, motion, safety, adaptability in the face of unexpected environments, and more. Free and open source software are allowing bold developers to create robots we can use.

About Andrew Oram:

Andy is a writer and editor in the computer field. His editorial projects at O'Reilly Media ranged from a legal guide covering intellectual property to a graphic novel about teenage hackers. Andy also writes often on health IT, on policy issues related to the Internet, and on trends affecting technical innovation and its effects on society. Print publications where his work has appeared include The Economist, Communications of the ACM, Copyright World, the Journal of Information Technology & Politics, Vanguardia Dossier, and Internet Law and Business. Conferences where he has presented talks include O'Reilly's Open Source Convention, FISL (Brazil), FOSDEM (Brussels), DebConf, and LibrePlanet. Andy participates in the Association for Computing Machinery's policy organization, USTPC.

Laisser un commentaire

Votre adresse e-mail ne sera pas publiée. Les champs obligatoires sont indiqués avec *