RFID_STATUS WINAPI RFID_ConnectW ( RFID_HANDLE32 *  pReaderHandle,
TCHAR *  pHostName,
UINT32  port,
UINT32  timeoutMilliseconds,
LPCONNECTION_INFO  lpConnectionInfo 
)

This function establishes an LLRP connection to an RFID reader and returns a handle on successful connection.

Parameters:
[out] pReaderHandle 
Pointer to Handle to the RFID device.
[in] pHostName 
String containing the reader's host name. Can be NULL for device-based readers like MC, where the Dll connects to local-host.
[in] port 
Port number, if specified as zero (0), the default port 5084 will be used.
[in] timeoutMilliseconds 
Time out for the response from the Reader, if specified zero(0), the default time out 5000 (5sec) will be used. The lowest possible value could be 2sec. This value also translates to keep-alive timeout. If the connection to the reader was inactive (no keep-alive message from the Reader) for a time greater than 10 times the timeout, DISCONNECTION_EVENT will be triggered to the application, if the application has registered for the same.
[in] rsvd 
Reserved for future use.
Returns:
If the function succeeds, the return value is RFID_API_SUCCESS. If the function fails, the return value is one of the following:
  • RFID_COMM_OPEN_ERROR Unable to open connection with reader
  • RFID_COMM_CONNECTION_ALREADY_EXISTS Another Connection exists
  • RFID_COMM_RESOLVE_ERROR Unable to resolve IP or Host Name
Remarks:
None
See also:
RFID_Disconnect
Remarks:
Example:
RFID_HANDLE32 readerHandle;
RFID_STATUS rfidStatus = RFID_API_SUCCESS;
READER_ID readerId;
VERSION_INFO versionInfo;

if(RFID_API_SUCCESS == RFID_Connect(&readerHandle, TEXT("157.235.207.190"), 0, 0, 0))
{
// Set trace level
rfidStatus = RFID_SetTraceLevel(readerHandle, TRACE_LEVEL_ALL);
// Get DLL Version
RFID_GetDllVersionInfo(&versionInfo);
printf("\n Dll Verison: %S", versionInfo.dllVersion);

// Do something - Configurations, Capabilities, Inventory, Access
rfidStatus = RFID_Disconnect(readerHandle);
}


Generated on Fri Mar 4 02:25:29 2016 for RFIDAPI3 1.1 C API Documentation by  doxygen 1.5.6