ProgsX
asked on
serial number
How to take the serial number computer or motherboard
see here https://www.experts-exchange.com/questions/22022552/Motherboard-ID.html
CPU Serial NUmber:
type
TCPUID = array[1..4] of Longint;
function IsCPUID_Available : Boolean; register;
asm
PUSHFD {direct access to flags no possible, only via stack}
POP EAX {flags to EAX}
MOV EDX,EAX {save current flags}
XOR EAX,ID_BIT {not ID bit}
PUSH EAX {onto stack}
POPFD {from stack to flags, with not ID bit}
PUSHFD {back to stack}
POP EAX {get back to EAX}
XOR EAX,EDX {check if ID bit affected}
JZ @exit {no, CPUID not availavle}
MOV AL,True {Result=True}
@exit:
end;
function GetCPUID : TCPUID; assembler; register;
asm
PUSH EBX {Save affected register}
PUSH EDI
MOV EDI,EAX {@Resukt}
MOV EAX,1
DW $A20F {CPUID Command}
STOSD {CPUID[1]}
MOV EAX,EBX
STOSD {CPUID[2]}
MOV EAX,ECX
STOSD {CPUID[3]}
MOV EAX,EDX
STOSD {CPUID[4]}
POP EDI {Restore registers}
POP EBX
end;
Not sure you can get the graphics serial number as it is probably not coded into the GPU BIOS.
JJ
type
TCPUID = array[1..4] of Longint;
function IsCPUID_Available : Boolean; register;
asm
PUSHFD {direct access to flags no possible, only via stack}
POP EAX {flags to EAX}
MOV EDX,EAX {save current flags}
XOR EAX,ID_BIT {not ID bit}
PUSH EAX {onto stack}
POPFD {from stack to flags, with not ID bit}
PUSHFD {back to stack}
POP EAX {get back to EAX}
XOR EAX,EDX {check if ID bit affected}
JZ @exit {no, CPUID not availavle}
MOV AL,True {Result=True}
@exit:
end;
function GetCPUID : TCPUID; assembler; register;
asm
PUSH EBX {Save affected register}
PUSH EDI
MOV EDI,EAX {@Resukt}
MOV EAX,1
DW $A20F {CPUID Command}
STOSD {CPUID[1]}
MOV EAX,EBX
STOSD {CPUID[2]}
MOV EAX,ECX
STOSD {CPUID[3]}
MOV EAX,EDX
STOSD {CPUID[4]}
POP EDI {Restore registers}
POP EBX
end;
Not sure you can get the graphics serial number as it is probably not coded into the GPU BIOS.
JJ
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
this accessible site is not
http://www.workshop-alex.org/sources/WbemScripting_TLB/WbemScripting_TLB.pas
http://www.workshop-alex.org/sources/WbemScripting_TLB/WbemScripting_TLB.pas
Strange... i can download it from my browser.
Try from here :
http://www.geocities.com/kalatz_gr_fisher/TheFiles/WbemScripting_TLB.pas
Try from here :
http://www.geocities.com/kalatz_gr_fisher/TheFiles/WbemScripting_TLB.pas
CPU serial number?
Available on -some- PentiumIIIs not available on anything pre P3 and NOT available on anything after P3 either :(
Available on -some- PentiumIIIs not available on anything pre P3 and NOT available on anything after P3 either :(
@CodeK: Nice one! WMI is the -only- way to fly.
:)