#usb #device #probe #linux

usb-disk-probe

Provides a stream type which can be used to probe for USB storage devices in the system

1 unstable release

0.1.0 Dec 13, 2019

#11 in #device

Download history 35/week @ 2020-06-04 9/week @ 2020-06-11 27/week @ 2020-06-18 21/week @ 2020-06-25 34/week @ 2020-07-02 18/week @ 2020-07-09 29/week @ 2020-07-16 34/week @ 2020-07-23 55/week @ 2020-07-30 73/week @ 2020-08-06 60/week @ 2020-08-13 38/week @ 2020-08-20 59/week @ 2020-08-27 34/week @ 2020-09-03 55/week @ 2020-09-10 51/week @ 2020-09-17

186 downloads per month

MIT/Apache

12KB
84 lines

usb-disk-probe

Crates.io

Provides a stream type which can be used to probe for USB storage devices in the system.

Example

use usb_disk_probe::stream::UsbDiskProbe;

use futures::stream::StreamExt;

fn main() {
    futures::executor::block_on(async move {
        let mut stream = UsbDiskProbe::new().await.unwrap();
        while let Some(device_result) = stream.next().await {
            let device = device_result.unwrap();
            println!("{}", device.display());
        }
    });
}

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.

Dependencies

~2.1–4MB
~79K SLoC