aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorhuntc <[email protected]>2022-02-04 11:48:08 +1100
committerhuntc <[email protected]>2022-02-04 11:48:08 +1100
commitbc7266394ddba3d6128cc9de131109c2454f3d05 (patch)
treed666bc7039d255af8dbb4830adde779e46638e34
parent986295998a3fa8c665364d7b4a5fc009d186dee9 (diff)
Clarify why we need the mut buffer
-rw-r--r--embassy-nrf/src/pwm.rs2
1 files changed, 2 insertions, 0 deletions
diff --git a/embassy-nrf/src/pwm.rs b/embassy-nrf/src/pwm.rs
index a4bc94765..e561f0383 100644
--- a/embassy-nrf/src/pwm.rs
+++ b/embassy-nrf/src/pwm.rs
@@ -428,6 +428,8 @@ impl Default for SequenceConfig {
428#[non_exhaustive] 428#[non_exhaustive]
429pub struct Sequence<'d> { 429pub struct Sequence<'d> {
430 /// The words comprising the sequence. Must not exceed 32767 words. 430 /// The words comprising the sequence. Must not exceed 32767 words.
431 /// The reason for this buffer to be mutable is so that stopping
432 /// the PWM can relinquish the sequence for subsequent modification.
431 pub words: &'d mut [u16], 433 pub words: &'d mut [u16],
432 /// Configuration associated with the sequence. 434 /// Configuration associated with the sequence.
433 pub config: SequenceConfig, 435 pub config: SequenceConfig,