Mastering ROS for Robotics Programming
eBook - ePub

Mastering ROS for Robotics Programming

  1. 594 pages
  2. English
  3. ePUB (mobile friendly)
  4. Available on iOS & Android
eBook - ePub

Mastering ROS for Robotics Programming

About this book

Design, build, and simulate complex robots using the Robot Operating SystemKey Features• Become proficient in ROS programming using C++ with this comprehensive guide• Build complex robot applications using the ROS Noetic Ninjemys release to interface robot manipulators with mobile robots• Learn to interact with aerial robots using ROSBook DescriptionThe Robot Operating System (ROS) is a software framework used for programming complex robots. ROS enables you to develop software for building complex robots without writing code from scratch, saving valuable development time. Mastering ROS for Robotics Programming provides complete coverage of the advanced concepts using easy-to-understand, practical examples and step-by-step explanations of essential concepts that you can apply to your ROS robotics projects. The book begins by helping you get to grips with the basic concepts necessary for programming robots with ROS. You'll then discover how to develop a robot simulation, as well as an actual robot, and understand how to apply high-level capabilities such as navigation and manipulation from scratch. As you advance, you'll learn how to create ROS controllers and plugins and explore ROS's industrial applications and how it interacts with aerial robots. Finally, you'll discover best practices and methods for working with ROS efficiently. By the end of this ROS book, you'll have learned how to create various applications in ROS and build your first ROS robot.What you will learn• Create a robot model with a 7-DOF robotic arm and a differential wheeled mobile robot• Work with Gazebo, CoppeliaSim, and Webots robotic simulators• Implement autonomous navigation in differential drive robots using SLAM and AMCL packages• Interact with and simulate aerial robots using ROS• Explore ROS pluginlib, ROS nodelets, and Gazebo plugins• Interface I/O boards such as Arduino, robot sensors, and high-end actuators• Simulate and perform motion planning for an ABB robot and a universal arm using ROS-Industrial• Work with the motion planning features of a 7-DOF arm using MoveItWho this book is forIf you are a robotics graduate, robotics researcher, or robotics software professional looking to work with ROS, this book is for you. Programmers who want to explore the advanced features of ROS will also find this book useful. Basic knowledge of ROS, GNU/Linux, and C++ programming concepts is necessary to get started with this book.

Frequently asked questions

Yes, you can cancel anytime from the Subscription tab in your account settings on the Perlego website. Your subscription will stay active until the end of your current billing period. Learn how to cancel your subscription.
No, books cannot be downloaded as external files, such as PDFs, for use outside of Perlego. However, you can download books within the Perlego app for offline reading on mobile or tablet. Learn more here.
Perlego offers two plans: Essential and Complete
  • Essential is ideal for learners and professionals who enjoy exploring a wide range of subjects. Access the Essential Library with 800,000+ trusted titles and best-sellers across business, personal growth, and the humanities. Includes unlimited reading time and Standard Read Aloud voice.
  • Complete: Perfect for advanced learners and researchers needing full, unrestricted access. Unlock 1.4M+ books across hundreds of subjects, including academic and specialized titles. The Complete Plan also includes advanced features like Premium Read Aloud and Research Assistant.
Both plans are available with monthly, semester, or annual billing cycles.
We are an online textbook subscription service, where you can get access to an entire online library for less than the price of a single book per month. With over 1 million books across 1000+ topics, we’ve got you covered! Learn more here.
Look out for the read-aloud symbol on your next book to see if you can listen to it. The read-aloud tool reads text aloud for you, highlighting the text as it is being read. You can pause it, speed it up and slow it down. Learn more here.
Yes! You can use the Perlego app on both iOS or Android devices to read anytime, anywhere — even offline. Perfect for commutes or when you’re on the go.
Please note we cannot support devices running on iOS 13 and Android 7 or earlier. Learn more about using the app.
Yes, you can access Mastering ROS for Robotics Programming by Lentin Joseph,Jonathan Cacace in PDF and/or ePUB format, as well as other popular books in Ciencia de la computación & Hardware. We have over one million books available in our catalogue for you to explore.

Information

Section 1 – ROS Programming Essentials

This section discusses the fundamental concepts of ROS in detail. You will get a clear and crisp idea of ROS concepts after this section. These concepts are required to be understood in order to work on the chapters covering advanced concepts of ROS.
This section comprises the following chapters:
  • Chapter 1, Introduction to ROS
  • Chapter 2, Getting Started with ROS Programming

Chapter 1: Introduction to ROS

The first two chapters of this book will introduce basic ROS concepts and the ROS package management system in order to approach ROS programming. In this first chapter, we will go through ROS concepts such as the ROS master, the ROS nodes, the ROS parameter server, and ROS messages and services, all while discussing what we need to install ROS and how to get started with the ROS master.
In this chapter, we will cover the following topics:
  • Why should we learn ROS?
  • Understanding the ROS filesystem level.
  • Understanding ROS computation graph level.
  • ROS community level.

Technical requirements

To follow this chapter, the only thing you need is a standard computer running Ubuntu 20.04 LTS or a Debian 10 GNU/Linux distribution.

Why should we use ROS?

Robot Operating System (ROS) is a flexible framework that provides various tools and libraries for writing robotic software. It offers several powerful features to help developers in tasks such as message passing, distributed computing, code reusing, and implementing state-of-the-art algorithms for robotic applications. The ROS project was started in 2007 by Morgan Quigley and its development continued at Willow Garage, a robotics research lab for developing hardware and open source software for robots. The goal of ROS was to establish a standard way to program robots while offering off-the-shelf software components that can be easily integrated with custom robotic applications. There are many reasons to choose ROS as a programming framework, and some of them are as follows:
  • High-end capabilities: ROS comes with ready-to-use functionalities. For example, the Simultaneous Localization and Mapping (SLAM) and Adaptive Monte Carlo Localization (AMCL) packages in ROS can be used for having autonomous navigation in mobile robots, while the MoveIt package can be used for motion planning for robot manipulators. These capabilities can directly be used in our robot software without any hassle. In several cases, these packages are enough for having core robotics tasks on different platforms. Also, these capabilities are highly configurable; we can fine-tune each one using various parameters.
  • Tons of tools: The ROS ecosystem is packed with tons of tools for debugging, visualizing, and having a simulation. The tools, such as rqt_gui, RViz, and Gazebo, are some of the strongest open source tools for debugging, visualization, and simulation. A software framework that has this many tools is very rare.
  • Support for high-end sensors and actuators: ROS allows us to use different device drivers and the interface packages of various sensors and actuators in robotics. Such high-end sensors include 3D LIDAR, laser scanners, depth sensors, actuators, and more. We can interface these components with ROS without any hassle.
  • Inter-platform operability: The ROS message-passing middleware allows communication between different programs. In ROS, this middleware is known as nodes. These nodes can be programmed in any language that has ROS client libraries. We can write high-haveance nodes in C++ or C and other nodes in Python or Java.
  • Modularity: One of the issues that can occur in most standalone robotic applications is that if any of the threads of the main code crash, the entire robot application can stop. In ROS, the situation is different; we are writing different nodes for each process, and if one node crashes, the system can still work.
  • Concurrent resource handling: Handling a hardware resource via more than two processes is always a headache. Imagine that we want to process an image from a camera for face detection and motion detection; we can either write the code as a single entity that can do both, or we can write a single-threaded piece of code for concurrency. If we want to add more than two features to threads, the application behavior will become complex and difficult to debug. But in ROS, we can access devices using ROS topics from the ROS drivers. Any number of ROS nodes can subscribe to the image message from the ROS camera driver, and each node can have different functionalities. This can reduce the complexity in computation and also increase the debugging ability of the entire system.
The ROS community is growing very fast, and there are many users and developers worldwide. Most high-end robotics companies are now porting their software to ROS. This trend is also visible in industrial robotics, in which companies are switching from proprietary robotic applications to ROS.
Now that we know why it is convenient to study ROS, we can start introducing its core concepts. There are mainly three levels in ROS: the filesystem level, the computation graph level, and the community level. We will briefly have a look at each level.

Understanding the ROS filesystem level

ROS is more than a development framework. We can refer to ROS as a meta-OS, since it offers not only tools and libraries but even OS-like functions, such as hardware abstraction, package management, and a developer toolchain. Like a real operating system, ROS files are organized on the hard disk in a particular manner, as depicted in the following diagram:
Figure 1.1 – ROS filesystem level
Figure 1.1 – ROS filesystem level
Here are the explanations for each block in the filesystem:
  • Packages: The ROS packages are a central element of the ROS softwar...

Table of contents

  1. Mastering ROS for Robotics Programming Third Edition
  2. Contributors
  3. Preface
  4. Section 1 – ROS Programming Essentials
  5. Chapter 1: Introduction to ROS
  6. Chapter 2: Getting Started with ROS Programming
  7. Section 2 – ROS Robot Simulation
  8. Chapter 3: Working with ROS for 3D Modeling
  9. Chapter 4: Simulating Robots Using ROS and Gazebo
  10. Chapter 5: Simulating Robots Using ROS, CoppeliaSim, and Webots
  11. Chapter 6: Using the ROS MoveIt! and Navigation Stack
  12. Chapter 7: Exploring the Advanced Capabilities of ROS MoveIt!
  13. Chapter 8: ROS for Aerial Robots
  14. Section 3 – ROS Robot Hardware Prototyping
  15. Chapter 9: Interfacing I/O Board Sensors and Actuators to ROS
  16. Chapter 10: Programming Vision Sensors Using ROS, OpenCV, and PCL
  17. Chapter 11: Building and Interfacing Differential Drive Mobile Robot Hardware in ROS
  18. Section 4 – Advanced ROS Programming
  19. Chapter 12: Working with pluginlib, nodelets, and Gazebo Plugins
  20. Chapter 13: Writing ROS Controllers and Visualization Plugins
  21. Chapter 14: Using ROS in MATLAB and Simulink
  22. Chapter 15: ROS for Industrial Robots
  23. Chapter 16: Troubleshooting and Best Practices in ROS
  24. Other Books You May Enjoy