diff --git a/embassy-nrf/src/pwm.rs b/embassy-nrf/src/pwm.rs index c0d73bdc5..895292bc8 100644 --- a/embassy-nrf/src/pwm.rs +++ b/embassy-nrf/src/pwm.rs @@ -342,6 +342,14 @@ impl<'d, 's, T: Instance> SingleSequencer<'d, 's, T> { }; self.sequencer.start(start_seq, times) } + + /// Stop playback. Disables the peripheral. Does NOT clear the last duty + /// cycle from the pin. Returns any sequences previously provided to + /// `start` so that they may be further mutated. + #[inline(always)] + pub fn stop(&self) { + self.sequencer.stop(); + } } /// A composition of sequences that can be started and stopped.