0
$\begingroup$

Rosanswers logo

I am creating an application to control the Baxter robot with the Oculus Rift. Everything worked fine but after simply copying the program to another computer and running it from there, I am getting the error "Buffer overrun when attempting to parse setup message" at initialisation.

I am using two computers, obtaining and publishing data (using Rosserial Windows) on a Windows PC and creating ROS subscribers + processing the data on an Ubuntu PC. I migrated the code from my Windows laptop onto a Windows desktop, but haven't changed it otherwise. The error occurs immediately as the Windows node attempts to connect.

I am not sure what triggered the error, since I haven't changed my code. Apparently, it is caused by the StreamOverrun exception. More specifically, Rosserial's Session.h shows when the exception is triggered - I am also getting that ROS_ERRROR_ONCE message, which suggests topic_id < 100. I don't understand how that could be the case:

try {
          callbacks_[topic_id](stream);
        } catch(ros::serialization::StreamOverrunException e) {
          if (topic_id < 100) {
            ROS_ERROR("Buffer overrun when attempting to parse setup message.");
            ROS_ERROR_ONCE("Is this firmware from a pre-Groovy rosserial?");
          } else {
            ROS_WARN("Buffer overrun when attempting to parse user message.");
          }
        }

For reference, my code can be found on my github.

I would appreciate any help. Thanks.


Originally posted by retepvan on ROS Answers with karma: 16 on 2017-08-28

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

I discovered what the issue was. Optimisation set in the Release Configuration in Visual Studio of my Rosserial Windows application was causing problems. The solution was to disable optimisation.


Originally posted by retepvan with karma: 16 on 2017-09-02

This answer was ACCEPTED on the original site

Post score: 0


Original comments

Comment by gvdhoorn on 2017-09-03:
If changing the optimalisation levels really works-around / resolves this, then I think that would be something to report at rosserial/issues, as it would seem to point to a serious issue.

Comment by retepvan on 2017-09-03:
Cheers, I will do that.

$\endgroup$

Your Answer

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