I still think you need to break the problem down into the smallest piece possible, than add more features. I would start by writing a Qt program that simply starts the listener process, reads the output from your sensor and prints it using qDebug(). No printing it to a text edit, no logging to files, no plotting. At this point, you have no idea which step in this chain is going wrong, so eliminate everything except the first one: getting data successfully from the QProcess into your program. Once that seems to be working in the same way as your C program, then you know the communication works, so add the graphics and other features.
You might also try using QProcess:readAllStandardOutput() to get all of the available data at once instead of using readLine(). Use QByteArray::data() or QByteArray::constData() to get the NULL-terminated C string it contains. This way you do not have to worry about the buffer size or whether you have read it all.
Bookmarks