[][src]Struct usbd_scsi::Scsi

pub struct Scsi<'a, B: UsbBus, BD: BlockDevice> { /* fields omitted */ }

Methods

impl<'_, B: UsbBus, BD: BlockDevice> Scsi<'_, B, BD>[src]

pub fn new<V: AsRef<[u8]>, P: AsRef<[u8]>, R: AsRef<[u8]>>(
    alloc: &UsbBusAllocator<B>,
    max_packet_size: u16,
    block_device: BD,
    vendor_identification: V,
    product_identification: P,
    product_revision_level: R
) -> Scsi<B, BD>
[src]

Creates a new Scsi block device

block_device provides reading and writing of blocks to the underlying filesystem vendor_identification is an ASCII string that forms part of the SCSI inquiry response. Should come from t10. Any semi-unique non-blank string should work fine for local development. Panics if > 8 characters are supplied. product_identification is an ASCII string that forms part of the SCSI inquiry response. Vendor (probably you...) defined so pick whatever you want. Panics if > 16 characters are supplied. product_revision_level is an ASCII string that forms part of the SCSI inquiry response. Vendor (probably you...) defined so pick whatever you want. Typically a version number. Panics if > 4 characters are supplied.

Trait Implementations

impl<'_, B: UsbBus, BD: BlockDevice> UsbClass<B> for Scsi<'_, B, BD>[src]

Auto Trait Implementations

impl<'a, B, BD> Send for Scsi<'a, B, BD> where
    BD: Send

impl<'a, B, BD> Sync for Scsi<'a, B, BD> where
    BD: Sync

impl<'a, B, BD> Unpin for Scsi<'a, B, BD> where
    BD: Unpin

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T[src]

type Output = T

Should always be Self

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.