introlab / rtabmap

RTAB-Map library and standalone application
https://introlab.github.io/rtabmap
Other
2.78k stars 787 forks source link

Issue with publishing map frame: map frame does not exist #616

Open rjam92 opened 4 years ago

rjam92 commented 4 years ago

Hello,

When I try to use rtabmap with d435 and kobuki, I follow the instructions on the rtabmap tutorials for it. I have also setup a laaunch file

<launch>
    <!-- 
          NOTICE: Installation of rtabmap is required for using this launch file:
                  For installation type:
                        apt-get install ros-melodic-rtabmap-ros
    -->
    <arg name="serial_no"                 default=""/>
    <arg name="camera"                    default="camera"/>    
    <arg name="clip_distance"             default="-2"/>
    <arg name="use_rviz"                  default="true"/>
    <arg name="use_rtabmapviz"            default="false"/>

    <include file="$(find realsense2_camera)/launch/d435_without_model.launch">
            <arg name="serial_no"               value="$(arg serial_no)"/>
            <arg name="camera"                  value="$(arg camera)"/>
            <arg name="clip_distance"           value="$(arg clip_distance)"/>
            <arg name="align_depth"             value="true"/>    
    </include>

    <include file="$(find rtabmap_ros)/launch/rtabmap.launch">
            <arg name="rtabmap_args"       value="--delete_db_on_start"/>
            <arg name="depth_topic"        value="/$(arg camera)/aligned_depth_to_color/image_raw"/>
            <arg name="frame_id"           value="$(arg camera)_link"/>
            <arg name="rgb_topic"          value="/$(arg camera)/color/image_raw"/>
            <arg name="camera_info_topic"  value="/$(arg camera)/color/camera_info"/>
            <arg name="queue_size"         value="200"/>
            <arg name="rviz"               value="$(arg use_rviz)"/>
            <arg name="rtabmapviz"         value="$(arg use_rtabmapviz)"/>
        <arg name="approx_sync"        value="false"/>
            <arg name="visual_odometry"    value="true"/>
            <arg name="odom_topic"         value="/odom"/>
    </include>
</launch>

When I use the following arguments in the launch file I get the rviz no map found error.

<arg name="visual_odometry"    value="true"/>
            <arg name="odom_topic"         value="/odom"/>

What could be the reason for this?

matlabbe commented 3 years ago

Look if there are warnings on the terminal, rtabmap should publish a status at 1 Hz if it is running.