Select the corresponding ros version according to the Ubuntu system. For the corresponding relationship, please refer to [1. ROS Introduction]-[1.5. Release Version] to select.This course takes the installation of ROS-Noetic on Ubuntu20.04 as an example to explain how to install ros.
xxxxxxxxxx
#Raspberry Pi 5 master control, ROS tutorials are all used in the DOCKER container, just follow the ROS/07 and docker usage tutorials.
#ubuntu23.10 has not updated ROS yet. The host machine cannot install the ROS environment for the time being. Waiting for subsequent updates...
Terminal input,
sudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" > /etc/apt/sources.list.d/ros-latest.list'
Terminal input,
xxxxxxxxxx
sudo apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654
Terminal input,
xxxxxxxxxx
sudo apt update
What is installed here is the basic desktop version, terminal input,
xxxxxxxxxx
sudo apt install ros-noetic-desktop -y
Add the path of ROS to the environment variable so that when you open the terminal in the future, you can find the running environment of ROS and enter it in the terminal.
xxxxxxxxxx
echo "source /opt/ros/noetic/setup.bash" >> ~/.bashrc
Then reopen the terminal or source to refresh the environment variables, and enter in the terminal,
xxxxxxxxxx
source ~/.bashrc
Terminal input,
xxxxxxxxxx
roscore
If the following screen appears, the installation can be successful.