Class WebUSBDevice

Wrapper to make a node-usb device look like a webusb device

Implements

  • USBDevice

Properties

configurations: USBConfiguration[] = []
deviceClass: number
deviceProtocol: number
deviceSubclass: number
deviceVersionMajor: number
deviceVersionMinor: number
deviceVersionSubminor: number
manufacturerName?: string
productId: number
productName?: string
serialNumber?: string
usbVersionMajor: number
usbVersionMinor: number
usbVersionSubminor: number
vendorId: number

Accessors

  • get configuration(): undefined | USBConfiguration
  • Returns undefined | USBConfiguration

Methods

  • Parameters

    • interfaceNumber: number

    Returns Promise<void>

  • Parameters

    • direction: USBDirection
    • endpointNumber: number

    Returns Promise<void>

  • Parameters

    • setup: USBControlTransferParameters
    • length: number

    Returns Promise<USBInTransferResult>

  • Parameters

    • setup: USBControlTransferParameters
    • Optionaldata: ArrayBuffer

    Returns Promise<USBOutTransferResult>

  • Parameters

    • _endpointNumber: number
    • _packetLengths: number[]

    Returns Promise<USBIsochronousInTransferResult>

  • Parameters

    • _endpointNumber: number
    • _data: BufferSource
    • _packetLengths: number[]

    Returns Promise<USBIsochronousOutTransferResult>

  • Parameters

    • interfaceNumber: number

    Returns Promise<void>

  • Parameters

    • interfaceNumber: number
    • alternateSetting: number

    Returns Promise<void>

  • Parameters

    • configurationValue: number

    Returns Promise<void>

  • Parameters

    • endpointNumber: number
    • length: number

    Returns Promise<USBInTransferResult>

  • Parameters

    • endpointNumber: number
    • data: ArrayBuffer

    Returns Promise<USBOutTransferResult>