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

rosserial_python arduino node queue_size problem

asked 2015-01-13 02:25:19 -0500

Chrimo gravatar image

updated 2015-01-15 03:04:03 -0500

When launching rosserial_python I receive the following warning:

  • /rosdistro: indigo
  • /rosversion: 1.11.10
  • /serial_node/baud: 57600
  • /serial_node/port: /dev/ttyACM0

NODES / serial_node (rosserial_python/serial_node.py)

auto-starting new master process[master]: started with pid [6087] ROS_MASTER_URI=http://localhost:11311

setting /run_id to f6d85ce2-9af7-11e4-b2dc-eca86bf8a38d process[rosout-1]: started with pid [6100] started core service [/rosout] process[serial_node-2]: started with pid [6117] /opt/ros/indigo/lib/python2.7/dist-packages/rosserial_python/SerialClient.py:336: SyntaxWarning: The publisher should be created with an explicit keyword argument 'queue_size'. Please see http://wiki.ros.org/rospy/Overview/Pu... for more information. self.pub_diagnostics = rospy.Publisher('/diagnostics', diagnostic_msgs.msg.DiagnosticArray) /opt/ros/indigo/lib/python2.7/dist-packages/rosserial_python/SerialClient.py:101: SyntaxWarning: The publisher should be created with an explicit keyword argument 'queue_size'. Please see http://wiki.ros.org/rospy/Overview/Pu... for more information. self.publisher = rospy.Publisher(self.topic, self.message)

How can I fix it ?

I've tried to change my arduino code:

ros::Publisher pub("/MockBot/adc", &adc_msg, queue_size=1);

But I now the compiler throw me errors...

Where is the trick to make it work ?

Thanks in advance Christian

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2015-01-15 03:23:37 -0500

ahendrix gravatar image

This is a warning in the rosserial_python node; not in your arduino program.

This particular warning is just a warning; you can ignore it and your code will continue to work reasonably well. You can learn more about the details by reading the link mentioned in the warning.

You should check the rosserial_python bug tracker to see if this has been reported or fixed, and if it hasn't you should report it as a bug.

edit flag offensive delete link more

Comments

I just observed this warning, too! Opened issue oh github: https://github.com/ros-drivers/rosser...

Wolf gravatar image Wolf  ( 2015-02-27 03:49:01 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2015-01-13 02:25:19 -0500

Seen: 1,557 times

Last updated: Jan 15 '15