MCHPHIDClass::HIDClassInit Method (unsigned int, unsigned int, unsigned int, unsigned int)

HID Class DLL

HID Class DLL
MCHPHIDClass::HIDClassInit Method (unsigned int, unsigned int, unsigned int, unsigned int)
C
static void HIDClassInit(
    unsigned int VendorID, 
    unsigned int ProductID, 
    unsigned int BuffSize, 
    unsigned int Timeout
);
Description

Initializes the DLL with the VID, PID, and Buffersize of the device. This function should be called before attempting to communicate with the device. The reads and write use overlapped transfers. This version allows specifying how long to wait before timing out. The default is 1000mS.

Preconditions

None

Parameters
Parameters 
Description 
VendorID 
16 bit unsigned integer. 
ProductID 
16 bit unsigned integer 
BufferSize 
16 bit unsigned integer. Usually 64 
TimeOut 
16 bit unsigned integer. Time in mS to wait for a read or write to timeout before returning. 
Returns

Nothing

Remarks

This function, or an overloaded variant, should be called proir to attempting to communicate with the device.

Example
MCHPHIDCLASS::HIDClassInit(0x4D8, 0x0F00, 64, 250);
Microchip HID Class DLL 1.10 - [15 April 2010]
Copyright © 2009, 2010 Microchip Technology, Inc.  All rights reserved.