Struct nrf_smartled::pwm::Pwm [−][src]
pub struct Pwm<T: Instance> { /* fields omitted */ }
Expand description
A PWM peripheral driven Smartled driver
Implementations
Create a new Smartled driver with a given pin and PWM engine
Start sending raw data
NOTE: You should probably use Pwm::send_full_buf() instead.
SAFETY: the contents of buf
must live and be constant until Pwm::is_done_raw()
returns true.
Set the seq[1] register’s ptr and length
SAFETY: the contents of buf
must live and me constant until sequence 1
is completed
Is the raw send complete?
Note: You probably shouldn’t use this function unless you are also using Pwm::start_send_raw().
Send a series of colors and a stop pattern, using a given scratch space
NOTE: the size of scratch
must be >= u16s_needed_slice(colors).
NOTE: You can also use the SmartLedsWrite::write method to avoid the need for a scratch space (it uses its own)
Trait Implementations
Auto Trait Implementations
impl<T> RefUnwindSafe for Pwm<T> where
T: RefUnwindSafe,
impl<T> UnwindSafe for Pwm<T> where
T: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more
Casts the value.
Casts the value.
Performs the conversion.
Performs the conversion.
Casts the value.
OverflowingCasts the value.
Casts the value.
Casts the value.
Casts the value.
UnwrappedCasts the value.
Casts the value.
WrappingCasts the value.