NFM demod: fixed AF squelch initialization

pull/27/head
f4exb 2017-05-12 23:10:54 +02:00
rodzic 375f327004
commit a39b102f89
1 zmienionych plików z 3 dodań i 2 usunięć

Wyświetl plik

@ -37,7 +37,7 @@ AFSquelch::AFSquelch() :
m_u0 = new double[m_nTones];
m_u1 = new double[m_nTones];
m_power = new double[m_nTones];
m_movingAverages.resize(m_nTones, MovingAverage<double>(m_nbAvg, 0.0));
m_movingAverages.resize(m_nTones, MovingAverage<double>(m_nbAvg, 1.0f));
m_toneSet[0] = 2000.0;
m_toneSet[1] = 10000.0;
@ -45,7 +45,7 @@ AFSquelch::AFSquelch() :
AFSquelch::AFSquelch(unsigned int nbTones, const Real *tones) :
m_N(0),
m_nbAvg(0),
m_nbAvg(128),
m_sampleRate(0),
m_samplesProcessed(0),
m_maxPowerIndex(0),
@ -63,6 +63,7 @@ AFSquelch::AFSquelch(unsigned int nbTones, const Real *tones) :
m_u0 = new double[m_nTones];
m_u1 = new double[m_nTones];
m_power = new double[m_nTones];
m_movingAverages.resize(m_nTones, MovingAverage<double>(m_nbAvg, 1.0f));
for (int j = 0; j < m_nTones; ++j)
{