You are not logged in. Please login or register.
Active topics Unanswered topics
Search options
DriverPacks.net Forum » Posts by jayphizzle
Hey everyone,
i found something to identify the hardware typ (notebook/desktop).
Don't know if this can be implemented "easily" into the script.
"ChassisTypes"
http://msdn.microsoft.com/en-us/library … s.85).aspx
In a vbs script it looks like this:
' Get the SMBIOS asset tag from the Win32_SystemEnclosure class
Set objResults = objWMI.InstancesOf("Win32_SystemEnclosure")
bIsLaptop = false
bIsDesktop = false
bIsServer = false
For each objInstance in objResults
If objInstance.ChassisTypes(0) = 12 or objInstance.ChassisTypes(0) = 21 then
' Ignore docking stations
Else
If not IsNull(objInstance.SMBIOSAssetTag) then
sAssetTag = Trim(objInstance.SMBIOSAssetTag)
End if
Select Case objInstance.ChassisTypes(0)
Case "8", "9", "10", "11", "12", "14", "18", "21"
bIsLaptop = true
Case "3", "4", "5", "6", "7", "15", "16"
bIsDesktop = true
Case "23"
bIsServer = true
Case Else
' Do nothing
End Select
End if
Next
For a Desktop it would only select the DriverPacks:
Audio
Chipset
Graphics A&B
LAN
MassStorage
Misc
and for a Laptop all DriverPacks without the Graphics A&B.
TechDud wrote:...look for the presence of a battery to detect a portable, perhaps?
I had the same idea, but did not found any command to check that.
mr_smartepants wrote:Hmm. It's possible. I'd have to do some testing.
Maybe I'll put it on my "to do" list.
Would be great
mr_smartepants wrote:I don't know how you'd do your second option. How would the script know what machine it's running on? I'm not going to have it scan HWIDs and match a table of known laptops. That would take longer than to copy the files over!
Ok i thougt there is an registry entrie or something like this.
We use small script with identifiy the hardware typ.
FOR /F "tokens=2 delims==" %%A IN ('WMIC csproduct GET Name /VALUE ^| FIND /I "Name="') DO SET HWType=%%A
ECHO Computer model: "%HWType%"
GOTO %HWType%
:RETURN
GOTO CONTINUE
With the identified typ e.g. HPCompaq8000EliteSFFPC the related driver installation will be started.
:HPCompaq8000EliteSFFPC
SET LAPTOP=NO
call s:\Driver\Win7\%HWType%\32\8000E.bat
GOTO CONTINUE
Sure this can not be used in your script, the hardware list will be too long.
But perhaps i can change your script for my needs.
Where can i configure that the script only extract the DP's X Y & Z and not all placed in the related folders ?
(Then i can create one for laptops and one for desktops)
Thanks in advance & Happy Easter holidays!
first, thanks mr_smartepants for the great script.
I think it will help me a lot in the next months deploying win7 to several different hardware configurations.
I miss only one "feature" (or perhaps i did not found it yet):
It is possible to install the drivers directly (method 1) from a network source ? (without copying it first to the systemdrive) ?
My hope is that it will be a little bi faster and save some bandwith.
And how can i procced if i will add drivers (OEM specific) manually (method 1&2)?
#EDIT#
In option that the script check if the client is a laptop/desktop would be nice too.
So some packages does not need to coped (e.g. Desktop need to Mobile Graphics, WLAN, Touchpad / Laptop need no Graphics A/B) -> More bandwidth too save
Posts found [ 4 ]
DriverPacks.net Forum » Posts by jayphizzle
Powered by PunBB, supported by Informer Technologies, Inc.
Currently installed 3 official extensions. Copyright © 2003–2009 PunBB.
[ Generated in 0.027 seconds, 6 queries executed ]