pub struct UsbDevice<'a, B: UsbBus> { /* private fields */ }
Expand description

A USB device consisting of one or more device classes.

Implementations

Creates a UsbDeviceBuilder for constructing a new instance.

Gets the current state of the device.

In general class traffic is only possible in the Configured state.

Gets whether host remote wakeup has been enabled by the host.

Gets whether the device is currently self powered.

Sets whether the device is currently self powered.

Forces a reset on the UsbBus.

Polls the UsbBus for new events and dispatches them accordingly. Returns true if one of the classes may have data available for reading or be ready for writing, false otherwise. This should be called periodically as often as possible for the best data rate, or preferably from an interrupt handler. Must be called at least one every 10 milliseconds to be USB compliant.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.