aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrafael <[email protected]>2024-10-21 11:59:03 +0200
committerrafael <[email protected]>2024-10-21 11:59:03 +0200
commitd7db8fbab9a2bc363520505757386500d5710735 (patch)
treef18781250b1f305a3288e94f76ac0529c85a305e
parentf32b0fbc3b614ab79b7756b49e44a380e5e60192 (diff)
rustfmt
-rw-r--r--embassy-rp/src/pwm.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/embassy-rp/src/pwm.rs b/embassy-rp/src/pwm.rs
index de2c2f81e..cfb99c569 100644
--- a/embassy-rp/src/pwm.rs
+++ b/embassy-rp/src/pwm.rs
@@ -1,6 +1,7 @@
1//! Pulse Width Modulation (PWM) 1//! Pulse Width Modulation (PWM)
2 2
3use embassy_hal_internal::{into_ref, Peripheral, PeripheralRef}; 3use embassy_hal_internal::{into_ref, Peripheral, PeripheralRef};
4pub use embedded_hal_1::pwm::SetDutyCycle;
4use embedded_hal_1::pwm::{Error, ErrorKind, ErrorType}; 5use embedded_hal_1::pwm::{Error, ErrorKind, ErrorType};
5use fixed::traits::ToFixed; 6use fixed::traits::ToFixed;
6use fixed::FixedU16; 7use fixed::FixedU16;
@@ -10,8 +11,6 @@ use pac::pwm::vals::Divmode;
10use crate::gpio::{AnyPin, Pin as GpioPin, Pull, SealedPin as _}; 11use crate::gpio::{AnyPin, Pin as GpioPin, Pull, SealedPin as _};
11use crate::{pac, peripherals, RegExt}; 12use crate::{pac, peripherals, RegExt};
12 13
13pub use embedded_hal_1::pwm::SetDutyCycle;
14
15/// The configuration of a PWM slice. 14/// The configuration of a PWM slice.
16/// Note the period in clock cycles of a slice can be computed as: 15/// Note the period in clock cycles of a slice can be computed as:
17/// `(top + 1) * (phase_correct ? 1 : 2) * divider` 16/// `(top + 1) * (phase_correct ? 1 : 2) * divider`