new·The score now tells you which way it movedA brain's exam only ever grows: its own material writes questions, and so does every question a real caller asked and did not get answered. The score is a percentage over that growing set, so a brain that learned more could post a smaller number — and this week three did. One of them answered two MORE questions than the week before and showed eighteen points less. Printed as a single percentage, that reads as decline to a reader and as punishment to anyone who contributes material.all news →
mozg.beta
Sign in

Electron · API · all subjects

hid-device/structure

7 notes, read out of this brain and free to use. Each one was extracted from a source and is re-checked against its exam.

HIDDevice Object structure and fields

The HIDDevice object represents a HID (Human Interface Device) with the following fields: deviceId (string, required) - unique identifier for the device; name (string, required) - name of the device; vendorId (integer, required) - USB vendor ID; productId (integer, required) - USB product ID; serialNumber (string, optional) - USB device serial number; guid (string, optional) - unique identifier for the HID interface (a device may have multiple HID interfaces); collections (Object array, required) - an array of report formats.

HIDDevice collections array structure

Each item in the collections array of a HIDDevice contains: usage (integer) - usage ID component of the HID usage associated with this collection; usagePage (integer) - usage page component of the HID usage associated with this collection; type (integer) - 8-bit value representing collection type describing different relationship between grouped items; children (Object array) - sub-collections in the same format as top-level collection; inputReports (Object array) - input reports described in this collection; outputReports (Object array) - output reports described in this collection; featureReports (Object array) - feature reports described in this collection.

USBDevice object structure and properties

The USBDevice object contains the following properties: configuration (optional USBConfiguration object with configurationValue Integer, configurationName string, and interfaces array), configurations array of USBConfiguration objects, deviceClass Integer, deviceId string, deviceProtocol Integer, deviceSubclass Integer, deviceVersionMajor Integer, deviceVersionMinor Integer, deviceVersionSubminor Integer, manufacturerName string (optional), productId Integer, productName string (optional), serialNumber string (optional), usbVersionMajor Integer, usbVersionMinor Integer, usbVersionSubminor Integer, and vendorId Integer.

USBConfiguration object structure

The USBConfiguration object contains configurationValue (Integer - the configuration value of this configuration), configurationName (string - the name provided by the device to describe this configuration), and interfaces (array of USBInterface objects containing information about interfaces provided by the USB device).

USBInterface object structure

The USBInterface object contains interfaceNumber (Integer - the interface number of this interface), alternate (the currently selected alternative configuration of this interface), and alternates (array of USBAlternateInterface objects describing each of the alternative configurations possible for this interface).

USBAlternateInterface object structure

The USBAlternateInterface object (returned within the alternate property and alternates array) contains alternateSetting (Integer - the alternate setting number), interfaceClass (Integer - the class of this interface, see USB.org for class code descriptions), interfaceSubclass (Integer - the subclass of this interface), interfaceProtocol (Integer - the protocol supported by this interface), interfaceName (string, optional - the name of the interface if provided by the device), and endpoints (array of USBEndpoint objects describing each endpoint that is part of this interface).

USBEndpoint object structure

The USBEndpoint object contains endpointNumber (Integer - value from 1 to 15), direction (string - either 'in' or 'out'), type (string - either 'bulk', 'interrupt', or 'isochronous'), and packetSize (Integer - the size of packets that data sent through this endpoint will be divided into).

Give your agent this brain