PDA

Click to See Complete Forum and Search --> : Cpu


Slime
Feb 27th, 2001, 10:32 AM
what are the API that show CPU information , same as the FSB , the clock rate or the temperature...

Vlatko
Feb 27th, 2001, 02:14 PM
GetSystemInfo API can retrieve some CPU characteristics.

Private Declare Sub GetSystemInfo Lib "kernel32" (lpSystemInfo As SYSTEM_INFO)
Private Type SYSTEM_INFO
dwOemID As Long
dwPageSize As Long
lpMinimumApplicationAddress As Long
lpMaximumApplicationAddress As Long
dwActiveProcessorMask As Long
dwNumberOrfProcessors As Long
dwProcessorType As Long
dwAllocationGranularity As Long
dwReserved As Long
End Type
Private Sub Form_Load()
Dim SInfo As SYSTEM_INFO
'Set the graphical mode to persistent
Me.AutoRedraw = True
'Get the system information
GetSystemInfo SInfo
'Print it to the form
Me.Print "Number of procesor:" + str$(SInfo.dwNumberOrfProcessors)
Me.Print "Processor:" + str$(SInfo.dwProcessorType)
Me.Print "Low memory address:" + str$(SInfo.lpMinimumApplicationAddress)
Me.Print "High memory address:" + str$(SInfo.lpMaximumApplicationAddress)
End Sub

Slime
Feb 28th, 2001, 06:37 AM
thx