OC1M_W

Struct OC1M_W 

Source
pub struct OC1M_W<'a> { /* private fields */ }
Expand description

Write proxy for field OC1M

Implementations§

Source§

impl<'a> OC1M_W<'a>

Source

pub fn variant(self, variant: OC1M_A) -> &'a mut W

Writes variant to the field

Source

pub fn frozen(self) -> &'a mut W

The comparison between the output compare register TIMx_CCRy and the counter TIMx_CNT has no effect on the outputs

Source

pub fn active_on_match(self) -> &'a mut W

Set channel to active level on match. OCyREF signal is forced high when the counter matches the capture/compare register

Source

pub fn inactive_on_match(self) -> &'a mut W

Set channel to inactive level on match. OCyREF signal is forced low when the counter matches the capture/compare register

Source

pub fn toggle(self) -> &'a mut W

OCyREF toggles when TIMx_CNT=TIMx_CCRy

Source

pub fn force_inactive(self) -> &'a mut W

OCyREF is forced low

Source

pub fn force_active(self) -> &'a mut W

OCyREF is forced high

Source

pub fn pwm_mode1(self) -> &'a mut W

In upcounting, channel is active as long as TIMx_CNT<TIMx_CCRy else inactive. In downcounting, channel is inactive as long as TIMx_CNT>TIMx_CCRy else active

Source

pub fn pwm_mode2(self) -> &'a mut W

Inversely to PwmMode1

Source

pub fn opm_mode1(self) -> &'a mut W

Retriggerable OPM mode 1 - In up-counting mode, the channel is active until a trigger event is detected (on TRGI signal). In down-counting mode, the channel is inactive

Source

pub fn opm_mode2(self) -> &'a mut W

Inversely to OpmMode1

Source

pub fn combined_pwm_mode1(self) -> &'a mut W

OCyREF has the same behavior as in PWM mode 1. OCyREFC is the logical OR between OC1REF and OC2REF

Source

pub fn combined_pwm_mode2(self) -> &'a mut W

OCyREF has the same behavior as in PWM mode 2. OCyREFC is the logical AND between OC1REF and OC2REF

Source

pub fn asymmetric_pwm_mode1(self) -> &'a mut W

OCyREF has the same behavior as in PWM mode 1. OCyREFC outputs OC1REF when the counter is counting up, OC2REF when it is counting down

Source

pub fn asymmetric_pwm_mode2(self) -> &'a mut W

OCyREF has the same behavior as in PWM mode 2. OCyREFC outputs OC1REF when the counter is counting up, OC2REF when it is counting down

Source

pub unsafe fn bits(self, value: u8) -> &'a mut W

Writes raw bits to the field

Auto Trait Implementations§

§

impl<'a> Freeze for OC1M_W<'a>

§

impl<'a> !RefUnwindSafe for OC1M_W<'a>

§

impl<'a> Send for OC1M_W<'a>

§

impl<'a> !Sync for OC1M_W<'a>

§

impl<'a> Unpin for OC1M_W<'a>

§

impl<'a> !UnwindSafe for OC1M_W<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.