aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJacob Rosenthal <[email protected]>2021-11-01 00:30:42 -0700
committerJacob Rosenthal <[email protected]>2021-11-01 00:30:42 -0700
commit7b092f463e630e7d8725f6af2d0138b608050b1f (patch)
tree6243a7065b0c6c2822f49db4d9197c193ed7b12c
parent72fa1c8482270e3004b7ef717a45cfe0bd3cde97 (diff)
clarify infinite
-rw-r--r--embassy-nrf/src/pwm.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/embassy-nrf/src/pwm.rs b/embassy-nrf/src/pwm.rs
index 64a25f238..5ed9cf146 100644
--- a/embassy-nrf/src/pwm.rs
+++ b/embassy-nrf/src/pwm.rs
@@ -258,11 +258,12 @@ impl<'d, T: Instance> Pwm<'d, T> {
258 r.tasks_seqstart[1].write(|w| unsafe { w.bits(0x01) }); 258 r.tasks_seqstart[1].write(|w| unsafe { w.bits(0x01) });
259 } 259 }
260 } 260 }
261 // to play infinitely, repeat the sequence one time, then have loops done self trigger seq0 again
261 LoopMode::Infinite => { 262 LoopMode::Infinite => {
262 r.loop_.write(|w| unsafe { w.cnt().bits(0x1) }); 263 r.loop_.write(|w| unsafe { w.cnt().bits(0x1) });
263 r.shorts.write(|w| w.loopsdone_seqstart1().enabled()); 264 r.shorts.write(|w| w.loopsdone_seqstart0().enabled());
264 // tasks_seqstart doesnt exist in all svds so write its bit instead 265 // tasks_seqstart doesnt exist in all svds so write its bit instead
265 r.tasks_seqstart[1].write(|w| unsafe { w.bits(0x01) }); 266 r.tasks_seqstart[0].write(|w| unsafe { w.bits(0x01) });
266 } 267 }
267 } 268 }
268 269