PTRobot API
Page 9 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.
// pdwNumRobots
//
///////////////////////////
DWORD WINAPI
PTRobot_EnumRobots
(HANDLE
*
phRobots, DWORD
*
pdwNumRobots);
2.1.5
PTRobot_EnumDrives
///////////////////////////
//
// PTRobot_EnumDrives
//
// Description:
//
Function to enumerate the drives on the system and
//
determine which drives are under the control of this
//
robot.
// Params:
//
hRobot
Handle to the robot to enumerate the drives of.
//
phDrives
points to an array of DWORDS to store
//
the Drives found.
//
pdwNumDrives
points to a DWORD containing the number of HANDLEs
//
in the phDrives array. This value is an input
//
and an output. The user should specify the size
//
(number of HANDLEs) of the phDrives array on input.
//
The value of the pdwNumDrives on output will be the
//
number of drives found.
//
// Notes:
//
Both params will be updated upon successful completion of this
//
command. phDrives will contain handles to drives connected to
//
this system. pdwNumDrives will will be updated with the number of
//
drives found.
//
//
The format of the drive handles is the following:
//
//
The least significant byte should contain the drive letter, the
//
other three bytes should contain the SCSI triple.
//
The drive can be identified by either of these methods.
//
//
For Example: 0x01030044 would identify a drive with:
//
Host=1, ID = 3, LUN = 0, and a drive letter of "D"
//
//
To identify the same drive the client could pass
//
down 0x01030000, 0x00000044, or 0x01030044.
//
// Return:
//
PTROBOT_OK if Successful
//
PTROBOT_SEQUENCE if this command is called out of sequence or after
// PTRobot_EnumDrivesWithList
//
PTROBOT_INTERNAL if an internal error occurred
//
PTROBOT_INVALID_ROBOT if the robot handle is invalid
//
PTROBOT_OVERFLOW if the number of drives found is > the value in
// pdwNumDrives
//
PTROBOT_MULTDRIVES if the module cannot determine which drives are