Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-36758

QSerialPort::waitForBytesWritten() does not work properly

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P1: Critical
    • 5.3.1
    • 5.2.1
    • Serial Port
    • None
    • Qt5.2.1, Windows 7 64bit, Qt 5.2.1 for Windows 32-bit (MinGW 4.8, OpenGL, 634 MB)

    Description

      Now, in Qt5.2.1 QTBUG-33987 seems to be fixed, I have no longer the problem that waitForReadyRead returns true although the following readAll() returns an empty QByteArray.

      Unfortunately, the method waitForBytesWritten seems to be broken now. Sometimes, not always, the function timeouts and therefore returns false. At the moment I have two solutions:

      1. Don't call waitForBytesWritten. I've a handshake based communication, so every write causes a response, that I check by calling waitForReadyRead. Instead of
        write -> waitForBytesWritten -> waitForReadyRead -> readAll
        I just use it this way now:
        write -> waitForReadyRead -> readAll
      2. Return to Qt5.2.0

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            kuzulis Denis Shienkov
            rene René Keimling
            Votes:
            0 Vote for this issue
            Watchers:
            6 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes