1.启动gazebo
roslaunch turtlebot3_gazebo ORB_turtlebot.launch
2.把robot_state_publisher启动
cd
/home/s/catkin_ws/src/turtlebot3/turtlebot3_bringup/launch
roslaunch turtlebot3_remote.launch
3.启动move_base
roslaunch turtlebot3_navigation turtlebot3_navigation.launch map_file:=$HOME/map_1.yaml
4.启动odom_pub
先启动amcl_pub,在启动odom_listen
rosrun amcl_publisher amcl_publisher
rosrun odom_pub odom_listen
5.记录位姿,用以对比
rosbag record subset /amcl_pose /ground_truth
将bagfile转为txt
rostopic echo -b 2019 -p /amcl_pose >pose_1.txt
rostopic echo -b 2019 -p /ground_truth >gt_1.txt
6.启动ORB-SLAM
cd /home/s/ORB_SLAM2/Examples/ROS/ORB_SLAM2
./Stereo /home/s/ORB_SLAM2/Vocabulary/ORBvoc.txt /home/s/gazebo_zed.yaml false
7.启动ORB-ODOM
rosrun yolo_test9 yolo_test9 /home/s/catkin_ws/src/yolo_test9/Vocabulary/ORBvoc.txt /home/s/gazebo_zed.yaml false
8.三个路标点
PONT0
rostopic pub /move_base_simple/goal geometry_msgs/PoseStamped \
'{ header: { frame_id: "map" }, pose: { position: { x: 1, y: 0.17, z: 0 }, orientation: { x: 0, y: 0, z: -0.99, w: 0.016 } } }'
PONT1
rostopic pub /move_base_simple/goal geometry_msgs/PoseStamped \
'{ header: { frame_id: "map" }, pose: { position: { x: -2.0803, y: -4.042, z: 0 }, orientation: { x: 0, y: 0, z: -0.4826, w: 0.8758} } }'
PONT2
rostopic pub /move_base_simple/goal geometry_msgs/PoseStamped \
'{ header: { frame_id: "map" }, pose: { position: { x: 1.9896, y: -4.2494, z: 0 }, orientation: { x: 0, y: 0, z: 0.4319, w:0.9019 } } }'