From e392692a0401add2572d00b39c036df05c815641 Mon Sep 17 00:00:00 2001 From: controllercustom <139927207+controllercustom@users.noreply.github.com> Date: Fri, 2 Oct 2026 19:25:29 -0700 Subject: [PATCH] Add MOZZI_OUTPUT_EXTERNAL_CUSTOM for mbed giga --- internal/MozziGuts_impl_MBED.hpp | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/internal/MozziGuts_impl_MBED.hpp b/internal/MozziGuts_impl_MBED.hpp index c4611bce4..a595e59f0 100644 --- a/internal/MozziGuts_impl_MBED.hpp +++ b/internal/MozziGuts_impl_MBED.hpp @@ -131,6 +131,19 @@ void stopMozzi() { audio_output_timer.detach(); } +#elif MOZZI_IS(MOZZI_AUDIO_MODE, MOZZI_OUTPUT_EXTERNAL_CUSTOM) +// Demand-driven: no timer is claimed and no interrupt is installed. The sketch +// drives audioHook() itself and provides audioOutput() / canBufferAudioOutput(), +// so startAudio() has nothing to attach and stopMozzi() nothing to detach. +// startAudioInput() is still called so a sketch using +// MOZZI_AUDIO_INPUT_STANDARD gets its acquisition running. +static void startAudio() { + startAudioInput(); +} + +void stopMozzi() { +} + #elif MOZZI_IS(MOZZI_AUDIO_MODE, MOZZI_OUTPUT_INTERNAL_DAC) } // namespace MozziPrivate