; OEMSETUP.INF
; Digi AccelePort FEP5
; Version 2.7.22.0
; Copyright 1992-2003 Digi International Inc.
[Identification]
OptionType = NetAdapter
[PlatformsSupported]
ISA
"Jazz-Internal Bus"
PCI
[LanguagesSupported]
ENG
[OptionsISA]
DigiISA2e
DigiISA4e
DigiISA8e
DigiISACX
DigiISAXem
[OptionsPCI]
DigiPCICX
DigiPCIEPC
DigiPCIXem
DigiPCI4r422
DigiPCI8r422
DigiPCI2r920
DigiPCI4r920
DigiPCI8r920
[OptionsObsolete]
[AdapterInfo]
DigiISA2e = "2e EIA-232 ISA", 2Port, ntxall, 4, "Digi", xacook.bin xabios.bin conc-not-used "ISA" {0} "" ""
DigiISA4e = "4e EIA-232/422 ISA", 4Port, ntxall, 6, "Digi", xacook.bin xabios.bin conc-not-used "ISA" {0} "" ""
DigiISA8e = "8e EIA-232/422 ISA", 8Port, ntxall, 7, "Digi", xacook.bin xabios.bin conc-not-used "ISA" {0} "" ""
DigiISACX = "C/X ISA", ntcx, ntcx, 3, "Digi", cxfep.bin cxbios.bin conc-cx "ISA" {0} "" ""
DigiISAXem = "Xem ISA", ntxem, ntxem, 2, "Digi", sxfep.bin sxbios.bin conc-not-used "ISA" {0} "" ""
DigiPCICX = "C/X PCI", dgapcicx, dgapci, 3, "Digi", cxpfep.bin cxpbios.bin conc-epc "PCI" {6,23} "" ""
DigiPCIEPC = "EPC/X PCI", dgapciepc, dgapci, 11, "Digi", pcifep.bin pcibios.bin conc-epc "PCI" {2,10,22} "" ""
DigiPCIXem = "Xem PCI", dgapcixem, dgapci, 2, "Digi", sxfep.bin sxbios.bin conc-not-used "PCI" {4,21} "" ""
DigiPCI4r422 = "4r EIA-422 PCI", dgapci4r, dgapci, 15, "Digi", xrfep.bin xrbios.bin conc-not-used "PCI" {18,20} "" ""
DigiPCI8r422 = "8r EIA-422 PCI", dgapci8r, dgapci, 14, "Digi", xrfep.bin xrbios.bin conc-not-used "PCI" {18,20} "" ""
DigiPCI2r920 = "2r 920 PCI", dgapci2r, dgapci, 18, "Digi", xrfep.bin xrbios.bin conc-not-used "PCI" {52} "" ""
DigiPCI4r920 = "4r 920 PCI", dgapci4r, dgapci, 17, "Digi", xrfep.bin xrbios.bin conc-not-used "PCI" {38} "" ""
DigiPCI8r920 = "8r 920 PCI", dgapci8r, dgapci, 16, "Digi", xrfep.bin xrbios.bin conc-not-used "PCI" {39} "" ""
[AdapterInfoMCA]
[ObsoleteOptionInfo]
[BinaryList]
conc-epc = { "fxcon.bin", "cxcon.bin", "mbcon.bin" }
conc-cx = { "fxcon.bin", "cxcon.bin", "ibmcxcon.bin" }
conc-not-used = ""
conc-all = { "cxcon.bin", "fxcon.bin", "ibmcxcon.bin", "mbcon.bin" }
fep-all = { "xacook.bin", "sxfep.bin", "fxfep.bin", "cxfep.bin", "cxpfep.bin", "pcifep.bin", "xrfep.bin" }
[FileConstants]
ExitState = "Active"
OldVersionExisted = $(FALSE)
HdwDriverComponentExists = $(FALSE)
InstallDuplicateAdapter = $(FALSE)
DriverPath = $(!STF_NTPATH)"\drivers"
UtilityInf = "UTILITY.INF"
subroutninf = "SUBROUTN.INF"
ParamInf = "NCPARAM.INF"
HandleNull = ""
DGCONFIG_HANDLE = $(HandleNull)
AdapterList = ^(AdapterInfo$(BusType),0)
AdapterTitleList = ^(AdapterInfo$(BusType), 1)
AdapterHardwareNameList = ^(AdapterInfo$(BusType), 2)
AdapterHardwareDriverList = ^(AdapterInfo$(BusType), 3)
AdapterHardwareTypeList = ^(AdapterInfo$(BusType), 4)
ManufacturerDisplayNameList = ^(AdapterInfo$(BusType), 5)
AdapterFepList = ^(AdapterInfo$(BusType), 6)
AdapterBiosList = ^(AdapterInfo$(BusType), 7)
AdapterConcList = ^(AdapterInfo$(BusType), 8)
AdapterBusTypeList = ^(AdapterInfo$(BusType), 9)
AdapterHardwareAdapterIDList = ^(AdapterInfo$(BusType), 10)
AdapterIDByte1List = ^(AdapterInfo$(BusType), 11)
AdapterIDByte2List = ^(AdapterInfo$(BusType), 12)
AdapterTitle = *($(AdapterTitleList), ~($(AdapterList), $(Option)))
AdapterHardwareName = *($(AdapterHardwareNameList), ~($(AdapterList), $(Option)))
AdapterHardwareDriver = *($(AdapterHardwareDriverList), ~($(AdapterList), $(Option)))
AdapterHardwareType = *($(AdapterHardwareTypeList), ~($(AdapterList), $(Option)))
AdapterHardwareAdapterID = *($(AdapterHardwareAdapterIDList), ~($(AdapterList), $(Option)))
AdapterIDByte1 = *($(AdapterIDByte1List), ~($(AdapterList), $(Option)))
AdapterIDByte2 = *($(AdapterIDByte2List), ~($(AdapterList), $(Option)))
AdapterRule = *($(AdapterHardwareDriverList), ~($(AdapterList), $(Option)))
ManufacturerDisplayName = *($(ManufacturerDisplayNameList), ~($(AdapterList), $(Option)))
AdapterFepImage = *($(AdapterFepList), ~($(AdapterList), $(Option)))
AdapterBiosImage = *($(AdapterBiosList), ~($(AdapterList), $(Option)))
AdapterConcKey = *($(AdapterConcList), ~($(AdapterList), $(Option)))
AdapterConcImages = #(BinaryList,$(AdapterConcKey),1)
AdapterBusType = *($(AdapterBusTypeList), ~($(AdapterList), $(Option)))
AdapterServiceName = ""
AdapterName = ""
NetEventDLL = "%SystemRoot%\System32\netevent.dll"
IoLogMsgDLL = "%SystemRoot%\System32\IoLogMsg.dll"
Manufacturer = "DigiBoard"
ProductMajorVersion = "4"
ProductMinorVersion = "00"
ProductVersion = $(ProductMajorVersion)"."$(ProductMinorVersion)
ProductReview = "1"
DriverMajorVersion = "2"
DriverMinorVersion = "7"
DriverSubMinorVersion = "22"
DriverBugfixVersion = "0"
DriverVersion = $(DriverMajorVersion)"."$(DriverMinorVersion)"."$(DriverSubMinorVersion)"."$(DriverBugfixVersion)
SoftwareType = "driver"
ProductSoftwareName = "DigiFEP5"
ProductSoftwareImagePath = "%SystemRoot%\System32\drivers\digifep5.sys"
NetRuleSoftwareType = "digiFEP5Sys serialDriver digiFEP5Driver"
NetRuleSoftwareUse = $(SoftwareType)
NetRuleSoftwareBindForm = """DigiFEP5Driver"" yes no container"
NetRuleSoftwareClass = {"serialDriver basic","digiFEP5Driver basic"}
NetRuleSoftwareHiddenDriver = 1
ProductMajorVersionHdwDriver = "4"
ProductMinorVersionHdwDriver = "00"
ProductVersionHdwDriver = $(ProductMajorVersionHdwDriver)"."$(ProductMinorVersionHdwDriver)
ProductSoftwareNameHdwDriver = $(AdapterHardwareDriver)
ProductSoftwareImagePathHdwDriver = "%SystemRoot%\System32\drivers\"$(AdapterHardwareDriver)".sys"
NetRuleSoftwareTypeHdwDriver = $(AdapterHardwareDriver)"sys "$(AdapterHardwareDriver)"Driver"
NetRuleSoftwareUseHdwDriver = $(SoftwareType)
NetRuleSoftwareBindFormHdwDriver = """"$(AdapterHardwareDriver)"Driver"" yes no container"
NetRuleSoftwareClassHdwDriver = {$(AdapterHardwareDriver)"Driver basic"}
NetRuleSoftwareHiddenHdwDriver = 1
NetRuleHardwareType = $(AdapterRule)" "$(AdapterRule)"Adapter"
NetRuleHardwareBindForm = " yes yes container"
NetRuleHardwareClass = {$(AdapterHardwareDriver)"Adapter basic"}
ProductHardwareName = $(AdapterHardwareDriver)
AdapterParameters = {}
BusType_ISA = 1
BusType_PCI = 5
ProductKeyName = $(!NTN_SoftwareBase)"\"$(Manufacturer)"\"$(ProductSoftwareName)"\CurrentVersion"
ProductKeyNameHdwDriver = $(!NTN_SoftwareBase)"\"$(Manufacturer)"\"$(ProductSoftwareNameHdwDriver)"\CurrentVersion"
ParamKeyName = $(!NTN_ServiceBase)"\"$(ProductHardwareName)"\Parameters"
NTVersionKeyName= $(!NTN_SoftwareBase)"\Microsoft\Windows NT\CurrentVersion"
PerformanceKeyName = $(!NTN_ServiceBase)"\"$(ProductSoftwareName)"\Performance"
[GeneralConstants]
ExitCodeOk = 0
ExitCodeCancel = 1
ExitCodeFatal = 2
KeyNull = ""
MAXIMUM_ALLOWED = 33554432
RegistryErrorIndex = NO_ERROR
KeyProduct = ""
KeyParameters = ""
TRUE = 1
FALSE = 0
NoTitle = 0
fRemoveDigi = TRUE
[UpdateObsoleteNames]
ObsoleteList = ^(ObsoleteOptionInfo, 0)
ISAReplacementList = ^(ObsoleteOptionInfo, 1)
MCAReplacementList = ^(ObsoleteOptionInfo, 2)
EISAReplacementList = ^(ObsoleteOptionInfo, 3)
ISAReplacement = *($(ISAReplacementList), ~($(ObsoleteList), $(InfOption)))
MCAReplacement = *($(MCAReplacementList), ~($(ObsoleteList), $(InfOption)))
EISAReplacement = *($(EISAReplacementList), ~($(ObsoleteList), $(InfOption)))
[DebugOptions]
!G:DebugOutputControl = 0
TraceConfig = 0
[UiVars]
from = ""
to = ""
!STF_NTDRIVE = ""
!STF_NTPATH = ""
!STF_WINDOWSPATH = "" ? $(!LIBHANDLE) GetWindowsNtDir
!STF_WINDOWSSYSPATH = "" ? $(!LIBHANDLE) GetWindowsNtSysDir
!STF_FLOPPYLIST = {} ? $(!LIBHANDLE) GetFloppyDriveLetters
!STF_UNUSEDDRIVES = {} ? $(!LIBHANDLE) GetUnusedDrives
!STF_LANGUAGE = "ENG"
VolumeList = {} ? $(!LIBHANDLE) GetHardDriveLetters
VolumeFreeList = {} ? $(!LIBHANDLE) GetHardDriveFreeSpace
VolumeFSList = {} ? $(!LIBHANDLE) GetHardDriveFileSystems
DestVolume = ""
MinHelpID = 25000
MaxHelpID = 25999
[date]
Now = {} ? $(!LIBHANDLE) GetSystemDate
[Identify]
read-syms Identification
set Status = STATUS_SUCCESSFUL
set Identifier = $(OptionType)
set Media = #("Source Media Descriptions", 1, 1)
Return $(Status) $(Identifier) $(Media)
[ReturnOptions]
set Status = STATUS_FAILED
set OptionList = {}
set OptionTextList = {}
read-syms DebugOptions
Debug-Output "OEMNADDS.INF: In [ReturnOptions] section"
Debug-OutPut "OEMNADDS.INF: Bus Type "$($1)
Debug-OutPut "OEMNADDS.INF: Bus Type "$(!STF_BUSTYPELIST)
set KeyName = "Software\Microsoft\Windows NT\CurrentVersion"
OpenRegKey $(!REG_H_LOCAL) "" $(KeyName) $(!REG_KEY_READ) KeyHandle
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
Debug-Output "REGISTRY.INF: Couldn't open windows nt software key for read access"
goto finish_ReturnOptions
endif
GetRegValue $(KeyHandle) "CurrentVersion" NTVersionValueList
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
CloseRegKey $(KeyHandle)
goto finish_ReturnOptions
endif
set NTVersion = *($(NTVersionValueList), 4)
CloseRegKey $(KeyHandle)
set LanguageList = ^(LanguagesSupported, 1)
Ifcontains(i) $($0) in $(LanguageList)
ifstr(i) $($1) == ""
goto returnoptions
endif
set PlatformList = ^(PlatformsSupported, 1)
Ifcontains(i) $($1) in $(PlatformList)
goto returnoptions
else
set Status = STATUS_NOTSUPPORTED
goto finish_ReturnOptions
endif
Else
set Status = STATUS_NOLANGUAGE
goto finish_ReturnOptions
Endif
returnoptions = +
read-syms ProductType
ifstr(i) $(STF_PLATFORM) != $(!STF_PLATFORM)
set Status = "STATUS_NOTSUPPORTED"
goto finish_ReturnOptions
endif
ForListDo $(!STF_BUSTYPELIST)
ifstr(i) $($) == "MCA"
set OptionTempList = ^(OptionsMCA, 1)
ForListDo $(OptionTempList)
set OptionList = >($(OptionList), *($($), 1))
EndForListDo
set OptionTempTextList = ^(OptionsTextMCA$($0), 1)
ForListDo $(OptionTempTextList)
set OptionTextList = >($(OptionTextList), *($($), 1))
EndForListDo
endif
ifstr(i) $($) == "PCI"
ifstr $(NTVersion) != "3.50"
set OptionTempList = ^(OptionsPCI, 1)
ForListDo $(OptionTempList)
set OptionList = >($(OptionList), *($($), 1))
EndForListDo
set OptionTempTextList = ^(OptionsTextPCI$($0), 1)
ForListDo $(OptionTempTextList)
set OptionTextList = >($(OptionTextList), *($($), 1))
EndForListDo
endif
endif
ifstr(i) $($) == "EISA"
Ifcontains(i) "ISA" not-in $(!STF_BUSTYPELIST)
set OptionTempList = ^(OptionsISA, 1)
ForListDo $(OptionTempList)
set OptionList = >($(OptionList), *($($), 1))
EndForListDo
set OptionTempTextList = ^(OptionsTextISA$($0), 1)
ForListDo $(OptionTempTextList)
set OptionTextList = >($(OptionTextList), *($($), 1))
EndForListDo
endif
set OptionTempList = ^(OptionsEISA, 1)
ForListDo $(OptionTempList)
set OptionList = >($(OptionList), *($($), 1))
EndForListDo
set OptionTempTextList = ^(OptionsTextEISA$($0), 1)
ForListDo $(OptionTempTextList)
set OptionTextList = >($(OptionTextList), *($($), 1))
EndForListDo
endif
ifstr(i) $($) == "ISA"
set OptionTempList = ^(OptionsISA, 1)
ForListDo $(OptionTempList)
set OptionList = >($(OptionList), *($($), 1))
EndForListDo
set OptionTempTextList = ^(OptionsTextISA$($0), 1)
ForListDo $(OptionTempTextList)
set OptionTextList = >($(OptionTextList), *($($), 1))
EndForListDo
endif
EndForListDo
ifstr(i) $(!NTN_InstallMode) == Update
Debug-Output "Update: Obsolete options added to list"
set OptionTempList = ^(OptionsObsolete, 1)
ForListDo $(OptionTempList)
set OptionList = >($(OptionList), *($($), 1))
EndForListDo
endif
set Status = STATUS_SUCCESSFUL
Debug-Output "OEMNADDS.INF OptionList "$(OptionList)
Debug-Output "OEMNADDS.INF OptionText "$(OptionTextList)
finish_ReturnOptions = +
Return $(Status) $(OptionList) $(OptionTextList)
[Shell Commands]
set-title "Serial Setup"
set-subst LF = "\n"
set Exit_Code = $(ExitCodeOk)
Debug-Output "OEMNADDS.INF: STF_CWDDIR is "$(!STF_CWDDIR)
Debug-Output "OEMNADDS.INF: STF_RANFROM is "$(!STF_RANFROM)
ifstr(i) $(!STF_RANFROM) != ""
ifstr(i) $(!STF_RANFROM) != $(!STF_CWDDIR)"SERIAL\"
set !STF_SRCDIR = $(!STF_RANFROM)
endif
endif
LoadLibrary "x" $(!STF_CWDDIR)setupdll.dll !LIBHANDLE
shell "" InstallOption ENG DigiBoard $(!STF_SRCDIR)
FreeLibrary $(!LIBHANDLE)
set Status = $($R0)
Return $(Status)
[InstallOption]
read-syms DebugOptions
Debug-Output "OEMNADDS.INF: In [InstallOption] section"
Debug-Output "OEMNADDS.INF: TraceConfig = "$(TraceConfig)
set Status = STATUS_FAILED
set Option = $($1)
set SrcDir = $($2)
set AddCopy = $($3)
set DoCopy = $($4)
set DoConfig = $($5)
set !SourceDir = $($2)
set BusType = ""
read-syms GeneralConstants
read-syms FileConstants
set KeyName = "Software\Microsoft\Windows NT\CurrentVersion"
OpenRegKey $(!REG_H_LOCAL) "" $(KeyName) $(!REG_KEY_READ) KeyHandle
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
Debug-Output "REGISTRY.INF: Couldn't open windows nt software key for read access"
goto finish_ReturnOptions
endif
GetRegValue $(KeyHandle) "CurrentVersion" NTVersionValueList
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
CloseRegKey $(KeyHandle)
goto finish_ReturnOptions
endif
set NTVersion = *($(NTVersionValueList), 4)
CloseRegKey $(KeyHandle)
Debug-Output "OEMNADDS.INF: Language = "$($0)
Debug-Output "OEMNADDS.INF: OptionID = "$($1)
Debug-Output "OEMNADDS.INF: SourceDirectory = "$($2)
Debug-Output "OEMNADDS.INF: AddCopy = "$(AddCopy)
Debug-Output "OEMNADDS.INF: DoCopy = "$(DoCopy)
Debug-Output "OEMNADDS.INF: DoConfig = "$(DoConfig)
set LanguageList = ^(LanguagesSupported, 1)
Ifcontains(i) $($0) NOT-IN $(LanguageList)
Debug-Output "OEMNADDS.INF: returning STATUS_NO_LANGUAGE"
return STATUS_NOLANGUAGE
Endif
set-subst LF = "\n"
Debug-Output "OEMNADDS.INF: ManufacturerDisplayName = "$(ManufacturerDisplayName)
Debug-Output "OEMNADDS.INF: AdapterTitle = "$(AdapterTitle)
Debug-Output "OEMNADDS.INF: AdapterHardwareName = "$(AdapterHardwareName)
Debug-Output "OEMNADDS.INF: AdapterHardwareDriver = "$(AdapterHardwareDriver)
read-syms BindingInfo-DigiFEP5
set NetRuleSoftwareBindable = $(BindingInfo)
read-syms BindingInfo-HardwareDriver
set NetRuleSoftwareBindableHdwDriver = $(BindingInfo)
read-syms DialogConstants$(!STF_LANGUAGE)
ifstr(i) $(!NTN_Origination) == "NCPA"
set Continue = "OK"
endif
read-syms FileConstants$(!STF_LANGUAGE)
detect date
set-title $(FunctionTitle)
set to = Begin
set from = Begin
set CommonStatus = STATUS_SUCCESSFUL
EndWait
Begin = +
Ifstr(i) $(!NTN_InstallMode) == deinstall
set StartLabel = removeadapter
else-Ifstr(i) $(!NTN_InstallMode) == Update
set StartLabel = UpgradeSoftware
else-Ifstr(i) $(!NTN_InstallMode) == bind
set StartLabel = bindingadapter
else-Ifstr(i) $(!NTN_InstallMode) == configure
set StartLabel = ConfigureAdapter
Ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
Debug-Output "Cannot configure the DigiBoard FEP 5 driver software."
Shell $(UtilityInf),RegistryErrorString,CANNOT_CONFIGURE_SOFTWARE
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: cannot get an error string."
goto ShellCodeError
endif
set Error = $($R0)
set from = end
set to = end
goto nonfatalinfo
endif
Ifstr(i) $(ProductKeyNameHdwDriver) == $(!NTN_RegBase)
Debug-Output "This should not have happened! Cannot configure the "$(AdapterHardwareName)" driver software."
Shell $(UtilityInf),RegistryErrorString,CANNOT_CONFIGURE_SOFTWARE
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: cannot get an error string."
goto ShellCodeError
endif
set Error = $($R0)
set from = end
set to = end
goto nonfatalinfo
endif
Debug-Output "We need to determine how to find out which adapter"
Debug-Output " we should be configuring!!!!!!"
set from = writeparameters
Debug-Output "setting from = "$(from)
else
set StartLabel = installadapter
set OEM_ABANDON_OPTIONS = {}
set OEM_ABANDON_FEP5_SOFTWARE = FALSE
set OEM_ABANDON_SOFTWARE = FALSE
set OEM_ABANDON_ON = TRUE
endif
Debug-Output "OEMNADDS.INF: Option is: "$(Option)
set to = $(fatal)
Goto $(StartLabel)
installadapter = +
Debug-Output "******************Entering installadapter******************"
OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
Ifstr $(KeyProduct) != $(KeyNull)
GetRegValue $(KeyProduct),"DriverMajorVersion", MajorVersionInfo
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
set MajorVersion = 0
else
set MajorVersion = *($(MajorVersionInfo), 4)
endif
GetRegValue $(KeyProduct),"DriverMinorVersion", MinorVersionInfo
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
set MinorVersion = 0
else
set MinorVersion = *($(MinorVersionInfo), 4)
endif
GetRegValue $(KeyProduct),"DriverSubMinorVersion", SubMinorVersionInfo
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
set SubMinorVersion = 0
else
set SubMinorVersion = *($(SubMinorVersionInfo), 4)
endif
ifint $(MinorVersion) == 23
set MinorVersion = 2
set SubMinorVersion = 3
endif
ifint $(MajorVersion) < $(DriverMajorVersion)
goto ShouldUpgradeDriver
else-ifint $(MajorVersion) == $(DriverMajorVersion)
ifint $(MinorVersion) < $(DriverMinorVersion)
goto ShouldUpgradeDriver
else-ifint $(MinorVersion) == $(DriverMinorVersion)
ifint $(SubMinorVersion) < $(DriverSubMinorVersion)
goto ShouldUpgradeDriver
else-ifint $(SubMinorVersion) == $(DriverSubMinorVersion)
goto ContinueDriverInstall
endif
endif
endif
set Error = $(NewerInstalled)
set from = "end"
set CommonStatus = STATUS_USERCANCEL
LibraryProcedure Status , $(!LIBHANDLE), DelFile $(STF_CONTEXTINFNAME)
goto nonfatal
ShouldUpgradeDriver = +
set Error = $(ShouldUpgrade)
set from = "end"
set CommonStatus = STATUS_USERCANCEL
LibraryProcedure Status , $(!LIBHANDLE), DelFile $(STF_CONTEXTINFNAME)
goto nonfatal
ContinueDriverInstall = +
OpenRegKey $(KeyProduct) "" "NetRules" $(MAXIMUM_ALLOWED) NetRulesProduct
CloseRegKey $(KeyProduct)
Ifstr $(NetRulesProduct) != $(KeyNull)
GetRegValue $(NetRulesProduct), "InfName", InfNameList
CloseRegKey $(NetRulesProduct)
set TempInfFileName = $(!STF_WINDOWSSYSPATH)"\"*($(InfNameList), 4)
ifstr(i) $(TempInfFileName) != $(STF_CONTEXTINFNAME)
LibraryProcedure Status , $(!LIBHANDLE), DelFile $(STF_CONTEXTINFNAME)
Debug-Output "Shelling to InstallOption to use existing inf file..."
shell $(TempInfFileName) InstallOption $($0) $(Option) $(SrcDir) $(AddCopy) $(DoCopy) $(DoConfig)
set CommonStatus = $($R0)
goto end
endif
endif
ifstr(i) $(!NTN_RegBase) == $(ProductKeyName)
Shell $(UtilityInf), VerExistedDlg, $(ProductSoftwareTitle),+
$(ProductVersion)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: Don't allow installation of software."
goto ShellCodeError
endif
goto end
else
OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyNameHdwDriver) +
$(MAXIMUM_ALLOWED) KeyProductHdwDriver
Ifstr $(KeyProductHdwDriver) != $(KeyNull)
set HdwDriverComponentExists = $(TRUE)
GetRegValue $(KeyProductHdwDriver) "Title" ExistingTitleHdwDriverList
set ExistingTitleHdwDriver = *($(ExistingTitleHdwDriverList),4)
Debug-Output "Existing Title = "$(ExistingTitleHdwDriver)
Debug-Output "ProductSoftwareTitleHdwDriver = "$(ProductSoftwareTitleHdwDriver)
CloseRegKey $(KeyProductHdwDriver)
Ifstr(i) $(ProductSoftwareTitleHdwDriver) == $(ExistingTitleHdwDriver)
Shell $(UtilityInf), CardExistedDlg
Ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: --One adapter already exists, install another-- FAILED."
goto ShellCodeError
endif
ifstr(i) $($R1) != "OK"
set CommonStatus = STATUS_USERCANCEL
goto end
endif
set InstallDuplicateAdapter = $(TRUE)
Endif
else
CloseRegKey $(KeyProductHdwDriver)
EndIf
set OldVersionExisted = $(TRUE)
endif
endif
ifint $(HdwDriverComponentExists) == $(TRUE)
ifstr(i) $(!NTN_InstallMode) == configure
goto ConfigureAdapter
endif
endif
set BusTypeNum = 1
set SlotNumber = -1
Debug-Output " AdapterBusType = "$(AdapterBusType)
goto find$(AdapterBusType)
findMCA = +
set DetectedAdapterList = {}
ForListDo $(AdapterHardwareAdapterID)
Debug-Output "Calling MCAFindBus, "*($(AdapterIDByte1),$(#))", "*($(AdapterIDByte2),$(#))
Shell $(UtilityInf), MCAFindBus, *($(AdapterIDByte1),$(#)), *($(AdapterIDByte2),$(#))
ifint $($ShellCode) != $(!SHELL_CODE_OK)
goto ShellCodeError
endif
ifstr $($R0) != "NO_ERROR"
set Error = $($R0)
goto fatal
endif
Debug-Output "MCAFindBus returned "$($R1)
ifstr(i) $($R1) != {}
set DetectedAdapterList = $($R1)
ForListDo $(DetectedAdapterList)
set BusNumber = *($($),1)
set SlotNumber = *($($),2)
set MCAPosId = *($($), 3)
shell "", IsCardAlreadyInstalled, $(BusNumber), $(SlotNumber), "3"
ifstr(i) $($R1) != "YES"
set BusTypeNum = 3
goto CopyDriverFiles
endif
EndForListDo
endif
EndForListDo
goto notinstalled
findPCI = +
Debug-Output "FindPCI"
set Vendor = 4431
ForListDo $(AdapterHardwareAdapterID)
Debug-Output "Calling GetPCIInformation, "$($)
Shell $(UtilityInf), GetPCIInformation, $(Vendor) $($)
Debug-Output "GetPCIInformation returned "$($R0)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
goto ShellCodeError
endif
ifstr(i) $($R0) != {}
set DetectedAdapterList = $($R0)
ForListDo $(DetectedAdapterList)
set BusNumber = *($($),1)
set SlotNumber = *($($),2)
shell "", IsCardAlreadyInstalled, $(BusNumber), $(SlotNumber), "5"
Debug-Output " IsCardAlreadyInstalled returned: "$($R1)
ifstr(i) $($R1) != "YES"
set BusTypeNum = 5
goto CopyDriverFiles
endif
EndForListDo
endif
EndForListDo
goto notinstalled
findEISA = +
ForListDo $(AdapterHardwareAdapterID)
ifint $($) != 0
Debug-Output "Calling EISAFindBus, "$($)
Shell $(UtilityInf), EISAFindBus, $($)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
goto ShellCodeError
endif
ifstr(i) $($R1) != {}
set DetectedAdapterList = $($R1)
ForListDo $(DetectedAdapterList)
set BusNumber = *($($), 1)
set SlotNumber = *($($), 2)
shell "", IsCardAlreadyInstalled, $(BusNumber), $(SlotNumber), "2"
ifstr(i) $($R1) != "YES"
set BusTypeNum = 2
set-mul EISAIOBaseAddress = $(SlotNumber), 4096
set-add EISAIOBaseAddress = $(EISAIOBaseAddress), 5
Debug-Output "EISAIOBaseAddress ="$(EISAIOBaseAddress)
goto CopyDriverFiles
endif
EndForListDo
endif
endif
EndForListDo
notinstalled = +
Debug-Output "No new PCI/MCA/EISA cards found!"
set Error = $(CANNOT_FIND_ANY_CARD)
set CommonStatus = USER_CANCEL
set from = end
set to = end
goto nonfatal
findISA = +
goto CopyDriverFiles
CopyDriverFiles = +
StartWait
Ifint $(InstallDuplicateAdapter) == $(FALSE)
ifstr(i) $(!NTN_InstallMode) == "install"
shell $(UtilityInf) AssignAdapterNumber
set AdapterName = $(ProductHardwareName)$($R1)
Debug-Output "AdapterName: "$(AdapterName)
Ifstr(i) $(DoCopy) == "YES"
Shell $(UtilityInf), DoAskSource, $(!STF_CWDDIR), $(SrcDir) YES
Ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output"Shell code error: DoAskSource"
Goto ShellCodeError
Else-Ifstr(i) $($R0) == STATUS_FAILED
Shell $(UtilityInf) RegistryErrorString "ASK_SOURCE_FAIL"
ifint $($ShellCode) != $(!SHELL_CODE_OK)
goto ShellCodeError
endif
set Error = $($R0)
Goto fatal
Else-Ifstr(i) $($R0) == STATUS_USERCANCEL
set CommonStatus = STATUS_USERCANCEL
Goto successful
Endif
Set SrcDir = $($R1)
Split-String $(SrcDir) "\" JunkList
QueryListSize JunkSize $(JunkList)
Set JunkItem = *($(JunkList),$(JunkSize))
set JunkItem2 = "foo"
ifstr $(JunkItem2)$(JunkItem)$(JunkItem2) != $(JunkItem2)"\"$(JunkItem2)
Debug-Output "In ifstr"
set SrcDir = $(SrcDir)"\"
endif
Debug-Output "Reassigning SourceDirectory = "$(SrcDir)
Endif
install "Install-Option"
ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
Shell $(UtilityInf) RegistryErrorString "UNABLE_COPY_FILE"
ifint $($ShellCode) != $(!SHELL_CODE_OK)
goto ShellCodeError
endif
set Error = $($R0)
goto fatal
endif
endif
endif
addDigiFEP5Component = +
Debug-Output "******************Entering addDigiFEP5Component******************"
Ifint $(OldVersionExisted) == $(TRUE)
goto addHdwDriverComponent
Endif
Debug-Output "OEMNADDS.INF: Adding DigiFEP5Component"
set DigiSpecificString = $(ProductSoftwareName)
set TypeofService = "kernelautostart"
set ServiceOrderGroup = "Extended base"
set Dependencies = {}
set ObjectName = ""
set TypeSupported = "7"
set EventLogLocation = "System"
set ErrorControlValue = 1
Debug-Output "OEMNADDS.INF: [InstallOption]: About to call AddSoftwareComponent"
Debug-Output "OEMNADDS.INF: Parameters passed in:"
Debug-Output "OEMNADDS.INF: Manufacturer = "$(Manufacturer)
Debug-Output "OEMNADDS.INF: Product = "$(ProductSoftwareName)
Debug-Output "OEMNADDS.INF: Service = "$(ProductSoftwareName)
Debug-Output "OEMNADDS.INF: Display name = "$(ProductSoftwareTitle)
Debug-Output "OEMNADDS.INF: INFfile = "$(STF_CONTEXTINFNAME)
Debug-Output "OEMNADDS.INF: ImagePath = "$(ProductSoftwareImagePath)
Debug-Output "OEMNADDS.INF: Type of software = "$(TypeofService)
Debug-Output "OEMNADDS.INF: Service Order group = "$(ServiceOrderGroup)
Debug-Output "OEMNADDS.INF: Dependencies = "$(Dependencies)
Debug-Output "OEMNADDS.INF: ObjectName = "$(ObjectName)
Debug-Output "OEMNADDS.INF: EventMessageFile = "$(IoLogMsgDLL)";"$(ProductSoftwareImagePath)
Debug-Output "OEMNADDS.INF: TypeSupported = "$(TypeSupported)
Debug-Output "OEMNADDS.INF: Event log location = "$(EventLogLocation)
Debug-Output "OEMNADDS.INF: Error control value = "$(ErrorControlValue)
Shell $(UtilityInf), AddSoftwareComponent, +
$(Manufacturer), +
$(ProductSoftwareName), +
$(ProductSoftwareName), +
$(ProductSoftwareTitle), +
$(STF_CONTEXTINFNAME), +
$(ProductSoftwareImagePath), +
$(TypeofService), +
$(ServiceOrderGroup), +
$(Dependencies), +
$(ObjectName), +
$(IoLogMsgDLL)";"$(ProductSoftwareImagePath), +
$(TypeSupported), +
$(EventLogLocation), +
$(ErrorControlValue)
Set OEM_ABANDON_FEP5_SOFTWARE = TRUE
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: Add software component FAILED!"
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Registry error: add software components"
CloseRegKey $($R1)
CloseRegKey $($R2)
CloseRegKey $($R3)
CloseRegKey $($R4)
CloseRegKey $($R5)
goto fatalregistry
endif
Set SoftProductKey = $($R1)
Set SoftNetRuleKey = $($R2)
Set SoftServiceKey = $($R3)
Set SoftParameterKey = $($R4)
Set SoftLinkageKey = $($R5)
ifstr $(NTVersion) != "3.50"
ifstr $(NTVersion) != "3.51"
set ProductReview = "0"
endif
endif
set NewValueList = {{SoftwareType,$(NoTitle),$(!REG_VT_SZ),$(SoftwareType)},+
{MajorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMajorVersion)},+
{MinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMinorVersion)},+
{Title,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareTitle)},+
{Description,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareDescription)},+
{ServiceName,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareName)},+
{hidden,$(NoTitle),$(!REG_VT_DWORD),$(NetRuleSoftwareHiddenDriver)}, +
{Review,$(NoTitle),$(!REG_VT_DWORD),$(ProductReview)},+
{DriverMajorVersion,$(NoTitle),$(!REG_VT_DWORD),$(DriverMajorVersion)},+
{DriverMinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(DriverMinorVersion)},+
{DriverSubMinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(DriverSubMinorVersion)},+
{InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
read-syms BinaryList
ForListDo $(fep-all)
set NewValueList = >($(NewValueList),{Image$($)RefCount,$(NoTitle),$(!REG_VT_DWORD), 0})
EndForListDo
ForListDo $(conc-all)
set NewValueList = >($(NewValueList),{Image$($)RefCount,$(NoTitle),$(!REG_VT_DWORD), 0})
EndForListDo
Shell $(UtilityInf), AddValueList, $(SoftProductKey), $(NewValueList)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: AddValueList FAILED! --"$(SoftProductKey)
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Registry error: add value list."
CloseRegKey $(SoftProductKey)
CloseRegKey $(SoftNetRuleKey)
CloseRegKey $(SoftServiceKey)
CloseRegKey $(SoftParameterKey)
CloseRegKey $(SoftLinkageKey)
goto fatalregistry
endif
set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareType)},+
{use,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareUse)}, +
{bindform,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareBindForm)}, +
{class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareClass)}, +
{bindable,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareBindable)}, +
{InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
Shell $(UtilityInf), AddValueList, $(SoftNetRuleKey), $(NewValueList)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: AddValueList FAILED! --"$(SoftNetRuleKey)
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
ifstr(i) $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Registry error: add value list."
CloseRegKey $(SoftProductKey)
CloseRegKey $(SoftNetRuleKey)
CloseRegKey $(SoftServiceKey)
CloseRegKey $(SoftParameterKey)
CloseRegKey $(SoftLinkageKey)
goto fatalregistry
endif
Debug-Output "OEMNADDS.INF: About to create Performance key"
CreateRegKey $(SoftServiceKey) {"Performance",$(NoTitle),GenericClass} "" +
$(MAXIMUM_ALLOWED) "" KeyPerformance
set NewValueList = {{Library,$(NoTitle),$(!REG_VT_SZ),fepctrs.dll}, +
{Open,$(NoTitle),$(!REG_VT_SZ),"OpenFepPerformanceData"}, +
{Close,$(NoTitle),$(!REG_VT_SZ),"CloseFepPerformanceData"}, +
{Collect,$(NoTitle),$(!REG_VT_SZ),"CollectFepPerformanceData"}}
Shell $(UtilityInf), AddValueList, $(KeyPerformance), $(NewValueList)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: AddValueList FAILED! --"$(KeyPerformance)
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
ifstr $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Registry error: add value list."
CloseRegKey $(KeyPerformance)
CloseRegKey $(SoftProductKey)
CloseRegKey $(SoftNetRuleKey)
CloseRegKey $(SoftServiceKey)
CloseRegKey $(SoftParameterKey)
CloseRegKey $(SoftLinkageKey)
goto fatalregistry
endif
set FLibraryErrCtl = 1
StartDetachedProcess ExitCode "" "" $(!STF_WINDOWSSYSPATH)\lodctr.exe $(!STF_WINDOWSSYSPATH)\fepctrs.ini
Debug-Output "OEMNADDS.INF LODCTR result:"$(ExitCode)
ifint $(ExitCode) != 0
Debug-Output "OEMNADDS.INF: error loading perfmon counters"
endif
set Status = STATUS_SUCCESSFUL
set FLibraryErrCtl = 0
OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\EventLog\Application" $(MAXIMUM_ALLOWED) KeyEventLog
ifstr $(KeyEventLog) == ""
Debug-Output "OEMNADDS.INF: Cannot open eventlog key"
else
Debug-Output "OEMNADDS.INF: Adding eventlog key"
CreateRegKey $(KeyEventLog) {"fepctrs",$(NoTitle),GenericClass} "" $(MAXIMUM_ALLOWED) "" KeyEventLogFep
ifstr $(KeyEventLogFep) == ""
OpenRegKey $(KeyEventLogFep) "" "fepctrs" $(MAXIMUM_ALLOWED) KeyEventLogFep
endif
ifstr $(KeyEventLogFep) != ""
SetRegValue $(KeyEventLogFep) {EventMessageFile,$(NoTitle),$(!REG_VT_EXPAND_SZ),"%SystemRoot%\System32\fepctrs.dll"}
SetRegValue $(KeyEventLogFep) {TypesSupported,$(NoTitle),$(!REG_VT_DWORD),7}
FlushRegKey $(KeyEventLogFep)
CloseRegKey $(KeyEventLogFep)
endif
FlushRegKey $(KeyEventLog)
CloseRegKey $(KeyEventLog)
endif
FlushRegKey $(KeyPerformance)
FlushRegKey $(SoftProductKey)
FlushRegKey $(SoftNetRuleKey)
FlushRegKey $(SoftServiceKey)
FlushRegKey $(SoftParameterKey)
FlushRegKey $(SoftLinkageKey)
CloseRegKey $(KeyPerformance)
CloseRegKey $(SoftProductKey)
CloseRegKey $(SoftNetRuleKey)
CloseRegKey $(SoftServiceKey)
CloseRegKey $(SoftParameterKey)
CloseRegKey $(SoftLinkageKey)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Registry error: add value list."
goto fatalregistry
endif
goto addHdwDriverComponent
addHdwDriverComponent = +
Debug-Output "******************Entering addHdwDriverComponent******************"
set DigiSpecificString = $(AdapterHardwareName)
Ifint $(HdwDriverComponentExists) == $(TRUE)
goto addAdapterComponent
Endif
Debug-Output "OEMNADDS.INF: Adding HdwDriverComponent"
set TypeofService = "kernelautostart"
set ServiceOrderGroup = "Extended base"
set Dependencies = {}
set ObjectName = ""
set TypeSupported = "7"
set EventLogLocation = "System"
set ErrorControlValue = 1
Shell $(UtilityInf), AddSoftwareComponent, +
$(Manufacturer), +
$(ProductSoftwareNameHdwDriver), +
$(ProductSoftwareNameHdwDriver), +
$(ProductSoftwareTitleHdwDriver), +
$(STF_CONTEXTINFNAME), +
$(ProductSoftwareImagePathHdwDriver), +
$(TypeofService), +
$(ServiceOrderGroup), +
$(Dependencies), +
$(ObjectName), +
$(IoLogMsgDLL)";"$(ProductSoftwareImagePathHdwDriver), +
$(TypeSupported), +
$(EventLogLocation), +
$(ErrorControlValue)
Set OEM_ABANDON_SOFTWARE = TRUE
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: AddSoftwareComponent FAILED! -- "$(ProductSoftwareNameHdwDriver)
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Registry error: add software components"
CloseRegKey $($R1)
CloseRegKey $($R2)
CloseRegKey $($R3)
CloseRegKey $($R4)
CloseRegKey $($R5)
goto fatalregistry
endif
Set SoftProductKey = $($R1)
Set SoftNetRuleKey = $($R2)
Set SoftServiceKey = $($R3)
Set SoftParameterKey = $($R4)
Set SoftLinkageKey = $($R5)
set NewValueList = {{SoftwareType,$(NoTitle),$(!REG_VT_SZ),$(SoftwareType)},+
{MajorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMajorVersionHdwDriver)},+
{MinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMinorVersionHdwDriver)},+
{Title,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareTitleHdwDriver)},+
{Description,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareDescriptionHdwDriver)},+
{ServiceName,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareNameHdwDriver)},+
{hidden,$(NoTitle),$(!REG_VT_DWORD),$(NetRuleSoftwareHiddenHdwDriver)}, +
{InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
Shell $(UtilityInf), AddValueList, $(SoftProductKey), $(NewValueList)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: AddValueList FAILED! -- "$(SoftProductKey)
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Resgitry error: add value list."
CloseRegKey $(SoftProductKey)
CloseRegKey $(SoftNetRuleKey)
CloseRegKey $(SoftServiceKey)
CloseRegKey $(SoftParameterKey)
CloseRegKey $(SoftLinkageKey)
goto fatalregistry
endif
set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareTypeHdwDriver)},+
{use,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareUseHdwDriver)}, +
{bindform,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareBindFormHdwDriver)}, +
{class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareClassHdwDriver)}, +
{bindable,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareBindableHdwDriver)}, +
{InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
Shell $(UtilityInf), AddValueList, $(SoftNetRuleKey), $(NewValueList)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error. AddValueList FAILED! -- "$(SoftNetRuleKey)
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
FlushRegKey $(SoftProductKey)
FlushRegKey $(SoftNetRuleKey)
FlushRegKey $(SoftServiceKey)
FlushRegKey $(SoftParameterKey)
FlushRegKey $(SoftLinkageKey)
CloseRegKey $(SoftProductKey)
CloseRegKey $(SoftNetRuleKey)
CloseRegKey $(SoftServiceKey)
CloseRegKey $(SoftParameterKey)
CloseRegKey $(SoftLinkageKey)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Registry error: add value list."
goto fatalregistry
endif
addAdapterComponent = +
Debug-Output "******************Entering addAdapterComponent******************"
Shell $(UtilityInf), AddHardwareComponent, $(ProductHardwareName), +
$(STF_CONTEXTINFNAME), $(ProductKeyNameHdwDriver)
ifint $($R4) != -1
Set OEM_ABANDON_OPTIONS = >($(OEM_ABANDON_OPTIONS), $(!NTN_SoftwareBase)"\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$($R4))
endif
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "Cannot add hardware component!"
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Registry error: add hardware component"
Debug-Output $(RegistryErrorIndex)
CloseRegKey $($R1)
CloseRegKey $($R2)
CloseRegKey $($R3)
goto fatalregistry
endif
set KeyParameters = $($R3)
set KeyAdapterRules = $($R2)
set AdapterNumber = $($R4)
set AdapterServiceName = $($R5)
set AdapterName = $(AdapterServiceName)
set NewValueList = {{Manufacturer,$(NoTitle),$(!REG_VT_SZ),$(Manufacturer)},+
{Title,$(NoTitle),$(!REG_VT_SZ),"["$($R4)"] "$(ProductHardwareTitle)},+
{Description,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareDescription)},+
{ProductName,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareName)},+
{ServiceName,$(NoTitle),$(!REG_VT_SZ),$($R5)},+
{InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
Shell $(UtilityInf), AddValueList, $($R1), $(NewValueList)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: AddValueList FAILED -- "$($R1)
goto ShellCodeError
endif
Debug-Output "****************** Incrementing DigiFEP5 ref count ***"
shell $(UtilityInf) IncrementRefCount $(ProductKeyName)
OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) ProductKey
ifstr $(ProductKey) == $(KeyNull)
goto fatalregistry
endif
GetRegValue $(ProductKey), "Image"$(AdapterFepImage)"RefCount", ImageRefCountList
set ImageRefCount = *($(ImageRefCountList),4)
set-add ImageRefCount = $(ImageRefCount), 1
SetRegValue $(ProductKey) {"Image"$(AdapterFepImage)"RefCount", $(NoTitle), +
$(!REG_VT_DWORD), $(ImageRefCount)}
Debug-Output "AdapterConcImages "$(AdapterConcImages)
ifstr(i) $(AdapterConcImages) != ""
ForListDo $(AdapterConcImages)
Debug-Output "Concentrator image file name "$($)
GetRegValue $(ProductKey), "Image"$($)"RefCount", ImageRefCountList
set ImageRefCount = *($(ImageRefCountList),4)
set-add ImageRefCount = $(ImageRefCount), 1
SetRegValue $(ProductKey) {"Image"$($)"RefCount", $(NoTitle), +
$(!REG_VT_DWORD), $(ImageRefCount)}
EndForListDo
endif
CloseRegKey $(ProductKey)
set TempProdName = """"$(ProductHardwareName)$(AdapterNumber)""""
set TempBindForm = $(TempProdName)$(NetRuleHardwareBindForm)
set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleHardwareType)},+
{bindform,$(NoTitle),$(!REG_VT_SZ),$(TempBindForm)}, +
{class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleHardwareClass)}, +
{InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
Shell $(UtilityInf), AddValueList, $(KeyAdapterRules), $(NewValueList)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error."
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Registry error: add value list."
CloseRegKey $(KeyParameters)
CloseRegKey $(KeyAdapterRules)
goto fatalregistry
endif
FlushRegKey $(KeyParameters)
FlushRegKey $(KeyAdapterRules)
CloseRegKey $(KeyParameters)
CloseRegKey $(KeyAdapterRules)
LoadLibrary "x" $(!STF_CWDDIR)dgconfig.dll DGCONFIG_HANDLE
goto adapteroptions
ConfigureAdapter = +
Debug-Output "******************Entering ConfigureAdapter******************"
Debug-Output "from value = "$(from)
set CtrlList = {}
LoadLibrary "x" $(!STF_CWDDIR)dgconfig.dll DGCONFIG_HANDLE
Ifstr $(!NTN_RegBase) != $(KeyNull)
OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) SoftwareKey
Ifstr $(SoftwareKey) == $(KeyNull)
Debug-Output "Unable to open "$(!NTN_RegBase)" key!!!!"
goto getAdapterSettingsExit
Else
GetRegValue $(SoftwareKey), "ServiceName", ServiceNameList
set AdapterServiceName = *($(ServiceNameList),4)
set AdapterName = $(AdapterServiceName)
CloseRegKey $(SoftwareKey)
Endif
Endif
Debug-Output "AdapterServiceName = "$(AdapterServiceName)
Debug-Output "AdapterName = "$(AdapterName)
OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(AdapterServiceName) $(MAXIMUM_ALLOWED) BaseKey
Ifstr $(BaseKey) == $(KeyNull)
Debug-Output "Error opening BaseKey "$(!NTN_ServiceBase)"\"$(AdapterServiceName)
CloseRegKey $(BaseKey)
goto fatalregistry
Endif
set BusTypeNum = 1
set SlotNumber = -1
set ParametersKey = $(KeyNull)
OpenRegKey $(BaseKey) "" "Parameters" $(MAXIMUM_ALLOWED) ParametersKey
Debug-Output "Reading Parameters Key for current configuration"
GetRegValue $(ParametersKey) "BusType" BusTypeNum
set BusTypeNum = *($(BusTypeNum),4)
ifstr(i) $(AdapterBusType) == "MCA"
read-syms UpdateObsoleteNames
Ifcontains(i) $(Option) in $(ObsoleteList)
set BusType = "MCA"
read-syms FileConstants
read-syms FileConstants$(!STF_LANGUAGE)
endif
GetRegValue $(ParametersKey) "MCAPosId" MCAPosId
GetRegValue $(ParametersKey) "SlotNumber" SlotNumber
GetRegValue $(ParametersKey) "BusNumber" BusNumber
set MCAPosId = *($(MCAPosId),4)
set SlotNumber = *($(SlotNumber),4)
set BusNumber = *($(BusNumber),4)
Debug-Output "MCAPosId read from registry = "$(MCAPosId)
Debug-Output "SlotNumber read from registry = "$(SlotNumber)
Debug-Output "BusNumber read from registry = "$(BusNumber)
else
ifstr(i) $(AdapterBusType) == "PCI"
GetRegValue $(ParametersKey) "SlotNumber" SlotNumber
GetRegValue $(ParametersKey) "BusNumber" BusNumber
set SlotNumber = *($(SlotNumber),4)
set BusNumber = *($(BusNumber),4)
Debug-Output "SlotNumber read from registry = "$(SlotNumber)
Debug-Output "BusNumber read from registry = "$(BusNumber)
else
ifstr(i) $(AdapterBusType) == "EISA"
GetRegValue $(ParametersKey) "BusNumber" BusNumber
GetRegValue $(ParametersKey) "SlotNumber" SlotNumber
GetRegValue $(ParametersKey) "IOBaseAddress" EISAIOBaseAddress
set BusNumber = *($(BusNumber),4)
set SlotNumber = *($(SlotNumber),4)
set EISAIOBaseAddress = *($(EISAIOBaseAddress),4)
Debug-OutPut "BusNumber read from registry = "$(BusNumber)
endif
endif
endif
adapteroptions = +
Debug-Output "******************Entering adapteroptions ******************"
set SlotDeviceNumList = {}
ifstr(i) $(AdapterBusType) == "PCI"
ForListDo $(AdapterHardwareAdapterID)
ifint $($) != 0
set Vendor = 4431
Shell $(UtilityInf), GetPCIInformation, $(Vendor) $($)
set CardInfo = {}
ifstr(i) $($R0) != {}
set CardInfo = $($R0)
set SlotDeviceNumList = $($R0)
endif
endif
EndForListDo
Debug-OutPut "OEMNADDS.INF: PCI Information: "$(SlotDeviceNumList)
set SlotDefault = 0
ForListDo $(SlotDeviceNumList)
Ifstr(i) $(BusNumber) == *($($),1)
Ifstr(i) $(SlotNumber) == *($($),2)
set-sub SlotDefault = $(#),1
Debug-Output "OEMNADDS.INF: Current adapter in bus "*($($),1)" and slot "*($($),2)
Endif
Endif
EndForListDo
else-ifstr(i) $(AdapterBusType) == "EISA"
ForListDo $(AdapterHardwareAdapterID)
ifint $($) != 0
Shell $(UtilityInf), EISAFindBus, $($)
set CardInfo = {}
ifstr(i) $($R1) != {}
set CardInfo = $($R1)
set SlotDeviceNumList = $($R1)
endif
endif
EndForListDo
set SlotDefault = 0
ForListDo $(SlotDeviceNumList)
Ifstr(i) $(BusNumber) == *($($),1)
Ifstr(i) $(SlotNumber) == *($($),2)
set-sub SlotDefault = $(#),1
Debug-Output "OEMNADDS.INF: Current adapter in bus "*($($),1)" and slot "*($($),2)
Endif
Endif
EndForListDo
endif
QueryListSize SlotDeviceNumListSize $(SlotDeviceNumList)
Debug-Output "AdapterHardwareType = "$(AdapterHardwareType)
Debug-Output "Manufacturer = "$(ManufacturerDisplayName)
Debug-Output "ConfigurationTitle = "$(ConfigurationTitle)
Debug-Output "AdapterName = "$(AdapterName)
Debug-Output "ProductHardwareDescription = "$(ProductHardwareDescription)
Debug-Output "BusTypeNum = "$(BusTypeNum)
Debug-OutPut "Slot/Device number default = "$(SlotDefault)
LibraryProcedure Result, $(DGCONFIG_HANDLE), +
DGConfigEntryPoint, $(AdapterHardwareType), +
$(ManufacturerDisplayName), +
$(AdapterName), +
$(ProductHardwareDescription), +
$(BusTypeNum),+
$(SlotNumber), +
$(!STF_HWND)
Ifstr(i) $(Result) == "Cancel"
Debug-Output "Returned from dll with "$(Result)
ifstr(i) $(!NTN_InstallMode) == install
set Error = $(DigiAsyncCancelInstall)
set from = "end"
goto fatal
else
goto cancel
endif
Endif
read-syms UpdatingConfiguration$(!STF_LANGUAGE)
shell $(subroutninf) PushBillBoard NETSTATUSDLG $(UpdatingConfiguration)
writeparameters = +
Debug-Output "******************Entering writeparameters******************"
StartWait
Debug-Output "Trying to open: "$(!NTN_ServiceBase)"\"$(AdapterServiceName)
OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(AdapterServiceName) $(MAXIMUM_ALLOWED) BaseKey
Ifstr $(BaseKey) == $(KeyNull)
Debug-Output "Error opening BaseKey "$(!NTN_ServiceBase)"\"$(AdapterServiceName)
CloseRegKey $(BaseKey)
goto fatal
Endif
OpenRegKey $(BaseKey) "" "Parameters" $(MAXIMUM_ALLOWED) ParametersKey
Ifstr $(ParametersKey) == $(KeyNull)
Debug-Output "Assuming Parameters key does not exist!!!"
CloseRegKey $(BaseKey)
goto fatal
Endif
set HdwDeviceName = "\Device\"$(AdapterHardwareDriver)
SetRegValue $(ParametersKey) {HdwDeviceName,$(NoTitle),$(!REG_VT_SZ),$(HdwDeviceName)}
SetRegValue $(ParametersKey) {BusType,$(NoTitle),$(!REG_VT_DWORD),$(BusTypeNum)}
SetRegValue $(ParametersKey) {FEPImagePath,$(NoTitle),$(!REG_VT_SZ),$(AdapterFepImage)}
SetRegValue $(ParametersKey) {BiosImagePath,$(NoTitle),$(!REG_VT_SZ),$(AdapterBiosImage)}
ifstr $(AdapterConcImages) != ""
SetRegValue $(ParametersKey) {ConcImagePath,$(NoTitle),$(!REG_VT_MULTI_SZ),$(AdapterConcImages)}
endif
goto WriteParams$(AdapterBusType)
WriteParamsMCA = +
Debug-Output "MCAPosId = "$(MCAPosId)
Debug-Output "SlotNumber = "$(SlotNumber)
SetRegValue $(ParametersKey) {MCAPosId,$(NoTitle),$(!REG_VT_DWORD),$(MCAPosId)}
SetRegValue $(ParametersKey) {SlotNumber,$(NoTitle),$(!REG_VT_DWORD),$(SlotNumber)}
SetRegValue $(ParametersKey) {BusNumber,$(NoTitle),$(!REG_VT_DWORD),$(BusNumber)}
goto WriteParamsDone
WriteParamsPCI = +
Debug-Output "PCI SlotNumber = "$(SlotNumber)
SetRegValue $(ParametersKey) {SlotNumber,$(NoTitle),$(!REG_VT_DWORD),$(SlotNumber)}
SetRegValue $(ParametersKey) {BusNumber,$(NoTitle),$(!REG_VT_DWORD),$(BusNumber)}
goto WriteParamsDone
WriteParamsEISA = +
SetRegValue $(ParametersKey) {IOBaseAddress,$(NoTitle),$(!REG_VT_DWORD),$(EISAIOBaseAddress)}
SetRegValue $(ParametersKey) {SlotNumber,$(NoTitle),$(!REG_VT_DWORD),$(SlotNumber)}
SetRegValue $(ParametersKey) {BusNumber,$(NoTitle),$(!REG_VT_DWORD),$(BusNumber)}
goto WriteParamsDone
WriteParamsISA = +
goto WriteParamsDone
WriteParamsDone = +
Debug-Output " Done writing parameters..."
CloseRegKey $(ParametersKey)
EndWait
goto successful
bindingadapter = +
Debug-Output "******************Entering bindingadapter******************"
Debug-Output "Updating ras\modem.inf file with Digi modem entries"
LoadLibrary "x" $(!STF_CWDDIR)dgconfig.dll DGCONFIG_HANDLE
LibraryProcedure Result, $(DGCONFIG_HANDLE), +
DGConfigModemInfFile, $(!STF_HWND)
goto successful
removeadapter = +
read-syms DebugOptions
Debug-Output "******************Entering removeadapter******************"
Debug-Output "OEMNADDS.INF: removeadapter"
Debug-Output "OEMNADDS.INF: Removing Hardware Components"
Debug-Output "OEMNADDS.INF: ProductKeyName = "$(ProductKeyName)
Debug-Output "OEMNADDS.INF: ProductSoftwareName = "$(ProductSoftwareName)
Debug-Output "OEMNADDS.INF: ProductSoftwareNameHdwDriver = "$(ProductSoftwareNameHdwDriver)
Debug-Output "OEMNADDS.INF: NTN_RegBase = "$(!NTN_RegBase)
ifstr(i) $(fRemoveDigi) == FALSE
install RemoveFiles
goto removeadapterExit
endif
LoadLibrary "x" $(!STF_CWDDIR)dgconfig.dll DGCONFIG_HANDLE
Ifstr $(!NTN_RegBase) != $(KeyNull)
OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) SoftwareKey
Ifstr $(SoftwareKey) == $(KeyNull)
Debug-Output "Unable to open "$(!NTN_RegBase)" key!!!!"
Else
GetRegValue $(SoftwareKey), "ServiceName", ServiceNameList
set AdapterServiceName = *($(ServiceNameList),4)
CloseRegKey $(SoftwareKey)
LibraryProcedure Result, $(DGCONFIG_HANDLE), +
DGDeinstallPorts, $(AdapterServiceName)
Endif
Endif
Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
$(ProductSoftwareNameHdwDriver), $(!NTN_RegBase)
Debug-Output "OEMNADDS.INF: RemoveHardwareComponent return value = "$($R0)
Ifstr(i) $($R0) != NO_ERROR
Debug-Output "OEMNADDS.INF: RemoveHardwareComponent != NO_ERROR"
Endif
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error"
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
Debug-Output "fatal registry error"
goto fatalregistry
endif
shell $(UtilityInf), DecrementRefCount, $(ProductKeyName)
Debug-Output "OEMNADDS.INF: DecrementRefCount return value = "$($R0)
Ifstr(i) $($R0) != NO_ERROR
Debug-Output "OEMNADDS.INF: DecrementRefCount != NO_ERROR"
Endif
Shell $(UtilityInf), IsRefCountEqualZero $(ProductKeyName)
ifint $($R1) == 1
set FLibraryErrCtl = 1
StartDetachedProcess ExitCode "" "" $(!STF_WINDOWSSYSPATH)\unlodctr.exe digifep5
Debug-Output "OEMNADDS.INF UNLODCTR result:"$(ExitCode)
ifint $(ExitCode) != 0
Debug-Output "OEMNADDS.INF: error unloading perfmon counters"
endif
set Status = STATUS_SUCCESSFUL
set FLibraryErrCtl = 0
OpenRegKey $(!REG_H_LOCAL) "" "SYSTEM\CurrentControlSet\Services\EventLog\Application" $(MAXIMUM_ALLOWED) KeyEventLog
ifstr $(KeyEventLog) == ""
Debug-Output "OEMNADDS.INF: Cannot open eventlog key"
else
Debug-Output "OEMNADDS.INF: Deleting eventlog key"
DeleteRegKey $(KeyEventLog) "fepctrs"
FlushRegKey $(KeyEventLog)
CloseRegKey $(KeyEventLog)
endif
endif
Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
$(ProductSoftwareName), TRUE
Debug-Output "RemoveSoftwareComponent return value = "$($R0)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error"
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
Ifstr(i) $(RegistryErrorIndex) != REF_COUNT_NOT_ZERO
goto fatalregistry
endif
endif
install RemoveFiles
removeadapterExit = +
Debug-Output "OEMNADDS.INF: Exiting removeadapter"
goto end
UpgradeSoftware = +
Debug-Output "******************Entering UpgradeSoftware******************"
Debug-Output " ProductKeyName = "$(ProductKeyName)
Debug-Output " NTN_RegBase = "$(!NTN_RegBase)
Debug-Output "OEMNADDS.INF: INFfile = "$(STF_CONTEXTINFNAME)
OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
Ifstr $(KeyProduct) != $(KeyNull)
GetRegValue $(KeyProduct),"DriverMajorVersion", MajorVersionInfo
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
set MajorVersion = 0
else
set MajorVersion = *($(MajorVersionInfo), 4)
endif
GetRegValue $(KeyProduct),"DriverMinorVersion", MinorVersionInfo
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
set MinorVersion = 0
else
set MinorVersion = *($(MinorVersionInfo), 4)
endif
GetRegValue $(KeyProduct),"DriverSubMinorVersion", SubMinorVersionInfo
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
set SubMinorVersion = 0
else
set SubMinorVersion = *($(SubMinorVersionInfo), 4)
endif
CloseRegKey $(KeyProduct)
ifint $(MinorVersion) == 23
set MinorVersion = 2
set SubMinorVersion = 3
endif
Debug-Output "OEMNADDS.INF: Installed MajorVersion: "$(MajorVersion)
Debug-Output " Installed MinorVersion: "$(MinorVersion)
Debug-Output " Installed SubMinorVersion: "$(SubMinorVersion)
Debug-Output "OEMNADDS.INF: Upgrade MajorVersion: "$(DriverMajorVersion)
Debug-Output " Upgrade MinorVersion: "$(DriverMinorVersion)
Debug-Output " Upgrade SubMinorVersion: "$(DriverSubMinorVersion)
ifint $(MajorVersion) > $(DriverMajorVersion)
goto NewerDriverInstalled
else-ifint $(MajorVersion) == $(DriverMajorVersion)
ifint $(MinorVersion) > $(DriverMinorVersion)
goto NewerDriverInstalled
else-ifint $(MinorVersion) == $(DriverMinorVersion)
ifint $(SubMinorVersion) > $(DriverSubMinorVersion)
goto NewerDriverInstalled
else-ifint $(SubMinorVersion) == $(DriverSubMinorVersion)
set Error = $(AlreadyUpgraded)
set from = "end"
set CommonStatus = STATUS_USERCANCEL
goto nonfatal
endif
endif
endif
goto ContinueUpgrade
NewerDriverInstalled = +
set Error = $(NewerInstalled)
set from = "end"
set CommonStatus = STATUS_USERCANCEL
goto nonfatal
ContinueUpgrade = +
Debug-Output "Compared installed driver version - continuing with upgrade..."
OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
Shell $(UtilityInf), GetInfFileNameFromRegistry, $(KeyProduct)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error"
goto ShellCodeError
endif
set !UG_Filename = $($R0)
set STF_CONTEXTINFNAME = $(!STF_WINDOWSSYSPATH)"\"$(!UG_Filename)
ifstr(i) $(!UG_Filename) == ""
set from = "end"
goto nonfatal
endif
Debug-Output "OEMNADDS.INF: INFfile = "$(STF_CONTEXTINFNAME)
Debug-Output "OEMNADDS.INF:Product Key Name = "$(ProductKeyName)
OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
Ifstr $(KeyProduct) != $(KeyNull)
GetRegValue $(KeyProduct),"Imagexacook.binRefCount", BinRefCount
ifint $(RegLastError) != $(!REG_ERROR_SUCCESS)
set UpdateBinRefCounts = $(TRUE)
read-syms BinaryList
set NewValueList = {}
ForListDo $(fep-all)
set NewValueList = >($(NewValueList),{Image$($)RefCount,$(NoTitle),$(!REG_VT_DWORD), 0})
EndForListDo
ForListDo $(conc-all)
set NewValueList = >($(NewValueList),{Image$($)RefCount,$(NoTitle),$(!REG_VT_DWORD), 0})
EndForListDo
Debug-Output "NewValueList "$(NewValueList)
Shell $(UtilityInf), AddValueList, $(KeyProduct), $(NewValueList)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: AddValueList FAILED! --"$(KeyProduct)
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
CloseRegKey $(KeyProduct)
goto fatalregistry
endif
else
set UpdateBinRefCounts = $(FALSE)
endif
CloseRegKey $(KeyProduct)
else
goto fatalregistry
endif
set NetworkCardKeyName = $(!NTN_SoftwareBase)"\Microsoft\Windows NT\CurrentVersion\NetworkCards"
OpenRegKey $(!REG_H_LOCAL) "" $(NetworkCardKeyName) $(MAXIMUM_ALLOWED) IE_KeyNetcards
ifstr(i) $(IE_KeyNetcards) != ""
EnumRegKey $(IE_KeyNetcards) IE_KeyNameList
ForListDo $(IE_KeyNameList)
OpenRegKey $(IE_KeyNetcards) "" *($($),1) +
$(MAXIMUM_ALLOWED) NetworkCardKey
Ifstr(i) $(NetworkCardKey) != $(KeyNull)
GetRegValue $(NetworkCardKey),"Manufacturer", ManufacturerInfo
set ManufacturerName = *($(ManufacturerInfo), 4)
Debug-Output " Manufacturer = "$(ManufacturerName)
Ifstr $(ManufacturerName) != $(Manufacturer)
goto nextnetcard
endif
GetRegValue $(NetworkCardKey),"ProductName", ProductNameInfo
set ProductName = *($(ProductNameInfo), 4)
Debug-Output " ProductName = "$(ProductName)
ifcontains(i) $(ProductName) not-in $(AdapterHardwareDriverList)
goto nextnetcard
endif
GetRegValue $(NetworkCardKey),"ServiceName", ServiceNameInfo
set ServiceName = *($(ServiceNameInfo), 4)
Debug-Output " ServiceName = "$(ServiceName)
OpenRegKey $(NetworkCardKey) "" "NetRules" +
$(MAXIMUM_ALLOWED) NetRuleKey
Ifstr $(NetRuleKey) != $(KeyNull)
GetRegValue $(NetRuleKey), "InfName", InfNameList
set InfName = *($(InfNameList), 4)
ifstr(i) $(!UG_Filename) != $(InfName)
LibraryProcedure STATUS, $(!LIBHANDLE), DelFile $(!STF_WINDOWSSYSPATH)"\"$(InfName)
endif
SetRegValue $(NetRuleKey) {InfName,$(NoTitle),$(!REG_VT_SZ),$(!UG_Filename)}
GetRegValue $(NetRuleKey),"InfOption", InfOptionInfo
set InfOption = *($(InfOptionInfo), 4)
Debug-Output "InfOption "$(InfOption)
Ifcontains(i) $(InfOption) not-in $(AdapterList)
Debug-Output "Error, InfOption is not in current AdapterList"
set Error = $(UpgradeNotPossible)
set from = "end"
goto nonfatal
endif
read-syms UpdateObsoleteNames
Ifcontains(i) $(InfOption) in $(ObsoleteList)
OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(ServiceName) $(MAXIMUM_ALLOWED) BaseKey
Ifstr $(BaseKey) == $(KeyNull)
Debug-Output "Error opening BaseKey "$(!NTN_ServiceBase)"\"$(ServiceName)
CloseRegKey $(BaseKey)
goto fatalregistry
Endif
set ParametersKey = $(KeyNull)
OpenRegKey $(BaseKey) "" "Parameters" $(MAXIMUM_ALLOWED) ParametersKey
GetRegValue $(ParametersKey) "BusType" BusTypeNum
set BusTypeNum = *($(BusTypeNum),4)
ifstr $(BusTypeNum) == $(BusType_ISA)
Debug-Output "ISA Replacement "$(ISAReplacement)
set InfOption = $(ISAReplacement)
endif
ifstr $(BusTypeNum) == $(BusType_EISA)
Debug-Output "EISA Replacement "$(EISAReplacement)
set InfOption = $(EISAReplacement)
set UpgradeObsoleteEISA = TRUE
endif
ifstr $(BusTypeNum) == $(BusType_MCA)
Debug-Output "MCA Replacement "$(MCAReplacement)
set InfOption = $(MCAReplacement)
endif
Debug-Output "Updated obsolete InfOption to "$(InfOption)
ifstr $(InfOption) == ""
Debug-Output "Replacement infoption is invalid"
set Error = $(UpgradeNotPossible)
set from = "end"
goto nonfatal
endif
Ifcontains(i) $(InfOption) not-in $(AdapterList)
Debug-Output "Replacement infoption is invalid"
set Error = $(UpgradeNotPossible)
set from = "end"
goto nonfatal
endif
SetRegValue $(NetRuleKey) {InfOption,$(NoTitle),$(!REG_VT_SZ),$(InfOption)}
endif
set Option = $(InfOption)
read-syms FileConstants
read-syms FileConstants$(!STF_LANGUAGE)
Debug-Output "Replacing NetworkCardKey Title ["*($($),1)"] "$(ProductHardwareDescription)
SetRegValue $(NetworkCardKey) {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareDescription)}
SetRegValue $(NetworkCardKey) {Title,$(NoTitle),$(!REG_VT_SZ),"["*($($),1)"] "$(ProductHardwareDescription)}
endif
CloseRegKey $(NetRules)
CloseRegKey $(NetRuleKey)
CloseRegKey $(NetworkCardKey)
endif
install "Install-Upgrade"
ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
Shell $(UtilityInf) RegistryErrorString "UNABLE_COPY_FILE"
ifint $($ShellCode) != $(!SHELL_CODE_OK)
goto ShellCodeError
endif
set Error = $($R0)
goto fatal
endif
Debug-Output " UpdateBinRefCounts = "$(UpdateBinRefCounts)
ifstr(i) $(UpdateBinRefCounts) == $(TRUE)
OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
Ifstr $(KeyProduct) == $(KeyNull)
goto fatalregistry
endif
GetRegValue $(KeyProduct), "Image"$(AdapterFepImage)"RefCount", ImageRefCountList
set ImageRefCount = *($(ImageRefCountList),4)
set-add ImageRefCount = $(ImageRefCount), 1
SetRegValue $(KeyProduct) {"Image"$(AdapterFepImage)"RefCount", $(NoTitle), +
$(!REG_VT_DWORD), $(ImageRefCount)}
Ifstr $(AdapterConcImages) != ""
ForListDo $(AdapterConcImages)
GetRegValue $(KeyProduct), "Image"$($)"RefCount", ImageRefCountList
set ImageRefCount = *($(ImageRefCountList),4)
set-add ImageRefCount = $(ImageRefCount), 1
SetRegValue $(KeyProduct) {"Image"$($)"RefCount", $(NoTitle), +
$(!REG_VT_DWORD), $(ImageRefCount)}
EndForListDo
endif
read-syms BindingInfo-DigiFEP5
Debug-Output "OEMNADDS.INF Updating the bindable parameter: "$(BindingInfo)
OpenRegKey $(KeyProduct) "" "NetRules" $(MAXIMUM_ALLOWED) NetRulesProduct
Ifstr(i) $(NetRulesProduct) != $(KeyNull)
SetRegValue $(NetRulesProduct) {"bindable",$(NoTitle),$(!REG_VT_MULTI_SZ),$(BindingInfo)}
CloseRegKey $(NetRulesProduct)
endif
CloseRegKey $(KeyProduct)
endif
OpenRegKey $(!REG_H_LOCAL) "" +
$(!NTN_ServiceBase)"\"$(ServiceName) +
$(MAXIMUM_ALLOWED) ServiceKey
Ifstr $(ServiceKey) != $(KeyNull)
Debug-Output " Opened service key "$(ServiceName)" successfully"
OpenRegKey $(ServiceKey) "" "Parameters" +
$(MAXIMUM_ALLOWED) ParametersKey
Ifstr $(ParametersKey) != $(KeyNull)
SetRegValue $(ParametersKey) {FEPImagePath,$(NoTitle),$(!REG_VT_SZ),$(AdapterFepImage)}
SetRegValue $(ParametersKey) {BiosImagePath,$(NoTitle),$(!REG_VT_SZ),$(AdapterBiosImage)}
ifstr $(AdapterConcImages) != ""
SetRegValue $(ParametersKey) {ConcImagePath,$(NoTitle),$(!REG_VT_MULTI_SZ),$(AdapterConcImages)}
endif
ifstr $(UpgradeObsoleteEISA) == TRUE
GetRegValue $(ParametersKey) "IOBaseAddress" EISAIOBaseAddress
set EISAIOBaseAddress = *($(EISAIOBaseAddress),4)
set-sub TmpValue = $(EISAIOBaseAddress),5
set-div SlotNumber = $(TmpValue),4096
SetRegValue $(ParametersKey) {SlotNumber,$(NoTitle),$(!REG_VT_DWORD),$(SlotNumber)}
endif
CloseRegKey $(ParametersKey)
else
goto fatalregistry
Endif
StartWait
Debug-Output "OEMNADDS.INF: Update: checking for "$(PerformanceKeyName)
OpenRegKey $(!REG_H_LOCAL) "" $(PerformanceKeyName) $(MAXIMUM_ALLOWED) KeyPerformance
ifstr $(KeyPerformance) != $(KeyNull)
Debug-Output "OEMNADDS.INF: Performance key found"
set FLibraryErrCtl = 1
StartDetachedProcess ExitCode "" "" $(!STF_WINDOWSSYSPATH)\unlodctr.exe digifep5
Debug-Output "OEMNADDS.INF UNLODCTR result:"$(ExitCode)
ifint $(ExitCode) != 0
Debug-Output "OEMNADDS.INF: error unloading perfmon counters"
endif
set Status = STATUS_SUCCESSFUL
set FLibraryErrCtl = 0
Sleep 2000
Else
Debug-Output "OEMNADDS.INF: Performance key not found, "$(KeyPerformance)" creating"
OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\"$(ProductSoftwareName) $(MAXIMUM_ALLOWED) KeyDigiFEP5
CreateRegKey $(KeyDigiFEP5) {"Performance",$(NoTitle),GenericClass} "" +
$(MAXIMUM_ALLOWED) "" KeyPerformance
set NewValueList = {{Library,$(NoTitle),$(!REG_VT_SZ),fepctrs.dll}, +
{Open,$(NoTitle),$(!REG_VT_SZ),"OpenFepPerformanceData"}, +
{Close,$(NoTitle),$(!REG_VT_SZ),"CloseFepPerformanceData"}, +
{Collect,$(NoTitle),$(!REG_VT_SZ),"CollectFepPerformanceData"}}
Shell $(UtilityInf), AddValueList, $(KeyPerformance), $(NewValueList)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: AddValueList FAILED! --"$(KeyPerformance)
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
ifstr $(RegistryErrorIndex) != NO_ERROR
EndWait
Debug-Output "Registry error: add value list."
CloseRegKey $(KeyPerformance)
CloseRegKey $(KeyDigiFEP5)
CloseRegKey $(ServiceKey)
goto fatalregistry
endif
OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_ServiceBase)"\EventLog\Application" $(MAXIMUM_ALLOWED) KeyEventLog
ifstr $(KeyEventLog) == ""
Debug-Output "OEMNADDS.INF: Cannot open eventlog key"
else
Debug-Output "OEMNADDS.INF: Adding eventlog key"
CreateRegKey $(KeyEventLog) {"fepctrs",$(NoTitle),GenericClass} "" $(MAXIMUM_ALLOWED) "" KeyEventLogFep
ifstr $(KeyEventLogFep) == ""
OpenRegKey $(KeyEventLogFep) "" "fepctrs" $(MAXIMUM_ALLOWED) KeyEventLogFep
endif
ifstr $(KeyEventLogFep) != ""
SetRegValue $(KeyEventLogFep) {EventMessageFile,$(NoTitle),$(!REG_VT_EXPAND_SZ),"%SystemRoot%\System32\fepctrs.dll"}
SetRegValue $(KeyEventLogFep) {TypesSupported,$(NoTitle),$(!REG_VT_DWORD),7}
FlushRegKey $(KeyEventLogFep)
CloseRegKey $(KeyEventLogFep)
endif
FlushRegKey $(KeyEventLog)
CloseRegKey $(KeyEventLog)
endif
CloseRegKey $(KeyDigiFEP5)
endif
FlushRegKey $(KeyPerformance)
CloseRegKey $(KeyPerformance)
CloseRegKey $(ServiceKey)
set FLibraryErrCtl = 1
StartDetachedProcess ExitCode "" "" $(!STF_WINDOWSSYSPATH)\lodctr.exe $(!STF_WINDOWSSYSPATH)\fepctrs.ini
Debug-Output "OEMNADDS.INF LODCTR result:"$(ExitCode)
ifint $(ExitCode) != 0
Debug-Output "OEMNADDS.INF: error loading perfmon counters"
endif
set Status = STATUS_SUCCESSFUL
set FLibraryErrCtl = 0
EndWait
else
goto fatalregistry
endif
nextnetcard = +
EndForListDo
OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
Ifstr $(KeyProduct) != $(KeyNull)
SetRegValue $(KeyProduct) {MajorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMajorVersion)}
SetRegValue $(KeyProduct) {MinorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMinorVersion)}
SetRegValue $(KeyProduct) {DriverMajorVersion,$(NoTitle),$(!REG_VT_SZ),$(DriverMajorVersion)}
SetRegValue $(KeyProduct) {DriverMinorVersion,$(NoTitle),$(!REG_VT_SZ),$(DriverMinorVersion)}
SetRegValue $(KeyProduct) {DriverSubMinorVersion,$(NoTitle),$(!REG_VT_SZ),$(DriverSubMinorVersion)}
CloseRegKey $(KeyProduct)
endif
goto end
cancel = +
Debug-Output "****************** Entering cancel ******************"
set CommonStatus = STATUS_USERCANCEL
goto end
successful = +
Debug-Output "******************Entering successful******************"
goto end
abandon = +
Debug-Output "******************Entering abandon******************"
ForListDo $(OEM_ABANDON_OPTIONS)
Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
$(ProductSoftwareName), $($)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error"
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
goto fatalregistry
endif
EndForListDo
Ifstr(i) $(OEM_ABANDON_SOFTWARE) == TRUE
Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
$(ProductSoftwareNameHdwDriver), FALSE
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error"
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
goto fatalregistry
endif
endif
Ifstr(i) $(OEM_ABANDON_FEP5_SOFTWARE) == TRUE
Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
$(ProductSoftwareName), FALSE
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error"
goto ShellCodeError
endif
set RegistryErrorIndex = $($R0)
Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
goto fatalregistry
endif
endif
install RemoveFiles
goto end
warning = +
Debug-Output "******************Entering warning******************"
Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "WARNING", $(Error)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
goto ShellCodeError
endif
ifstr(i) $($R1) == "OK"
goto $(to)
else-ifstr(i) $($R1) == "CANCEL"
goto $(from)
else
goto "end"
endif
nonfatalinfo = +
Debug-Output "******************Entering nonfatalinfo******************"
Set CommonStatus = STATUS_USERCANCEL
Set Severity = STATUS
goto nonfatalmsg
nonfatal = +
Debug-Output "******************Entering nonfatal******************"
Set Severity = NONFATAL
goto nonfatalmsg
nonfatalmsg = +
Debug-Output "******************Entering nonfatalmsg******************"
ifstr(i) $(Error) == ""
Set Severity = NONFATAL
Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
ifint $($ShellCode) != $(!SHELL_CODE_OK)
goto ShellCodeError
endif
set Error = $($R0)
endif
set DlgText = $(Error)
read-syms NonfatalDlg$(!STF_LANGUAGE)
ui start "SetupMessage"
ifstr(i) $(DLGEVENT) == "OK"
goto $(from)
else
goto "end"
endif
fatalregistry = +
Debug-Output "******************Entering fatalregistry******************"
Shell $(UtilityInf) RegistryErrorString $(RegistryErrorIndex)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "fatalregistry: shell to find RegistryErrorString failed."
goto ShellCodeError
endif
set Error = $($R0)" - service "$(DigiSpecificString)"."
ifstr(i) $(fRemoveDigi) == TRUE
read-syms AbortMessage$(!STF_LANGUAGE)
set Error = $(Error)$(!LF)$(!LF)$(AbortText)
endif
goto fatal
fataldetect = +
Debug-Output "******************Entering fataldetect******************"
Shell $(UtilityInf),RegistryErrorString,CANNOT_DETECT
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "ShellCode error: cannot get an error string."
goto ShellCodeError
endif
set Error = $($R0)
Goto fatal
fatal = +
Debug-Output "******************Entering fatal******************"
Debug-Output "OEMNADDS.INF: ---- fatal called"
Shell $(subroutninf) SetupMessage, $(!STF_LANGUAGE), "FATAL", $(Error)
ifint $($ShellCode) != $(!SHELL_CODE_OK)
Debug-Output "fatal: shell to SetupMessage failed."
goto ShellCodeError
endif
goto setfailed
ShellCodeError = +
Debug-Output "******************Entering ShellCodeError******************"
set DlgType = "MessageBox"
set STF_MB_TITLE = "Error: "$(FunctionTitle)
set STF_MB_TEXT = "Shell Code Error"
set STF_MB_TYPE = 1
set STF_MB_ICON = 3
set STF_MB_DEF = 1
ui start "Error Message"
goto setfailed
setfailed = +
Debug-Output "******************Entering setfailed******************"
set CommonStatus = STATUS_FAILED
ifstr(i) $(OEM_ABANDON_ON) == TRUE
set OEM_ABANDON_ON = FALSE
goto abandon
endif
ifstr(i) $(fRemoveDigi) == TRUE
set fRemoveDigi = FALSE
goto removeadapter
endif
goto end
end = +
Debug-Output "******************Entering end******************"
goto term
term = +
ifstr(i) $(DGCONFIG_HANDLE) != $(HandleNull)
FreeLibrary $(DGCONFIG_HANDLE)
endif
Debug-Output "******************Entering term -- GoodBye!!!******************"
Return $(CommonStatus)
[RemoveFiles]
Debug-Output "******************Entering [RemoveFiles]******************"
set RemoveList = {}
set RenameList = {}
OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyNameHdwDriver) +
$(MAXIMUM_ALLOWED) KeyProductHdwDriver
CloseRegKey $(KeyProductHdwDriver)
ifstr $(KeyProductHdwDriver) == $(KeyNull)
Debug-Output "Remove hardware driver: "$(AdapterHardwareDriver)".sys"
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\drivers\"$(AdapterHardwareDriver)".sys")
endif
OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) +
$(MAXIMUM_ALLOWED) KeyProduct
ifstr $(KeyProduct) == $(KeyNull)
CloseRegKey $(KeyProduct)
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\drivers\"$(ProductSoftwareName)".sys")
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\dgconfig.dll")
set RemoveList = >($(RemoveList), $(!STF_WINDOWSSYSPATH)"\dgconfig.hlp")
set RemoveList = >($(RemoveList), $(!STF_WINDOWSSYSPATH)"\dgconfig.cnt")
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\fepctrs.dll")
set RemoveList = >($(RemoveList), $(!STF_WINDOWSSYSPATH)"\fepctrs.ini")
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\fepctrnm.h")
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\drivers\"$(AdapterFepImage))
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\drivers\"$(AdapterBiosImage))
Ifstr(i) $(AdapterConcImages) != ""
ForListDo $(AdapterConcImages)
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\drivers\"$($))
EndForListDo
endif
else
GetRegValue $(KeyProduct), "Image"$(AdapterFepImage)"RefCount", ImageRefCountList
set ImageRefCount = *($(ImageRefCountList),4)
set-sub ImageRefCount = $(ImageRefCount), 1
SetRegValue $(KeyProduct) { "Image"$(AdapterFepImage)"RefCount", $(NoTitle), +
$(!REG_VT_DWORD), $(ImageRefCount)}
ifint $(ImageRefCount) == 0
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\drivers\"$(AdapterFepImage))
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\drivers\"$(AdapterBiosImage))
endif
Ifstr(i) $(AdapterConcImages) != ""
ForListDo $(AdapterConcImages)
GetRegValue $(KeyProduct), "Image"$($)"RefCount", ImageRefCountList
set ImageRefCount = *($(ImageRefCountList),4)
set-sub ImageRefCount = $(ImageRefCount), 1
SetRegValue $(KeyProduct) { "Image"$($)"RefCount", $(NoTitle), +
$(!REG_VT_DWORD), $(ImageRefCount)}
ifint $(ImageRefCount) == 0
set RenameList = >($(RenameList), $(!STF_WINDOWSSYSPATH)"\drivers\"$($))
endif
EndForListDo
endif
CloseRegKey $(KeyProduct)
endif
Debug-Output "RemoveList = "$(RemoveList)
Debug-Output "RenameList = "$(RenameList)
ForListDo $(RemoveList)
Debug-Output "Removing "$($)
LibraryProcedure Status , $(!LIBHANDLE), DelFile $($)
Debug-Output "Status is "$(Status)
EndForListDo
ForListDo $(RenameList)
Debug-Output "RenameList entry = "$($)
Split-String $($) "\" FilePath
QueryListSize PathLen $(FilePath)
Split-String *($(FilePath),$(PathLen)) "." FullFileName
Set FileName = *($(FullFileName),1)
Debug-Output "FileName is "$(FileName)
LibraryProcedure STATUS, $(!LIBHANDLE),CheckFileExistance $(!STF_WINDOWSSYSPATH)"\DRIVERS\"$(FileName)".old"
Debug-Output "CheckFile Status = "$(STATUS)
ifstr(i) $(STATUS) == YES
LibraryProcedure STATUS, $(!LIBHANDLE), DelFile $(!STF_WINDOWSSYSPATH)"\DRIVERS\"$(FileName)".old"
Debug-Output "Delfile Status = "$(STATUS)
LibraryProcedure STATUS, $(!LIBHANDLE), DelFile $($)
Debug-Output "Delfile Status = "$(STATUS)
else
ifstr(i) $(fRemoveDigi) == TRUE
Debug-Output "Renaming from "$($)
Debug-Output "Renaming to "$(!STF_WINDOWSSYSPATH)"\DRIVERS\"$(FileName)".old"
LibraryProcedure Status1 , $(!LIBHANDLE), RenFile $($), $(!STF_WINDOWSSYSPATH)"\DRIVERS\"$(FileName)".old"
Debug-Output "Status is "$(Status1)
AddFileToDeleteList $(!STF_WINDOWSSYSPATH)"\DRIVERS\"$(FileName)".old"
endif
endif
EndForListDo
exit
[ExCreateRegKey]
Debug-Output "******************Entering [ExCreateRegKey]******************"
set ECR_Result = NO_ERROR
set ECR_BaseKeyHandle = $($0)
set ECR_NewPath = $($1)
set KeyNull = ""
set MAXIMUM_ALLOWED = 33554432
Debug-Output "ExCreateRegKey - ECR_BaseKeyHandle = "$(ECR_BaseKeyHandle)
Debug-Output " ECR_NewPath = "$(ECR_NewPath)
Debug-Output " MAXIMUM_ALLOWED = "$(MAXIMUM_ALLOWED)
Debug-Output " KeyNull = "$(KeyNull)
OpenRegKey $(ECR_BaseKeyHandle) "" $(ECR_NewPath) $(MAXIMUM_ALLOWED) +
ECR_BaseKey
Debug-Output "ECR_BaseKey = "$(ECR_BaseKey)
Debug-Output " OpenRegKey returned "$($R0)
Ifstr $(ECR_BaseKey) == $(KeyNull)
Debug-Output "ECR_BaseKey == KeyNull"
Else
Debug-Output "ECR_BaseKey != KeyNull"
set ECR_KeyHandle = $(ECR_BaseKey)
goto ECR_Return
Endif
set ECR_TmpPath = ""
Split-String $(ECR_NewPath) "\" ECR_PList
Debug-Output "ECR_PList = "$(ECR_PList)
ForListDo $(ECR_PList)
Ifstr(i) $($) != "\"
Ifint $(#) == 1
set ECR_TmpPath = $($)
Else
set ECR_TmpPath = $(ECR_TmpPath)"\"$($)
Endif
Debug-Output "Determining if "$(ECR_TmpPath)" exists"
OpenRegKey $(ECR_BaseKeyHandle) "" $(ECR_TmpPath) $(MAXIMUM_ALLOWED) ECR_BaseKey
Ifstr $(ECR_BaseKey) == $(KeyNull)
Debug-Output "Creating "$(ECR_TmpPath)
CreateRegKey $(ECR_BaseKeyHandle) {$(ECR_TmpPath),0,GenericClass} "" $(MAXIMUM_ALLOWED) "" ECR_KeyHandle
Ifstr(i) $(ECR_KeyHandle) == $(KeyNull)
set ECR_Result = $($R0)
goto ECR_Return
Endif
Endif
Endif
EndForListDo
ECR_Return = +
return $(ECR_Result) $(ECR_KeyHandle)
[DebugExternalGlobals]
Set InfName = "OEMNADDS.INF"
Debug-Output $(InfName)" NTN_Origination = "$(!NTN_Origination)
Debug-Output $(InfName)" NTN_InstallMode = "$(!NTN_InstallMode)
Debug-Output $(InfName)" NTN_RegBase = "$(!NTN_RegBase)
Debug-Output $(InfName)" NTN_SoftwareBase = "$(!NTN_SoftwareBase)
Debug-Output $(InfName)" NTN_ServiceBase = "$(!NTN_ServiceBase)
Debug-Output $(InfName)" STF_NTPATH = "$(!STF_NTPATH)
Debug-Output $(InfName)" STF_NTWINDOWSSYSPATH = "$(!STF_WINDOWSSYSPATH)
Debug-Output $(InfName)" STF_CWDIR = "$(!STF_CWDIR)
Debug-Output $(InfName)" STF_LANGUAGE = "$(!STF_LANGUAGE)
Debug-Output $(InfName)" STF_NCDETECT = "$(!STF_NCDETECT)
Debug-Output $(InfName)" STF_NCOPTION = "$(!STF_NCOPTION)
Debug-Output $(InfName)" STF_NCDETCARD = "$(!STF_NCDETCARD)
Debug-Output $(InfName)" STF_NCDETINFO = "$(!STF_NCDETINFO)
Debug-Output $(InfName)" STF_INSTALL_MODE = "$(!STF_INSTALL_MODE)
Debug-Output $(InfName)" STF_CONTEXTINFNAME = "$(!STF_CONTEXTINFNAME)
return
[DebugConfiguration]
Set InfName = "OEMNADDS.INF"
Debug-Output $(InfName)" **CONFIGURATION STATE: "$($0)
Debug-Output $(InfName)" IRQ_Level is "$(!p:IRQ_Level)
Debug-Output $(InfName)" IOBaseAddrValue is "$(!p:IOBaseAddrValue)
Debug-Output $(InfName)" TransceiverValue is "$(!p:TransceiverValue)
Debug-Output $(InfName)" MemBaseAddrDec is "$(!p:MemBaseAddrDec)
Debug-Output $(InfName)" MappedValue is "$(!p:MappedValue)
return
[BindingInfo-DigiFEP5]
BindingInfo = {+
"digiFEP5Driver ntepcDriver non exclusive 100", +
"digiFEP5Driver ntcxDriver non exclusive 100", +
"digiFEP5Driver ntxemDriver non exclusive 100", +
"digiFEP5Driver ntxallDriver non exclusive 100", +
"digiFEP5Driver dgapciDriver non exclusive 100" +
}
[BindingInfo-HardwareDriver]
BindingInfo = {+
$(AdapterHardwareDriver)"Driver "$(AdapterHardwareDriver)"Adapter non exclusive 100", +
}
[InstallResources]
set STF_VITAL = ""
Debug-Output "OEMNADDS.INF: [InstallResources]"
AddSectionFilesToCopyList Files-Resource $(!SourceDir) $(!STF_WINDOWSSYSPATH)
Debug-Output "CopyFilesInCopyList 3"
CopyFilesInCopyList
Debug-Output "OEMNADDS.INF: [InstallResources] - Exiting"
exit
[Install-Option]
Debug-Output "********************* Inside Install-Option *************************"
Debug-Output " AddCopy = "$(AddCopy)
Debug-Output " DoCopy = "$(DoCopy)
Debug-Output " DoConfig = "$(DoConfig)
Debug-Output " NTN_InstallPhase = "$(!NTN_InstallPhase)
set STF_VITAL = ""
set STF_OVERWRITE = "VERIFYSOURCEOLDER"
ifstr(i) $(AddCopy) == "YES"
AddSectionFilesToCopyList Files-Inf $(SrcDir) $(!STF_WINDOWSSYSPATH)
AddSectionFilesToCopyList Files-Resource $(SrcDir) $(!STF_WINDOWSSYSPATH)
AddSectionFilesToCopyList Files-DigiFEP5 $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
AddSectionFilesToCopyList Files-$(AdapterHardwareDriver) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
LibraryProcedure FilePresent, $(!LIBHANDLE), CheckFileExistance $(SrcDir)..\images\fxfep.bin
ifstr(i) $(FilePresent) != "YES"
LibraryProcedure FilePresent, $(!LIBHANDLE), CheckFileExistance $(SrcDir)..\images\fxfep.bi_
ifstr(i) $(FilePresent) != "YES"
Debug-Output "Retrieving images from "$(SrcDir)
AddSectionFilesToCopyList Files-$(AdapterFepImage) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
AddSectionFilesToCopyList Files-$(AdapterConcKey) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
else
Debug-Output "Retrieving images from "$(SrcDir)"..\images"
AddSectionFilesToCopyList Files-$(AdapterFepImage) $(SrcDir)..\images $(!STF_WINDOWSSYSPATH)\drivers
AddSectionFilesToCopyList Files-$(AdapterConcKey) $(SrcDir)..\images $(!STF_WINDOWSSYSPATH)\drivers
endif
else
Debug-Output "Retrieving images from "$(SrcDir)"..\images"
AddSectionFilesToCopyList Files-$(AdapterFepImage) $(SrcDir)..\images $(!STF_WINDOWSSYSPATH)\drivers
AddSectionFilesToCopyList Files-$(AdapterConcKey) $(SrcDir)..\images $(!STF_WINDOWSSYSPATH)\drivers
endif
ifstr $(AdapterHardwareType) == "2"
goto Install-Modem-Files
endif
ifstr $(AdapterHardwareType) == "11"
goto Install-Modem-Files
endif
endif
ready_to_copyfiles = +
ifstr(i) $(DoCopy) == "YES"
set !STF_NCPA_FLUSH_COPYLIST = TRUE
Debug-Output "CopyFilesInCopyList 1"
CopyFilesInCopyList
else-ifstr(i) $(!NTN_InstallPhase) == primary
set !STF_NCPA_FLUSH_COPYLIST = TRUE
Debug-Output "CopyFilesInCopyList 2"
CopyFilesInCopyList
endif
ifstr(i) $(DoConfig) == "YES"
endif
Exit
Install-Modem-Files = +
Debug-Output "Install Modem em files"
ifstr $(NTVersion) != "3.50"
ifstr $(NTVersion) != "3.51"
Debug-Output "Retrieving ModemEm files for 4.00 or above"
AddSectionFilesToCopyList Files-ModemEm $(SrcDir) $(!STF_WINDOWSPATH)\inf
endif
endif
goto ready_to_copyfiles
[Install-Upgrade]
Debug-Output "********************* Inside Install-Upgrade *************************"
Debug-Output " AddCopy = "$(AddCopy)
Debug-Output " DoCopy = "$(DoCopy)
Debug-Output " DoConfig = "$(DoConfig)
Debug-Output " NTN_InstallPhase = "$(!NTN_InstallPhase)
set STF_VITAL = ""
set STF_OVERWRITE = "VERIFYSOURCEOLDER"
AddSectionFilesToCopyList Files-Inf $(SrcDir) $(!STF_WINDOWSSYSPATH)
AddSectionFilesToCopyList Files-UpgradeInf $(SrcDir) $(!STF_WINDOWSSYSPATH)
AddSectionFilesToCopyList Files-Resource $(SrcDir) $(!STF_WINDOWSSYSPATH)
AddSectionFilesToCopyList Files-DigiFEP5 $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
AddSectionFilesToCopyList Files-$(AdapterHardwareDriver) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
LibraryProcedure FilePresent, $(!LIBHANDLE), CheckFileExistance $(SrcDir)..\images\fxfep.bin
ifstr(i) $(FilePresent) != "YES"
LibraryProcedure FilePresent, $(!LIBHANDLE), CheckFileExistance $(SrcDir)..\images\fxfep.bi_
ifstr(i) $(FilePresent) != "YES"
Debug-Output "Retrieving images from "$(SrcDir)
AddSectionFilesToCopyList Files-$(AdapterFepImage) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
AddSectionFilesToCopyList Files-$(AdapterConcKey) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
else
Debug-Output "Retrieving images from "$(SrcDir)"..\images"
AddSectionFilesToCopyList Files-$(AdapterFepImage) $(SrcDir)..\images $(!STF_WINDOWSSYSPATH)\drivers
AddSectionFilesToCopyList Files-$(AdapterConcKey) $(SrcDir)..\images $(!STF_WINDOWSSYSPATH)\drivers
endif
else
Debug-Output "Retrieving images from "$(SrcDir)"..\images"
AddSectionFilesToCopyList Files-$(AdapterFepImage) $(SrcDir)..\images $(!STF_WINDOWSSYSPATH)\drivers
AddSectionFilesToCopyList Files-$(AdapterConcKey) $(SrcDir)..\images $(!STF_WINDOWSSYSPATH)\drivers
endif
ifstr $(AdapterHardwareType) == "2"
goto Upgrade-Modem-Files
endif
ifstr $(AdapterHardwareType) == "11"
goto Upgrade-Modem-Files
endif
ready_to_do_copyfiles = +
set !STF_NCPA_FLUSH_COPYLIST = TRUE
Debug-Output "CopyFilesInCopyList 4"
CopyFilesInCopyList
Exit
Upgrade-Modem-Files = +
Debug-Output "Upgrade Modem em files"
ifstr $(NTVersion) != "3.50"
ifstr $(NTVersion) != "3.51"
Debug-Output "Retrieving ModemEm files for 4.00 or above"
AddSectionFilesToCopyList Files-ModemEm $(SrcDir) $(!STF_WINDOWSPATH)\inf
endif
endif
goto ready_to_do_copyfiles
[IsCardAlreadyInstalled]
read-syms DebugOptions
read-syms GeneralConstants
Debug-Output "Entering IsCardAlreadyInstalled.."
set AlreadyExisted = "NO"
set TestBusNum = $($0)
set TestSlotNum = $($1)
set TestBusType = $($2)
set NetworkCardKeyName = $(!NTN_SoftwareBase)"\Microsoft\Windows NT\CurrentVersion\NetworkCards"
OpenRegKey $(!REG_H_LOCAL) "" $(NetworkCardKeyName) $(MAXIMUM_ALLOWED) IE_KeyNetcards
Ifstr $(IE_KeyNetcards) == $(KeyNull)
set RegistryErrorIndex = UNABLE_OPEN_NETWORKCARD_SECTION
goto IE_Return
endif
EnumRegKey $(IE_KeyNetcards) IE_KeyNameList
ForListDo $(IE_KeyNameList)
set IE_KeyName = *($($),1)
OpenRegKey $(IE_KeyNetcards) "" $(IE_KeyName) $(MAXIMUM_ALLOWED) IE_Card
Ifstr $(IE_Card) == $(KeyNull)
set RegistryErrorIndex = UNABLE_OPEN_NETWORKCARD_SECTION
goto IE_Return
endif
GetRegValue $(IE_Card), "ServiceName", ServiceNameInfo
set ServiceName = *($(ServiceNameInfo), 4)
OpenRegKey $(!REG_H_LOCAL) "" +
$(!NTN_ServiceBase)"\"$(ServiceName)"\Parameters" +
$(MAXIMUM_ALLOWED) IE_KeyService
Ifstr $(IE_KeyService) == $(KeyNull)
set RegistryErrorIndex = UNABLE_OPEN_NETWORKCARD_SECTION
goto IE_Return
endif
GetRegValue $(IE_KeyService), "BusNumber", InstalledBusInfo
GetRegValue $(IE_KeyService), "SlotNumber",InstalledSlotInfo
GetRegValue $(IE_KeyService), "BusType", InstalledBusTypeInfo
set InstalledCardBusNum = *($(InstalledBusInfo), 4)
set InstalledCardSlotNum = *($(InstalledSlotInfo), 4)
set InstalledCardBusTypeNum = *($(InstalledBusTypeInfo), 4)
ifint $(InstalledCardBusTypeNum) == $(TestBusType)
ifint $(InstalledCardBusNum) == $(TestBusNum)
ifint $(InstalledCardSlotNum) == $(TestSlotNum)
set AlreadyExisted = "YES"
endif
endif
endif
EndForListDo
IE_Return = +
return $(RegistryErrorIndex) $(AlreadyExisted)
[Signature]
FileType = MICROSOFT_FILE
[GetSignature]
read-syms Signature
return $(FileType)
[Source Media Descriptions]
1 = "Digi Int'l Windows NT Async Driver"
2 = "Digi Int'l Windows NT Async Driver"
[Files-Inf]
2, oemsetup.inf, SIZE=1000, RENAME=OEMNADDS.INF
[Files-UpgradeInf]
1,oemsetup.inf, SIZE=1000, RENAME=$(!UG_Filename)
[Files-Resource]
1,dgconfig.dll, SIZE=330000
1,dgconfig.hlp, SIZE=32000
1,dgconfig.cnt, SIZE=1700
1,fepctrs.dll, SIZE=39476
1,fepctrs.ini, SIZE=2708
1,fepctrnm.h, SIZE=2048
[Files-DigiFEP5]
1, digifep5.sys, SIZE=114176
[Files-ntxall]
1, ntxall.sys, SIZE=37376
[Files-ntxem]
1, ntxem.sys, SIZE=69632
[Files-ntcx]
1, ntcx.sys, SIZE=108032
[Files-ntepc]
1, ntepc.sys, SIZE=108032
[Files-dgapci]
1, dgapci.sys, SIZE=69632
[Files-xacook.bin]
1, xacook.bin, SIZE=6144
1, xabios.bin, SIZE=2048
[Files-sxfep.bin]
1, sxfep.bin, SIZE=24064
1, sxbios.bin, SIZE=32768
[Files-xrfep.bin]
1, xrfep.bin, SIZE=24064
1, xrbios.bin, SIZE=32768
[Files-cxfep.bin]
1, cxfep.bin, SIZE=12032
1, cxbios.bin, SIZE=2048
[Files-fxfep.bin]
1, fxfep.bin, SIZE=35328
1, fxbios.bin, SIZE=25600
[Files-pcifep.bin]
1, pcifep.bin, SIZE=24064
1, pcibios.bin, SIZE=32768
[Files-cxpfep.bin]
1, cxpfep.bin, SIZE=24064
1, cxpbios.bin, SIZE=32768
[Files-conc-epc]
1, mbcon.bin, SIZE=94400
1, fxcon.bin, SIZE=51000
1, cxcon.bin, SIZE=20000
[Files-conc-cx]
1, fxcon.bin, SIZE=51000
1, cxcon.bin, SIZE=20000
1, ibmcxcon.bin, SIZE=20000
[Files-conc-not-used]
[Files-ModemEm]
1, mdmdigi.inf, SIZE=24000
[OptionsTextISAENG]
DigiISA2e = "Digi AccelePort 2e EIA-232 ISA"
DigiISA4e = "Digi AccelePort 4e EIA-232/422 ISA"
DigiISA8e = "Digi AccelePort 8e EIA-232/422 ISA"
DigiISACX = "Digi AccelePort C/X ISA"
DigiISAXem = "Digi AccelePort Xem ISA"
[OptionsTextPCIENG]
DigiPCICX = "Digi AccelePort C/X PCI"
DigiPCIEPC = "Digi AccelePort EPC/X PCI"
DigiPCIXem = "Digi AccelePort Xem PCI"
DigiPCI4r422 = "Digi AccelePort 4r EIA-422 PCI"
DigiPCI8r422 = "Digi AccelePort 8r EIA-422 PCI"
DigiPCI2r920 = "Digi AccelePort 2r 920 PCI"
DigiPCI4r920 = "Digi AccelePort 4r 920 PCI"
DigiPCI8r920 = "Digi AccelePort 8r 920 PCI"
[FileConstantsENG]
ProCaption = $(ManufacturerDisplayName)" "$(AdapterTitle)" Adapter Setup"
ProCancel = "Cance&l"
ProCancelMsg = $(ManufacturerDisplayName)" Adapters and/or Drivers are not correctly installed. "+
"Are you sure you want to cancel copying files?"
ProCancelCap = $(ProCaption)
ProText1 = "Copying:"
ProText2 = "To:"
Error = "Unable to determine proper source disk location; copy cannot be performed."
CANNOT_FIND_ANY_CARD = "Network card is not present in the system"
UNABLE_OPEN_NETWORKCARD_SECTION = "Unable to open NetworkCards subkey in Registry"
UNABLE_COPY_FILE = "File copy operation failed."
DigiAsyncCancelInstall = "Installation of adapter software has been canceled."
ShouldUpgrade = "A older version of this driver is already installed. "+
"Press the Update button in the Control Panel and enter the path to "+
"this INF."
NewerInstalled = "A newer version of this driver is already installed."
AlreadyUpgraded = "Software has already been upgraded to the latest version."
UpgradeNotPossible = "Unable to determine current adapter option; upgrade cannot be performed."
FunctionTitle = $(ProCaption)
ProductSoftwareDescription = $(ManufacturerDisplayName)" FEP 5 Adapter Driver"
ProductSoftwareDescriptionHdwDriver = $(ManufacturerDisplayName)" "$(AdapterTitle)" Miniport Driver"
ProductSoftwareTitle = $(ManufacturerDisplayName)" FEP 5 Driver"
ProductSoftwareTitleHdwDriver = $(ManufacturerDisplayName)" "$(AdapterTitle)" Miniport Driver"
ConfigurationTitle = $(ProCaption)
IRQDisableLabel = "Disabled"
ProductHardwareDescription = $(ManufacturerDisplayName)" "$(AdapterTitle)" Adapter"
ProductHardwareTitle = $(ManufacturerDisplayName)" "$(AdapterTitle)" Adapter"
[DialogConstantsENG]
Help = "&Help"
Exit = "E&xit"
OK = "OK"
HelpContext = ""
Continue = "C&ontinue"
Cancel = "C&ancel"
[UpdatingConfigurationENG]
UpdatingConfiguration = "Updating new configuration..."
[AbortMessageENG]
AbortText = "Aborting "$(ManufacturerDisplayName)" Setup. Please reboot the system "+
"to fix the problem."
[NonfatalDlgENG]
STF_MB_TITLE = "Setup Message"
DlgType = "MessageBox"
STF_MB_TEXT = $(DlgText)
STF_MB_TYPE = 1
STF_MB_ICON = 5
STF_MB_DEF = 1
[ProductType]
STF_PRODUCT = Winnt
STF_PLATFORM = i386
Download Driver Pack
After your driver has been downloaded, follow these simple steps to install it.
Expand the archive file (if the download file is in zip or rar format).
If the expanded file has an .exe extension, double click it and follow the installation instructions.
Otherwise, open Device Manager by right-clicking the Start menu and selecting Device Manager.
Find the device and model you want to update in the device list.
Double-click on it to open the Properties dialog box.
From the Properties dialog box, select the Driver tab.
Click the Update Driver button, then follow the instructions.
Very important: You must reboot your system to ensure that any driver updates have taken effect.
For more help, visit our Driver Support section for step-by-step videos on how to install drivers for every file type.