Drivers Instalation in Post-Install stage (New Method) Updated: 1.XII.2009 version 2.0.0.28
#151
Posted 11 October 2006 - 06:28 AM
So should I have it start first? Before anything? or wait till windows completely loads then run it?
#152
Posted 11 October 2006 - 06:41 AM
1. Install automaticly windows
2. Login
3. Put CD in drive and start the program
4. Wait for it to do it's job
5. Reboot
6. Do other things.
To make sure program will automagically close when done you can check for process in taskmanager "rundll32.exe". If it exists before program starts then it means program will hang on that and won't close. If it doesn't exist and program still doesn't close check for process rundll32.exe and eventually kill it and see what happens.
Does this intel driver comes with BTS Driver Packs? I never had any problem with using those except on Windows 2000 (well my program on WIN2k was acting strange, not the driver packs itself). On Windows XP or Windows 2003 i didn't had much problems. You can always send me log if you want to.
And have you checked Driver's Path in registry? If it's correctly added there? I don't know how it's possible but my program was reporting 7000 or 12000+ lenght of key registry while everyone is saying 4096 is the limit
So i wonder if it's allright "
#153
Posted 11 October 2006 - 07:08 AM
Where should I look for the string?
Could I do a batch to end process rundll32 before it starts?
I'm not using the driverpacks only because I want to keep the image slim, should I? Or test with the driver packs instead?
This post has been edited by kickarse: 11 October 2006 - 07:14 AM
#154
Posted 11 October 2006 - 07:14 AM
Check here if the path to driver is correct.
And yes you can use batch file to kill process rundll32.exe before my program starts but i think you shouldn't waste your energy on that as my program in next rls should have the ability i wrote in my last posts so it should just skip that .dll. Try doing a test with driver packs (GRAPHICS) and report if it works or behaves the same. If it works maybe it means your "unpacked intel drivers are corrupted or so?".
This post has been edited by MadBoy: 11 October 2006 - 07:16 AM
#155
Posted 11 October 2006 - 07:29 AM
It's all in there properly... It's not a huge deal I suppose. But I cant wait till the next version
This post has been edited by kickarse: 12 October 2006 - 08:22 AM
#156
Posted 12 October 2006 - 08:56 AM
- Changed to diffrent icon
- Added Time_To_Start option in Automatic mode
- Fixed so rundll32.exe process is now detected with more precision (as in even if rundll32.exe processes are running before program starts it only will care for the one that is started right after detection procedure and will ignore the rest)
Mmm kickarse.. here you go
#157
Posted 12 October 2006 - 09:05 PM
I'll check it out tomorrow...
Is Time_to_start in milliseconds?
This post has been edited by kickarse: 13 October 2006 - 06:28 AM
#158
Posted 13 October 2006 - 11:36 AM
#159
Posted 16 October 2006 - 07:16 AM
#160
Posted 17 October 2006 - 10:55 AM
#161
Posted 18 October 2006 - 05:46 AM
#162
Posted 18 October 2006 - 09:16 PM
i think ive finally found a problem with this method,, today i was working on doing a fresh install on a pc thats almost 10 years old,, its sad its a 500 mhz pc with a 10 g hd,, well any ways ,, after i did a fresh install, i tested your latest 6.7 app with bashrats latest driver packs, and the program ran fine, but it says all drivers were there and no need to run program,,
well this is true and not true,, mainly because yes they pc and its perhpriels had its drivers, its deefault drivers on/ from the windows install, but i know for a fact that , that pc has updated drivers that it can have because ive got them all on a disk, i just wanted to test your installer again..
well any ways thats my latest news flash,,, is there any way you can possible set the program to scan for the need on updated drivers and if one is there, the program updates that driver ?
just a thought,,
#163
Posted 19 October 2006 - 03:21 AM
It's a bit problematic to add this without a lot of code. First of all program needs to have some kinda database for it to work. Then it gotta compare driver version and do a lot of comparision to not return false-positive.
I must say the program i am slowly working on might have all this new features but it's gonna be a pain to write it, to test it and to realy make it work
So you gotta be very patient
One of the projects i have in my mind is to totally automate Windows configuration. For example:
1. You install Windows from unattended CD where on the end RunOnceExec starts my little program.
2. In that program you type in new computer name, new domain name, users that are supposed to be added to Administrators Group, your login/pass to domain (for domain connection and for security check). You also choose if missing drivers are supposed to be installed (will use my Pro-S Hardware Standard program) and eventually what Applications from profile of your choice should be installed (i haven't yet rlsed that to public but it works nicely in my ex-company, only problem is this program has everything hardcoded so i will have to rewrite it).
3. Hit START and computer from whatever you choose should do all you wanted.. it will restart automagically everytime it's needed and at the end it will send you email and remove itself
Well that's the plan but who knows how much time i need to do it
#164
Posted 19 October 2006 - 10:55 AM
#165
Posted 28 October 2006 - 08:56 AM
I need your expertise. The script you provided is the script I was looking for.
But I cannot get it to work.
It doesn't do anything. The script you posted hangs on this line:
$DirOutputOnce &= $DirData
I removed the & and script works but doesn't do anything.
I think I know where it hangs. Dirdata and or DirOutputOnce
I hope you can help me.
I need to use this method cause I have 2gb in drivers on my hdd
and the SetupCopyOEMInf.exe method is hanging my system.
Thx
#NoTrayIcon
#include <Constants.au3>
Opt("ExpandEnvStrings", 1)
Opt("WinWaitDelay", 0)
Opt("WinTitleMatchMode",2)
;http://www.msfn.org/board/index.php?showtopic=70209&st=60
$path_to_drivers = "%SYSTEMDRIVE%\WINNT\Drvs\C"
$DirOutputOnce = 0
$DirOutput = Run(@ComSpec & " /c DIR /A:D /S C:\WINNT\Drvs\C", '', @SW_HIDE, 2)
While 1
$DirData = StdoutRead($DirOutput)
If @error Then ExitLoop
If $DirData Then
$DirOutputOnce &= $DirData
Else
Sleep(10)
EndIf
WEnd
MsgBox(0, "DirData", "" & $DirData)
; Remove spaces from output
MsgBox(0, "DirOutputOnce", "" & $DirOutputOnce)
$DirOutputOnce = StringStripWS($DirOutputOnce, 3)
MsgBox(0, "DirOutputOnce Striped", "" & $DirOutputOnce)
; Split output into array
$DirSplit = StringSplit($DirOutputOnce, @CRLF, 1)
$NrCopiedInfs = 0
For $i = 1 To $DirSplit[0]
If StringInStr($DirSplit[$i], $path_to_drivers) Then
$registrystring = StringSplit($DirSplit[$i], ": ", 1)
If $registrystring[0] = 2 Then; Testing amount of elements in array, if more then 2 Exits
If StringInStr($registrystring[2], $path_to_drivers) Then; Making sure that Drivers path exists in string
$drivers_directory = $registrystring[2]
MsgBox(4096, "", "" & $drivers_directory)
$search_ini = FileFindFirstFile($drivers_directory & "\*.inf")
If $search_ini = -1 Then
Else
$dll_exe = DllOpen("setupapi.dll")
While 1
$search_file = FileFindNextFile($search_ini)
$full_path_to_inf = $drivers_directory & "\" & $search_file
If @error Then ExitLoop
$dll_result = DllCall($dll_exe, "int", "SetupCopyOEMInf", "str", $full_path_to_inf, "str", "", "int", 1, "int", 8, "str", "", "int", 0, "int", 0, "str", "")
$NrCopiedInfs = $NrCopiedInfs + 1
; If $logging_option = "Advanced" Then
; If @error = 0 Then
; _AddLineBox("Inf integration passed: " & $drivers_directory & "\" & $search_file)
; $NrCopiedInfs = $NrCopiedInfs + 1
; ElseIf @error = 1 Then
; _AddLineBox("Inf integration failed: " & $drivers_directory & "\" & $search_file)
; ElseIf @error = 2 Or @error = 3 Then
; _AddLineBox("Unknown return type or Function not found in DLL. Tell author about it!")
; EndIf
; EndIf
WEnd
DllClose($dll_exe)
EndIf
FileClose($search_ini)
EndIf
EndIf
EndIf
Next
If $NrCopiedInfs = 1 Then MsgBox(4096, "", "SetupCopyOemInf method completed. " & $NrCopiedInfs & " driver was integrated.",5)
If $NrCopiedInfs = 0 Then MsgBox(4096, "", "SetupCopyOemInf method completed. No drivers were integrated.",5)
If $NrCopiedInfs <> 0 And $NrCopiedInfs <> 1 Then MsgBox(4096, "", "SetupCopyOemInf method completed. " & $NrCopiedInfs & " drivers were integrated.",5)
#166
Posted 28 October 2006 - 01:50 PM
Anyways when you remove "&" from $DirOutputOnce &= $DirData you break it for sure
&= --> Concatenation assignment. e.g. $var = "one", and then $var &= 10 ($var now equals "one10")
In other words. New variable is being added to end of the current value. So it's nessecary.
Btw. have you tested new version of my program (0.6.7) in registrydevicepath method? I believe the limitation of 4096 chars isn't realy in place on WindowsXP and Windows 2003. As you can notice in log after all drivers get added i measure the line in registry and it says 12000 chars here! So check it out. Maybe it will work.
And how your code would be any diffrent then mine? If my code in Pro-S Hardware Standard hangs for you why my code in your use would be any diffrent? Or maybe you use SetupCopyOEMInf.exe from pyron and not my program (as you should know it has that function builtin in it? maybe it won't hang your system).
Edit:
I thought about it and it seems you clearly didn't tried to use my program
This post has been edited by MadBoy: 28 October 2006 - 01:52 PM
#167
Posted 28 October 2006 - 02:09 PM
$path_to_drivers = "C:\Windows"
$DirOutput = Run(@ComSpec & " /c DIR /A:D /S " & $path_to_drivers, '', @SW_HIDE, 2)
#NoTrayIcon
#include <Constants.au3>
Opt("ExpandEnvStrings", 1)
Opt("WinWaitDelay", 0)
Opt("WinTitleMatchMode",2)
;http://www.msfn.org/board/index.php?showtopic=70209&st=60
$path_to_drivers = "C:\Windows"
$DirOutputOnce = 0
$DirOutput = Run(@ComSpec & " /c DIR /A:D /S " & $path_to_drivers, '', @SW_HIDE, 2)
While 1
$DirData = StdoutRead($DirOutput)
If @error Then ExitLoop
If $DirData Then
$DirOutputOnce &= $DirData
Else
Sleep(10)
EndIf
WEnd
$DirOutputOnce = StringStripWS($DirOutputOnce, 3)
; Split output into array
$DirSplit = StringSplit($DirOutputOnce, @CRLF, 1)
$NrCopiedInfs = 0
For $i = 1 To $DirSplit[0]
If StringInStr($DirSplit[$i], $path_to_drivers) Then
$registrystring = StringSplit($DirSplit[$i], ": ", 1)
If $registrystring[0] = 2 Then; Testing amount of elements in array, if more then 2 Exits
If StringInStr($registrystring[2], $path_to_drivers) Then; Making sure that Drivers path exists in string
$drivers_directory = $registrystring[2]
$search_ini = FileFindFirstFile($drivers_directory & "\*.inf")
If $search_ini = -1 Then
Else
$dll_exe = DllOpen("setupapi.dll")
While 1
$search_file = FileFindNextFile($search_ini)
$full_path_to_inf = $drivers_directory & "\" & $search_file
If @error Then ExitLoop
;$dll_result = DllCall($dll_exe, "int", "SetupCopyOEMInf", "str", $full_path_to_inf, "str", "", "int", 1, "int", 8, "str", "", "int", 0, "int", 0, "str", "")
$NrCopiedInfs = $NrCopiedInfs + 1
; If $logging_option = "Advanced" Then
; If @error = 0 Then
; _AddLineBox("Inf integration passed: " & $drivers_directory & "\" & $search_file)
; $NrCopiedInfs = $NrCopiedInfs + 1
; ElseIf @error = 1 Then
; _AddLineBox("Inf integration failed: " & $drivers_directory & "\" & $search_file)
; ElseIf @error = 2 Or @error = 3 Then
; _AddLineBox("Unknown return type or Function not found in DLL. Tell author about it!")
; EndIf
; EndIf
WEnd
DllClose($dll_exe)
EndIf
FileClose($search_ini)
EndIf
EndIf
EndIf
Next
If $NrCopiedInfs = 1 Then MsgBox(4096, "", "SetupCopyOemInf method completed. " & $NrCopiedInfs & " driver was integrated.",5)
If $NrCopiedInfs = 0 Then MsgBox(4096, "", "SetupCopyOemInf method completed. No drivers were integrated.",5)
If $NrCopiedInfs <> 0 And $NrCopiedInfs <> 1 Then MsgBox(4096, "", "SetupCopyOemInf method completed. " & $NrCopiedInfs & " drivers were integrated.",5)
#168
Posted 28 October 2006 - 06:44 PM
I will try your program and the code.
But I use the oemcopy thing before driver detection in the setup In winnt.sif as "DetachedProgram" I thought your programm doesn't work unattendedly?
#169
Posted 28 October 2006 - 08:13 PM
$DirSplit is empty. And the path has directories with inf files.
It goes directly to the message "No drivers were integrated"
I will check your app tommorow It's late here in amsterdam.
#170
Posted 29 October 2006 - 01:01 AM
in these days I have tested lastest version of your application.
I have tested about 10 PCs with windows XP Pro, it works great.
I have put it with BTS Driverpack on my portable USB hard drive.
If necessary I modify ini file for path and it can recognize almost every hardware.
I have only find a little problem with a RAID controller.
It seems very difficult to recognize.
I have read you want create a client server version of your application, is it right?
I wait your answer
THX for your marvellous work



Help


Back to top









