Robotics Software Engineer Lab "SLAM"
$ sudo apt-get update
$ sudo apt-get upgrade -y
$ cd ..
$ source devel/setup.bash
$ rosdep -i install turtlebot_gazebo
$ rosdep -i install turtlebot_teleop
$ catkin_make
$ source devel/setup.bash
$ roslaunch my_robot world.launch
$ roslaunch turtlebot_teleop keyboard_teleop.launch
With the map_server you can load and save maps. Running map_server will generate the map.pgm and the map.yaml files.
$ rosrun map_server map_saver -f myMap
That’s because the gmapping parameters values used were the default values. In general, it’s essential to tune them in order to get a 100% accurate map. These parameters are all listed under the gmapping documentation, where you can look at them yourself. If you experiment with some of these parameter values, you should be able to get better maps. For example, you might try, reducing the angularUpdate and linearUpdate values so the map gets updated for smaller ranges of movements, reducing the x and y limits, which represent the initial map size, increasing the number of particles. You can try tweaking these parameters and/or any other parameter you think should be changed.