Ask Your Question

Revision history [back]

how to increase rosserial buffer size

I am trying to publish an odometry message with rosserial:

nav_msgs::Odometry myOdom;

ros::Publisher odom_pub("odom", &myOdom); .... odom_pub.publish(&myOdom);

and it compiles fine, but I get an error that the message exceeds the buffer:

[ERROR] [WallTime: 1376891179.350615] Message from device dropped: message larger than buffer.

I saw in the documentation: http://www.ros.org/wiki/rosserial/Overview/Limitations

that the way to increase the buffer was by changing BUFFER_SIZE in the arduino library file ros.h However, there is no such parameter in ros.h. I did find in nodehandle.h the parameters INPUT_SIZE and OUTPUT_SIZE, so I tried changing those from 512 to 1024, but the initial INFO message that comes up still says that the max buffer size is 512.

I searched for where the error message is being sent from and was able to find a similar message in SerialClient.py, which says: rospy.logerr("Message from ROS network dropped: message larger than buffer.") but I cannot find where the error message for ""Message from device dropped..." is coming from. I was hoping to find it and then include in the error note the size of the message I am trying to send. It's possible the odom message is > 512 bytes, but if I can find out how many bytes are trying to be sent, then, once I find BUFFER_SIZE, I will know what it needs to be set to.

Thanks for the help!

how to increase rosserial buffer size

I am trying to publish an odometry message with rosserial:

nav_msgs::Odometry myOdom;

ros::Publisher odom_pub("odom", &myOdom); .... odom_pub.publish(&myOdom);

and it compiles fine, but I get an error that the message exceeds the buffer:

[ERROR] [WallTime: 1376891179.350615] Message from device dropped: message larger than buffer.

I saw in the documentation: http://www.ros.org/wiki/rosserial/Overview/Limitations

that the way to increase the buffer was by changing BUFFER_SIZE in the arduino library file ros.h However, there is no such parameter in ros.h. I did find in nodehandle.h the parameters INPUT_SIZE and OUTPUT_SIZE, so I tried changing those from 512 to 1024, but the initial INFO message that comes up still says that the max buffer size is 512.

I searched for where the error message is being sent from and was able to find a similar message in SerialClient.py, which says: rospy.logerr("Message from ROS network dropped: message larger than buffer.") but I cannot find where the error message for ""Message from device dropped..." is coming from. I was hoping to find it and then found it also in nodehandle.h and changed it to include in the error note the size of the message I am trying to send. It's possible the odom message is > 512 bytes, but if I can find out how many bytes are trying to be sent, then, once I find BUFFER_SIZE, I will know what it needs to be set to.

That change did not show up in the error, so now I realize that when I am recompiling the arduino code, the changes I made to nodehandle.h are not being incorporated. The file is located in the correct place (<sketchbook>/libraries) and I closed and reopened the arduino IDE, so it should pick up the change.

Thanks for the help!

how to increase rosserial buffer size

I am trying to publish an odometry message with rosserial:

nav_msgs::Odometry myOdom;

ros::Publisher odom_pub("odom", &myOdom); .... odom_pub.publish(&myOdom);

and it compiles fine, but I get an error that the message exceeds the buffer:

[ERROR] [WallTime: 1376891179.350615] Message from device dropped: message larger than buffer.

I saw in the documentation: http://www.ros.org/wiki/rosserial/Overview/Limitations

that the way to increase the buffer was by changing BUFFER_SIZE in the arduino library file ros.h However, there is no such parameter in ros.h. I did find in nodehandle.h the parameters INPUT_SIZE and OUTPUT_SIZE, so I tried changing those from 512 to 1024, but the initial INFO message that comes up still says that the max buffer size is 512.

I searched for where the error message is being sent from and found it also in nodehandle.h and changed it to include in the error note the size of the message I am trying to send. It's possible the odom message is > 512 bytes, but if I can find out how many bytes are trying to be sent, then, once I find BUFFER_SIZE, I will know what it needs to be set to.

That change did not show up in the error, so now I realize that when I am recompiling the arduino code, the changes I made to nodehandle.h are not being incorporated. The file is located in the correct place (<sketchbook>/libraries) (...sketchbook/libraries/ros_lib/ros) and I closed and reopened the arduino IDE, so it should pick up the change.

Thanks for the help!

how to increase rosserial buffer size

I am trying to publish an odometry message with rosserial:

nav_msgs::Odometry myOdom;

ros::Publisher odom_pub("odom", &myOdom); .... odom_pub.publish(&myOdom);

and it compiles fine, but I get an error that the message exceeds the buffer:

[ERROR] [WallTime: 1376891179.350615] Message from device dropped: message larger than buffer.

I saw in the documentation: http://www.ros.org/wiki/rosserial/Overview/Limitations

that the way to increase the buffer was by changing BUFFER_SIZE in the arduino library file ros.h However, there is no such parameter in ros.h. I did find in nodehandle.h the parameters INPUT_SIZE and OUTPUT_SIZE, so I tried changing those from 512 to 1024, but the initial INFO message that comes up still says that the max buffer size is 512.

I searched for where the error message is being sent from and found it also in nodehandle.h and changed it to include in the error note the size of the message I am trying to send. It's possible the odom message is > 512 bytes, but if I can find out how many bytes are trying to be sent, then, once I find BUFFER_SIZE, I will know what it needs to be set to.

That change did not show up in the error, so now I realize that when I am recompiling the arduino code, the changes I made to nodehandle.h are not being incorporated. The file is located in the correct place (...sketchbook/libraries/ros_lib/ros) and I closed and reopened the arduino IDE, so it should pick up the change.

Thanks for the help!

how to increase rosserial buffer size

I am trying to publish an odometry message with rosserial:

nav_msgs::Odometry myOdom;

ros::Publisher odom_pub("odom", &myOdom); .... odom_pub.publish(&myOdom);

and it compiles fine, but I get an error that the message exceeds the buffer:

[ERROR] [WallTime: 1376891179.350615] Message from device dropped: message larger than buffer.

I saw in the documentation: http://www.ros.org/wiki/rosserial/Overview/Limitations

that the way to increase the buffer was by changing BUFFER_SIZE in the arduino library file ros.h However, there is no such parameter in ros.h. I did find in nodehandle.h the parameters INPUT_SIZE and OUTPUT_SIZE, so I tried changing those from 512 to 1024, but the initial INFO message that comes up still says that the max buffer size is 512.

I searched for where the error message is being sent from and found it also in nodehandle.h and changed it to include in the error note the size of the message I am trying to send. It's possible the odom message is > 512 bytes, but if I can find out how many bytes are trying to be sent, then, once I find BUFFER_SIZE, I will know what it needs to be set to.

That change did not show up in the error, so now I realize that when I am recompiling the arduino code, the changes I made to nodehandle.h are not being incorporated. The file is located in the correct place (...sketchbook/libraries/ros_lib/ros) and I closed and reopened the arduino IDE, so it should pick up the change.

Thanks for the help!