turtlebot3 how to do slam without teleop

asked 2020-01-04 10:59:55 -0500

sarim.mehdi.550 gravatar image

Hello. I spawned my ROS robot on the map using:

roslaunch turtlebot3_gazebo turtlebot3_world.launch

Then I started SLAM using:

roslaunch turtlebot3_slam turtlebot3_slam.launch slam_methods:=gmapping

Now, I want to move my robot using code and not teleop. I am using the following code: http://wiki.ros.org/navigation/Tutori...

However, when I execute the file, the robot doesn't move. This means that the robot subscribes to some unknown topic. I don't know the name of this topic and I cannot understand how to send goals to my robot from code. I decided to get a list of active rostopics:

/clicked_point
/clock
/cmd_vel
/gazebo/link_states
/gazebo/model_states
/gazebo/parameter_descriptions
/gazebo/parameter_updates
/gazebo/set_link_state
/gazebo/set_model_state
/gazebo_gui/parameter_descriptions
/gazebo_gui/parameter_updates
/imu
/initialpose
/joint_states
/map
/map_metadata
/map_updates
/move_base_simple/goal
/odom
/rosout
/rosout_agg
/scan
/tf
/tf_static
/turtlebot3_slam_gmapping/entropy

Then I decided to check whether my robot subscribes to move_base_simple:

Type: geometry_msgs/PoseStamped

Publishers: 
 * /rviz (http://sarim-VirtualBox:38285/)

Subscribers: None

So, how do I move my robot then? Furthermore, I am unable to move robot in rviz by setting the nav_goal

edit retag flag offensive close merge delete

Comments

Looks like you are missing the move_base node, try

roslaunch turtlebot3_navigation move_base.launch
Humpelstilzchen gravatar image Humpelstilzchen  ( 2020-01-06 07:33:29 -0500 )edit