May 2019
Intermediate to advanced
542 pages
13h 37m
English
QUdpSocket would be best here, since it allows for broadcasting packets, and the status packets do not need the overhead of TCP.
def on_ready_read(self): while self.socket.hasPendingDatagrams(): self.process_data(self.socket.readDatagram())
QTcpSocket does not have a hasPendingDatagrams() or readDatagram() method. TCP sockets work with data streams, not datagrams. ...
Read now
Unlock full access