Further template BlockDecimator by element type, use for audio buffer.

Appropriating for use as a buffer accumulator that will save up enough audio samples to put into an audio DMA buffer.
This commit is contained in:
Jared Boone 2016-01-29 19:25:08 -08:00
parent aead1d8798
commit a558565886
8 changed files with 23 additions and 20 deletions

View file

@ -38,12 +38,8 @@ void NarrowbandAMAudio::execute(const buffer_c8_t& buffer) {
feed_channel_stats(channel_out);
channel_spectrum.feed(channel_out, channel_filter_pass_f, channel_filter_stop_f);
channel_block_buffer.feed(
channel_out, [this](const buffer_c16_t buffer) {
auto audio = this->demod.execute(buffer, this->audio_buffer);
this->audio_output.write(audio);
}
);
auto audio = demod.execute(channel_out, audio_buffer);
audio_output.write(audio);
}
void NarrowbandAMAudio::on_message(const Message* const message) {