欢迎来到天天文库
浏览记录
ID:22513475
大小:55.00 KB
页数:18页
时间:2018-10-29
《获取本机信息》由会员上传分享,免费在线阅读,更多相关内容在行业资料-天天文库。
1、#define FILE_DEVICE_SCSI 0x0000001b#define IOCTL_SCSI_MINIPORT_IDENTIFY ((FILE_DEVICE_SCSI<<16)+0x0501)#define IOCTL_SCSI_MINIPORT0x0004D008 #define IDENTIFY_BUFFER_SIZE 512#define SENDIDLENGTH (sizeof(SENDCMDOUTPARAMS)+IDENTIFY_BUFFER_SIZE)#define IDE_ATA
2、PI_IDENTIFY 0xA1 // ReturnsIDsectorforATAPI.#define IDE_ATA_IDENTIFY 0xEC // ReturnsIDsectorforATA.#define DFP_RECEIVE_DRIVE_DATA 0x0007c088 typedefstruct_IDSECTOR{ USHORT wGenConfig; USHORT wNumCyls; USHORT wReserved; USHORT wNumHeads; USHORT wB
3、ytesPerTrack; USHORT wBytesPerSector; USHORT wSectorsPerTrack; USHORT wVendorUnique[3]; CHAR sSerialNumber[20]; USHORT wBufferType; USHORT wBufferSize; USHORT wECCSize; CHAR sFirmwareRev[8]; CHAR sModelNumber[40]; USHORT wMoreVendor
4、Unique; USHORT wDoubleWordIO; USHORT wCapabilities; USHORT wReserved1; USHORT wPIOTiming; USHORT wDMATiming; USHORT wBS; USHORT wNumCurrentCyls; USHORT wNumCurrentHeads; USHORT wNumCurrentSectorsPerTrack; ULONG ulCurrentSectorCapacity;
5、 USHORT wMultSectorStuff; ULONG ulTotalAddressableSectors; USHORT wSingleWordDMA; USHORT wMultiWordDMA; BYTE bReserved[128];}IDSECTOR,*PIDSECTOR; typedefstruct_DRIVERSTATUS{ BYTE bDriverError; // Errorcodefromdriver,or0ifnoerror. BYTE bIDEStatus
6、; // ContentsofIDEErrorregister. // OnlyvalidwhenbDriverErrorisSMART_IDE_ERROR. BYTE bReserved[2]; // Reservedforfutureexpansion. DWORD dwReserved[2]; // Reservedforfutureexpansion.}DRIVERSTATUS,*PDRIVERSTATUS,*LPDRIVERSTATUS; typedefstruct_SENDCMDOUTPARAMS{
7、 DWORD cBufferSize; // SizeofbBufferinbytes DRIVERSTATUS DriverStatus; // Driverstatusstructure. BYTE bBuffer[1]; // Bufferofarbitrarylengthinwhichtostorethedatareadfromthe //drive.}SENDCM
8、DOUTPARAMS,*PSENDCMDOUTPARAMS,*LPSENDCMDOUTPARAMS; typ
此文档下载收益归作者所有