没有合适的资源?快使用搜索试试~ 我知道了~
VB获取硬盘物理序列号源码借鉴.pdf
1.该资源内容由用户上传,如若侵权请联系客服进行举报
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
2.虚拟产品一经售出概不退款(资源遇到问题,请及时私信上传者)
版权申诉
0 下载量 27 浏览量
2021-11-18
14:32:45
上传
评论
收藏 92KB PDF 举报
温馨提示
试读
9页
VB获取硬盘物理序列号源码借鉴.pdf
资源推荐
资源详情
资源评论
VB 获取硬盘物理序列号源码
'============================================
'模块功能:取得硬盘的信息
'更新日期: 2005/7/8
'调用方法:
' GetDiskVolume() 取得逻辑盘的序列号
' GetHardDiskInfo() 取得物理盘的型号或序列号
'============================================
Private Const MAX_IDE_DRIVES As Long = 4 ' Max number of drives assuming p
rimary/secondary, master/slave topology
Private Const READ_ATTRIBUTE_BUFFER_SIZE As Long = 512
Private Const IDENTIFY_BUFFER_SIZE As Long = 512
Private Const READ_THRESHOLD_BUFFER_SIZE As Long = 512
Private Const DFP_GET_VERSION As Long = &H74080
Private Const DFP_SEND_DRIVE_COMMAND As Long = &H7C084
Private Const DFP_RECEIVE_DRIVE_DATA As Long = &H7C088
Private Type GETVERSIONOUTPARAMS
bVersion As Byte ' Binary driver version.
bRevision As Byte ' Binary driver revision.
bReserved As Byte ' Not used.
bIDEDeviceMap As Byte ' Bit m ap of IDE devices.
fCapabilities As Long ' Bit m ask of driver capabilities.
dwReserved( 3 ) As Long ' For future use.
End Type
Private Const CAP_IDE_ID_FUNCTION As Long = 1 ' ATA ID command s
upported
Private Const CAP_IDE_ATAPI_ID As Long = 2 ' ATAPI ID command s
upported
Private Const CAP_IDE_EXECUTE_SMART_FUNCTION As Long = 4 ' SMART com
mannds supported
Private Type IDEREGS
bFeaturesReg As Byte ' Used for specifying SMART "commands".
bSectorCount Reg As Byte ' IDE sector count register
bSectorNumberReg As Byte ' IDE sector number register
bCylLowReg As Byte ' IDE low order cylinder value
bCylHighReg As Byte ' IDE high order cylinder value
bDriveHeadReg As Byte ' IDE drive/head register
bCommandReg As Byte ' Actual IDE command.
bReserved As Byte ' reserved for future use. Must be zero.
End Type
Private Type SENDCMDINPARAMS
cBufferSize As Long ' Buffer size in bytes
irDriveRegs As IDEREGS ' Structure with drive register values.
bDriveNumber As Byte ' Physical drive number to send
资源评论
hyj15659071652
- 粉丝: 0
- 资源: 7万+
下载权益
C知道特权
VIP文章
课程特权
开通VIP
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功