@echo off
echo Please wait while installing drivers. Do not turn off or unplug the computer power during the installation...
for /F "eol=; tokens=1 delims==" %%i in ('dir /b C:\Windows\inf\oem*.inf') do (
    if "%%i" == "" break
    call %~dp0OEMFILE.cmd %%i
)


REG ADD "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell" /f /v "ExecutionPolicy" /d "RemoteSigned" /t REG_SZ

powershell -executionpolicy bypass -File .\deloeminf.ps1

REG DELETE "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\PowerShell\1\ShellIds\Microsoft.PowerShell" /v "ExecutionPolicy" /f 

"%~dp0devcon.exe" remove "PCI\VEN_8086&DEV_15F2"

"%~dp0devcon.exe" remove "PCI\VEN_8086&DEV_15F3"

"%~dp0devcon.exe" remove "PCI\VEN_8086&DEV_125B"

"%~dp0devcon.exe" remove "PCI\VEN_8086&DEV_125C"


"%~dp0devcon.exe" rescan
%windir%/system32/pnputil /delete-driver net2ic68.inf /uninstall /force

"%~dp0devcon.exe" update "%~dp0e2fn.inf" "PCI\VEN_8086&DEV_125C"
"%~dp0devcon.exe" update "%~dp0e2fn.inf" "PCI\VEN_8086&DEV_125B"
"%~dp0devcon.exe" update "%~dp0e2fn.inf" "PCI\VEN_8086&DEV_15F2"
"%~dp0devcon.exe" update "%~dp0e2fn.inf" "PCI\VEN_8086&DEV_15F3"



:End

exit