Struct rusb::Device [−][src]
pub struct Device<T: UsbContext> { /* fields omitted */ }
Expand description
A reference to a USB device.
Implementations
Get the raw libusb_device pointer, for advanced use in unsafe code
Safety
Converts an existing libusb_device
pointer into a Device<T>
.
device
must be a pointer to a valid libusb_device
. Rusb increments refcount.
Reads the device descriptor.
Reads a configuration descriptor.
Reads the configuration descriptor for the current configuration.
Returns the number of the bus that the device is connected to.
Opens the device.
Returns the device’s port number
Returns the device’s parent
Trait Implementations
Auto Trait Implementations
impl<T> RefUnwindSafe for Device<T> where
T: RefUnwindSafe,
impl<T> UnwindSafe for Device<T> where
T: UnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more