FogROS2: An Adaptive Platform for Cloud and Fog Robotics Using ROS 2
Jeffrey Ichnowski, Kaiyuan Chen, Karthik Dharmarajan, Simeon Oluwafunmilore Adebola, Michael Danielczuk, Victor Mayoral-Vilches, Nikhil Jha, Hugo Zhan, Edith LLontop, Derek Xu, Camilo Buscaron, John Kubiatowicz, Ion Stoica, Joseph E. Gonzalez, Ken Goldberg
Abstract
Mobility, power, and price points often dictate that robots do not have sufficient computing power on board to run contemporary robot algorithms at desired rates. Cloud computing providers such as AWS, GCP, and Azure offer immense computing power and increasingly low latency on demand, but tapping into that power from a robot is non- trivial. We present FogROS2, an open-source platform to facilitate cloud and fog robotics that is included in the Robot Operating System 2 (ROS 2) distribution. FogROS2 is distinct from its predecessor FogROS1 in 9 ways, including lower latency, overhead, and startup times; improved usability, and additional automation, such as region and computer type selection. Additionally, FogROS2 gains performance, timing, and additional improvements associated with ROS 2. In common robot applications, FogROS2 reduces SLAM latency by 50 %, reduces grasp planning time from 14 s to 1.2 s, and speeds up motion planning 45x. When compared to FogROS1, FogROS2 reduces network utilization by up to 3.8x, improves startup time by 63 %, and network round-trip latency by 97 % for images using video compression. The source code, examples, and documentation for FogROS2 are available at https: //github.com/BerkeleyAutomation/FogROS2, and is available through the official ROS 2 repository at https: //index.ros.org/p/fogros2/. I. I N T RO D U C T I O N It is difficult for the onboard computing resources of robots to keep up with advances in robot algorithms and new com- puting hardware. Cloud computing offers on-demand access to immense computing resources and new and power-hungry computing platforms, such as GPUs, TPUs, and FPGAs. Prior work [1] showed that using the cloud for intensive computing in robotics can be practical and cost-effective. However, gaining access to evolving cloud computing resources requires expertise with many new and emerging software packages, and experience handling data security and privacy. In prior work [2], we introduced FogROS (henceforth FogROS1), a framework that extends the Robot Operating System (ROS) (henceforth ROS 1) to enable quick access to the cloud. ∗Equal Contribution 1Department of Electrical Engineering and Computer Science AThe AUTOLab at UC Berkeley (automation.berkeley.edu). 2Department of Industrial Engineering and Operations Research 1,2University of California, Berkeley, CA, USA 3Robotics Institute, Carnegie Mellon University 4Acceleration Robotics, Ecuador 3, 1 I, Vitoria, ́Alava, Spain, 5System Security Group, Universit ̈at Klagenfurt, Universit ̈atsstr. 65-67 9020 Klagenfurt, Austria jeffi@cmu.edu, kych@berkeley.edu Robot FogROS2 Launcher wireguard (c) H.264 (a) Camera Node Robot Control Node K8s API Server Kubernetes Control Plane (b) wireguard load balancer (c) H.264 (a) SLAM Node (d) Grasp Planner Node (f) Virtual Machine 1 (GPU) Motion Planner Node (e) Foxglove (g) Virtual Machine 2 (multicore CPU) Infrastructure Networking component ROS 2 Nodes Virtual machine Compressed video frame DDS Communication Configuration http://10.0.0.26/ http Fig. 1: FogROS2 addresses several deficiencies found in FogROS1, including latency, usability, and automation. For example, transmitting images from a camera to the cloud can require a lot of bandwidth, thus increasing latency. (a) FogROS2 transparently compresses video and image streams using the popular H.264 compression standard. FogROS2 further improves upon FogROS1 by speeding up launch times, improving scalability, and increasing compatibility by (b) migrating to Kubernetes (K8s), (c) switching to UDP over Wireguard, and updating to the ROS 2 ecosystem. In an example application, (d) FogROS2 moves a simultaneous localization and mapping (SLAM), (e) motion planning, (f) and grasp planning nodes to the cloud, taking advantage of the GPU and high CPU core counts available there to speed up processing. (g) By integrating Foxglove, users are also able to monitor robots from a browser any where in the world. However, FogROS1 has limitations in latency, usability, and automation. In this paper, we introduce FogROS2 to reduce latency, improve usabillity, and automate additional components of launching robot code in the cloud, while extending to additional potential robot applications. Further- more, we rewrote FogROS2 from scratch to fully integrate with ROS 2 to benefit from improvements in networking, launch configurability, and its command line interface; and we added integration points to Foxglove [3] to enable remote monitoring from anywhere in the world. Latency, the time between when an event occurs and when the robot reacts to the event, is a critical factor in many 2023 IEEE International Conference on Robotics and Automation (ICRA 2023) May 29 - June 2, 2023. London, UK 979-8-3503-2365-8/23/$31.00 ©2023 IEEE 5493