Method | Description | |
---|---|---|
AddDevice ( Primitive, VID, Primitive, PID, Primitive, name ) : Primitive, |
Add a HID connected device from its VID and PID. The VID and PID are 4 character (hex) values, and can be found from: Device Manager->Properties->Details->Hardware ids For example: HID\VID_046D PID_C215 REV_0204 has VID "046D" and PID "C215". Only add a device once.
|
|
FindDevices ( ) : Primitive, |
List all found HID (Human Interface Devices).
|
|
GetBits ( Primitive, data ) : Primitive, |
Get an 8 element array of 1s and 0s indicating which bit of a byte are set.
|
|
InputLength ( Primitive, name ) : Primitive, |
Get the input record length for a HID device.
|
|
Output ( Primitive, name, Primitive, data ) : Primitive, |
Send data to the HID device. This must be an array of bytes (0 to 255). The array must be indexed from 1 and have size OutputLength.
|
|
OutputLength ( Primitive, name ) : Primitive, |
Get the output record length for a HID device.
|
|
SetBits ( Primitive, data ) : Primitive, |
Set a byte from an 8 element array of 1s and 0s indicating which bit of a byte are set.
|
Method | Description | |
---|---|---|
CreateDevice ( string VID, string PID, string name ) : bool | ||
DeviceExists ( int VID, int PID, string name ) : bool | ||
FindAllDevices ( ) : List
|
||
GetDevice ( string name ) : HID_Device | ||
_OnDeviceChanged ( object sender, HIDChangedEventArgs args ) : void | ||
_OnDeviceRemoved ( object sender, EventArgs, args ) : void |
public static AddDevice ( Primitive, VID, Primitive, PID, Primitive, name ) : Primitive, | ||
VID | Primitive, | The device VID. |
PID | Primitive, | The device PID. |
name | Primitive, | A name for the device. |
return | Primitive, |
public static GetBits ( Primitive, data ) : Primitive, | ||
data | Primitive, | A byte number (0 to 255). |
return | Primitive, |
public static InputLength ( Primitive, name ) : Primitive, | ||
name | Primitive, | The device name. |
return | Primitive, |
public static Output ( Primitive, name, Primitive, data ) : Primitive, | ||
name | Primitive, | The HID device name. |
data | Primitive, | The data to send. |
return | Primitive, |
public static OutputLength ( Primitive, name ) : Primitive, | ||
name | Primitive, | The HID device name. |
return | Primitive, |
public static SetBits ( Primitive, data ) : Primitive, | ||
data | Primitive, | An 8 element array of 1s and 0s (small bit first). |
return | Primitive, |