embassy-rp

Crates

git

Versions

rp235xa

Flavors

Skip to main content

Gpout

Struct Gpout 

Source
pub struct Gpout<'d, T: GpoutPin> { /* private fields */ }
Expand description

General purpose clock output driver.

Implementations§

Source§

impl<'d, T: GpoutPin> Gpout<'d, T>

Source

pub fn new(gpout: Peri<'d, T>) -> Self

Create new general purpose clock output.

Source

pub fn set_div(&self, int: u16, frac: u16)

Set clock divider.

Source

pub fn set_src(&self, src: GpoutSrc)

Set clock source.

Source

pub fn enable(&self)

Enable clock.

Source

pub fn disable(&self)

Disable clock.

Source

pub fn get_freq(&self) -> u32

Clock frequency.

Trait Implementations§

Source§

impl<'d, T: GpoutPin> Drop for Gpout<'d, T>

Source§

fn drop(&mut self)

Executes the destructor for this type. Read more
Source§

fn pin_drop(self: Pin<&mut Self>)

🔬This is a nightly-only experimental API. (pin_ergonomics)
Execute the destructor for this type, but different to Drop::drop, it requires self to be pinned. Read more

Auto Trait Implementations§

§

impl<'d, T> !UnwindSafe for Gpout<'d, T>

§

impl<'d, T> Freeze for Gpout<'d, T>
where Peri<'d, T>: Freeze,

§

impl<'d, T> RefUnwindSafe for Gpout<'d, T>
where Peri<'d, T>: RefUnwindSafe,

§

impl<'d, T> Send for Gpout<'d, T>
where Peri<'d, T>: Send,

§

impl<'d, T> Sync for Gpout<'d, T>
where Peri<'d, T>: Sync,

§

impl<'d, T> Unpin for Gpout<'d, T>
where Peri<'d, T>: Unpin,

§

impl<'d, T> UnsafeUnpin for Gpout<'d, T>
where Peri<'d, T>: UnsafeUnpin,

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 = !

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.