mirror of
https://github.com/f4exb/sdrangel.git
synced 2026-06-03 06:24:48 -04:00
SDRdaemon plugin: apply buffer r/w correction at all ticks. Updated readme with warnings for Windows
This commit is contained in:
@@ -44,7 +44,8 @@ SDRdaemonUDPHandler::SDRdaemonUDPHandler(SampleFifo *sampleFifo, MessageQueue *o
|
||||
m_readLengthSamples(0),
|
||||
m_readLength(0),
|
||||
m_throttleToggle(false),
|
||||
m_rateDivider(1000/SDRDAEMON_THROTTLE_MS)
|
||||
m_rateDivider(1000/SDRDAEMON_THROTTLE_MS),
|
||||
m_autoCorrBuffer(false)
|
||||
{
|
||||
m_udpBuf = new char[SDRdaemonBuffer::m_udpPayloadSize];
|
||||
}
|
||||
@@ -223,6 +224,10 @@ void SDRdaemonUDPHandler::tick()
|
||||
m_throttleToggle = !m_throttleToggle;
|
||||
}
|
||||
|
||||
if (m_autoCorrBuffer) {
|
||||
m_readLengthSamples += m_sdrDaemonBuffer.getRWBalanceCorrection();
|
||||
}
|
||||
|
||||
// read samples directly feeding the SampleFifo (no callback)
|
||||
m_sampleFifo->write(reinterpret_cast<quint8*>(m_sdrDaemonBuffer.readData(m_readLength)), m_readLength);
|
||||
m_samplesCount += m_readLengthSamples;
|
||||
|
||||
Reference in New Issue
Block a user