CPUInfo for VB
Video Capture Help ] AVIFile Tutorial ] Licensing and Distribution ] Resources ] Awards ] Latest News ] Source Code ] Free Controls ]

 

CPUINFO.EXE
Download (20k) free DLL and VB source here!

This sample project demos how to obtain CPU information from Intel CPUs by using the CPUInf package available on the Intel Website. I have translated the original C declarations into a reusable VB module called CPUInf32.bas. If you want to examine the original C header files or source code you should download the 
Intel CPUInf developer package
here.

[VERSION HISTORY]
1/25/99
Now suports Pentium II Celeron A CPUs! - Added one line to a SelectCase statement. This shows how easy it is to add support for future processors too!

9/25/98
Because of feedback from a couple of intrepid VB'ers, I discovered that the original CPUINFO.EXE had two functions which were not reliable in all cases. I had originally tried to work around the incompatibilities in the Intel CPUinf32.dll as an exercise, but because of the problems I have decided to modify and recompile the C DLL to be more "VB-friendly". Because of this, and in order to avoid version problems with the Intel DLL, I have renamed the C DLL to vbCPUInf.dll. This new package should be faster and more reliable under VB and features the following expanded CPU benchmarking functions:
cpunormspeed()
cpurawspeed()
vbcpuspeed()

Techniques demonstrated in this project
---------------------------------------
-Calling functions in a 3rd party DLL function library
-Working with register-level "packed bitfields"
-Handling a 64bit integer by using a currency type to receive thevalue and then using RTLMoveMemory() to transfer it to 2 long types
Useful functions in CPUInf32.bas
--------------------------------
wincpuidsupport()
processorcount()
cpunormspeed()
cpurawspeed()
getCPUDescription()
getcpudescriptionString()
getcpumodel()
getcputype()
wincpuid()/getcpufamily()
CPUhasMMX()
CPUhasFPU()
CPUHasTimeStampCounter()
GetTimeStampCode()
GetDllVerString()
GetBit()
vbcpuspeed() (new!)


You may freely use and modify this code in your
own programs. However, you may not redistribute
this archive without permission from Ray Mercer
<raymer@shrinkwrapvb.com>

Copyright (c) 1998-2000, Ray Mercer - All Rights Reserved