C-Netz: Reset FSK decoder when switching channel mode
This prevents corrupt frames, as well as clear pending frames that were received during the old mode, but may not be received during the new mode.
This commit is contained in:
@@ -855,6 +855,8 @@ void cnetz_set_dsp_mode(cnetz_t *cnetz, enum dsp_mode mode)
|
||||
{
|
||||
PDEBUG_CHAN(DDSP, DEBUG_DEBUG, "DSP mode %d -> %d\n", cnetz->dsp_mode, mode);
|
||||
cnetz->dsp_mode = mode;
|
||||
/* we must get rid of partly received frame */
|
||||
fsk_demod_reset(&cnetz->fsk_demod);
|
||||
}
|
||||
|
||||
void cnetz_set_sched_dsp_mode(cnetz_t *cnetz, enum dsp_mode mode, int frames_ahead)
|
||||
|
Reference in New Issue
Block a user