Article count:1511 Read by:4580472

Account Entry

Introduction to ROS/ROS 2

Latest update time:2022-04-19
    Reads:

Author: Wang Yangming of JiKrypton Software and Electronics Center



Preface

ROS is the English abbreviation of Robot Operating System. ROS is a highly flexible software architecture for writing robot software programs. The prototype of ROS originated from the STanford Artificial Intelligence Robot (STAIR) and Personal Robotics (PR) projects at Stanford University.

There are clear differences between the robotics industry and academia on the use of software tools. Since the robot industry does not have huge shipments like consumer electronics, absolutely high technical barriers and closed ecology are very common. In order to improve their technical barriers, these companies often design a complete set of closed software and hardware themselves, so that others (competitors or developers) cannot replace it with their own tools. In academia, in order to reduce the work of reinventing the wheel, students and teachers often embrace the open source community and choose existing tools for development and research. The most well-known is ROS (Robot Operating System).

What is ROS

ROS/ROS 2 is not a piece of software, but a collection of software. Generally we call it a software solution stack. Includes hardware drivers, network modules, communication architecture, robot algorithm implementation, etc. ROS brings all these feature packages under one umbrella so developers don't have to reinvent the wheel.

ROS is not an operating system, but is generally called a meta-operating system, which is a class operating system based on the operating system.

ROS is not a middleware because it implements a variety of functions including perception, navigation, control, motion planning and simulation.


ROS

ROS version 1.0 was released in 2010, and a series of robot-related basic software packages were developed based on the PR2 robot. Subsequently, ROS versions have been iterated frequently, and ROS versions are generally updated with the Ubuntu system long-term support (LTS) version. The latest version of ROS has been adapted to Ubuntu 20.04 LTS. ROS is only tested for CI on Ubuntu, but community members actively support other Linux versions, Mac OS X, Android, and Windows, making ROS compatible, but only providing limited feature support.

Historical versions of ROS

ROS version

release time

Ubuntu version

ROS Noetic Ninjemys

May 23rd, 2020

Ubuntu 20.04 (Focal)

ROS Melodic Morenia

May 23rd, 2018

Ubuntu 18.04 (Bionic)

ROS Lunar Loggerhead

May 23rd, 2017

Ubuntu 17.04 (Zesty)

ROS Kinetic Kame

May 23rd, 2016

Ubuntu 16.04 (Xenial)

ROS Jade Turtle

May 23rd, 2015

Ubuntu 15.04 (Vivid)

ROS Indigo Igloo

July 22nd, 2014

Ubuntu 14.04 (Trusty)

ROS Hydro Medusa

September 4th, 2013

Ubuntu 12.04 (Precise)

ROS Groovy Galapagos

December 31, 2012

Ubuntu 12.04 (Precise)

ROS Fuerte Turtle

April 23, 2012

Ubuntu 10.04 (Lucid)

ROS Electric Emys

August 30, 2011

Ubuntu 10.04 (Lucid)

ROS Diamondback

March 2, 2011

Ubuntu 10.04 (Lucid)

ROS C Turtle

August 2, 2010

Ubuntu 9.04 (Lucid)

ROS Box Turtle

March 2, 2010

Ubuntu 8.04 (Hardy)


Comparison of advantages and disadvantages of ROS

ROS brings a lot of convenience to our robot development, but it does have some problems:

advantage

shortcoming

Loosely coupled mechanisms provide a framework

Communication real-time performance is limited

Rich robot function library

System stability does not yet meet industrial-grade requirements

Huge user base

No safety precautions

Free and open source

Only supports Linux (Ubuntu)

Convenient data recording, analysis, and simulation tools

The performance of the core mechanism is not optimized and consumes resources


Mature cases of ROS

ROS has been around for ten years. With the great development of robotics technology, ROS has also been greatly promoted and applied. Although ROS still has many limitations, it cannot conceal the edge of ROS. The function packages in the community are still increasing exponentially year by year, which brings great convenience to robot development. Many developers and research institutions have also made improvements to address the limitations of ROS, but these improvements in local functions are often difficult to improve overall performance. A large number of mature applications have been accumulated in the industry:
KEBA, the leader in robotic arm controllers , their controllers already support ROS :
Robonaut 2 developed by NASA based on ROS :

The bottom layer of Baidu Apollo unmanned vehicle is developed based on ROS:
Generally speaking, ROS is more suitable for scientific research and open source users. If it is used in industrial scenarios (such as driverless driving), optimization and customization are required. Currently, ROS has stopped updating, and robot developers are increasingly calling for a new generation of ROS. , the news of ROS2.0 is also endless.

ROS 2

ROS cannot truly enter the industry, and naturally cannot be commercialized. To solve this problem, the community proposed ROS 2. This enables ROS to have productized features, including real-time, adaptability to all platforms, suitability for low-performance hardware (MCU+RTOS), distribution, data encryption and support for modern programming languages.

Historical versions of ROS 2

ROS version

release time

Ubuntu version

Humble Hawksbill

May 23rd, 2022

TBD

Galactic Geochelone

May 23rd, 2021

Ubuntu 20.04 (Focal)

Foxy Fitzroy

June 5th, 2020

Ubuntu 20.04 (Focal)

Eloquent Elusor

November 22nd, 2019

Ubuntu 18.04 (Bionic)

Dashing Diademata

May 31st, 2019

Ubuntu 18.04 (Bionic)

Crystal Clemmys

December 14th, 2018

Ubuntu 16.04 (Xenial)

Bouncy Bolson

July 2nd, 2018

Ubuntu 16.04 (Xenial)

Ardent Apalone

December 8th, 2017

Ubuntu 16.04 (Xenial)


Real-time and distributed

In order to solve the problem of decentralization and real-time communication between messages, ROS 2 introduces Data Distribution Service ( DDS), which has been widely used in national defense, civil aviation, industrial control and other fields, and has become a data publishing/subscription in distributed real-time systems. standard solution. As shown in the figure below, ROS 1 is on the left and ROS 2 is on the right.

In ROS 1, each node of the user, whether it is the same device or a different device, must know the IP of the Master node, and all rely on the Master node for communication. Once the Master node fails or the device fails, the entire environment All node functions are lost. Unable to recover. It is precisely because of this that ROS 1 cannot be applied to official products.

ROS 2 introduces a decentralized data communication method based on DDS. Different nodes can communicate through unknown IP, which in turn helps solve the problem of multi-robot systems. And ROS 2 also introduces the Quality of Service mechanism, which ensures good communication effects in some poor network environments by setting different service qualities.

real-time

As for real-time performance, since DDS has many applications in many industries and industries and has a good ecology, its performance is beyond doubt. The test results are as shown below:
The test equipment is two PowerEdge R330 e34s
OS: Ubuntu 18.04.2 LTS bionic
Architecture: x86_64
CPU(s): 8
Thread(s) per co re: 2
Model name: Intel(R) X eon(R) CPU E3-1230 v6 @ 3.50GHz

Taking Fast-RTPS as an example, we can see that the delay in communication between dual devices can be stable below 100μs, and the throughput bandwidth has also reached more than 750Mbit/s. For detailed running score data, please refer to Fast-RTPS vs Cyclone DDS vs OpenSplice DDS , and the communication efficiency within the same device will far exceed this result.

data encryption

ROS 2 introduces the concept of SROS on the basis of DDS. The design document refers to ROS 2 DDS-Security integration , that is, all ROS 2 messages can be encrypted and decrypted, authenticated, authorized control, log and data marked through SROS. control etc. Based on the original design logic of ROS 2, we can even put the key generation and storage of data into the ARM TEE OS to achieve higher security data assurance.

Modern programming language support

Since the initial release of ROS 1 was in 2007, long-term support and support from many development libraries have resulted in many new features of the language not being well applied. For example, for Python, Python 3 was not supported for the first time until the Noetic version released in 2020, and Python 2 stopped supporting it in January 2020. Another example is C++. ROS 1 is implemented based on C++ 03, and the support for C++ 11 is not good, let alone the support for C++ 14 and C++ 17.

ROS 2 fully supports Python 3 and is written based on modern C++. And based on its loose coupling method, it also supports programming languages ​​​​such as Java and Rust. As shown in the line below the User Application in the figure below, any programming language can be supported as long as the developer is willing .

Flexible mechanism
ROS 2 provides a life cycle-based management model, that is, the running status of each node is fully controllable . Refer to the design document for an explanation of Managed nodes . All Managed nodes can be configured, managed, shut down and started in real time at runtime, and can be woken up and reset by the management node in the event of an error. This method ensures the stability and robustness of the entire system, and also improves the system's ability to return to normal after an error occurs.
ROS 2 can replace DDS middleware at runtime and can also communicate between implementations of different DDS middleware.

5G support

ROS 2, driven by Ericsson, is discussing the formulation and implementation of the ROS 2 communication solution for 5G.

Brand new ecology

Inheriting the extensive open source ecological resources of ROS 1, the release of ROS 2 has aroused everyone's enthusiasm for ROS productization. Many companies have contributed solutions and code to ROS 2, including but not limited to Intel, NVIDIA, Ericsson, etc.
In addition to contributing new code, the excellent tools of ROS 1 have also been fully inherited into ROS 2, such as Moveit, Rviz, and rosbag. And some modules, such as navigation, have been upgraded to navigation2 in the developer's improvements, which has improved many problems and improved the convenience of use.

Various communication methods

ROS 2 Topic communication node is a bridge for communication between nodes. Nodes can publish and receive topics at the same time. There is a many-to-many relationship between nodes and topics.
Service is another method of node communication on the ROS graph. Services are based on a call-response model rather than the publisher-subscriber model of a topic. There is a one-to-one or one-to-many relationship between the server and the client.
Action is one of the communication types used for long-running tasks in ROS 2. They consist of three parts: goal, result and feedback.

Mature cases of ROS 2

Ghost Robotics, invested by the US military , uses the Eloquent version of ROS 2 for development of its quadruped robot, and the DDS solution uses the commercial Cyclone DDS.
Mission Robotics' underwater robot (ROV) was developed using the Foxy version of ROS 2.

Summarize

The real revolution in the automotive industry has begun, and the era of software-defined cars has arrived. Cars are accelerating the transformation from mechanical equipment to highly digital and information-based intelligent terminals, involving large and complex fields. A self-driving car, in a sense, is also a self-driving robot. Of course, it can be developed using ROS 2. ROS 2 provides a large number of basic components, which greatly facilitates navigation algorithms, self-driving algorithms and Deployment of some AI algorithms. Of course, ROS 2 still has many flaws. The scheduling model of ROS 2 cannot be preempted. Sometimes high-priority scheduling instances may be blocked by low-priority scheduling. No automotive industry company has yet used ROS 2 to launch a product.
Faced with these challenges, JiKrypton's Software and Electronics Center made a bold attempt to develop an automotive operating system based on SOA architecture based on the communication framework and platform architecture of ROS 2, and achieved good test results. ZEEKR's Software and Electronics Center has been conducting in-depth exploration of cutting-edge technologies and is committed to building the ZEEKR OS vehicle operating system. We also welcome people with lofty ideals to join us and jointly explore the next generation of automotive operating systems.

Finally, send a recruitment advertisement:

Latest articles about

 
EEWorld WeChat Subscription

 
EEWorld WeChat Service Number

 
AutoDevelopers

About Us Customer Service Contact Information Datasheet Sitemap LatestNews

Room 1530, Zhongguancun MOOC Times Building,Block B, 18 Zhongguancun Street, Haidian District,Beijing, China Tel:(010)82350740 Postcode:100190

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号