PTRobot API
Page 8 of 41
© 2005, Primera Technology, Inc. Primera is a registered trademark and Bravo is a trademark of Primera Technology, Inc. All other trademarks are the property of
their respective companies.
//
Function to setup logging in the PTRobot module. We advise that your
//
application has a "back door" method of turning debugging on. All debugging
//
is off by default.
// Params:
//
szDbgFile
full path to a debug file
//
dwDbgLvl
debug
Level
(0-5)
//
0 = off, 1 = errors, 2 = warnings
//
3 = Info, 4 and 5 = more info
//
szTraceFile
full path to a trace file
// Notes:
//
If szDbgFile is NULL then debugging will be turned off. If szTraceFile is
//
NULL then function tracing will be off. Function tracing just logs the
//
API function calls including the parameters.
// Return:
//
PTROBOT_OK if Successful
//
PTROBOT_INTERNAL if an internal error occurred
//
///////////////////////////
DWORD WINAPI
PTRobot_SetupDebugging
(TCHAR
*
szDbgFile, DWORD dwDbgLvl, TCHAR
*
szTraceFile);
2.1.4
PTRobot_EnumRobots
///////////////////////////
//
// PTRobot_EnumRobots
//
// Description:
//
Function to enumerate the Robots on the system.
// Params:
//
phRobots
points to an array of HANDLEs to store
//
the Robots found.
//
pdwNumRobots
points to a DWORD containing the number of HANDLEs
//
in the phRobots array. This value is an input
//
and an output. The user should specify the size
//
(number of HANDLEs) of the phRobots array on input.
//
The value of the pdwNumRobots on output will be the
//
number of robots found.
//
// Notes:
//
Both params will be updated upon successful completion of this
// command. phRobots will contain handles to robots connected to
// this system. pdwNumRobots will will be updated with the number of
// robots found.
// Also, note that the hDrives[] array in the PTRobotInfo will not be
//
valid until PTRobot_EnumDrives is called.
//
// Return:
//
PTROBOT_OK if Successful
//
PTROBOT_INVALID_ROBOT if no robots found
//
PTROBOT_SEQUENCE if this command is called out of sequence
//
PTROBOT_INTERNAL if an internal error occurred
//
PTROBOT_OVERFLOW if the number of robots found is > the value in