[][src]Struct imxrt1062_hal::pwm::Controller

pub struct Controller<M> { /* fields omitted */ }

A PWM controller

There's one PWM controller per module. The controller allows a user to allocated PWM outputs. It allows a user to perform module-level configurations.

Methods

impl<M> Controller<M> where
    M: Module
[src]

pub fn outputs<A, B>(
    &mut self,
    pin_a: A,
    pin_b: B,
    timing: Timing
) -> Result<Pairs<M, <A as Pin>::Submodule>, TicksError> where
    A: Pin<Module = M, Output = A>,
    B: Pin<Module = M, Output = B, Submodule = <A as Pin>::Submodule>, 
[src]

Allocates a Pair of complementary PWM output pins containing pins A and B.

pin_a and pin_b may be obtained from the IOMUXC. Pins may need to be set to a certain alternative in order to be passed into the outputs method. The two pins must be associated with this controller's module, and the submodules of each pin must match.

Specify the timings for the PWM module / submodule with the Timing parameter. If the provided timings cannot define a representable driving frequency, outputs returns an error.

Auto Trait Implementations

impl<M> !Send for Controller<M>

impl<M> !Sync for Controller<M>

impl<M> Unpin for Controller<M> where
    M: Unpin

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.