Struct gd32e1::gd32e103::UsbfsHost

source ·
pub struct UsbfsHost { /* private fields */ }
Expand description

USB on the go full speed host

Implementations§

source§

impl UsbfsHost

source

pub const PTR: *const RegisterBlock = {0x50000400 as *const gd32e103::usbfs_host::RegisterBlock}

Pointer to the register block

source

pub const fn ptr() -> *const RegisterBlock

Return the pointer to the register block

source

pub unsafe fn steal() -> Self

Steal an instance of this peripheral

§Safety

Ensure that the new instance of the peripheral cannot be used in a way that may race with any existing instances, for example by only accessing read-only or write-only registers, or by consuming the original peripheral and using critical sections to coordinate access between multiple new instances.

Additionally, other software such as HALs may rely on only one peripheral instance existing to ensure memory safety; ensure no stolen instances are passed to such software.

Methods from Deref<Target = RegisterBlock>§

source

pub fn hctl(&self) -> &Hctl

0x00 - host configuration register (HCTL)

source

pub fn hft(&self) -> &Hft

0x04 - Host frame interval register

source

pub fn hfinfr(&self) -> &Hfinfr

0x08 - OTG_FS host frame number/frame time remaining register (HFINFR)

source

pub fn hptfqstat(&self) -> &Hptfqstat

0x10 - Host periodic transmit FIFO/queue status register (HPTFQSTAT)

source

pub fn hachint(&self) -> &Hachint

0x14 - Host all channels interrupt register

source

pub fn hachinten(&self) -> &Hachinten

0x18 - host all channels interrupt mask register

source

pub fn hpcs(&self) -> &Hpcs

0x40 - Host port control and status register (USBFS_HPCS)

source

pub fn hch0ctl(&self) -> &Hch0ctl

0x100 - host channel-0 characteristics register (HCH0CTL)

source

pub fn hch0intf(&self) -> &Hch0intf

0x108 - host channel-0 interrupt register (USBFS_HCHxINTF)

source

pub fn hch0inten(&self) -> &Hch0inten

0x10c - host channel-0 interrupt enable register (HCH0INTEN)

source

pub fn hch0len(&self) -> &Hch0len

0x110 - host channel-0 transfer length register

source

pub fn hch1ctl(&self) -> &Hch1ctl

0x120 - host channel-1 characteristics register (HCH1CTL)

source

pub fn hch1intf(&self) -> &Hch1intf

0x128 - host channel-1 interrupt register (HCH1INTF)

source

pub fn hch1inten(&self) -> &Hch1inten

0x12c - host channel-1 interrupt enable register (HCH1INTEN)

source

pub fn hch1len(&self) -> &Hch1len

0x130 - host channel-1 transfer length register

source

pub fn hch2ctl(&self) -> &Hch2ctl

0x140 - host channel-2 characteristics register (HCH2CTL)

source

pub fn hch2intf(&self) -> &Hch2intf

0x148 - host channel-2 interrupt register (HCH2INTF)

source

pub fn hch2inten(&self) -> &Hch2inten

0x14c - host channel-2 interrupt enable register (HCH2INTEN)

source

pub fn hch2len(&self) -> &Hch2len

0x150 - host channel-2 transfer length register

source

pub fn hch3ctl(&self) -> &Hch3ctl

0x160 - host channel-3 characteristics register (HCH3CTL)

source

pub fn hch3intf(&self) -> &Hch3intf

0x168 - host channel-3 interrupt register (HCH3INTF)

source

pub fn hch3inten(&self) -> &Hch3inten

0x16c - host channel-3 interrupt enable register (HCH3INTEN)

source

pub fn hch3len(&self) -> &Hch3len

0x170 - host channel-3 transfer length register

source

pub fn hch4ctl(&self) -> &Hch4ctl

0x180 - host channel-4 characteristics register (HCH4CTL)

source

pub fn hch4intf(&self) -> &Hch4intf

0x188 - host channel-4 interrupt register (HCH4INTF)

source

pub fn hch4inten(&self) -> &Hch4inten

0x18c - host channel-4 interrupt enable register (HCH4INTEN)

source

pub fn hch4len(&self) -> &Hch4len

0x190 - host channel-4 transfer length register

source

pub fn hch5ctl(&self) -> &Hch5ctl

0x1a0 - host channel-5 characteristics register (HCH5CTL)

source

pub fn hch5intf(&self) -> &Hch5intf

0x1a8 - host channel-5 interrupt register (HCH5INTF)

source

pub fn hch5inten(&self) -> &Hch5inten

0x1ac - host channel-5 interrupt enable register (HCH5INTEN)

source

pub fn hch5len(&self) -> &Hch5len

0x1b0 - host channel-5 transfer length register

source

pub fn hch6ctl(&self) -> &Hch6ctl

0x1c0 - host channel-6 characteristics register (HCH6CTL)

source

pub fn hch6intf(&self) -> &Hch6intf

0x1c8 - host channel-6 interrupt register (HCH6INTF)

source

pub fn hch6inten(&self) -> &Hch6inten

0x1cc - host channel-6 interrupt enable register (HCH6INTEN)

source

pub fn hch6len(&self) -> &Hch6len

0x1d0 - host channel-6 transfer length register

source

pub fn hch7ctl(&self) -> &Hch7ctl

0x1e0 - host channel-7 characteristics register (HCH7CTL)

source

pub fn hch7intf(&self) -> &Hch7intf

0x1e8 - host channel-7 interrupt register (HCH7INTF)

source

pub fn hch7inten(&self) -> &Hch7inten

0x1ec - host channel-7 interrupt enable register (HCH7INTEN)

source

pub fn hch7len(&self) -> &Hch7len

0x1f0 - host channel-7 transfer length register

Trait Implementations§

source§

impl Debug for UsbfsHost

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl Deref for UsbfsHost

§

type Target = RegisterBlock

The resulting type after dereferencing.
source§

fn deref(&self) -> &Self::Target

Dereferences the value.
source§

impl Send for UsbfsHost

Auto Trait Implementations§

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.