how to edit gmapping.launch.xml?
I am using turtlebot with astra sensor on ros indigo. I am having issues with creating an accurate map. it does not matter if i use it with simulation only or also connect with real turtlebot I keep getting the same error messages during creating map process. *"Scan Matching Failed, using odometry, likelihood = some number"*
I am not getting any help from anywhere. I have tried to update gmapping.launch.xml but it is read-only, can you help me that how to update parameters in this file. here is my initial configuration when i run gmapping.
... logging to /home/turtlebot/.ros/log/e6e79614-2232-11ea-a1e8-802bf9015fcb/roslaunch-turtlebot-Inspiron-3185-3393.log Checking log directory for disk usage. This may take a while. Press Ctrl-C to interrupt Done checking log file disk usage. Usage is <1GB.
started roslaunch server http://localhost:39887/
SUMMARY PARAMETERS * /rosdistro: indigo * /rosversion: 1.11.21 * /slamgmapping/angularUpdate: 0.436 * /slamgmapping/astep: 0.05 * /slamgmapping/baseframe: basefootprint * /slamgmapping/delta: 0.05 * /slamgmapping/iterations: 5 * /slamgmapping/kernelSize: 1 * /slamgmapping/lasamplerange: 0.005 * /slamgmapping/lasamplestep: 0.005 * /slamgmapping/linearUpdate: 0.5 * /slamgmapping/llsamplerange: 0.01 * /slamgmapping/llsamplestep: 0.01 * /slamgmapping/lsigma: 0.075 * /slamgmapping/lskip: 0 * /slamgmapping/lstep: 0.05 * /slamgmapping/mapupdateinterval: 5.0 * /slamgmapping/maxRange: 8.0 * /slamgmapping/maxUrange: 6.0 * /slamgmapping/minimumScore: 200 * /slamgmapping/odomframe: odom * /slamgmapping/ogain: 3.0 * /slamgmapping/particles: 80 * /slamgmapping/resampleThreshold: 0.5 * /slamgmapping/sigma: 0.05 * /slamgmapping/srr: 0.01 * /slamgmapping/srt: 0.02 * /slamgmapping/str: 0.01 * /slamgmapping/stt: 0.02 * /slamgmapping/temporalUpdate: -1.0 * /slamgmapping/xmax: 1.0 * /slamgmapping/xmin: -1.0 * /slamgmapping/ymax: 1.0 * /slam_gmapping/ymin: -1.0
NODES / slamgmapping (gmapping/slamgmapping)
ROSMASTERURI=http://localhost:11311
core service [/rosout] found process[slamgmapping-1]: started with pid [3415] -maxUrange 6 -maxUrange 8 -sigma 0.05 -kernelSize 1 -lstep 0.05 -lobsGain 3 -astep 0.05 -srr 0.01 -srt 0.02 -str 0.01 -stt 0.02 -linearUpdate 0.5 -angularUpdate 0.436 -resampleThreshold 0.5 -xmin -1 -xmax 1 -ymin -1 -ymax 1 -delta 0.05 -particles 80 update frame 0 update ld=0 ad=0 Laser Pose= -0.0866988 0.048044 -0.00490948 mcount 0 Registering First Scan
Asked by noor on 2019-12-19 06:09:15 UTC
Answers
I would advise creating your own package containing the launch files you need. You can copy the gmapping.launch.xml
file into your own package and include it from your own package instead of the original location.
Change sth like this <include file="$(find ORIGINAL_PACKAGE)/launch/includes/gmapping.launch.xml"/>
into this <include file="$(find YOUR_PACKAGE)/launch/includes/gmapping.launch.xml"/>
Then you can edit the file in your own package and also keep track of the required configuration.
See this for best practice on launch files: https://wiki.ros.org/ROS/Tutorials/Roslaunch%20tips%20for%20larger%20projects
Asked by ct2034 on 2019-12-19 13:37:37 UTC
Comments
Thanks a lot, i ll give it a try, and does it mean that i should create all packages of turtlebot_navigation myself. as all are ready only. and they have their own hierarchy. if i need to update gmapping file name in gampping demo .launch which is again a read only resource.
second I am still confused about how to identify the suitable values for launch file's different parameters. because my main problem is that i could not get an accurate map and get overlapping shapes in map using default gmapping.launch.xml.
gampping launch has a number of parameters. such as
odom_frame, map_update_interval maxUrange maxRange sigma, kernelSize angularUpdate angularUpdate angularUpdate delta etc
Asked by noor on 2019-12-20 03:28:09 UTC
No, you don't need to create everything yourself. Just one package with launch files. With the include tag, mentioned above you can then also include launch files from the original turtlebot packages. Only if you want to change something in the file, you have to create your one version and include that one, instead.
In terms of parameters, I would always start with the ones defined in the standard launch files and try to changes them from there. Often in ROS, parameters have also standard values that are used, when they are not defined in any launch file. You could also see what they are and try them.
Asked by ct2034 on 2019-12-20 05:27:04 UTC
Comments
Can you please clarify what you are trying to do, what you expect to happen and what happens instead? And please improve the formatting of your question
Asked by ct2034 on 2019-12-19 07:05:39 UTC
I am trying to create a map using roslaunch turtlebot_gazebo gmapping_demo.launch but generated map gives incorrect overlapping shapes and constantly gives error messages like "scan matching failed using odometry"
Asked by noor on 2019-12-19 07:30:23 UTC