0
$\begingroup$

Rosanswers logo

I am trying to set up a pan/tilt base with two Dynamixel servos and I would like to use joint_state_publisher with robot_state_publisher to publish the transforms (and maybe even control the joints via joint_state_publisher's GUI).

The problem is that the dynamixel_controllers stack publishes dynamixel_msgs/JointState messages while joint_state_publisher expects sensor_msgs/JointState messages, and the two are incompatible.

My Google-Fu failed to turn up any existing conversion between dynamixel_msgs and sensor_msgs JointState messages - but I have seen out there Dynamixel-based robots visualized in Rviz. Are my only options to publish my own transforms with the Dynamixels or write my own conversion between the two different JointState messages? Maybe someone can suggest an existing open-source solution?


Originally posted by autonomy on ROS Answers with karma: 435 on 2013-10-15

Post score: 1

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

After a lot of digging, I was lead to a solution by reading this tutorial: http://www.pirobot.org/blog/0023/

What's needed is the file dynamixel_joint_state_publisher.py, a copy can be found here. This file replaces joint_state_publisher and will connect your dynamixels to robot_state_publisher when configured correctly.

For that to happen, you will need a correct URDF model of your joints. More importantly, you will need to set the dynamixels param (read by the dynamixel_joint_publisher script) to a list of your joint names like this:

<rosparam param="dynamixels">[joint1 joint2 joint3]</rosparam>

These joint names have to correspond to what's in the URDF file and your dynamixel launch files. Then, you will have to make sure the namespaces are compatible. You won't need to publish static transforms if your URDF model correctly specifies the links and the joints.


Originally posted by autonomy with karma: 435 on 2013-10-22

This answer was ACCEPTED on the original site

Post score: 0


Original comments

Comment by Abdu on 2017-10-21:
@autonomy I have difficulty to move my two servos see here I checked the visual tracking part, but I failed, I am using arbotix so nothing to do with dynamixel_joint_stat_publisher.py right ??

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.