First of all : in line 47 (serial->readLine()...) You can get any number of bytes in the range of <1..1000>.
Before atof() you need to check whether the buffer contains a complete package.
First of all : in line 47 (serial->readLine()...) You can get any number of bytes in the range of <1..1000>.
Before atof() you need to check whether the buffer contains a complete package.
suhairkp (20th February 2017)
Bookmarks