From 630d2eaba3ba7a6d3e629dca0878ec2ed3727a5f Mon Sep 17 00:00:00 2001 From: Phil Taylor Date: Sat, 14 May 2022 11:10:27 +0100 Subject: [PATCH] Update commhandler.cpp --- commhandler.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/commhandler.cpp b/commhandler.cpp index a8ac59e..a771fad 100644 --- a/commhandler.cpp +++ b/commhandler.cpp @@ -90,7 +90,7 @@ void commHandler::sendDataOut(const QByteArray &writeData) { mutex.lock(); // Recycle port to attempt reconnection. - if (!this->isConnected) { + if (!this->isConnected || !port->isOpen()) { closePort(); openPort(); }