一路遇好人 发表于 2023-6-5 17:05:29

ubuntu20.4安装配置ros系统(noetic)

不同ubuntu版本对应的ros版本名称
ubuntu版本ros1版本ros2版本16.04kineticardent18.04melodicdashing20.04noeticfoxy1、打开软件与更新,切换ubuntu软件源(国内阿里云)

2、打开终端,添加ros软件源(中科大镜像站)
sudo sh -c '. /etc/lsb-release && echo "deb http://mirrors.ustc.edu.cn/ros/ubuntu/ $DISTRIB_CODENAME main" > /etc/apt/sources.list.d/ros-latest.list'3、配置公钥
sudo apt-key adv --keyserver 'hkp://keyserver.ubuntu.com:80' --recv-key C1CF6E31E6BADE8868B172B4F42ED6FBAB17C654 
4、系统软件源
sudo apt update
5、安装ros系统(ps:命令中的noetic根据自己的ros版本名更换)
sudo apt install ros-noetic-desktop-full
6、初始化rosdep
sudo rosdep init提示找不到rosdep命令

解决方法
sudo apt install python3-rosdep2
 再次初始化rosdep
sudo rosdep init提示不能从默认的来源列表下载

解决方法
sudo gedit /etc/hosts等自动打开hosts文件后,在文件中添加以下内容,然后保存并退出
199.232.28.133 raw.githubusercontent.com
再次初始化rosdep
sudo rosdep init
7、更新rosdep
rosdep update
8、设置环境变量(ps:命令中的noetic根据自己的ros版本名更换)
echo "source /opt/ros/noetic/setup.bash" >> ~/.bashrc9、使环境变量生效
source ~/.bashrc
10、安装rosinstall
sudo apt install python3-rosinstall python3-rosinstall-generator python3-wstool build-essential
 11、安装python3-roslaunch
sudo apt install python3-roslaunch
12、启动ros系统
roscore
提示Usage is
页: [1]
查看完整版本: ubuntu20.4安装配置ros系统(noetic)