ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question

Gmapping not working, errors with gmapping services.

asked 2017-06-14 13:46:21 -0600

EverestT gravatar image

Hello all, I am a new guy to ROS(Indigo) and dealing with a robot and SLAM which will use gmapping. However I got some error when launch the nodes (errors from roswtf):

Found 3 error(s).

ERROR Could not contact the following nodes: * /slam_gmapping

ERROR The following nodes should be connected but aren't: * /slam_gmapping->/rviz (/tf) * /slam_gmapping->/rviz (/map) * /r2000_node->/slam_gmapping (/r2000_node/scan) * /map_nav_broadcaster_pepperl->/slam_gmapping (/tf) * /qfeel_serial->/slam_gmapping (/tf) * /slam_gmapping->/slam_gmapping (/tf)

ERROR Errors connecting to the following services: * service [/slam_gmapping/get_loggers] appears to be malfunctioning: Unable to communicate with service [/slam_gmapping/get_loggers], address [rosrpc://jtian-Latitude-E6520:33331] * service [/slam_gmapping/set_logger_level] appears to be malfunctioning: Unable to communicate with service [/slam_gmapping/set_logger_level], address [rosrpc://jtian-Latitude-E6520:33331] * service [/dynamic_map] appears to be malfunctioning: Unable to communicate with service [/dynamic_map], address [rosrpc://jtian-Latitude-E6520:33331]

This is my gmapping.launch file:

<?xml version="1.0"?>

    <include file="$(find pepperl_fuchs_r2000)/launch/r2000.launch"> 
      <arg name="frame_id" value="/scan"/>
      <arg name="scanner_ip" value=""/>
      <arg name="scan_frequency" value="35"/>
      <arg name="samples_per_scan" value="3600"/>

    <include file="$(find ybot)/launch/ybot.launch"/>
    <node pkg="tf" type="static_transform_publisher" name="map_nav_broadcaster_pepperl" args="0.20 0 0.2 0 0 0  base_link scan 100" />

    <include file="$(find ybot)/launch/includes/gmapping.launch.xml">

    <node name="rviz" pkg="rviz" type="rviz" args="-d $(find ybot)/param/navigation.rviz"/>


And the gmapping.launch.xml:

<!-- -->
  <arg name="scan_topic" default="/r2000_node/scan" />

  <node pkg="gmapping" type="slam_gmapping" name="slam_gmapping" output="screen">
    <param name="base_frame" value="base_link"/>
    <param name="odom_frame" value="odom"/>
    <param name="map_update_interval" value="5.0"/>
    <param name="maxUrange" value="6.0"/>
    <param name="maxRange" value="8.0"/>
    <param name="sigma" value="0.05"/>
    <param name="kernelSize" value="1"/>
    <param name="lstep" value="0.05"/>
    <param name="astep" value="0.05"/>
    <param name="iterations" value="5"/>
    <param name="lsigma" value="0.075"/>
    <param name="ogain" value="3.0"/>
    <param name="lskip" value="0"/>
    <param name="srr" value="0.01"/>
    <param name="srt" value="0.02"/>
    <param name="str" value="0.01"/>
    <param name="stt" value="0.02"/>
    <param name="linearUpdate" value="0.5"/>
    <param name="angularUpdate" value="0.436"/>
    <param name="temporalUpdate" value="-1.0"/>
    <param name="resampleThreshold" value="0.5"/>
    <param name="particles" value="80"/>

    <param name="xmin" value="-50.0"/>
    <param name="ymin" value="-50.0"/>
    <param name="xmax" value="50.0"/>
    <param name="ymax" value="50.0"/>

    <!-- Increase resolution -->
    <param name="delta" value="0.01"/>
    <param name="llsamplerange" value="0.01"/>
    <param name="llsamplestep" value="0.01"/>
    <param name="lasamplerange" value="0.005"/>
    <param name="lasamplestep" value="0.005"/>
    <remap from="scan" to="/r2000_node/scan"/>

It seems there're some issue with the gmapping services. I intstalled the gmapping package via command

apt-get install ros-indigo-slam-gmapping

However after the installation is done, I can't find the package by

rospack find ros-indigo-slam-gmapping

It will prompt a message which saying : [rospack] Error: package 'ros-indigo-slam-gmapping' not found I suspect if the installation of gmapping package was ... (more)

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2017-06-14 18:40:10 -0600

Hi there, rospack tool uses the "ROS package name" to look for packages not the "Debian package name" (it is confusing, I know).

ros-indigo-slam-gmapping is the name of a debian package that contains the ROS packages gmapping and openslam_gmapping

So the correct way to check if the gmapping is present would be: rospack find gmapping

I assume that you are using Ubuntu 14.04, is that correct? Could you attach the console output when you execute your launch file?

edit flag offensive delete link more

Question Tools

1 follower


Asked: 2017-06-14 13:46:21 -0600

Seen: 843 times

Last updated: Jun 14 '17