#[non_exhaustive]pub struct SimpleConfig {
pub counter_mode: CounterMode,
pub max_duty: u16,
pub prescaler: Prescaler,
pub ch0_drive: OutputDrive,
pub ch1_drive: OutputDrive,
pub ch2_drive: OutputDrive,
pub ch3_drive: OutputDrive,
pub ch0_idle_level: Level,
pub ch1_idle_level: Level,
pub ch2_idle_level: Level,
pub ch3_idle_level: Level,
}Expand description
Configuration for the simple PWM driver.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.counter_mode: CounterModeSelects up mode or up-and-down mode for the counter
max_duty: u16Top value to be compared against buffer values
prescaler: PrescalerConfiguration for PWM_CLK
ch0_drive: OutputDriveDrive strength for the channel 0 line.
ch1_drive: OutputDriveDrive strength for the channel 1 line.
ch2_drive: OutputDriveDrive strength for the channel 2 line.
ch3_drive: OutputDriveDrive strength for the channel 3 line.
ch0_idle_level: LevelOutput level for the channel 0 line when PWM if disabled.
ch1_idle_level: LevelOutput level for the channel 1 line when PWM if disabled.
ch2_idle_level: LevelOutput level for the channel 2 line when PWM if disabled.
ch3_idle_level: LevelOutput level for the channel 3 line when PWM if disabled.
Trait Implementations§
Source§impl Clone for SimpleConfig
impl Clone for SimpleConfig
Source§fn clone(&self) -> SimpleConfig
fn clone(&self) -> SimpleConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for SimpleConfig
impl Debug for SimpleConfig
Source§impl Default for SimpleConfig
impl Default for SimpleConfig
Auto Trait Implementations§
impl Freeze for SimpleConfig
impl RefUnwindSafe for SimpleConfig
impl Send for SimpleConfig
impl Sync for SimpleConfig
impl Unpin for SimpleConfig
impl UnsafeUnpin for SimpleConfig
impl UnwindSafe for SimpleConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more