From ef6ae8ed94c6613378c08e407772f1b1e56ae02d Mon Sep 17 00:00:00 2001 From: Jared Boone Date: Mon, 4 Jan 2016 09:06:17 -0800 Subject: [PATCH] Add mute_audio() function to baseband processor. --- firmware/baseband/baseband_processor.cpp | 4 ++++ firmware/baseband/baseband_processor.hpp | 1 + 2 files changed, 5 insertions(+) diff --git a/firmware/baseband/baseband_processor.cpp b/firmware/baseband/baseband_processor.cpp index 9c05de3e..cfef43b2 100644 --- a/firmware/baseband/baseband_processor.cpp +++ b/firmware/baseband/baseband_processor.cpp @@ -54,6 +54,10 @@ void BasebandProcessor::fill_audio_buffer(const buffer_s16_t& audio) { feed_audio_stats(audio); } +void BasebandProcessor::mute_audio() { + i2s::i2s0::tx_mute(); +} + void BasebandProcessor::feed_audio_stats(const buffer_s16_t& audio) { audio_stats.feed( audio, diff --git a/firmware/baseband/baseband_processor.hpp b/firmware/baseband/baseband_processor.hpp index 48b23b7b..99df8703 100644 --- a/firmware/baseband/baseband_processor.hpp +++ b/firmware/baseband/baseband_processor.hpp @@ -45,6 +45,7 @@ protected: void feed_channel_stats(const buffer_c16_t& channel); void fill_audio_buffer(const buffer_s16_t& audio); + void mute_audio(); private: ChannelStatsCollector channel_stats;