TB3+X52入门(ROS2)教程-7.Gazebo仿真
按照以下说明使用 Gazebo 模拟 TurtleBot3 操作。
安装模拟包
安装用于 TurtleBot3 Manipulation Gazebo 模拟的软件包。
[远程 PC]
cd ~/turtlebot3_ws/src/
git clone -b humble https://ghfast.top/https://github.com/ROBOTIS-GIT/turtlebot3_simulations.git
cd ~/turtlebot3_ws && colcon build --symlink-install
如何运行 Gazebo
使用以下命令在 Gazebo 世界中启动带有 OpenMANIPULATOR-X 的 TurtleBot3。
[远程 PC]
ros2 launch turtlebot3_manipulation_gazebo gazebo.launch.py


提示
为了使用 RViz 运行,请附加start_rviz如下参数。
[远程 PC]
ros2 launch turtlebot3_manipulation_gazebo gazebo.launch.py start_rviz:=true
要在 Gazebo 模拟器中控制 TurtleBot3,必须先启动 MoveIt 的伺服服务器节点。
[远程 PC]
ros2 launch turtlebot3_manipulation_moveit_config servo.launch.py
启动键盘遥控节点。
[远程PC]
ros2 run turtlebot3_manipulation_teleop turtlebot3_manipulation_teleop
提示
以下键用于控制 TurtleBot3。
Use o|k|l|; keys to move turtlebot base and use 'space' key to stop the base
Use s|x|z|c|a|d|f|v keys to Cartesian jog
Use 1|2|3|4|q|w|e|r keys to joint jog.
'ESC' to quit.