Struct esp32s3_hal::otg_fs::USB

source ·
pub struct USB<'d, P, M>
where P: UsbDp + Send + Sync, M: UsbDm + Send + Sync,
{ /* private fields */ }

Implementations§

source§

impl<'d, P, M> USB<'d, P, M>
where P: UsbDp + Send + Sync, M: UsbDm + Send + Sync,

source

pub fn new( usb0: impl Peripheral<P = USB0> + 'd, usb_dp: impl Peripheral<P = P> + 'd, usb_dm: impl Peripheral<P = M> + 'd ) -> USB<'d, P, M>

Trait Implementations§

source§

impl<'d, P, M> UsbPeripheral for USB<'d, P, M>
where P: UsbDp + Send + Sync, M: UsbDm + Send + Sync,

source§

const REGISTERS: *const () = {0x60080000 as *const ()}

Pointer to the register block
source§

const HIGH_SPEED: bool = false

true for High Speed variants of the peripheral, false for Full Speed
source§

const FIFO_DEPTH_WORDS: usize = 256usize

FIFO size in 32-bit words
source§

const ENDPOINT_COUNT: usize = 5usize

Number of (bidirectional) endpoints
source§

fn enable()

Enables USB device on its peripheral bus
source§

fn ahb_frequency_hz(&self) -> u32

AHB frequency in hertz
source§

fn phy_type(&self) -> PhyType

Returns PHY type that should be used for USB peripheral
source§

fn setup_internal_hs_phy(&self)

Performs initial setup of the internal high-speed PHY Read more
source§

impl<'d, P, M> Sync for USB<'d, P, M>
where P: UsbDp + Send + Sync, M: UsbDm + Send + Sync,

Auto Trait Implementations§

§

impl<'d, P, M> RefUnwindSafe for USB<'d, P, M>

§

impl<'d, P, M> Send for USB<'d, P, M>

§

impl<'d, P, M> Unpin for USB<'d, P, M>
where M: Unpin, P: Unpin,

§

impl<'d, P, M> !UnwindSafe for USB<'d, P, M>

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.