[ros-users] two robot_state_publishers?

Wim Meeussen meeussen at willowgarage.com
Mon Oct 18 18:39:55 UTC 2010


Ben,

Are you saying that the second robot state publisher does not connect
to the 'sim_joint_states' topic? If that's the case, try to run
'rosnode info sim_state_publisher' and 'roswtf' to see what's going
on.  Are you publishing the joint states periodically or just once? If
you publish only once, it is possible that the nodes are not connected
yet when you send that data, and your data will get lost in that case.

Wim



On Fri, Oct 8, 2010 at 9:23 AM, Axelrod, Benjamin <baxelrod at irobot.com> wrote:
> I am trying to run two robot_state_publisher nodes in parallel.  My
> publications do not seem to be getting to the second one.  Here is some
> info:
>
>
>
> Here is a part of my launch file:
>
>
>
>   <param name="robot_description" textfile="$(find foo)/bar.urdf" />
>
>
>
>   <node name="robot_state_publisher" pkg="robot_state_publisher"
> type="state_publisher" output="screen" >
>
>     <param name="tf_prefix" value="robot" />
>
>   </node>
>
>
>
>   <node name="sim_state_publisher" pkg="robot_state_publisher"
> type="state_publisher" output="screen" >
>
>     <remap from="joint_states" to="sim_joint_states" />
>
>     <param name="tf_prefix" value="sim" />
>
>   </node>
>
>
>
> And here are my publishers:
>
>     joint_pub_ = handle_.advertise<sensor_msgs::JointState>("/joint_states",
> 1);
>
>     sim_joint_pub_ =
> handle_.advertise<sensor_msgs::JointState>("/sim_joint_states", 1);
>
>     …
>
>     joint_pub_.publish(joint_state_);
>
>     sim_joint_pub_.publish(sim_joint_state_);
>
>
>
> In rxgraph, I don’t see any connections going into the second
> robot_state_publisher (named sim_state_publisher).  Am I missing something?
> I am using Boxturtle, are there some features listed in the wiki that aren’t
> in this version?
>
>
>
> Thanks,
>
> -Ben
>
>
>
>
>
> Ben Axelrod
>
> Research Scientist
>
> iRobot Corporation
>
> 8 Crosby Drive, Mail Stop 8-1
>
> Bedford, MA 01730
>
> (781) 430-3315 (Tel)
>
> (781) 960-2628 (Fax)
>
> baxelrod at irobot.com
>
>
>
> _______________________________________________
> ros-users mailing list
> ros-users at code.ros.org
> https://code.ros.org/mailman/listinfo/ros-users
>
>



-- 
--
Wim Meeussen
Willow Garage Inc.
<http://www.willowgarage.com)



More information about the ros-users mailing list