Course Hive
Search

Welcome

Sign in or create your account

Continue with Google
or
Mobile Robot Position Control in ROS2 Jazzy and C++ From Scratch - Step-by -Step Tutorial
Play lesson

ROS2 Tutorials - Mobile Robot Position Control in ROS2 Jazzy and C++ From Scratch - Step-by -Step Tutorial

5.0 (0)
9 learners

What you'll learn

Content missing – cannot generate learning outcomes
Content missing – cannot generate learning outcomes
Content missing – cannot generate learning outcomes
Content missing – cannot generate learning outcomes

This course includes

  • 47.5 hours of video
  • Certificate of completion
  • Access on mobile and TV

Summary

Full Transcript

#ros2jazzy #ros2 #robotics #controltheory #mechatronics Manuals and code files are here: https://ko-fi.com/s/0ed848d35f In this Robot Operating System 2 (ROS2) Jazzy tutorial, we explain how to write a C++ program and a ROS2 package from scratch that demonstrate how to implement all the components of a controller for controlling the position of a mobile robot in 2D space. In particular, we explain how to implement a C++ class that embeds: 1) A ROS2 subscriber object for receiving sensor information, and a ROS2 publisher object for sending the control commands to the robot. 2) A callback function for reading sensor information. The sensor information consists of the current position, orientation, and velocity of the robot. This callback function is activated every time there is sensor data on a ROS2 sensor topic. This callback functions adds the feedback loop to the system. 3) A timer object for ensuring that a controller function is called at fixed time steps. This function is important for enforcing the desired control frequency. 4) The controller function which implements the control method. In this tutorial, we implement a proportional position controller. However, everything explained in this tutorial can easily be generalized to the case of implementing feedback control algorithms, such as PID, LQR, and other control algorithms. As a proof of principle and as a model of a 2D mobile robot we use a Turtlesim simulation. The Turtlesim simulation simulates a 2D mobile robot. It enables us to quickly test and prototype control algorithms before proceeding with the next step and testing algorithms in a Gazebo simulation. The figure below shows a Turtlesim simulation and the trajectory that the robot describes. The turtle is located in the desired position (final position), and the trajectory starts from the initial position.

Course Hive

Continue this lesson in the app

Install CourseHive on Android or iOS to keep learning while you move.

Related Courses

FAQs

Course Hive
Download CourseHive
Keep learning anywhere