sudo apt install python3-colcon-common-extensions
安装cartographer建图
sudo apt install ros-humble-cartographer
sudo apt install ros-humble-cartographer-ros
sudo apt install ros-humble-navigation2
sudo apt install ros-humble-nav2-bringup
sudo apt install python3-vcstool
sudo apt install ros-humble-gazebo-ros*
步骤:
安装git
sudo apt install git
下载编译
mkdir -p ~/tb3_ws/src
cd ~/tb3_ws
#humble版本
wget https://raw.githubusercontent.com/ROBOTIS-GIT/turtlebot3/humble-devel/turtlebot3.repos
vcs import src < turtlebot3.repos
colcon build --symlink-install
编译成功
编译问题
删掉出错不影响使用然后编译就通过了
添加环境变量
echo 'source ~/tb3_ws/install/setup.bash' >> ~/.bashrc
echo 'export ROS_DOMAIN_ID=30 #TURTLEBOT3' >> ~/.bashrc
source ~/.bashrc
ros2与turtlebot3仿真教程-启动gazebo不同环境