pub enum PollResult {
None,
Reset,
Data {
ep_out: u16,
ep_in_complete: u16,
ep_setup: u16,
},
Suspend,
Resume,
}
Expand description
Event and incoming packet information returned by UsbBus::poll
.
Variants§
None
No events or packets to report.
Reset
The USB reset condition has been detected.
Data
USB packets have been received or sent. Each data field is a bit-field where the least significant bit represents endpoint 0 etc., and a set bit signifies the event has occurred for the corresponding endpoint.
Fields
§
ep_out: u16
An OUT packet has been received. This event should continue to be reported until the packet is read.
Suspend
A USB suspend request has been detected or, in the case of self-powered devices, the device has been disconnected from the USB bus.
Resume
A USB resume request has been detected after being suspended or, in the case of self-powered devices, the device has been connected to the USB bus.
Auto Trait Implementations§
impl Freeze for PollResult
impl RefUnwindSafe for PollResult
impl Send for PollResult
impl Sync for PollResult
impl Unpin for PollResult
impl UnwindSafe for PollResult
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more