Skip to content

Commit

Permalink
Fixing #453 - HamlibDrv: Added multiplatform reliable sleep
Browse files Browse the repository at this point in the history
  • Loading branch information
foldynl committed Sep 4, 2024
1 parent c48a12a commit 2d784a8
Showing 1 changed file with 3 additions and 11 deletions.
14 changes: 3 additions & 11 deletions rig/drivers/HamlibRigDrv.cpp
Original file line number Diff line number Diff line change
@@ -1,11 +1,5 @@
#include <QtGlobal>

#ifdef Q_OS_WIN
#include <windows.h>
#else
#include <unistd.h>
#endif

#include <QRegularExpression>
#include "HamlibRigDrv.h"
#include "core/debug.h"
Expand Down Expand Up @@ -1031,11 +1025,9 @@ void HamlibRigDrv::__setKeySpeed(qint16 wpm)

void HamlibRigDrv::commandSleep()
{
#ifdef Q_OS_WIN
Sleep(100);
#else
usleep(100000);
#endif
FCT_IDENTIFICATION;

QThread::msleep(200);
}

const QString HamlibRigDrv::getModeNormalizedText(const rmode_t mode,
Expand Down

0 comments on commit 2d784a8

Please sign in to comment.