pub struct Pwm<const N: u8> { /* private fields */ }
Expand description
Implementations§
source§impl<const N: u8> Pwm<N>
impl<const N: u8> Pwm<N>
sourcepub fn load_ok(&self) -> Mask
pub fn load_ok(&self) -> Mask
Read the LDOK
bits.
Note that the hardware will deassert LDOK
after the values are loaded.
sourcepub fn set_load_ok(&mut self, mask: Mask)
pub fn set_load_ok(&mut self, mask: Mask)
Set LDOK
for zero or more submodules.
A high bit indicates which LDOK
bit(s) will be set.
sourcepub fn clear_load_ok(&mut self, mask: Mask)
pub fn clear_load_ok(&mut self, mask: Mask)
Clear LDOK
for zero or more submodules.
A high bit indicates which LDOK
bit(s) will be cleared.
sourcepub fn set_run(&mut self, mask: Mask)
pub fn set_run(&mut self, mask: Mask)
Set or clear the RUN
bit(s) for one or more submodules.
This bitmask is written directly to the hardware. To perform a read-modify-write
operation on these bits, make sure to read the initial values with Pwm::run
.
sourcepub fn output_enable(&self, channel: Channel) -> Mask
pub fn output_enable(&self, channel: Channel) -> Mask
Read a PWM channel’s output enable bits.
sourcepub fn set_output_enable(&mut self, channel: Channel, mask: Mask)
pub fn set_output_enable(&mut self, channel: Channel, mask: Mask)
Set a PWM channel’s output enable.
A high bit indicates the channel is enabled. A low bit disables the channel.
Auto Trait Implementations§
impl<const N: u8> !RefUnwindSafe for Pwm<N>
impl<const N: u8> Send for Pwm<N>
impl<const N: u8> !Sync for Pwm<N>
impl<const N: u8> Unpin for Pwm<N>
impl<const N: u8> !UnwindSafe for Pwm<N>
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