0
$\begingroup$

Rosanswers logo

I am trying the tutorial with turtlesim and joystick on ROS electric, and Ubuntu 11.4. I keep getting [ERROR] [1324135517.676376697]: Client [/teleop] wants topic /joy to have datatype/md5sum [joy/Joy/e3ef016fcdf22397038b36036c66f7c8], but our version has [sensor_msgs/Joy/5a9ea5f83505693b71e785041e67a8bb]. Dropping connection. I know that the call back has to be changed to sensor_msgs, but I am not sure how to do this.

Thank you, Morpheus


Originally posted by Morpheus on ROS Answers with karma: 111 on 2011-12-17

Post score: 1

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

Hi, Go to the teleop_base.cpp file and search for Joy::joy, it will in the joy_cb callback function, change it to sensor_msgs::joy. Check if the

#include "sensor_msgs/Joy.h

is included in the file if not include it. rosmake the teleop_base and it should work.

Hope this helps, Karthik


Originally posted by karthik with karma: 2831 on 2011-12-17

This answer was ACCEPTED on the original site

Post score: 3


Original comments

Comment by Morpheus on 2011-12-20:
Thanks karthik, I am new at ROS

Comment by karthik on 2011-12-19:
if you don't know what is call back function then you have to go through the tutorials http://www.ros.org/wiki/ROS/Tutorials/WritingPublisherSubscriber(c%2B%2B)

Comment by karthik on 2011-12-19:
Its just about the type of the object. In your teleop_base.cpp there will be a call back function in expecting a msg of the form Joy::joy you have to change that type to sensor_msgs::joy. Include the above mentioned header file also.

Comment by Morpheus on 2011-12-19:
I am new at this, and I am not sure what and where I need to make these changes.

Comment by karthik on 2011-12-17:
Thanks Eric :)

Comment by Eric Perko on 2011-12-17:
I've ticketed updating all the tutorials to use the new sensor_msgs::Joy message here: https://code.ros.org/trac/ros-pkg/ticket/5306

$\endgroup$

Your Answer

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