pub struct TIM8 { /* private fields */ }
Expand description

TIM8 peripheral

Implementations§

source§

impl TIM8

source

pub unsafe fn steal() -> Self

Unsafely create an instance of this peripheral out of thin air.

Safety

You must ensure that you’re only using one instance of this type at a time.

Trait Implementations§

source§

impl AdvancedControlInstance for TIM8

source§

fn regs_advanced() -> TimAdv

Get access to the advanced timer registers.
source§

impl Basic16bitInstance for TIM8

§

type Interrupt = TIM8_UP_TIM13

Interrupt for this timer.
source§

fn regs() -> TimBasic

Get access to the basic 16bit timer registers. Read more
source§

fn start(&mut self)

Start the timer.
source§

fn stop(&mut self)

Stop the timer.
source§

fn reset(&mut self)

Reset the counter value to 0
source§

fn set_frequency(&mut self, frequency: Hertz)

Set the frequency of how many times per second the timer counts up to the max value or down to 0. Read more
source§

fn clear_update_interrupt(&mut self) -> bool

Clear update interrupt. Read more
source§

fn enable_update_interrupt(&mut self, enable: bool)

Enable/disable the update interrupt.
source§

fn enable_update_dma(&mut self, enable: bool)

Enable/disable the update dma.
source§

fn get_update_dma_state(&self) -> bool

Get the update dma enable/disable state.
source§

fn set_autoreload_preload(&mut self, enable: bool)

Enable/disable autoreload preload.
source§

fn get_frequency(&self) -> Hertz

Get the timer frequency.
source§

impl BreakInput2Comparator1Pin<TIM8> for PA8

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as BreakInput2Comparator1Pin
source§

impl BreakInput2Comparator2Pin<TIM8> for PA8

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as BreakInput2Comparator2Pin
source§

impl BreakInput2Pin<TIM8> for PA8

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as BreakInput2Pin
source§

impl BreakInputComparator1Pin<TIM8> for PA6

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as BreakInputComparator1Pin
source§

impl BreakInputComparator2Pin<TIM8> for PA6

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as BreakInputComparator2Pin
source§

impl BreakInputPin<TIM8> for PA6

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as BreakInputPin
source§

impl CaptureCompare16bitInstance for TIM8

source§

fn enable_outputs(&mut self)

Enable timer outputs.
source§

fn set_input_capture_filter(&mut self, channel: Channel, icf: Icf)

Set input capture filter.
source§

fn clear_input_interrupt(&mut self, channel: Channel)

Clear input interrupt.
source§

fn enable_input_interrupt(&mut self, channel: Channel, enable: bool)

Enable input interrupt.
source§

fn set_input_capture_prescaler(&mut self, channel: Channel, factor: u8)

Set input capture prescaler.
source§

fn set_input_ti_selection(&mut self, channel: Channel, tisel: InputTISelection)

Set input TI selection.
source§

fn set_input_capture_mode(&mut self, channel: Channel, mode: InputCaptureMode)

Set input capture mode.
source§

fn set_output_compare_mode(&mut self, channel: Channel, mode: OutputCompareMode)

Set output compare mode.
source§

fn set_output_polarity(&mut self, channel: Channel, polarity: OutputPolarity)

Set output polarity.
source§

fn enable_channel(&mut self, channel: Channel, enable: bool)

Enable/disable a channel.
source§

fn get_channel_enable_state(&self, channel: Channel) -> bool

Get enable/disable state of a channel
source§

fn set_compare_value(&mut self, channel: Channel, value: u16)

Set compare value for a channel.
source§

fn get_capture_value(&mut self, channel: Channel) -> u16

Get capture value for a channel.
source§

fn get_max_compare_value(&self) -> u16

Get max compare value. This depends on the timer frequency and the clock frequency from RCC.
source§

fn get_compare_value(&self, channel: Channel) -> u16

Get compare value for a channel.
source§

fn set_output_compare_preload(&mut self, channel: Channel, preload: bool)

Set output compare preload.
source§

impl Channel1ComplementaryPin<TIM8> for PA5

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as Channel1ComplementaryPin
source§

impl Channel1ComplementaryPin<TIM8> for PA7

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as Channel1ComplementaryPin
source§

impl Channel1Pin<TIM8> for PC6

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as Channel1Pin
source§

impl Channel2ComplementaryPin<TIM8> for PB0

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as Channel2ComplementaryPin
source§

impl Channel2ComplementaryPin<TIM8> for PB14

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as Channel2ComplementaryPin
source§

impl Channel2Pin<TIM8> for PC7

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as Channel2Pin
source§

impl Channel3ComplementaryPin<TIM8> for PB1

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as Channel3ComplementaryPin
source§

impl Channel3ComplementaryPin<TIM8> for PB15

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as Channel3ComplementaryPin
source§

impl Channel3Pin<TIM8> for PC8

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as Channel3Pin
source§

impl Channel4Pin<TIM8> for PC9

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as Channel4Pin
source§

impl ComplementaryCaptureCompare16bitInstance for TIM8

source§

fn set_complementary_output_polarity( &mut self, channel: Channel, polarity: OutputPolarity )

Set complementary output polarity.
source§

fn set_dead_time_clock_division(&mut self, value: Ckd)

Set clock divider for the dead time.
source§

fn set_dead_time_value(&mut self, value: u8)

Set dead time, as a fraction of the max duty value.
source§

fn enable_complementary_channel(&mut self, channel: Channel, enable: bool)

Enable/disable a complementary channel.
source§

impl ExternalTriggerPin<TIM8> for PA0

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as ExternalTriggerPin
source§

impl ExternalTriggerPin<TIM8> for PG8

source§

fn af_num(&self) -> u8

Get the AF number needed to use this pin as ExternalTriggerPin
source§

impl GeneralPurpose16bitInstance for TIM8

source§

fn regs_gp16() -> TimGp16

Get access to the general purpose 16bit timer registers. Read more
source§

fn set_counting_mode(&mut self, mode: CountingMode)

Set counting mode.
source§

fn get_counting_mode(&self) -> CountingMode

Get counting mode.
source§

fn set_clock_division(&mut self, ckd: Ckd)

Set clock divider.
source§

impl Peripheral for TIM8

§

type P = TIM8

Peripheral singleton type
source§

unsafe fn clone_unchecked(&self) -> Self::P

Unsafely clone (duplicate) a peripheral singleton. Read more
source§

fn into_ref<'a>(self) -> PeripheralRef<'a, Self::P>
where Self: 'a,

Convert a value into a PeripheralRef. Read more
source§

impl RccPeripheral for TIM8

source§

impl AdvancedControlInstance for TIM8

source§

impl Basic16bitInstance for TIM8

source§

impl CaptureCompare16bitInstance for TIM8

source§

impl ComplementaryCaptureCompare16bitInstance for TIM8

source§

impl GeneralPurpose16bitInstance for TIM8

source§

impl RccPeripheral for TIM8

Auto Trait Implementations§

§

impl RefUnwindSafe for TIM8

§

impl Send for TIM8

§

impl Sync for TIM8

§

impl Unpin for TIM8

§

impl UnwindSafe for TIM8

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

§

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

§

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.
source§

impl<T> UpDma<TIM8> for T
where T: Channel<Mux = DMAMUX1> + MuxChannel,

source§

fn request(&self) -> u8

Get the DMA request number needed to use this channel asUpDma Note: in some chips, ST calls this the “channel”, and calls channels “streams”. embassy-stm32 always uses the “channel” and “request number” names.