Make FM squelch runtime-configurable.

This commit is contained in:
Jared Boone
2016-01-03 17:03:16 -08:00
parent 86cf967464
commit 8adaddac5f
3 changed files with 8 additions and 1 deletions

View File

@@ -106,6 +106,7 @@ void NarrowbandFMAudio::configure(const NBFMConfigureMessage& message) {
channel_filter_pass_f = message.channel_filter.pass_frequency_normalized * channel_filter_input_fs;
channel_filter_stop_f = message.channel_filter.stop_frequency_normalized * channel_filter_input_fs;
channel_spectrum.set_decimation_factor(std::floor((channel_filter_output_fs / 2) / ((channel_filter_pass_f + channel_filter_stop_f) / 2)));
squelch.set_threshold(8192);
configured = true;
}