1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-12-23 01:55:48 -05:00

ATV Demod: fixed interpolator rf bandwidth whe in SSB modes. Set interpolator taps per phase to 24

This commit is contained in:
f4exb 2017-03-20 05:06:33 +01:00
parent 94d7170890
commit 3721b445b1
3 changed files with 26 additions and 5 deletions

View File

@ -650,8 +650,9 @@ void ATVDemod::applySettings()
return;
}
if((m_objRFConfig.m_intFrequencyOffset != m_objRFRunning.m_intFrequencyOffset) ||
(m_objConfig.m_intSampleRate != m_objRunning.m_intSampleRate))
if((m_objRFConfig.m_intFrequencyOffset != m_objRFRunning.m_intFrequencyOffset)
|| (m_objRFConfig.m_enmModulation != m_objRFRunning.m_enmModulation)
|| (m_objConfig.m_intSampleRate != m_objRunning.m_intSampleRate))
{
m_nco.setFreq(-m_objRFConfig.m_intFrequencyOffset, m_objConfig.m_intSampleRate);
}
@ -674,7 +675,10 @@ void ATVDemod::applySettings()
}
m_interpolatorDistanceRemain = 0;
m_interpolator.create(16, m_objConfigPrivate.m_intTVSampleRate, m_objRFConfig.m_fltRFBandwidth / 2.2, 3.0);
m_interpolator.create(24,
m_objConfigPrivate.m_intTVSampleRate,
m_objRFConfig.m_fltRFBandwidth / getRFBandwidthDivisor(m_objRFConfig.m_enmModulation),
3.0);
m_objSettingsMutex.unlock();
}
@ -758,3 +762,20 @@ bool ATVDemod::getBFOLocked()
return false;
}
}
float ATVDemod::getRFBandwidthDivisor(ATVModulation modulation)
{
switch(modulation)
{
case ATV_USB:
case ATV_LSB:
return 1.05f;
break;
case ATV_FM1:
case ATV_FM2:
case ATV_AM:
default:
return 2.2f;
}
}

View File

@ -334,7 +334,7 @@ private:
void applySettings();
void demod(Complex& c);
static float getRFBandwidthDivisor(ATVModulation modulation);
};
#endif // INCLUDE_ATVDEMOD_H

View File

@ -26,7 +26,7 @@
const PluginDescriptor ATVDemodPlugin::m_ptrPluginDescriptor =
{
QString("ATV Demodulator"),
QString("3.3.1"),
QString("3.3.2"),
QString("(c) F4HKW for F4EXB / SDRAngel"),
QString("https://github.com/f4exb/sdrangel"),
true,