Jianglan Wei | Carnegie Mellon Robotics Institute
I studied ROS 2 for my Autonomous Systems project at Huazhong University of Science and Technology:
This chapter is adapted from the ROS 2 Tutorials: CLI tools:
Beginner: CLI tools — ROS 2 Documentation: Kilted documentation
Notes:
Install ROS 2 here. The distribution used in this note is “ROS 2 Kilted Kaiju” (Optimized for Ubuntu 24.04).
ROS 2 is installed in a protected system directory. To make ROS commands available in the terminal, source the setup files in every new terminal window:
source /opt/ros/kilted/setup.bash # for ROS 2 Kilted on UbuntuOr append it to the shell’s startup script (
~/.bashrc).
Each node in ROS should be responsible for a single, modular purpose, e.g. a sensor node that reads data from a laser scanner, or a motor node that sends commands to the wheel motor. Each node can send and receive data from other nodes via topics, services, actions, or parameters. A full robotics system is comprised of many nodes working in concert.