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

Error when running markers.launch

asked 2018-08-05 20:02:09 -0500

hyonietta gravatar image

updated 2018-08-06 22:42:52 -0500

jayess gravatar image

OS : Ubuntu 14.04 LTS ROS : Indigo

I'm studying Stockroom_bot. (Book : Programming Robots with ROS, Ch.14) My source same the book's example.

I've just finished at go_to_bin.sh. So next step is 'markers.launch' There is an error when I run the markers.launch.

1. markers.launch - Error message is this:

[ WARN] [1533512740.109920017]: Command line arguments are deprecated. Consider using ROS parameters and remappings.
**[ INFO] [1533512740.112981476]: Subscribing to info topic
[ INFO] [1533512740.136521085]: AR tracker reconfigured: ENABLED 1.00 12.30 0.20 0.00
terminate called after throwing an instance of 'ros::InvalidNameException'
  what():  Character [0] is not valid as the first character in Graph Resource Name [0.8].  Valid characters are a-z, A-Z, / and in some cases ~.
           [ar_track_alvar-1] process has died [pid 13581, exit code -6, cmd /opt/ros/indigo/lib/ar_track_alvar/individualMarkersNoKinect 12.3 0.2   0.8 /head_camera/rgb/image_raw   /head_camera/rgb/camera_info /base_link __name:=ar_track_alvar __log:=/home/aaaabbbb/.ros/log/6bf17ba4-9909-11e8-ad84-645106a90f90/ar_track_alvar-1.log].
             log file: /home/aaaabbbb/.ros/log/6bf17ba4-9909-11e8-ad84-645106a90f90/ar_track_alvar-1*.log**

2. stockroom_bot.launch - error message is this

ERROR] [1533263314.110014050, 10.048000000]: Client [/ar_track_alvar] wants topic /head_camera/rgb/image_raw to have datatype/md5sum [sensor_msgs/CameraInfo/c9a58c1b0b154e0e6da7578cb991d214], but our version has [sensor_msgs/Image/060021388200f6f0f447d0fcd9c64743]. Dropping connection.

What is that means ? Why the ROS can't execute the markers.launch ? I don't know what I can do. And, ROS don't make the log file /home/...ar_track_alvar-1*.log

Please help me...

  1. This is my 'markers.launch' source

    <launch> <arg name="marker_size" default="12.3"/> <arg name="max_new_marker_error" default="0.2"/> <arg name="max_track_error" default="0.8"/> <arg name="cam_image_topic" default="/head_camera/rgb/image_raw"/> <arg name="cam_info_topic" default="/head_camera/rgb/camera_info"/> <arg name="output_frame" default="/base_link"/> <node name="ar_track_alvar" pkg="ar_track_alvar" type="individualMarkersNoKinect" respawn="false" output="screen" args="$(arg marker_size) $(arg max_new_marker_error) \ $(arg max_track_error) $(arg cam_image_topic) \ $(arg cam_info_topic) $(arg output_frame)"/> <arg name="tag_rot" default="0 0 0 0 0 -1.57"/> <arg name="tag_trans" default="0 -0.28 -0.1 0 0 0"/>

    <node pkg="tf" type="static_transform_publisher" name="ar_0_up" args="$(arg tag_rot) ar_marker_0 ar_0_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_1_up" args="$(arg tag_rot) ar_marker_1 ar_1_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_2_up" args="$(arg tag_rot) ar_marker_2 ar_2_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_3_up" args="$(arg tag_rot) ar_marker_3 ar_3_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_4_up" args="$(arg tag_rot) ar_marker_4 ar_4_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_5_up" args="$(arg tag_rot) ar_marker_5 ar_5_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_6_up" args="$(arg tag_rot) ar_marker_6 ar_6_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_7_up" args="$(arg tag_rot) ar_marker_7 ar_7_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_8_up" args="$(arg tag_rot) ar_marker_8 ar_8_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_9_up" args="$(arg tag_rot) ar_marker_9 ar_9_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_10_up" args="$(arg tag_rot) ar_marker_10 ar_10_up 100"/> <node pkg="tf" type="static_transform_publisher" name="ar_11_up" args="$(arg tag_rot) ar_marker_11 ar_11_up 100"/>

    <node pkg="tf" type="static_transform_publisher" name="item_0" args="$(arg tag_trans ...

(more)
edit retag flag offensive close merge delete

Comments

Can you post a copy of the 'markers.launch' file you're trying to use. There are actually two different errors described here, they seem to be something to do with missing/wrong topic names. But we'll need to see the launch file to be sure.

PeteBlackerThe3rd gravatar image PeteBlackerThe3rd  ( 2018-08-06 05:27:57 -0500 )edit

I added my 'markers.launch' source. I'm using the book's stockroom_bot source. Should I edit stockroom_bot package sources? Or I run wrong method?

hyonietta gravatar image hyonietta  ( 2018-08-06 19:07:49 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2018-09-06 10:04:07 -0500

ajonna gravatar image

I ran into the same problem while running markers.launch. The key being the error message stating a type mismatch in the topics. I believe it has something to do with the order of arguments while initializing the ar_track_alvar node.

To fix it, change

  <node name="ar_track_alvar" pkg="ar_track_alvar"
        type="individualMarkersNoKinect" respawn="false" output="screen" 
        args="$(arg marker_size) $(arg max_new_marker_error) \
              $(arg max_track_error) $(arg cam_image_topic)  \
              $(arg cam_info_topic) $(arg output_frame)" />

to

  <node name="ar_track_alvar" pkg="ar_track_alvar"
        type="individualMarkersNoKinect" respawn="false" output="screen"> 
        <param name="marker_size"   type="double" value="$(arg marker_size)"/>
        <param name="max_new_marker_error"  type="double" value="$(arg max_new_marker_error)"/>
        <param name="max_track_error"   type="double" value="$(arg max_track_error)"/>
        <param name="output_frame"  type="string" value="$(arg output_frame)"/>

        <remap from="camera_image" to="$(arg cam_image_topic)"/>
        <remap from="camera_info" to="$(arg cam_info_topic)"/>
  </node>

Using parameter names and remap makes sure that the arguments are parsed correctly.

edit flag offensive delete link more

Comments

Thank you! This problem would have sent me down the .launch file rabbit hole; at a time when I'm just trying to get a quick ROS overview.

cerebric gravatar image cerebric  ( 2020-01-12 19:58:54 -0500 )edit

Question Tools

2 followers

Stats

Asked: 2018-08-05 20:02:09 -0500

Seen: 501 times

Last updated: Aug 06 '18