Oemsetup.inf Driver File Contents (harm11a14.zip)

;/*++
;
;Copyright (c) 2002 Proxim, Inc., Incorporated All Rights Reserved
;
;Module Name:
;
;    Oemsetup.inf
;
;Abstract:
;    INF file for installing Proxim Wireless Network Adapter
; on Windows NT 4.0
;
;--*/

[Identification]
    OptionType = NetAdapter

[PlatformsSupported]
    ISA
    EISA
    MCA
    PCI

[Options]
    HARMONY11A 

[OptionsTextENG]
    HARMONY11A = "Harmony 802.11a Network Adapter"
 
[AllFileConstants]
GenericInfVersion       = " V1.4.1.1"
UtilityInf              = "UTILITY.INF"
ParamInf                = "NCPARAM.INF"
subroutineinf           = "SUBROUTN.INF"
SoftwareType            = "driver"
Exit_Code               = 0
NetEventDLL             = "%SystemRoot%\System32\netevent.dll"
IoLogMsgDLL             = "%SystemRoot%\System32\IoLogMsg.dll"
Manufacturer            = "Proxim, Corp."
CardName				= "802.11a Wireless CardBus Adapter."
DISABLEPCMCIASYS        = "0"			; "1"

PCIVendorID				= 5772 ;0x168c
PCIDeviceIDList			= { 7 };0x007  								
										    
[FileConstants-HARMONY11A]
GenericAdapterName      = "Harmony 802.11a Network Adapter"
GenericTitleName        = "Harmony 802.11a Network Adapter"
GenericDriverName       = "Harmony 802.11a Network Adapter" 
GenericSysName          = "PROX11AN4.SYS"
GenericName             = "PROX11AN4"
ProductMajorVersion     = "1"
ProductMinorVersion     = "2"
ProductVersion          = $(ProductMajorVersion)"."$(ProductMinorVersion)
ProductSoftwareName     = "PROX11AN4"
ProductSoftwareDesc     = "Harmony 802.11a Network Adapter" 
ProductSoftwarePath     = "\SystemRoot\System32\drivers\"$(GenericSysName)
NetRuleSoftwareType     = "prox11an4Sys ndisDriver prox11an4Driver"
NetRuleSoftwareUse      = $(SoftwareType)
NetRuleSoftwareBindForm = """prox11an4Sys"" yes no container"
NetRuleSoftwareClass    = {"prox11an4Driver basic"}
NetRuleSoftwareBindable = {"prox11an4Driver prox11an4Adapter non exclusive 100"}
ProductHardwareName     = "PROX11AN4"
ProductHardwareDesc     = "Harmony 802.11a Network Adapter"
NetRuleHardwareType     = "PROX11AN4 prox11an4Adapter"
NetRuleHardwareBindForm = " yes yes container"
NetRuleHardwareClass    = {"prox11an4Adapter basic"}

ProductKeyName          = $(!NTN_SoftwareBase)"\"$(Manufacturer)"\"$(ProductSoftwareName)"\CurrentVersion"
ParamKeyName            = $(!NTN_ServiceBase)"\"$(ProductHardwareName)"\Parameters"

VERS1Manufacturer       = "Proxim"
VERS1Product            = "Harmony 802.11a Network Adapter"  
VERS1Type               = "PROX11A"
PCMCIA                  = 0

[GeneralConstants]
From            = ""
To              = ""
ExitCodeOk      = 0
ExitCodeCancel  = 1
ExitCodeFatal   = 2
KeyNull         = ""
MaximumAllowed  = 33554432
RegistryError   = NO_ERROR
KeyProduct      = ""
KeyParameters   = ""
TRUE            = 1
FALSE           = 0
NoTitle         = 0
ExitState       = "Active"
OldVersionExist = $(FALSE)
DriverPath      = $(!STF_NTPATH)\drivers

[date]
; Now is a list which contains { Sec From 1-1-1970, Year, Month, Day, Hour,
; Minute, Second }
Now = {} ? $(!LIBHANDLE) GetSystemDate

;---------------------------------------------------------------------------
; 1. Identify
;
; DESCRIPTION:   To verify that this INF deals with the same type of options
;                as we are choosing currently.
;
; INPUT:         None
;
; OUTPUT:        $($R0): STATUS: STATUS_SUCCESSFUL
;                $($R1): Option Type (COMPUTER ...)
;                $($R2): Diskette description
;---------------------------------------------------------------------------

[Identify]
    read-syms Identification
    set Status     = STATUS_SUCCESSFUL
    set Identifier = $(OptionType)
    set Media      = #("Source Media Descriptions", 1, 1)
    Return $(Status) $(Identifier) $(Media)

;------------------------------------------------------------------------
; 2. ReturnOptions:
;
; DESCRIPTION:   To return the option list supported by this INF and the
;                localised text list representing the options.
;
;
; INPUT:         $($0):  Language used. ( ENG | FRN | ... )
;
; OUTPUT:        $($R0): STATUS: STATUS_SUCCESSFUL |
;                                STATUS_NOLANGUAGE
;                                STATUS_FAILED
;                                STATUS_NOTSUPPORTED
;                $($R1): Option List
;                $($R2): Option Text List
;------------------------------------------------------------------------

[ReturnOptions]
    set Status          = STATUS_FAILED
    set OptionList      = {}
    set OptionTextList  = {}

    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 = +
    set OptionList     = ^(Options, 1)
    set OptionTextList = ^(OptionsText$($0), 1)
    set Status         = STATUS_SUCCESSFUL

finish_ReturnOptions = +
    Return $(Status) $(OptionList) $(OptionTextList)

;------------------------------------------------------------------------
; InstallOption:
;
;      This section is shelled to by main installation processing
;      or by NCPASHEL.INF during reconfig, removal, update, etc.
;
; FUNCTION:  To copy files representing Options
;            To configure the installed option
;            To update the registry for the installed option
;
; INPUT:     $($0):  Language to use
;            $($1):  OptionID to install
;            $($2):  SourceDirectory
;            $($3):  AddCopy  (YES | NO)
;            $($4):  DoCopy   (YES | NO)
;            $($5):  DoConfig (YES | NO)
;
; OUTPUT:    $($R0): STATUS: STATUS_SUCCESSFUL |
;                            STATUS_NOLANGUAGE |
;                            STATUS_USERCANCEL |
;                            STATUS_FAILED
;------------------------------------------------------------------------

[InstallOption]

    set Status   = STATUS_FAILED

    set Option   = $($1)
    set SrcDir   = $($2)
    set AddCopy  = $($3)
    set DoCopy   = $($4)
    set DoConfig = $($5)

    Set !DebugOutputControl = 1
    Debug-Output "OEMSETUP.INF: InstallOption"

    set LanguageList = ^(LanguagesSupported, 1)
    Ifcontains(i) $($0) NOT-IN $(LanguageList)
        Return STATUS_NOLANGUAGE
    endif

    set-subst LF = "\n"
    read-syms GeneralConstants
    read-syms AllFileConstants
    read-syms FileConstants"-"$(Option)
    read-syms DialogConstants$(!STF_LANGUAGE)"-"$(Option)
    ifstr(i) $(!NTN_Origination) == "NCPA"
        set Continue = $(OK)
    endif

    read-syms AllFileConstants$(!STF_LANGUAGE)
    read-syms FileConstants$(!STF_LANGUAGE)"-"$(Option)

    detect date
    set-title  $(FunctionTitle)
    set To   = Begin
    set From = Begin
    set CommonStatus = STATUS_SUCCESSFUL
    EndWait

Begin = +
    Set ActivateDetection = FALSE

    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)
            Shell $(UtilityInf),RegistryErrorString,CANNOT_CONFIGURE_SOFTWARE
            ifint $($ShellCode) != $(!SHELL_CODE_OK)
                goto ShellCodeError
            endif
            set Error = $($R0)
            set From = end
            set To = end
            goto nonfatalinfo
        endif
    else
        set StartLabel = installadapter
        set OEM_ABANDON_OPTIONS = {}
        set OEM_ABANDON_SOFTWARE = FALSE
        set OEM_ABANDON_ON = TRUE
    endif

    ; Set the Default values

    set bssTypeValue	     = *($(bssTypeValues), 1)        ; bssType = AP (Infrastructure)
    set sleepModeValue	     = *($(sleepModeValues), 0)      ; sleepMode = Off
    set TurboEnableValue     = *($(TurboEnableValues), 1)    ; TurboEnable = Disabled
    set defaultKeyValue	     = *($(defaultKeyValues), 1)     ; defaultKey = Shared Key 1 (key0)
    set uniqKeyLengthValue   = *($(keyLengthValues), 1)		 ; uniqKeyLength = 40 bits
    set keyLength0Value	     = *($(keyLengthValues), 1)       ; keyLength0 = 40 bits
    set keyLength1Value	     = *($(keyLengthValues), 1)       ; keyLength1  = 40 bits
    set keyLength2Value	     = *($(keyLengthValues), 1)       ; keyLength2  = 40 bits
    set keyLength3Value	     = *($(keyLengthValues), 1)       ; keyLength3 = 40 bits
	set MapRegistersValue    = *($(MapRegistersValues), 4)	  ; 256
	set QoSValue			 = *($(QoSList), 1)			      ; QoS = Disabled
	set tpcValue			 = *($(tpcList), 1)			      ; tpc = Highest Power
    set SsidValue	    = ""
    set NetworkAddressValue = ""
    set uniqKeyValue	    = ""
    set key0Value	    = ""
    set key1Value	    = ""
    set key2Value           = ""
    set Key3Value 	    = ""
    set privacyInvokedValue = "0"			     ; privacyInvoked = 0 (Disabled)
	set beaconIntervalValue = "100"
	set BusNum			= 0
	set DeviceNum		= 0
	set FunctionNum		= 0

    Set From = $(fatal)
    Set To = $(fatal)
    Goto $(StartLabel)

;-----------------------------------------------
; Installation Section
;-----------------------------------------------

installadapter = +

	; PCI Support. 
	; If a device is not found, don't error out => assume it's Cardbus.

	Debug-Output "INF: Vendor ID = $(PCIVendorID)"
	Debug-Output "INF: Device ID = $(PCIDeviceIDList)"

	set AdapterList = {}

	ForListDo $(PCIDeviceIDList)

		set PCIDeviceID = $($)
		Shell $(UtilityInf), GetPCIInformation, $(PCIVendorID) $(PCIDeviceID)
		ifint $($ShellCode) != $(!SHELL_CODE_OK)
			goto ShellCodeError
		endif
		
		; append all adapters onto the adapter list
		ForListDo $($R0)
			set AdapterList = >( $(AdapterList), {*($($),1), *($($),2), *($($),3)} )
		EndForListDo

	EndForListDo

	Debug-Output "INF: Adapter List= $(AdapterList)"

	ifstr(i) $(AdapterList) != {}
		; Only support one PCI adapter 
		set BusNum		= *(*($(AdapterList),1),1)
        set DeviceNum	= *(*($(AdapterList),1),2)
        set FunctionNum = *(*($(AdapterList),1),3)
    endif

    ; Check whether the same version of the software exists
    OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MaximumAllowed) KeyProduct
    Ifstr $(KeyProduct) != $(KeyNull)
        ; Same version already existed in the local machine
        ; Popup the dialog and ask the user whether he wants to continue
        CloseRegKey $(KeyProduct)
        ifstr(i) !(NTN_RegBase) == $(ProductKeyName)
           Shell $(UtilityInf), VerExistedDlg, $(ProductSoftwareTitle),+
               $(ProductVersion)
           ifint $($ShellCode) != $(!SHELL_CODE_OK)
               Debug-Output "ShellCode error: cannot get an error string."
               goto ShellCodeError
           endif
           goto end
        else
           ; Add a new adapter card?
           Shell $(UtilityInf), CardExistedDlg
           ifint $($ShellCode) != $(!SHELL_CODE_OK)
               Debug-Output "ShellCode error: cannot get an error string."
               goto ShellCodeError
           endif
           ifstr(i) $($R1) != "OK"
               goto end
           endif
           set OldVersionExist = $(TRUE)
        endif
    endif

    ; DLL load addition
    Shell $(UtilityInf), DoAskSource, $(!STF_CWDDIR), $(SrcDir) NO
    Ifint $($ShellCode) != $(!SHELL_CODE_OK)
        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
        Goto successful
    Endif

    Set SrcDir = $($R1)

    goto adaptersetup

;-----------------------------------------------
; Configuration Section
;-----------------------------------------------

; Get the current values of all the parameters
configureadapter = +
    Ifstr $(KeyProduct) == $(KeyNull)
        OpenRegKey $(!REG_H_LOCAL) "" $(!NTN_RegBase) $(MaximumAllowed) KeyProduct
        Ifstr $(KeyProduct) == $(KeyNull)
            set RegistryError = CANNOT_FIND_COMPONENT_SERVICE
            Debug-Output "Cannot find component product key"
            goto fatalregistry
        Endif
    Endif

    ; Get the other parameters; they're attached to the service parameters key
    Debug-Output "INF: Shelling to FindService"
    Shell $(UtilityInf) FindService, $(KeyProduct)
    Ifint $($ShellCode) != $(!SHELL_CODE_OK)
        Debug-Output "INF: FindService shell failure"
        Goto ShellCodeError
    Endif
    Ifstr(i) $($R0) != NO_ERROR
        Debug-Output "INF: FindService Shell error: "$($R0)
        Goto fatalregistry
    endif

    Set KeyParameters = $($R2)
    CloseRegKey $($R1)

    Ifstr $(KeyParameters) == $(KeyNull)
        set RegistryError = CANNOT_FIND_COMPONENT_SERVICE
        Debug-Output "Cannot find component service"
        goto fatalregistry
    endif

    set OldVersionExist = $(TRUE)
    set ValueName = ""
    set ValueData = ""
    set ValueStr  = ""
    set ValueList = {}
     
    ; Get the old values from the Registry [Get Values]
    EnumRegValue $(KeyParameters) ValueList
    ForListDo $(ValueList)
        set ValueItem = $($)
        set ValueName = *($(ValueItem),1)
        set ValueData = *($(ValueItem),4)
        ifstr(i) $(ValueName) == "bssType"
             set bssTypeValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "sleepMode"
             set sleepModeValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "TurboEnable"
             set TurboEnableValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "defaultKey"
             set defaultKeyValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "uniqKeyLength"
             set uniqKeyLengthValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "keyLength0"
             set keyLength0Value = $(ValueData)
        else-ifstr(i) $(ValueName) == "keyLength1"
             set keyLengthValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "keyLength2"
             set keyLength2Value = $(ValueData)
        else-ifstr(i) $(ValueName) == "keyLength3"
             set keyLength3Value = $(ValueData)
        else-ifstr(i) $(ValueName) == "MapRegisters"
             set MapRegistersValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "QoS"
             set QoSIndex = $(ValueData)
        else-ifstr(i) $(ValueName) == "tpc"
             set tpcIndex = $(ValueData)
        else-ifstr(i) $(ValueName) == "Ssid"
             set SsidValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "NetworkAddress"
             set NetworkAddressValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "uniqKey"
             set uniqKeyValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "key0"
             set key0Value = $(ValueData)
        else-ifstr(i) $(ValueName) == "key1"
             set key1Value = $(ValueData)
        else-ifstr(i) $(ValueName) == "key2"
             set key2Value = $(ValueData)
        else-ifstr(i) $(ValueName) == "key3"
             set key3Value = $(ValueData)
        else-ifstr(i) $(ValueName) == "privacyInvoked"
             set privacyInvokedValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "beaconInterval"
             set beaconIntervalValue = $(ValueData)
        else-ifstr(i) $(ValueName) == "BusNumber"
             set BusNum = $(ValueData)
        else-ifstr(i) $(ValueName) == "SlotNumber"
             set DeviceNum = $(ValueData)
        else-ifstr(i) $(ValueName) == "FunctionNumber"
             set FunctionNum = $(ValueData)
        endif
    EndForListDo

	; translate from registry value to listbox index
	; e.g. 0/1 => disabled/enabled

    set QoSValue = *($(QoSList), ~($(QoSValues),$(QoSIndex)))
    ifstr(i) $(QoSValue) == ""
        set QoSValue = *($(QoSList), 1)
    endif

    set tpcValue = *($(tpcList), ~($(tpcValues),$(tpcIndex)))
    ifstr(i) $(tpcValue) == ""
        set tpcValue = *($(tpcList), 1)
    endif


adaptersetup = +
    Set From = adapteroptions

adapteroptions = +
;----->remove QOS & MapReg
;	--> if configuring don't do anything
    ifint $(OldVersionExist) == $(TRUE)
        ifstr(i) $(!NTN_InstallMode) == configure
	     set CommonStatus = STATUS_USERCANCEL
	     goto end
        endif
;	--> if installing set the tpc value and proceed
    else
    	set tpcIndex			= $(Combo3Out)
    endif
;<-------

; If installing, go create the necessary keys;
; if configuring, they're already open.
skipoptions =+
    ifint $(OldVersionExist) == $(TRUE)
        ifstr(i) $(!NTN_InstallMode) == configure
            goto writeparameters
        endif
    endif
    StartWait

    ; Add Software Component
    ifint $(OldVersionExist) == $(FALSE)
        ifstr(i) $(!NTN_InstallMode) == "install"
           Ifstr(i) $(DoCopy) == "YES"
              Shell $(UtilityInf), DoAskSource, $(!STF_CWDDIR), $(SrcDir) YES
              Ifint $($ShellCode) != $(!SHELL_CODE_OK)
                  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
                  Goto successful
              Endif
              Set SrcDir = $($R1)
           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

        Shell $(UtilityInf), AddSoftwareComponent, $(Manufacturer), +
            $(ProductSoftwareName), +
            $(ProductSoftwareName), +
            $(ProductSoftwareTitle), $(STF_CONTEXTINFNAME), +
            $(ProductSoftwarePath), "kernel", "NDIS", {}, "",+
            $(NetEventDLL)

        Set OEM_ABANDON_SOFTWARE = TRUE
        ifint $($ShellCode) != $(!SHELL_CODE_OK)
            Debug-Output "ShellCode error"
            goto ShellCodeError
        endif

        ; $R1 contains the product version key handle
        ; $R2 contains the NetRules subkey handle
        ; $R3 contains the new Services key handle
        ; $R4 contains the Parameters key
        ; $R5 contains the Linkage Key
        set RegistryError = $($R0)
        set KeyProduct      = $($R1)
        Set SoftNetRulesKey = $($R2)
        CloseRegKey $($R3)
        CloseRegKey $($R4)
        CloseRegKey $($R5)

        Ifstr(i) $(RegistryError) != NO_ERROR
            EndWait
            Debug-Output "Registry error: add software components"
            CloseRegKey $(KeyProduct)
            CloseRegKey $(SoftNetRulesKey)
            goto fatalregistry
        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),$(ProductSoftwareDesc)},+
                           {ServiceName,$(NoTitle),$(!REG_VT_SZ),$(ProductSoftwareName)},+
                           {InstallDate,$(NoTitle),$(!REG_VT_DWORD),*($(Now),1)}}

        Shell  $(UtilityInf), AddValueList, $(KeyProduct), $(NewValueList)
        ifint $($ShellCode) != $(!SHELL_CODE_OK)
            Debug-Output "ShellCode error."
            goto ShellCodeError
        endif

        set RegistryError = $($R0)

        Ifstr(i) $(RegistryError) != NO_ERROR
            EndWait
            Debug-Output "Registry error: add value list."
            CloseRegKey $(KeyProduct)
            CloseRegKey $(SoftNetRulesKey)
            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, $(SoftNetRulesKey), $(NewValueList)
        ifint $($ShellCode) != $(!SHELL_CODE_OK)
            Debug-Output "ShellCode error."
            goto ShellCodeError
        endif

        set RegistryError = $($R0)

        CloseRegKey $(KeyProduct)
        CloseRegKey $(SoftNetRulesKey)

        Ifstr(i) $(RegistryError) != NO_ERROR
            EndWait
            Debug-Output "Resgitry error: add value list."
            goto fatalregistry
        endif
    endif

    ; Create the HARDWARE\Netcard region and its corresponding service
    Shell $(UtilityInf), AddHardwareComponent, $(ProductHardwareName),$(STF_CONTEXTINFNAME),$(ProductKeyName)
    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 RegistryError = $($R0)
    Ifstr(i) $(RegistryError) != NO_ERROR
        EndWait
        Debug-Output "Registry error: add hardware component"
        CloseRegKey $($R1)
        CloseRegKey $($R2)
        CloseRegKey $($R3)
        goto fatalregistry
    endif

    ; $R1  Registry key variable for HARDWARE\Netcard\(n)
    ; $R2  Registry key variable for HARDWARE\Netcard\(n)\\NetRules
    ; $R3  Registry key handle for <service>\Parameters key
    ; $R4  Adapter number assigned to adapter
    ; $R5  Service name generated by combining svc name with adapter number
    set KeyParameters = $($R3)
    set KeyAdapterRules = $($R2)
    set AdapterNumber = $($R4)

    set NewValueList = {{Manufacturer,$(NoTitle),$(!REG_VT_SZ),$(Manufacturer)},+
                       {Title,$(NoTitle),$(!REG_VT_SZ),"["$($R4)"] "$(ProductHardwareTitle)},+
                       {Description,$(NoTitle),$(!REG_VT_SZ),$(ProductHardwareDesc)},+
                       {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"
        goto ShellCodeError
    endif
    CloseRegKey $($R1)

    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 RegistryError = $($R0)

    Ifstr(i) $(RegistryError) != NO_ERROR
        EndWait
        Debug-Output "Resgitry error: add value list."
        CloseRegKey $(KeyParameters)
        CloseRegKey $(KeyAdapterRules)
        goto fatalregistry
    endif

    CloseRegKey $(KeyAdapterRules)
    goto writeparameters

; REQUIRED: $(KeyParameters) contains service Parameters key handle
writeparameters = +
    Shell $(UtilityInf), GetBusTypeNum
    set BusTypeNum = $($R1)
    ifint $($ShellCode) != $(!SHELL_CODE_OK)
        Debug-Output "ShellCode error."
        goto ShellCodeError
    endif

    ; Add the rest of the parameters to the Services area
    Debug-Output "OEMSETUP.INF: - Create Driver Parameters"

	; Translate listbox index to registry value
	; e.g. Disabled/Enabled to 0/1
    set QoSValue            = *($(QoSValues), ~($(QoSList), $(QoSIndex)))
    set tpcValue            = *($(tpcValues), ~($(tpcList), $(tpcIndex)))

    set NewValueList        = {{bssType, $(NoTitle),$(!REG_VT_SZ),$(bssTypeValue)},+
                              {sleepMode, $(NoTitle),$(!REG_VT_SZ),$(sleepModeValue)},+
                              {TurboEnable, $(NoTitle),$(!REG_VT_SZ),$(TurboEnableValue)},+
                              {defaultKey, $(NoTitle),$(!REG_VT_SZ),$(defaultKeyValue)},+
                              {uniqKeyLength, $(NoTitle),$(!REG_VT_SZ),$(uniqKeyLengthValue)},+
                              {keyLength0, $(NoTitle),$(!REG_VT_SZ),$(keyLength0Value)},+
                              {keyLength1, $(NoTitle),$(!REG_VT_SZ),$(keyLength1Value)},+
                              {keyLength2, $(NoTitle),$(!REG_VT_SZ),$(keyLength2Value)},+
                              {keyLength3, $(NoTitle),$(!REG_VT_SZ),$(keyLength3Value)},+
                              {MapRegisters, $(NoTitle),$(!REG_VT_SZ),$(MapRegistersValue)},+
                              {QoS, $(NoTitle),$(!REG_VT_SZ),$(QoSValue)},+
                              {tpc, $(NoTitle),$(!REG_VT_SZ),$(tpcValue)},+
                              {Ssid, $(NoTitle),$(!REG_VT_SZ),$(SsidValue)},+
                              {NetworkAddress, $(NoTitle),$(!REG_VT_SZ),$(NetworkAddressValue)},+
                              {uniqKey, $(NoTitle),$(!REG_VT_SZ),$(uniqKeyValue)},+
                              {key0, $(NoTitle),$(!REG_VT_SZ),$(key0Value)},+
                              {key1, $(NoTitle),$(!REG_VT_SZ),$(key1Value)},+
                              {key2, $(NoTitle),$(!REG_VT_SZ),$(key2Value)},+
                              {key3, $(NoTitle),$(!REG_VT_SZ),$(key3Value)},+
                              {privacyInvoked, $(NoTitle),$(!REG_VT_SZ),$(privacyInvokedValue)},+
                              {beaconInterval, $(NoTitle),$(!REG_VT_SZ),$(beaconIntervalValue)},+
                              {MediaType, $(NoTitle),$(!REG_VT_DWORD),1},+
                              {BusType, $(NoTitle),$(!REG_VT_DWORD),$(BusTypeNum)},+
							  {BusNumber,$(NoTitle),$(!REG_VT_DWORD),$(BusNum)},+
                              {SlotNumber,$(NoTitle),$(!REG_VT_DWORD),$(DeviceNum)},+
                              {FunctionNumber,$(NoTitle),$(!REG_VT_DWORD),$(FunctionNum)},+
                              {DriverDesc,$(NoTitle),$(!REG_VT_SZ),$(GenericAdapterName)},+
                              {AdapterType, $(NoTitle),$(!REG_VT_DWORD),0},+
                              {PCMCIA, $(NoTitle),$(!REG_VT_DWORD),0},+
                              {DriverType,$(NoTitle),$(!REG_VT_DWORD),1},+
                              {MediaType,$(NoTitle),$(!REG_VT_DWORD),1},+
                              {NwayProtocol,$(NoTitle),$(!REG_VT_DWORD),1},+
                              {PlatformType,$(NoTitle),$(!REG_VT_DWORD),1}}

    Shell  $(UtilityInf), AddValueList, $(KeyParameters), $(NewValueList)
    CloseRegKey $(KeyParameters)

    ifint $(DISABLEPCMCIASYS) == 1
        set PCMCIAKeyName = $(!NTN_ServiceBase)"\Pcmcia"
        OpenRegKey $(!REG_H_LOCAL) "" $(PCMCIAKeyName) $(MaximumAllowed) PCMCIAKey
        SetRegValue $(PCMCIAKey) {Start, 0, $(!REG_VT_DWORD),4}  ; '4' disables the driver
        CloseRegKey $(PCMCIAKey)
    endif
     
    ifint $($ShellCode) != $(!SHELL_CODE_OK)
        Debug-Output "ShellCode error."
        goto ShellCodeError
    endif

    set RegistryError = $($R0)

    Ifstr(i) $(RegistryError) != NO_ERROR
        Debug-Output "Registry error: Add value list"
        goto fatalregistry
    endif
    EndWait

    ; ----------------------------------------------------------------------------------------------------------
    ; add driver info to the SYSTEM\CurrentControlSet\Services\resman\Database\Atheros for CardWizard
    ; ----------------------------------------------------------------------------------------------------------
    set CWKey 			= "SYSTEM\CurrentControlSet\Services\resman"
    set CWDatabaseKey 		= $(CWKey)"\Database"
    set CWManufacturerKey 	= $(CWDatabaseKey)"\"$(Manufacturer)
    set CWCardNameKey		= $(CWManufacturerKey)"\"$(CardName)
    Debug-Output "OEMSETUP.INF: Check the presence of CardWizard"
	OpenRegKey $(!REG_H_LOCAL) "" $(CWKey) $(MaximumAllowed) MyPcmciaHandle
	Ifstr $(MyPcmciaHandle) == $(KeyNull)
	    goto successful
	endif

    Debug-Output "OEMSETUP.INF: Create Registry Keys for CardWizard"

	OpenRegKey $(!REG_H_LOCAL) "" $(CWCardNameKey) $(MaximumAllowed) MyPcmciaHandle
	Ifstr $(MyPcmciaHandle) == $(KeyNull)
	    Debug-Output "OEMSETUP.INF: Create Registry Keys (for CardName)"
	    OpenRegKey $(!REG_H_LOCAL) "" $(CWDatabaseKey) $(MaximumAllowed) MyPcmciaKey
	    CreateRegKey $(MyPcmciaKey) {$(Manufacturer),0,GenericClass} "" $(MaximumAllowed) "" MyPcmcialHandle
	    CloseRegKey $(MyPcmciaKey)
	    OpenRegKey $(!REG_H_LOCAL) "" $(CWManufacturerKey) $(MaximumAllowed) MyPcmciaKey
	    CreateRegKey $(MyPcmciaKey) {$(CardName),0,GenericClass} "" $(MaximumAllowed) "" MyPcmcialHandle
	    CloseRegKey $(MyPcmciaKey)
	    OpenRegKey $(!REG_H_LOCAL) "" $(CWCardNameKey) $(MaximumAllowed) MyPcmciaHandle
	endif
	set NewValueList = {{Driver,$(NoTitle),$(!REG_VT_SZ),$(GenericName)}}
	Shell  $(UtilityInf), AddValueList, $(MyPcmciaHandle), $(NewValueList)
	Debug-Output "<DBG> AddValueList - Driver:REG_SZ:"$(CardName)
	CloseRegKey $(MyPcmciaHandle)

    goto successful

;-----------------------------------------------
; Binding section
;-----------------------------------------------

bindingadapter =+
    set Error = "Binding: Sorry, not yet implemented."
    goto fatal

;-----------------------------------------------
; Removeadapter section
;-----------------------------------------------

removeadapter = +
    Ifstr(i) $(ProductKeyName) == $(!NTN_RegBase)
        ; Remove Software Component
        Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
            $(ProductSoftwareName)
        ifint $($ShellCode) != $(!SHELL_CODE_OK)
            Debug-Output "ShellCode error"
            goto ShellCodeError
        endif
        set RegistryError = $($R0)
        Ifstr(i) $(RegistryError) != NO_ERROR
            goto fatalregistry
        endif
    else
        Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
            $(ProductSoftwareName), $(!NTN_RegBase)
        ifint $($ShellCode) != $(!SHELL_CODE_OK)
            Debug-Output "ShellCode error"
            goto ShellCodeError
        endif
        set RegistryError = $($R0)
        Ifstr(i) $(RegistryError) != NO_ERROR
            goto fatalregistry
        endif
    endif
    ifint $(DISABLEPCMCIASYS) == 1
        set PCMCIAKeyName = $(!NTN_ServiceBase)"\Pcmcia"
        OpenRegKey $(!REG_H_LOCAL) "" $(PCMCIAKeyName) $(MaximumAllowed) PCMCIAKey
        SetRegValue $(PCMCIAKey) {Start, 0, $(!REG_VT_DWORD),0}  ; '0' restores the driver to "BOOT"
        CloseRegKey $(PCMCIAKey)
    endif
    goto end

;-----------------------------------------------
; Upgrade Software section
;-----------------------------------------------

UpgradeSoftware = +
	
	; Update Software\ManufacturerName\ProductName\CurrentVersion and
	; install new drivers and INF

	OpenRegKey $(!REG_H_LOCAL) "" $(ProductKeyName) $(MaximumAllowed) KeyProduct
	Ifstr $(KeyProduct) != $(KeyNull)
		
		Shell $(UtilityInf), GetInfFileNameFromRegistry, $(KeyProduct)
		ifint $($ShellCode) != $(!SHELL_CODE_OK)
		   Debug-Output "ShellCode error"
		   goto ShellCodeError
		endif
		set !UG_Filename = $($R0)
		ifstr(i) $(!UG_Filename) != ""
			install "Install-Update"
			ifstr(i) $(STF_INSTALL_OUTCOME) != STF_SUCCESS
				goto fatal
			endif
		endif

		SetRegValue $(KeyProduct) {MajorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMajorVersion)}
		SetRegValue $(KeyProduct) {MinorVersion,$(NoTitle),$(!REG_VT_SZ),$(ProductMinorVersion)}

		CloseRegKey $(KeyProduct)
	else
	   goto fatalregistry
	endif

	goto end

successful = +
    goto end

abandon = +
    ForListDo $(OEM_ABANDON_OPTIONS)
        Shell $(UtilityInf), RemoveHardwareComponent, $(Manufacturer), +
            $(ProductSoftwareName), $($)
        ifint $($ShellCode) != $(!SHELL_CODE_OK)
            Debug-Output "ShellCode error"
            goto ShellCodeError
        endif
        set RegistryError = $($R0)
        Ifstr(i) $(RegistryError) != NO_ERROR
            goto fatalregistry
        endif
    EndForListDo
    Ifstr(i) $(OEM_ABANDON_SOFTWARE) == TRUE
        Shell $(UtilityInf), RemoveSoftwareComponent, $(Manufacturer), +
            $(ProductSoftwareName), FALSE
        ifint $($ShellCode) != $(!SHELL_CODE_OK)
            Debug-Output "ShellCode error"
            goto ShellCodeError
        endif
        set RegistryError = $($R0)
        Ifstr(i) $(RegistryError) != NO_ERROR
            goto fatalregistry
        endif
    endif
    goto end

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 = +
    Set Severity = STATUS
    Set CommonStatus = STATUS_USERCANCEL
    goto nonfatalmsg

nonfatal = +
    Set Severity = NONFATAL
    goto nonfatalmsg

nonfatalmsg = +
    ifstr(i) $(Error) == ""
        Set Severity = NONFATAL
        Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
        ifint $($ShellCode) != $(!SHELL_CODE_OK)
            goto ShellCodeError
        endif
        set Error = $($R0)
    endif
    Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), $(Severity), $(Error)
    ifint $($ShellCode) != $(!SHELL_CODE_OK)
        goto ShellCodeError
    endif
    ifstr(i) $($R1) == "OK"
        goto $(From)
    else
        goto "end"
    endif

fatalregistry = +
    Shell $(UtilityInf) RegistryErrorString $(RegistryError)
    ifint $($ShellCode) != $(!SHELL_CODE_OK)
        goto ShellCodeError
    endif
    set Error = $($R0)
    goto fatal

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 = +
    ifstr(i) $(Error) == ""
        Shell $(UtilityInf) RegistryErrorString "SETUP_FAIL"
        ifint $($ShellCode) != $(!SHELL_CODE_OK)
            goto ShellCodeError
        endif
        set Error = $($R0)
    endif
    Shell $(subroutineinf) SetupMessage, $(!STF_LANGUAGE), "FATAL", $(Error)
    ifint $($ShellCode) != $(!SHELL_CODE_OK)
        goto ShellCodeError
    endif
    goto setfailed

ShellCodeError = +
    set DlgType      = "MessageBox"
    set STF_MB_TITLE = $(ShellCodeErrorTitle)
    set STF_MB_TEXT  = $(ShellCodeErrorText)
    set STF_MB_TYPE  = 1
    set STF_MB_ICON  = 3
    set STF_MB_DEF   = 1
    ui start "Error Message"
    goto setfailed

setfailed = +
    set CommonStatus = STATUS_FAILED
    ifstr(i) $(OEM_ABANDON_ON) == TRUE
        set OEM_ABANDON_ON = FALSE
        goto abandon
    endif
    goto end

end = +
    goto term

term = +
    Return $(CommonStatus)

[DebugConfiguration]
    Set InfName = "OEMSETUP.INF"
    return

[Install-Option]
    set STF_VITAL = ""
    ifstr(i) $(AddCopy) == "YES"
        AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
    endif
    ifstr(i) $(DoCopy) == "YES"
        set !STF_NCPA_FLUSH_COPYLIST = TRUE
        CopyFilesInCopyList
    endif
    Exit

[Install-Update]
    set STF_VITAL = ""
    set STF_OVERWRITE = "VERIFYSOURCEOLDER"
    AddSectionFilesToCopyList Files-$(Option) $(SrcDir) $(!STF_WINDOWSSYSPATH)\drivers
    AddSectionFilesToCopyList Files-Inf $(SrcDir) $(!STF_WINDOWSSYSPATH)
    set !STF_NCPA_FLUSH_COPYLIST = TRUE
    CopyFilesInCopyList
    exit

[Source Media Descriptions]
    1  = "Harmony 802.11a Setup Disk for NT"

[ProductType]
STF_PRODUCT  = Winnt
STF_PLATFORM = I386

[Files-Inf]
1, OEMSETUP.INF, SIZE=58000, RENAME=$(!UG_Filename)

[Files-HARMONY11A]
1, PROX11AN4.SYS, SIZE=53000

[LanguagesSupported]
    ENG

[AllFileConstantsENG]
ProCaption      = "Windows NT Setup"
ProCancel       = "Cancel"
ProCancelMsg    = "Windows NT Networking is not correctly installed.  "+
                  "Are you sure you want to cancel copying files?"
ProCancelCap    = "Network Setup Message"
ProText1        = "Copying:"
ProText2        = "To:"

[FileConstantsENG-HARMONY11A]
FunctionTitle           = $(GenericTitleName)" Setup"$(GenericInfVersion)
ProductSoftwareTitle    = $(GenericDriverName)
ProductHardwareTitle    = $(GenericAdapterName)
bssTypeList     	= ^(bssTypeChoices, 1)
bssTypeValues   	= ^(bssTypeChoices, 2)
sleepModeList     	= ^(sleepModeChoices, 1)
sleepModeValues   	= ^(sleepModeChoices, 2)
TurboEnableList     	= ^(TurboEnableChoices, 1)
TurboEnableValues   	= ^(TurboEnableChoices, 2)
defaultKeyList     	= ^(defaultKeyChoices, 1)
defaultKeyValues   	= ^(defaultKeyChoices, 2)
keyLengthList     	= ^(keyLengthChoices, 1)
keyLengthValues   	= ^(keyLengthChoices, 2)
MapRegistersList   	= ^(MapRegistersChoices, 1)
MapRegistersValues 	= ^(MapRegistersChoices, 2)
QoSList   			= ^(QoSChoices, 1)
QoSValues 			= ^(QoSChoices, 2)
tpcList   			= ^(tpcChoices, 1)
tpcValues 			= ^(tpcChoices, 2)

[DialogConstantsENG-HARMONY11A]
Help        = "&Help"
Exit        = "Cancel"
OK          = "OK"
HelpContext = ""
Continue    = "Continue"
Cancel      = "Cancel"

[FileDependentDlgENG-HARMONY11A]
DlgType     = "RadioCombination"
DlgTemplate = "PROX11AN4"
Caption     = $(FunctionTitle)
HelpContext = $(!IDH_DB_OEMNADE2_INS)
CBOptionsGreyed = {}
NotifyFields = {NO}

Combo1Label = "Map Registers:"
Combo2Label = "QoS (802.11e):"
Combo3Label = "Transmit Power Control:"


Combo1List = $(MapRegistersList)
Combo1Out  = $(MapRegistersValue)

Combo2List = $(QoSList)
Combo2Out  = $(QoSValue)

Combo3List = $(tpcList)
Combo3Out  = $(tpcValue)

ComboListItemsIn  = {Combo1List, Combo2List, Combo3List} 
ComboListItemsOut = {Combo1Out, Combo2Out, Combo3Out}

EditTextIn = {"",""}
EditTextLim = {"",""}
 

[bssTypeChoices]
bssType_1 = "AP (Infrastructure)", 1
bssType_2 = "Ad Hoc", 2

[sleepModeChoices] 
sleepMode_0 = "Off", 0
sleepMode_1 = "Normal", 2
sleepMode_2 = "Maximum", 1

[TurboEnableChoices]
TurboEnable_0 = "Disabled", 0
TurboEnable_1 = "Enabled", 1

[defaultKeyChoices]
defaultKey_0 = "Shared Encryption Key 1", 0
defaultKey_1 = "Shared Encryption Key 2", 1
defaultKey_2 = "Shared Encryption Key 3", 2
defaultKey_3 = "Shared Encryption Key 4", 3
defaultKey_4 = "Unique Encryption Key"  , 4

[keyLengthChoices]
keyLength_0 = "40 bits", 5
keyLength_1 = "104 bits", 13
keyLength_2 = "128 bits", 16

[MapRegistersChoices]
MapRegisters_1 = "32", 32
MapRegisters_2 = "64", 64
MapRegisters_3 = "128", 128
MapRegisters_4 = "256", 256
MapRegisters_5 = "384", 384
MapRegisters_6 = "512", 512

[QoSChoices]
QoS_0 = "Disabled", 0
QoS_1 = "Enabled", 1

[tpcChoices]
tpc_0 = "Highest Power"	, 0
tpc_1 = "50% Power"		, 1
tpc_2 = "25% Power"		, 2
tpc_3 = "12% Power"		, 3
tpc_4 = "Lowest Power"	, 4
Download Driver Pack

How To Update Drivers Manually

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.

server: ftp, load: 0.41