mirror of
https://github.com/portapack-mayhem/mayhem-firmware.git
synced 2025-10-10 07:52:06 +00:00
Move I2S management to application side.
This commit is contained in:
@@ -77,10 +77,7 @@ void AudioOutput::on_block(
|
||||
audio_present_history = (audio_present_history << 1) | (audio_present_now ? 1 : 0);
|
||||
const bool audio_present = (audio_present_history != 0);
|
||||
|
||||
if( audio_present ) {
|
||||
i2s::i2s0::tx_unmute();
|
||||
} else {
|
||||
i2s::i2s0::tx_mute();
|
||||
if( !audio_present ) {
|
||||
for(size_t i=0; i<audio.count; i++) {
|
||||
audio.p[i] = 0;
|
||||
}
|
||||
|
Reference in New Issue
Block a user