能力值:
(RANK:260 )
|
-
-
2 楼
用scsi方法来读。
大致步骤是这样几个API
sprintf (driveName, "\\\\.\\Scsi%d:", controller);
// Windows NT, Windows 2000, any rights should do
hScsiDriveIOCTL = CreateFile (driveName,
GENERIC_READ | GENERIC_WRITE,
FILE_SHARE_READ | FILE_SHARE_WRITE, NULL,
OPEN_EXISTING, 0, NULL);
DeviceIoControl (hScsiDriveIOCTL, IOCTL_SCSI_MINIPORT,
&inBuffer,
sizeof (inBuffer),
&outBuffer,
sizeof (outBuffer),
&dummy, NULL)
关于 IOCTL_SCSI_MINIPORT及缓冲区数据的结构,自己查。
|
|
|