Struct rp2040_pac2::pwm::Pwm[][src]

pub struct Pwm(pub *mut u8);

Simple PWM

Implementations

impl Pwm[src]

pub fn ch0_csr(self) -> Reg<Ch0Csr, RW>[src]

Control and status register

pub fn ch0_div(self) -> Reg<Ch0Div, RW>[src]

INT and FRAC form a fixed-point fractional number. Counting rate is system clock frequency divided by this number. Fractional division uses simple 1st-order sigma-delta.

pub fn ch0_ctr(self) -> Reg<Ch0Ctr, RW>[src]

Direct access to the PWM counter

pub fn ch0_cc(self) -> Reg<Ch0Cc, RW>[src]

Counter compare values

pub fn ch0_top(self) -> Reg<Ch0Top, RW>[src]

Counter wrap value

pub fn ch1_csr(self) -> Reg<Ch1Csr, RW>[src]

Control and status register

pub fn ch1_div(self) -> Reg<Ch1Div, RW>[src]

INT and FRAC form a fixed-point fractional number. Counting rate is system clock frequency divided by this number. Fractional division uses simple 1st-order sigma-delta.

pub fn ch1_ctr(self) -> Reg<Ch1Ctr, RW>[src]

Direct access to the PWM counter

pub fn ch1_cc(self) -> Reg<Ch1Cc, RW>[src]

Counter compare values

pub fn ch1_top(self) -> Reg<Ch1Top, RW>[src]

Counter wrap value

pub fn ch2_csr(self) -> Reg<Ch2Csr, RW>[src]

Control and status register

pub fn ch2_div(self) -> Reg<Ch2Div, RW>[src]

INT and FRAC form a fixed-point fractional number. Counting rate is system clock frequency divided by this number. Fractional division uses simple 1st-order sigma-delta.

pub fn ch2_ctr(self) -> Reg<Ch2Ctr, RW>[src]

Direct access to the PWM counter

pub fn ch2_cc(self) -> Reg<Ch2Cc, RW>[src]

Counter compare values

pub fn ch2_top(self) -> Reg<Ch2Top, RW>[src]

Counter wrap value

pub fn ch3_csr(self) -> Reg<Ch3Csr, RW>[src]

Control and status register

pub fn ch3_div(self) -> Reg<Ch3Div, RW>[src]

INT and FRAC form a fixed-point fractional number. Counting rate is system clock frequency divided by this number. Fractional division uses simple 1st-order sigma-delta.

pub fn ch3_ctr(self) -> Reg<Ch3Ctr, RW>[src]

Direct access to the PWM counter

pub fn ch3_cc(self) -> Reg<Ch3Cc, RW>[src]

Counter compare values

pub fn ch3_top(self) -> Reg<Ch3Top, RW>[src]

Counter wrap value

pub fn ch4_csr(self) -> Reg<Ch4Csr, RW>[src]

Control and status register

pub fn ch4_div(self) -> Reg<Ch4Div, RW>[src]

INT and FRAC form a fixed-point fractional number. Counting rate is system clock frequency divided by this number. Fractional division uses simple 1st-order sigma-delta.

pub fn ch4_ctr(self) -> Reg<Ch4Ctr, RW>[src]

Direct access to the PWM counter

pub fn ch4_cc(self) -> Reg<Ch4Cc, RW>[src]

Counter compare values

pub fn ch4_top(self) -> Reg<Ch4Top, RW>[src]

Counter wrap value

pub fn ch5_csr(self) -> Reg<Ch5Csr, RW>[src]

Control and status register

pub fn ch5_div(self) -> Reg<Ch5Div, RW>[src]

INT and FRAC form a fixed-point fractional number. Counting rate is system clock frequency divided by this number. Fractional division uses simple 1st-order sigma-delta.

pub fn ch5_ctr(self) -> Reg<Ch5Ctr, RW>[src]

Direct access to the PWM counter

pub fn ch5_cc(self) -> Reg<Ch5Cc, RW>[src]

Counter compare values

pub fn ch5_top(self) -> Reg<Ch5Top, RW>[src]

Counter wrap value

pub fn ch6_csr(self) -> Reg<Ch6Csr, RW>[src]

Control and status register

pub fn ch6_div(self) -> Reg<Ch6Div, RW>[src]

INT and FRAC form a fixed-point fractional number. Counting rate is system clock frequency divided by this number. Fractional division uses simple 1st-order sigma-delta.

pub fn ch6_ctr(self) -> Reg<Ch6Ctr, RW>[src]

Direct access to the PWM counter

pub fn ch6_cc(self) -> Reg<Ch6Cc, RW>[src]

Counter compare values

pub fn ch6_top(self) -> Reg<Ch6Top, RW>[src]

Counter wrap value

pub fn ch7_csr(self) -> Reg<Ch7Csr, RW>[src]

Control and status register

pub fn ch7_div(self) -> Reg<Ch7Div, RW>[src]

INT and FRAC form a fixed-point fractional number. Counting rate is system clock frequency divided by this number. Fractional division uses simple 1st-order sigma-delta.

pub fn ch7_ctr(self) -> Reg<Ch7Ctr, RW>[src]

Direct access to the PWM counter

pub fn ch7_cc(self) -> Reg<Ch7Cc, RW>[src]

Counter compare values

pub fn ch7_top(self) -> Reg<Ch7Top, RW>[src]

Counter wrap value

pub fn en(self) -> Reg<En, RW>[src]

This register aliases the CSR_EN bits for all channels. Writing to this register allows multiple channels to be enabled or disabled simultaneously, so they can run in perfect sync. For each channel, there is only one physical EN register bit, which can be accessed through here or CHx_CSR.

pub fn intr(self) -> Reg<Intr, RW>[src]

Raw Interrupts

pub fn inte(self) -> Reg<Inte, RW>[src]

Interrupt Enable

pub fn intf(self) -> Reg<Intf, RW>[src]

Interrupt Force

pub fn ints(self) -> Reg<Ints, RW>[src]

Interrupt status after masking & forcing

Trait Implementations

impl Clone for Pwm[src]

impl Copy for Pwm[src]

impl Send for Pwm[src]

impl Sync for Pwm[src]

Auto Trait Implementations

impl Unpin for Pwm

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, 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.