Set audio send period on server

merge-requests/9/head
Phil Taylor 2022-01-12 20:01:17 +00:00
rodzic 89ac99b3f9
commit 5a92c071d1
1 zmienionych plików z 4 dodań i 2 usunięć

Wyświetl plik

@ -3,7 +3,7 @@
#define STALE_CONNECTION 15
#define LOCK_PERIOD 10 // time to attempt to lock Mutex in ms
#define AUDIO_SEND_PERIOD 20 // how often to call the RX audio send function in ms
#define AUDIO_SEND_PERIOD 20 //
udpServer::udpServer(SERVERCONFIG config, audioSetup outAudio, audioSetup inAudio) :
config(config),
outAudio(outAudio),
@ -357,7 +357,7 @@ void udpServer::controlReceived()
rxAudioTimer = new QTimer();
rxAudioTimer->setTimerType(Qt::PreciseTimer);
connect(rxAudioTimer, &QTimer::timeout, this, std::bind(&udpServer::sendRxAudio, this));
rxAudioTimer->start(AUDIO_SEND_PERIOD);
rxAudioTimer->start(20);
}
}
@ -1277,6 +1277,8 @@ void udpServer::sendTokenResponse(CLIENT* c, quint8 type)
return;
}
#define PURGE_SECONDS 60
void udpServer::watchdog()
{
QDateTime now = QDateTime::currentDateTime();