Crate embassy_usb_driver

Source
Expand description

§embassy-usb-driver

This crate contains the driver traits for embassy-usb. HAL/BSP crates can implement these traits to add support for using embassy-usb for a given chip/platform.

The traits are kept in a separate crate so that breaking changes in the higher-level embassy-usb APIs don’t cause a semver-major bump of this crate. This allows existing HALs/BSPs to be used with the newer embassy-usb without needing updates.

If you’re writing an application using USB, you should depend on the main embassy-usb crate instead of this one.

§Interoperability

This crate can run on any executor.

Structs§

EndpointAddress
Type-safe endpoint address.
EndpointAllocError
Allocating an endpoint failed.
EndpointInfo
Information for an endpoint.
Unsupported
Operation is unsupported by the driver.

Enums§

Direction
Direction of USB traffic. Note that in the USB standard the direction is always indicated from the perspective of the host, which is backward for devices, but the standard directions are used for consistency.
EndpointError
Errors returned by EndpointIn::write and EndpointOut::read
EndpointType
USB endpoint transfer type. The values of this enum can be directly cast into u8 to get the transfer bmAttributes transfer type bits.
Event
Event returned by Bus::poll.

Traits§

Bus
USB bus trait.
ControlPipe
USB control pipe trait.
Driver
Main USB driver trait.
Endpoint
Endpoint trait, common for OUT and IN.
EndpointIn
IN Endpoint trait.
EndpointOut
OUT Endpoint trait.