home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 9 / 09.iso / d / d423_liu / 8.ddi / OEMNADIN.IN_ / OEMNADIN.IN
Encoding:
INI File  |  1993-07-24  |  32.6 KB  |  832 lines

  1. [Identification]
  2.     OptionType = NetAdapter
  3. [PlatformsSupported]
  4.     ISA
  5.     EISA
  6.     "Jazz-Internal Bus"
  7. [Options]
  8.     EE16
  9. [FileConstants]
  10. AllowEarly = 0
  11. UtilityInf      = "UTILITY.INF"
  12. ParamInf        = "NCPARAM.INF"
  13. subroutineinf   = "SUBROUTN.INF"
  14. SoftwareType    = "driver"
  15. Exit_Code       = 0
  16. NetEventDLL     = "%SystemRoot%\System32\netevent.dll"
  17. IoLogMsgDLL     = "%SystemRoot%\System32\IoLogMsg.dll"
  18. Manufacturer    = "Microsoft"
  19. ProductMajorVersion     = "3"
  20. ProductMinorVersion     = "1"
  21. ProductVersion  = $(ProductMajorVersion)"."$(ProductMinorVersion)
  22. ProductSoftwareName     = "EE16"
  23. ProductSoftwareImagePath = "\SystemRoot\System32\drivers\ee16.sys"
  24. NetRuleSoftwareType     = "ee16Sys ndisDriver ee16Driver"
  25. NetRuleSoftwareUse      = $(SoftwareType)
  26. NetRuleSoftwareBindForm = """Ee16Sys"" yes no container"
  27. NetRuleSoftwareClass    = {"ee16Driver basic"}
  28. NetRuleSoftwareBindable = {"ee16Driver ee16Adapter non exclusive 100"} 
  29. ProductHardwareName     = "EE16"
  30. NetRuleHardwareType     = "ee16 ee16Adapter"
  31. NetRuleHardwareBindForm = " yes yes container"
  32. NetRuleHardwareClass    = {"ee16Adapter basic"}
  33. ProductKeyName  = $(!NTN_SoftwareBase)"\"$(Manufacturer)"\"$(ProductSoftwareName)"\CurrentVersion"
  34. ParamKeyName    = $(!NTN_ServiceBase)"\"$(ProductHardwareName)"\Parameters"
  35. [GeneralConstants]
  36. from      = ""
  37. to        = ""
  38. ExitCodeOk     = 0
  39. ExitCodeCancel = 1
  40. ExitCodeFatal  = 2
  41. KeyNull         = ""
  42. MAXIMUM_ALLOWED   = 33554432
  43. RegistryErrorIndex = NO_ERROR
  44. KeyProduct      = ""
  45. KeyParameters   = ""
  46. TRUE            = 1
  47. FALSE           = 0
  48. NoTitle         = 0
  49. ExitState   = "Active"
  50. OldVersionExisted = $(FALSE)
  51. DriverPath      = $(!STF_NTPATH)\drivers
  52. [date]
  53.     Now = {} ? $(!LIBHANDLE) GetSystemDate
  54. [Identify]
  55.     read-syms Identification
  56.     set Status     = STATUS_SUCCESSFUL
  57.     set Identifier = $(OptionType)
  58.     set Media      = #("Source Media Descriptions", 1, 1)
  59.     Return $(Status) $(Identifier) $(Media)
  60. [ReturnOptions]
  61.     set Status        = STATUS_FAILED
  62.     set OptionList     = {}
  63.     set OptionTextList = {}
  64.     set LanguageList = ^(LanguagesSupported, 1)
  65.     Ifcontains(i) $($0) in $(LanguageList)
  66.         ifstr(i) $($1) == ""
  67.            goto returnoptions
  68.         endif
  69.         set PlatformList = ^(PlatformsSupported, 1)
  70.         Ifcontains(i) $($1) in $(PlatformList)
  71.            goto returnoptions
  72.         else
  73.            set Status = STATUS_NOTSUPPORTED
  74.            goto finish_ReturnOptions
  75.         endif
  76.     else
  77.         set Status = STATUS_NOLANGUAGE
  78.         goto finish_ReturnOptions
  79.     endif
  80. returnoptions = +
  81.     set OptionList     = ^(Options, 1)
  82.     set OptionTextList = ^(OptionsText$($0), 1)
  83.     set Status         = STATUS_SUCCESSFUL
  84. finish_ReturnOptions = +
  85.     Return $(Status) $(OptionList) $(OptionTextList)
  86. [InstallOption]
  87.     set Option   = $($1)
  88.     set SrcDir   = $($2)
  89.     set AddCopy  = $($3)
  90.     set DoCopy   = $($4)
  91.     set DoConfig = $($5)
  92.     set LanguageList = ^(LanguagesSupported, 1)
  93.     Ifcontains(i) $($0) NOT-IN $(LanguageList)
  94.         Return STATUS_NOLANGUAGE
  95.     endif
  96.     set-subst LF = "\n"
  97.     read-syms GeneralConstants
  98.     read-syms FileConstants
  99.     read-syms DialogConstants$(!STF_LANGUAGE)
  100.     ifstr(i) $(!NTN_Origination) == "NCPA"
  101.         set Continue = $(OK)
  102.     endif
  103.     read-syms FileConstants$(!STF_LANGUAGE)
  104.     detect date
  105.     set-title  $(FunctionTitle)
  106.     set to   = Begin
  107.     set from = Begin
  108.     set CommonStatus = STATUS_SUCCESSFUL
  109.     EndWait
  110. Begin = +
  111.     set ActivateDetection = FALSE
  112.     Ifstr(i) $(!NTN_InstallMode) == deinstall
  113.                 set StartLabel = removeadapter
  114.         else-Ifstr(i) $(!NTN_InstallMode) == Update
  115.                         set StartLabel = UpgradeSoftware
  116.         else-Ifstr(i) $(!NTN_InstallMode) == bind
  117.                 set StartLabel = bindingadapter
  118.         else-Ifstr(i) $(!NTN_InstallMode) == configure
  119.                 set CommonStatus = STATUS_REBOOT
  120.                 set ActivateDetection = TRUE
  121.                 set StartLabel = configureadapter
  122.                 Ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  123.                         Shell $(UtilityInf),RegistryErrorString,CANNOT_CONFIGURE_SOFTWARE
  124.                         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  125.                                 Debug-Output "ShellCode error: cannot get an error string."
  126.                                 goto ShellCodeError
  127.                         endif
  128.                         set Error = $($R0)
  129.                         set from = end
  130.                         set to = end
  131.                         goto nonfatalinfo
  132.                 endif
  133.     else
  134.                 set StartLabel = installadapter
  135.                 set OEM_ABANDON_OPTIONS = {}
  136.                 set OEM_ABANDON_SOFTWARE = FALSE
  137.                 set OEM_ABANDON_ON = TRUE
  138.                 set ActivateDetection = TRUE
  139.     endif
  140.     Debug-Output "OEMNADIN.INF: =================================================="
  141.     Debug-Output "OEMNADIN.INF: STF_CWDIR is: "$(!STF_CWDIR)
  142.     Debug-Output "OEMNADIN.INF: STF_LANGUAGE is: "$(!STF_LANGUAGE)
  143.     Debug-Output "OEMNADIN.INF: Option is: "$(Option)
  144.     Debug-Output "OEMNADIN.INF: !STF_NCDETECT  is: "$(!STF_NCDETECT)
  145.     Debug-Output "OEMNADIN.INF: !STF_NCOPTION  is: "$(!STF_NCOPTION)
  146.     Debug-Output "OEMNADIN.INF: !STF_NCDETCARD is: "$(!STF_NCDETCARD)
  147.     Debug-Output "OEMNADIN.INF: !STF_NCDETINFO is: "$(!STF_NCDETINFO)
  148.     Debug-Output "OEMNADIN.INF: =================================================="
  149.     Set DetectedCard = FALSE
  150.     Ifstr(i) $(ActivateDetection) != TRUE
  151.         Goto skipdetection
  152.     Endif
  153.     Set TypeList = {{IRQ,IRQList,IRQValue},+
  154.                     {IOADDR, IOBaseAddrDecList, IOBaseAddrValue},+
  155.                     {IOCHANNELREADY, IOReadyList_ignore, IOReady},+
  156.                     {TRANSCEIVER, TransceiverList_ignore, Transceiver}+
  157.                     }
  158.     Debug-Output "OEMNADIN.INF: Calling Param_BuildTypeLists"
  159.     Shell $(ParamInf) Param_BuildTypeLists $(Option) $(TypeList)
  160.     Set Status = $($R0)
  161.     ifstr(i) $(Status) != STATUS_SUCCESSFUL
  162.         Goto fataldetect
  163.     Endif
  164.     Debug-Output "OEMNADIN.INF: Calling Param_SetDefaults"
  165.     Shell $(ParamInf) Param_SetDefaults {}
  166.     set IOReady = 2
  167.     set Transceiver = 2
  168.     Shell $(ParamInf) HexListFromDecList $(IOBaseAddrDecList)
  169.     Set IOBaseAddrHexList = $($R0)
  170.     Shell $(UtilityInf) SortList $(IRQList) TRUE FALSE
  171.     Set IRQList = $($R0)
  172.     Ifstr(i) $(!STF_NCDETECT) == YES
  173.         Ifstr(i) $(!STF_NCOPTION) == $(Option)
  174.            Set DetectedCard = TRUE
  175.            Debug-Output "OEMNADIN.INF: Setting DetectedCard to TRUE"
  176.         Endif
  177.     Endif
  178. skipdetection =+
  179.     set from = $(fatal)
  180.     set to = $(fatal)
  181.     goto $(StartLabel)
  182. installadapter = +
  183.     OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
  184.     Ifstr $(KeyProduct) != $(KeyNull)
  185.         CloseRegKey $(KeyProduct)
  186.         ifstr(i) !(NTN_RegBase) == $(ProductKeyName)
  187.            Shell $(UtilityInf), VerExistedDlg, $(ProductSoftwareTitle),+
  188.                $(ProductVersion)
  189.            ifint $($ShellCode) != $(!SHELL_CODE_OK)
  190.                Debug-Output "ShellCode error: cannot get an error string."
  191.                goto ShellCodeError
  192.            endif
  193.            goto end
  194.         else
  195.            Shell $(UtilityInf), CardExistedDlg
  196.            ifint $($ShellCode) != $(!SHELL_CODE_OK)
  197.                Debug-Output "ShellCode error: cannot get an error string."
  198.                goto ShellCodeError
  199.            endif
  200.            ifstr(i) $($R1) != "OK"
  201.                set CommonStatus = STATUS_USERCANCEL
  202.                goto end
  203.            endif
  204.            set OldVersionExisted = $(TRUE)
  205.         endif
  206.     endif
  207.     Ifstr(i) $(DetectedCard) != TRUE
  208.         Goto adaptersetup
  209.     Endif
  210.     StartWait
  211.     Shell $(ParamInf) Param_QueryCard $(!STF_NCDETCARD)
  212.     EndWait
  213.     Ifstr(i) $($R0) != STATUS_SUCCESSFUL
  214.         Goto adaptersetup
  215.     Endif
  216.     Set DetectedParams = $($R1)
  217.     Debug-Output "OEMNADIN.INF: Calling Param_SetDefaults to merge detected params"
  218.     Shell $(ParamInf) Param_SetDefaults $(DetectedParams)
  219.     goto adapteroptions
  220. configureadapter = +
  221.     Ifstr $(KeyProduct) == $(KeyNull)
  222.         OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MAXIMUM_ALLOWED) KeyProduct
  223.         Ifstr $(KeyProduct) == $(KeyNull)
  224.             set RegistryErrorIndex = CANNOT_FIND_COMPONENT_SERVICE
  225.             Debug-Output "Cannot find component product key"
  226.             goto fatalregistry
  227.         Endif
  228.     Endif
  229.     Debug-Output "INF: Shelling to FindService"
  230.     Shell $(UtilityInf) FindService, $(KeyProduct)
  231.     Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  232.         Debug-Output "INF: FindService shell failure"
  233.         Goto ShellCodeError
  234.     Endif
  235.     Ifstr(i) $($R0) != NO_ERROR
  236.         Debug-Output "INF: FindService Shell error: "$($R0)
  237.         Goto fatalregistry
  238.     endif
  239.     set KeyParameters = $($R2)
  240.     CloseRegKey $($R1)
  241.     Ifstr $(KeyParameters) == $(KeyNull)
  242.         set RegistryErrorIndex = CANNOT_FIND_COMPONENT_SERVICE
  243.         Debug-Output "Cannot find component service"
  244.         goto fatalregistry
  245.     endif
  246.     set OldVersionExisted = $(TRUE)
  247.     set ValueName = ""
  248.     set ValueData = ""
  249.     set ValueStr  = ""
  250.     set ValueList = {}
  251.     EnumRegValue $(KeyParameters) ValueList
  252.     ForListDo $(ValueList)
  253.         set ValueItem = $($)
  254.         set ValueName = *($(ValueItem),1)
  255.         set ValueData = *($(ValueItem),4)
  256.         Ifstr(i) $(ValueName) == "InterruptNumber"
  257.             set IRQValue = $(ValueData)
  258.         else-ifstr(i) $(ValueName) == "IoBaseAddress"
  259.             set IOBaseAddrValue = $(ValueData)
  260.         else-ifstr(i) $(ValueName) == "IoChannelReady"
  261.             set IOReady = $(ValueData)
  262.         else-ifstr(i) $(ValueName) == "Transceiver"
  263.             set Transceiver = $(ValueData)
  264.         endif
  265.     EndForListDo
  266.     ifstr(i) $(IRQValue) == ""
  267.         set IRQValue = *($(IRQList), 2)
  268.     endif
  269.     ifstr(i) $(IOBaseAddrValue) == ""
  270.         set IOBaseAddrValue = *($(IOBaseAddrDecList), 1)
  271.     endif
  272. adaptersetup =+
  273.     Shell $(ParamInf) Param_ParameterConfidence
  274.     Ifstr(i) $($R0) != STATUS_SUCCESSFUL
  275.         Debug-Output "OEMNADE2.INF: parameter confidence too low to bypass configuration"
  276.         Goto adapteroptions
  277.     Endif
  278.     Ifstr(i) $(DetectedCard) == TRUE
  279.         Ifstr(i) $(!STF_INSTALL_MODE) != CUSTOM
  280.             Goto adapterverify
  281.         Endif
  282.     Endif
  283.     goto adapteroptions
  284. adapteroptions = +
  285.     Ifint $(IOReady) == 1
  286.         Set AllowEarly = 1
  287.     Endif
  288.     set from = adapteroptions
  289.     set IOBaseAddress = *($(IOBaseAddrHexList), ~($(IOBaseAddrDecList),+
  290.         $(IOBaseAddrValue)))
  291.     set IOReadyValue = *($(IOReadyList), $(IOReady))
  292.     set TransceiverValue = *($(TransceiverList), $(Transceiver))
  293.     Ifint $(AllowEarly) == 0
  294.        Set IOReadyListDisplay = $(IOReadyListShort)
  295.     Else
  296.        Set IOReadyListDisplay = $(IOReadyList)
  297.     Endif
  298.     read-syms FileDependentDlg$(!STF_LANGUAGE)
  299.     ui start "InputDlg"
  300.     ifstr(i) $(DLGEVENT) == "CONTINUE"
  301.                 set IRQValue = $(Combo1Out)
  302.                 set IOBaseAddress = $(Combo2Out)
  303.                 set IOReady = ~($(IOReadyList),$(Combo3Out))
  304.                 set Transceiver = ~($(TransceiverList),$(Combo4Out))
  305.                 Ifint $(IOReady) == 1
  306.                     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "WARNING", $(EarlyWarning)
  307.                     Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  308.                          goto ShellCodeError
  309.                     Endif
  310.                     Ifstr(i) $($R1) == "CANCEL"
  311.                          goto adapteroptions
  312.                     Endif
  313.                 Endif
  314.                 ui pop 1
  315.     else-ifstr(i) $(DLGEVENT) == "BACK"
  316.                 set CommonStatus = STATUS_USERCANCEL
  317.                 Debug-Output "Action: exit. Bye."
  318.                 ui pop 1
  319.                 goto end
  320.     else
  321.                 ui pop 1
  322.                 Debug-Output "Action: unknown. Bye."
  323.                 goto end
  324.     endif
  325.     set IOBaseAddrValue = *($(IOBaseAddrDecList), ~($(IOBaseAddrHexList),+
  326.         $(IOBaseAddress)))
  327. adapterverify =+
  328.     Ifstr(i) $(DetectedCard) != TRUE
  329.         Goto skipoptions
  330.     Endif
  331.     Debug-Output "OEMNADIN.INF: Calling Param_VerifyCard"
  332.     Shell $(ParamInf) Param_VerifyCard $(!STF_NCDETCARD)
  333.     Ifstr(i) $($R0) == STATUS_SUCCESSFUL
  334.         Debug-Output "OEMNADIN.INF: Param_VerifyCard succeeded"
  335.         Goto skipoptions
  336.     Endif
  337.     Set from = adapteroptions
  338.     Set to = skipoptions
  339.     Shell $(UtilityInf),RegistryErrorString,VERIFY_WARNING
  340.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  341.         Debug-Output "ShellCode error: cannot get an error string."
  342.         goto ShellCodeError
  343.     endif
  344.     set Error = $($R0)
  345.     Goto Warning
  346. skipoptions =+
  347.     ifint $(OldVersionExisted) == $(TRUE)
  348.                 ifstr(i) $(!NTN_InstallMode) == configure
  349.                         goto writeparameters
  350.                 endif
  351.     endif
  352.     StartWait
  353.     ifint $(OldVersionExisted) == $(FALSE)
  354.         ifstr(i) $(!NTN_InstallMode) == "install"
  355.             Ifstr(i) $(DoCopy) == "YES"
  356.                 Shell $(UtilityInf), DoAskSource, $(!STF_CWDDIR), $(SrcDir) YES
  357.                 Ifint $($ShellCode) != $(!SHELL_CODE_OK)
  358.                     Goto ShellCodeError
  359.                 Else-Ifstr(i) $($R0) == STATUS_FAILED
  360.                     Shell $(UtilityInf) RegistryErrorString "ASK_SOURCE_FAIL"
  361.                     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  362.                        goto ShellCodeError
  363.                     endif
  364.                     set Error = $($R0)
  365.                     Goto fatal
  366.                 Else-Ifstr(i) $($R0) == STATUS_USERCANCEL
  367.                     Goto successful
  368.                 Endif
  369.                 Set SrcDir = $($R1)
  370.             Endif
  371.             install "Install-Option"
  372.             ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
  373.                 Shell $(UtilityInf) RegistryErrorString "UNABLE_COPY_FILE"
  374.                 ifint $($ShellCode) != $(!SHELL_CODE_OK)
  375.                     goto ShellCodeError
  376.                 endif
  377.                 set Error = $($R0)
  378.                 goto fatal
  379.             endif
  380.         endif
  381.         Shell $(UtilityInf), AddSoftwareComponent, $(Manufacturer), +
  382.                 $(ProductSoftwareName), +
  383.                 $(ProductSoftwareName), +
  384.                 $(ProductSoftwareTitle), $(STF_CONTEXTINFNAME), +
  385.                 $(ProductSoftwareImagePath), "kernel", "NDIS", {}, "",+
  386.                 $(NetEventDLL)
  387.         Set OEM_ABANDON_SOFTWARE = TRUE
  388.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  389.                 Debug-Output "ShellCode error"
  390.                 goto ShellCodeError
  391.         endif
  392.         set RegistryErrorIndex = $($R0)
  393.         set KeyProduct      = $($R1)
  394.         Set SoftNetRulesKey = $($R2)
  395.         CloseRegKey $($R3)
  396.         CloseRegKey $($R4)
  397.         CloseRegKey $($R5)
  398.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  399.                 EndWait
  400.                 Debug-Output "Registry error: add software components"
  401.                 CloseRegKey $(KeyProduct)
  402.                 CloseRegKey $(SoftNetRulesKey)
  403.                 goto fatalregistry
  404.         endif
  405.         set NewValueList = {{SoftwareType,$(NoTitle),$(!REG_VT_SZ),$(SoftwareType)},+
  406.                            {MajorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMajorVersion)},+
  407.                            {MinorVersion,$(NoTitle),$(!REG_VT_DWORD),$(ProductMinorVersion)},+
  408.                            {Title,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareTitle)},+
  409.                            {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareDescription)},+
  410.                            {ServiceName,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareName)},+
  411.                            {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
  412.         Shell  $(UtilityInf), AddValueList, $(KeyProduct), $(NewValueList)
  413.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  414.                 Debug-Output "ShellCode error."
  415.                 goto ShellCodeError
  416.         endif
  417.         set RegistryErrorIndex = $($R0)
  418.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  419.                 EndWait
  420.                 Debug-Output "Registry error: add value list."
  421.                 CloseRegKey $(KeyProduct)
  422.                 CloseRegKey $(SoftNetRulesKey)
  423.                 goto fatalregistry
  424.         endif
  425.         set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareType)},+
  426.                                 {use,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareUse)}, +
  427.                                 {bindform,$(NoTitle),$(!REG_VT_SZ),$(NetRuleSoftwareBindForm)}, +
  428.                                 {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareClass)}, +
  429.                                 {bindable,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleSoftwareBindable)}, +
  430.                                 {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
  431.         Shell  $(UtilityInf), AddValueList, $(SoftNetRulesKey), $(NewValueList)
  432.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  433.                 Debug-Output "ShellCode error."
  434.                 goto ShellCodeError
  435.         endif
  436.         set RegistryErrorIndex = $($R0)
  437.         CloseRegKey $(KeyProduct)
  438.         CloseRegKey $(SoftNetRulesKey)
  439.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  440.                 EndWait
  441.                 Debug-Output "Resgitry error: add value list."
  442.                 goto fatalregistry
  443.         endif
  444.     endif
  445.     Shell $(UtilityInf), AddHardwareComponent, $(ProductHardwareName),$(STF_CONTEXTINFNAME),$(ProductKeyName)
  446.     ifint $($R4) != -1
  447.                 Set OEM_ABANDON_OPTIONS = >($(OEM_ABANDON_OPTIONS), $(!NTN_SoftwareBase)"\Microsoft\Windows NT\CurrentVersion\NetworkCards\"$($R4))
  448.     endif
  449.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  450.                 Debug-Output "Cannot add hardware component"
  451.                 goto ShellCodeError
  452.     endif
  453.     set RegistryErrorIndex = $($R0)
  454.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  455.                 EndWait
  456.                 Debug-Output "Registry error: add hardware component"
  457.                 CloseRegKey $($R1)
  458.                 CloseRegKey $($R2)
  459.                 CloseRegKey $($R3)
  460.                 goto fatalregistry
  461.     endif
  462.     set KeyParameters = $($R3)
  463.     set KeyAdapterRules = $($R2)
  464.     set AdapterNumber = $($R4)
  465.     set NewValueList = {{Manufacturer,$(NoTitle),$(!REG_VT_SZ),$(Manufacturer)},+
  466.                        {Title,$(NoTitle),$(!REG_VT_SZ),"["$($R4)"] "$(ProductHardwareTitle)},+
  467.                        {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareDescription)},+
  468.                        {ProductName,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareName)},+
  469.                        {ServiceName,$(NoTitle),$(!REG_VT_SZ),$($R5)},+
  470.                        {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}
  471.     Shell  $(UtilityInf), AddValueList, $($R1), $(NewValueList)
  472.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  473.                 Debug-Output "ShellCode error"
  474.                 goto ShellCodeError
  475.     endif
  476.     CloseRegKey $($R1)
  477.     set TempProdName = """"$(ProductHardwareName)$(AdapterNumber)""""
  478.     set TempBindForm = $(TempProdName)$(NetRuleHardwareBindForm)
  479.     set NewValueList = {{type,$(NoTitle),$(!REG_VT_SZ),$(NetRuleHardwareType)},+
  480.                         {bindform,$(NoTitle),$(!REG_VT_SZ),$(TempBindForm)}, +
  481.                         {class,$(NoTitle),$(!REG_VT_MULTI_SZ),$(NetRuleHardwareClass)}, +
  482.                         {InfOption,$(NoTitle),$(!REG_VT_SZ),$(Option)}}
  483.     Shell  $(UtilityInf), AddValueList, $(KeyAdapterRules), $(NewValueList)
  484.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  485.                 Debug-Output "ShellCode error."
  486.                 goto ShellCodeError
  487.     endif
  488.     set RegistryErrorIndex = $($R0)
  489.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  490.                 EndWait
  491.                 Debug-Output "Resgitry error: add value list."
  492.                 CloseRegKey $(KeyParameters)
  493.                 CloseRegKey $(KeyAdapterRules)
  494.                 goto fatalregistry
  495.     endif
  496.     CloseRegKey $(KeyAdapterRules)
  497.     goto writeparameters
  498. writeparameters = +
  499.     Shell $(UtilityInf), GetBusTypeNum
  500.     set BusTypeNum = $($R1)
  501.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  502.         Debug-Output "ShellCode error."
  503.         goto ShellCodeError
  504.     endif
  505.     set NewValueList = {{InterruptNumber,$(NoTitle),$(!REG_VT_DWORD),$(IRQValue)},+
  506.                        {BusType,$(NoTitle),$(!REG_VT_DWORD),$(BusTypeNum)},+
  507.                        {MediaType,$(NoTitle),$(!REG_VT_DWORD),1},+
  508.                        {IoChannelReady,$(NoTitle),$(!REG_VT_DWORD),$(IOReady)},+
  509.                        {Transceiver,$(NoTitle),$(!REG_VT_DWORD),$(Transceiver)},+
  510.                        {IoBaseAddress,$(NoTitle),$(!REG_VT_DWORD),$(IOBaseAddrValue)}}
  511.     Shell  $(UtilityInf), AddValueList, $(KeyParameters), $(NewValueList)
  512.     CloseRegKey $(KeyParameters)
  513.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  514.                 Debug-Output "ShellCode error."
  515.                 goto ShellCodeError
  516.     endif
  517.     set RegistryErrorIndex = $($R0)
  518.     Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  519.                 Debug-Output "Registry error: Add value list"
  520.                 goto fatalregistry
  521.     endif
  522.     EndWait
  523.     goto successful
  524. bindingadapter =+
  525.     set Error = "Binding: Sorry, not yet implemented."
  526.     goto fatal
  527. removeadapter = +
  528.     Ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  529.         Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
  530.                         $(ProductSoftwareName)
  531.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  532.                         Debug-Output "ShellCode error"
  533.                         goto ShellCodeError
  534.         endif
  535.         set RegistryErrorIndex = $($R0)
  536.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  537.                         goto fatalregistry
  538.         endif
  539.     else
  540.         Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
  541.                 $(ProductSoftwareName), $(!NTN_RegBase)
  542.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  543.                         Debug-Output "ShellCode error"
  544.                         goto ShellCodeError
  545.         endif
  546.         set RegistryErrorIndex = $($R0)
  547.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  548.                 goto fatalregistry
  549.         endif
  550.     endif
  551.     goto end
  552. UpgradeSoftware = +
  553.     ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
  554.         OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MAXIMUM_ALLOWED) KeyProduct
  555.         Ifstr $(KeyProduct) != $(KeyNull)
  556.             GetRegValue $(KeyProduct),"MajorVersion", VersionInfo
  557.             set Version = *($(VersionInfo), 4)
  558.             Shell $(UtilityInf), GetInfFileNameFromRegistry, $(KeyProduct)
  559.             ifint $($ShellCode) != $(!SHELL_CODE_OK)
  560.                 Debug-Output "ShellCode error"
  561.                 goto ShellCodeError
  562.             endif
  563.             set !UG_Filename = $($R0)
  564.             ifstr(i) $(!UG_Filename) != ""
  565.                 install "Install-Update"
  566.                 ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
  567.                     goto fatal
  568.                 endif
  569.             endif
  570.             SetRegValue $(KeyProduct) {MajorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMajorVersion)}
  571.             SetRegValue $(KeyProduct) {MinorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMinorVersion)}
  572.             ifint $(Version) != $(ProductVersion)
  573.             endif
  574.             CloseRegKey $(KeyProduct)
  575.         else
  576.             goto fatalregistry
  577.         endif
  578.     else
  579.         OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) +
  580.               $(MAXIMUM_ALLOWED) NetworkCardKey
  581.         Ifstr(i) $(NetworkCardKey) != $(KeyNull)
  582.             GetRegValue $(NetworkCardKey),"ServiceName", ServiceNameInfo
  583.             set ServiceName = *($(ServiceNameInfo), 4)
  584.             OpenRegKey $(NetworkCardKey) "" "NetRules" +
  585.                 $(MAXIMUM_ALLOWED) NetRuleKey
  586.             Ifstr(i) $(NetRuleKey) != $(KeyNull)
  587.             else
  588.                 goto fatalregistry
  589.             endif
  590.             CloseRegKey $(NetRules)
  591.             CloseRegKey $(NetworkCardKey)
  592.         else
  593.             goto fatalregistry
  594.         endif
  595.         OpenRegKey $(!REG_H_LOCAL) "" +
  596.               $(!NTN_ServiceBase)"\"$(ServiceName) +
  597.               $(MAXIMUM_ALLOWED) ServiceKey
  598.         Ifstr(i) $(ServiceKey) != $(KeyNull)
  599.             CloseRegKey $(ServiceKey)
  600.         else
  601.             goto fatalregistry
  602.         endif
  603.     endif
  604.     goto end
  605. successful = +
  606.     goto end
  607. abandon = +
  608.     ForListDo $(OEM_ABANDON_OPTIONS)
  609.         Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
  610.             $(ProductSoftwareName), $($)
  611.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  612.             Debug-Output "ShellCode error"
  613.             goto ShellCodeError
  614.         endif
  615.         set RegistryErrorIndex = $($R0)
  616.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  617.             goto fatalregistry
  618.         endif
  619.     EndForListDo
  620.     Ifstr(i) $(OEM_ABANDON_SOFTWARE) == TRUE
  621.         Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
  622.             $(ProductSoftwareName), FALSE
  623.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  624.             Debug-Output "ShellCode error"
  625.             goto ShellCodeError
  626.         endif
  627.         set RegistryErrorIndex = $($R0)
  628.         Ifstr(i) $(RegistryErrorIndex) != NO_ERROR
  629.             goto fatalregistry
  630.         endif
  631.     endif
  632.     goto end
  633. warning = +
  634.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "WARNING", $(Error)
  635.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  636.         goto ShellCodeError
  637.     endif
  638.     ifstr(i) $($R1) == "OK"
  639.         goto $(to)
  640.     else-ifstr(i) $($R1) == "CANCEL"
  641.         goto $(from)
  642.     else
  643.         goto "end"
  644.     endif
  645. nonfatalinfo = +
  646.     Set CommonStatus = STATUS_USERCANCEL
  647.     Set Severity = STATUS
  648.     goto nonfatalmsg
  649. nonfatal = +
  650.     Set Severity = NONFATAL
  651.     goto nonfatalmsg
  652. nonfatalmsg = +
  653.     ifstr(i) $(Error) == ""
  654.         Set Severity = NONFATAL
  655.         Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
  656.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  657.             goto ShellCodeError
  658.         endif
  659.         set Error = $($R0)
  660.     endif
  661.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), $(Severity), $(Error)
  662.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  663.         goto ShellCodeError
  664.     endif
  665.     ifstr(i) $($R1) == "OK"
  666.         goto $(from)
  667.     else
  668.         goto "end"
  669.     endif
  670. fatalregistry = +
  671.     Shell $(UtilityInf) RegistryErrorString $(RegistryErrorIndex)
  672.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  673.         goto ShellCodeError
  674.     endif
  675.     set Error = $($R0)
  676.     goto fatal
  677. fataldetect = +
  678.     Shell $(UtilityInf),RegistryErrorString,CANNOT_DETECT
  679.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  680.         Debug-Output "ShellCode error: cannot get an error string."
  681.         goto ShellCodeError
  682.     endif
  683.     set Error = $($R0)
  684.     Goto fatal
  685. fatal = +
  686.     ifstr(i) $(Error) == ""
  687.         Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
  688.         ifint $($ShellCode) != $(!SHELL_CODE_OK)
  689.             goto ShellCodeError
  690.         endif
  691.         set Error = $($R0)
  692.     endif
  693.     Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "FATAL", $(Error)
  694.     ifint $($ShellCode) != $(!SHELL_CODE_OK)
  695.         goto ShellCodeError
  696.     endif
  697.     goto setfailed
  698. ShellCodeError = +
  699.     set DlgType      = "MessageBox"
  700.     set STF_MB_TITLE = $(ShellCodeErrorTitle)
  701.     set STF_MB_TEXT  = $(ShellCodeErrorText)
  702.     set STF_MB_TYPE  = 1
  703.     set STF_MB_ICON  = 3
  704.     set STF_MB_DEF   = 1
  705.     ui start "Error Message"
  706.     goto setfailed
  707. setfailed = +
  708.     set CommonStatus = STATUS_FAILED
  709.     ifstr(i) $(OEM_ABANDON_ON) == TRUE
  710.         set OEM_ABANDON_ON = FALSE
  711.         goto abandon
  712.     endif
  713.     goto end
  714. end = +
  715.     goto term
  716. term = +
  717.     Return $(CommonStatus)
  718. [Install-Option]
  719.     set STF_VITAL = ""
  720.     ifstr(i) $(AddCopy) == "YES"
  721.         AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
  722.     endif
  723.     ifstr(i) $(DoCopy) == "YES"
  724.        set !STF_NCPA_FLUSH_COPYLIST = TRUE
  725.        CopyFilesInCopyList
  726.     endif
  727.     ifstr(i) $(DoConfig) == "YES"
  728.     endif
  729.     Exit
  730. [Install-Update]
  731.    set STF_VITAL        = ""
  732.    set STF_OVERWRITE    = "VERIFYSOURCEOLDER"
  733.    AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
  734.    AddSectionFilesToCopyList Files-Inf $(SrcDir) $(!STF_WINDOWSSYSPATH)
  735.    set !STF_NCPA_FLUSH_COPYLIST = TRUE
  736.    CopyFilesInCopyList
  737.    exit
  738. [Source Media Descriptions]
  739.     1    = "Windows NT Advanced Server Setup Disk #1"   , TAGFILE = disk1
  740.     2    = "Windows NT Advanced Server Setup Disk #2"   , TAGFILE = disk2
  741.     3    = "Windows NT Advanced Server Setup Disk #3"   , TAGFILE = disk3
  742.     4    = "Windows NT Advanced Server Setup Disk #4"   , TAGFILE = disk4
  743.     5    = "Windows NT Advanced Server Setup Disk #5"   , TAGFILE = disk5
  744.     6    = "Windows NT Advanced Server Setup Disk #6"   , TAGFILE = disk6
  745.     7    = "Windows NT Advanced Server Setup Disk #7"   , TAGFILE = disk7
  746.     8    = "Windows NT Advanced Server Setup Disk #8"   , TAGFILE = disk8
  747.     9    = "Windows NT Advanced Server Setup Disk #9"   , TAGFILE = disk9
  748.     10    = "Windows NT Advanced Server Setup Disk #10"  , TAGFILE = disk10
  749.     11    = "Windows NT Advanced Server Setup Disk #11"  , TAGFILE = disk11
  750.     12    = "Windows NT Advanced Server Setup Disk #12"  , TAGFILE = disk12
  751.     13    = "Windows NT Advanced Server Setup Disk #13"  , TAGFILE = disk13
  752.     14    = "Windows NT Advanced Server Setup Disk #14"  , TAGFILE = disk14
  753.     15    = "Windows NT Advanced Server Setup Disk #15"  , TAGFILE = disk15
  754.     16    = "Windows NT Advanced Server Setup Disk #16"  , TAGFILE = disk16
  755.     17    = "Windows NT Advanced Server Setup Disk #17"  , TAGFILE = disk17
  756.     18    = "Windows NT Advanced Server Setup Disk #18"  , TAGFILE = disk18
  757.     19    = "Windows NT Advanced Server Setup Disk #19"  , TAGFILE = disk19
  758.     20    = "Windows NT Advanced Server Setup Disk #20"  , TAGFILE = disk20
  759.     21    = "Windows NT Advanced Server Setup Disk #21"  , TAGFILE = disk21
  760.     22    = "Windows NT Advanced Server Setup Disk #22"  , TAGFILE = disk22
  761.     23    = "Windows NT Advanced Server Setup Disk #23"  , TAGFILE = disk23
  762.     24    = "Windows NT Advanced Server Setup Disk #24"  , TAGFILE = disk24
  763.     25    = "Windows NT Advanced Server Setup Disk #25"  , TAGFILE = disk25
  764.     26    = "Windows NT Advanced Server Setup Disk #26"  , TAGFILE = disk26
  765.     27    = "Windows NT Advanced Server Setup Disk #27"  , TAGFILE = disk27
  766.     28    = "Windows NT Advanced Server Setup Disk #28"  , TAGFILE = disk28
  767.     29    = "Windows NT Advanced Server Setup Disk #29"  , TAGFILE = disk29
  768. [ProductType]
  769. STF_PRODUCT  = LanmanNT
  770. STF_PLATFORM = I386
  771. [Files-Inf]
  772. 2,    oemsetup.inf,     SIZE=1000,    RENAME=$(!UG_Filename)
  773. [Files-EE16]
  774. 22,EE16.SYS , SIZE=37376
  775. [LanguagesSupported]
  776.     ENG
  777. [OptionsTextENG]
  778.     EE16     = "Intel Ether Express 16 LAN Adapter"
  779. [FileConstantsENG]
  780. ProCaption   = "Windows NT Setup"
  781. ProCancel    = "Cancel"
  782. ProCancelMsg = "Windows NT Networking is not correctly installed.  "+
  783.                "Are you sure you want to cancel copying files?"
  784. ProCancelCap = "Network Setup Message"
  785. ProText1     = "Copying:"
  786. ProText2     = "To:"
  787. FunctionTitle   = "Intel Ether Express 16 LAN Adapter Setup"
  788. ProductSoftwareDescription      = "Intel Ether Express 16 LAN Adapter Driver"
  789. ProductHardwareDescription      = "Intel Ether Express 16 LAN Adapter"
  790. ProductSoftwareTitle    = "Intel Ether Express 16 LAN Adapter Driver"
  791. ProductHardwareTitle    = "Intel Ether Express 16 LAN Adapter"
  792. ShellCodeErrorTitle     = "Error: "$(FunctionTitle)
  793. ShellCodeErrorText      = "Shell Code Error."
  794. IOReadyListShort = { "Late", "Never" }
  795. IOReadyList      = { "Early", "Late", "Never" }
  796. TransceiverList  = {"Thick Net (AUI/DIX)","Thin Net (BNC/COAX)","Twisted-Pair (TPE)"}
  797. [DialogConstantsENG]
  798. Help        = "&Help"
  799. Exit        = "Cancel"
  800. OK          = "OK"
  801. HelpContext = ""
  802. Continue    = "Continue"
  803. Cancel      = "Cancel"
  804. [FileDependentDlgENG]
  805. Combo1Label = "&IRQ Level:"
  806. Combo2Label = "I/&O Port Address:"
  807. Combo3Label = "I/O &Channel Ready:"
  808. Combo4Label = "&Transceiver Type:"
  809. EarlyWarning = "Use of the Early setting may cause system failure in some machines. "+
  810.                "Are you sure you wish to continue?"
  811. DlgType = "RadioCombination"
  812. DlgTemplate = "EE_16"
  813. Caption = $(FunctionTitle)
  814. Combo1List = $(IRQList)
  815. Combo1Out  = $(IRQValue)
  816. Combo2List = $(IOBaseAddrHexList)
  817. Combo2Out  = $(IOBaseAddress)
  818. Combo3List = $(IOReadyListDisplay)
  819. Combo3Out  = $(IOReadyValue)
  820. Combo4List = $(TransceiverList)
  821. Combo4Out  = $(TransceiverValue)
  822. ComboListItemsIn  = {Combo1List, Combo2List, Combo3List, Combo4List}
  823. ComboListItemsOut = {Combo1Out, Combo2Out, Combo3Out, Combo4Out}
  824. EditTextIn = ""
  825. EditTextLim = ""
  826. CBOptionsGreyed = {}
  827. NotifyFields = {NO, NO}
  828. HelpContext = $(!IDH_DB_OEMNADIN_INS)
  829.  
  830.  
  831.  
  832.