mirror of https://github.com/g4klx/MMDVM.git
Initialise and reset the FM noise squelch invalid counter.
m_invalidCount was missing from the constructor initialiser list and was read uninitialised in process(), making the squelch behaviour after power-up indeterminate. reset() also cleared neither hysteresis counter, so state leaked across squelch resets.
This commit is contained in:
parent
a1794b44ed
commit
2eb6f7fd06
|
|
@ -36,7 +36,8 @@ m_count(0U),
|
|||
m_q0(0),
|
||||
m_q1(0),
|
||||
m_state(false),
|
||||
m_validCount(0U)
|
||||
m_validCount(0U),
|
||||
m_invalidCount(0U)
|
||||
{
|
||||
|
||||
}
|
||||
|
|
@ -127,6 +128,8 @@ void CFMNoiseSquelch::reset()
|
|||
m_q1 = 0;
|
||||
m_state = false;
|
||||
m_count = 0U;
|
||||
m_validCount = 0U;
|
||||
m_invalidCount = 0U;
|
||||
}
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Reference in New Issue