Update commhandler.cpp

merge-requests/9/merge
Phil Taylor 2022-05-14 11:40:58 +01:00
rodzic d468e01d20
commit 2e1d88c194
1 zmienionych plików z 1 dodań i 1 usunięć

Wyświetl plik

@ -88,7 +88,7 @@ void commHandler::receiveDataFromUserToRig(const QByteArray &data)
void commHandler::sendDataOut(const QByteArray &writeData)
{
// Recycle port to attempt reconnection.
if (!this->isConnected || !port->isOpen() || lastDataReceived.msecsTo(QTime::currentTime()) > 2000) {
if (!this->isConnected || lastDataReceived.msecsTo(QTime::currentTime()) > 2000) {
qDebug(logSerial()) << "Serial port error? Attempting reconnect...";
lastDataReceived = QTime::currentTime();
QTimer::singleShot(500, this, SLOT(init()));