[PyQt] Using QSerialPort() instead of pyserial

Florian Bruhin me at the-compiler.org
Mon Nov 20 05:37:15 GMT 2017


Hi,

On Mon, Nov 20, 2017 at 08:20:19AM +1000, Phil wrote:
> This seems to be the equivalent but nothing is printed.
> 
> while (self.serial.waitForReadyRead(5000)):
>     data = self.serial.readAll()
>     print(:data = ")

That looks about right conceptually, apart from the print() being a syntax
error, and only showing part of the picture (how is self.serial defined)?

Can you please show a complete, working, minimal example script with PySerial
which works, and one with QSerialPort which does not?

Florian

-- 
https://www.qutebrowser.org  | me at the-compiler.org (Mail/XMPP)
   GPG: 916E B0C8 FD55 A072  | https://the-compiler.org/pubkey.asc
         I love long mails!  | https://email.is-not-s.ms/
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://www.riverbankcomputing.com/pipermail/pyqt/attachments/20171120/a27984ab/attachment.sig>


More information about the PyQt mailing list