Hi,
I also got the same error, in my case it was the simple mistake of reading from a wrong serial port. I had two usb serial connections for two sensors and their hardware device formation on ubuntu tty/ACM* got interchanged. Just changing the devices worked for me.