UsbDeviceClass UsbDeviceClass UsbDeviceClass UsbDeviceClass UsbDeviceClass Class

Definition

Provides a way for the app to get an Advanced Query Syntax (AQS) string by specifying the class code, subclass code, and the protocol code defined by the device. The properties in this class are passed in the call to GetDeviceClassSelector.

public : sealed class UsbDeviceClass : IUsbDeviceClass
struct winrt::Windows::Devices::Usb::UsbDeviceClass : IUsbDeviceClass
public sealed class UsbDeviceClass : IUsbDeviceClass
Public NotInheritable Class UsbDeviceClass Implements IUsbDeviceClass
var usbDeviceClass = new usbDeviceClass();
Attributes
Windows 10 requirements
Device family
Windows 10 (introduced v10.0.10240.0)
API contract
Windows.Foundation.UniversalApiContract (introduced v1)

Remarks

You can create a UsbDeviceClass object by specifying any one of the following sets of properties:

  • Class code.
  • Class and subclass codes.
  • Class, subclass, and protocol codes.

This code example shows how to specify the device class and subclass codes to obtain a UsbDevice object.

    byte deviceClass = 0xf0;
    byte deviceSubclass = 0x01;

    var myDevices = await 
                          Windows.Devices.Enumeration.DeviceInformation.FindAllAsync(
                          UsbDevice.GetDeviceClassSelector(
                          new UsbDeviceClass() {
                          Class = deviceClass, Subclass = deviceSubclass }));

Constructors

UsbDeviceClass() UsbDeviceClass() UsbDeviceClass() UsbDeviceClass() UsbDeviceClass()

Creates a UsbDeviceClass object.

Properties

ClassCode ClassCode ClassCode ClassCode ClassCode

Gets or sets the class code of the device.

ProtocolCode ProtocolCode ProtocolCode ProtocolCode ProtocolCode

Gets or sets the protocol code of the device.

SubclassCode SubclassCode SubclassCode SubclassCode SubclassCode

Gets or sets the subclass code of the device.