;****************************************************************************************
;
; DNETR28X.INF
;
;   This installation script supports Windows Vista, Win8 for the
;   D-Link DWA series USB Wireless LAN Card.
;
;   Copyright (C) 2002-2013 D-Link Technology Corporation. All Rights Reserved.
;
;****************************************************************************************

[Version]
Signature       = "$Windows NT$"
Class           = Net
ClassGUID       = {4d36e972-e325-11ce-bfc1-08002be10318}
Provider        = %D-Link%
CatalogFile     = Dnetr28x.cat
DriverVer       = 12/25/2013,5.00.38.0000

[ControlFlags]
ExcludeFromSelect = *

[Manufacturer]
%D-Link%        = D-Link, NTAMD64.6.2

;*******************************************************************************************
; Win7 specific entries
;*******************************************************************************************
[D-Link.NTAMD64.6.2]
; DisplayName                  Section                         DeviceID
; -----------                  -------                         --------
%D-Link_3C04.DeviceDesc%       = NDIS61_RT3900P_C1.ndi,        PCI\VEN_1814&DEV_3060&SUBSYS_3C041186
%D-Link_3C05.DeviceDesc%       = NDIS61_RT3900P_C1.ndi,        PCI\VEN_1814&DEV_5360&SUBSYS_3C051186
%D-Link_3C06.DeviceDesc%       = NDIS61_RT3900E3.ndi,          PCI\VEN_1814&DEV_5392&SUBSYS_3C061186

;*******************************************************************************************
; Win7 specific entries
;*******************************************************************************************
[NDIS61_RT3900P_C1.ndi.NT]
Include=netvwifibus.inf
Needs=VWiFiBus.CopyFiles
AddReg                  = RT2860_NDIS61.reg, RT2860.reg, SingleBand.reg, AdhocNMode.reg, Customer2.reg, CoInstOpt_DLink.reg, FastRoaming.reg
DelReg                  = RegRemove.delReg
Characteristics         = 0x84                      ; NCF_REMOVABLE | NCF_HAS_UI | NCF_PHYSICAL
BusType                 = 5
CopyFiles               = NT.CopyFiles
*IfType                 = 71                        ; IF_TYPE_IEEE80211
*MediaType              = 16                        ; NdisMediumNative802_11
*PhysicalMediaType      = 9                         ; NdisPhysicalMediumNative802_11

[NDIS61_RT3900P_C1.ndi.NT.Hw]
Include=netvwifibus.inf
Needs=VWiFiBus.PnPFilterRegistration

[NDIS61_RT3900E3.ndi.NT]
Include=netvwifibus.inf
Needs=VWiFiBus.CopyFiles
AddReg                  = RT2860_NDIS61.reg, RT2860.reg, SingleBand.reg, AdhocNMode.reg, PowerContrl_F2.reg, FastRoaming5range.reg, WOWLAN.reg, PM4Beacon.reg, SmartScan.reg
DelReg                  = RegRemove.delReg
Characteristics         = 0x84                      ; NCF_REMOVABLE | NCF_HAS_UI | NCF_PHYSICAL
BusType                 = 5
CopyFiles               = NT.CopyFiles
*IfType                 = 71                        ; IF_TYPE_IEEE80211
*MediaType              = 16                        ; NdisMediumNative802_11
*PhysicalMediaType      = 9                         ; NdisPhysicalMediumNative802_11

[NDIS61_RT3900E3.ndi.NT.Hw]
Include=netvwifibus.inf
Needs=VWiFiBus.PnPFilterRegistration
AddReg                  = MSI.Reg

;*******************************************************************************************
; Win7 services sections
;*******************************************************************************************
[NDIS61_RT3900E3.ndi.NT.Services]
Include=netvwifibus.inf
Needs=VWiFiBus.Services
AddService              = netr28x, 2, Generic.Service, common.EventLog

[NDIS61_RT3900P_C1.ndi.NT.Services]
Include=netvwifibus.inf
Needs=VWiFiBus.Services
AddService              = netr28x, 2, Generic.Service, common.EventLog

;*******************************************************************************************
; NT CoInstallers Sections(Win7)
;*******************************************************************************************
[NDIS61_RT3900P_C1.ndi.NT.CoInstallers]
CopyFiles = CoInstaller.CopyFiles
AddReg = CoInstaller_AddReg 

[NDIS61_RT3900E3.ndi.NT.CoInstallers]
CopyFiles = CoInstaller.CopyFiles
AddReg = CoInstaller_AddReg

;*******************************************************************************************
; Registry for Win7
;*******************************************************************************************
[RT2860_NDIS61.reg]
HKR, Ndi,                       Service,    0, "netr28x"

HKR, Ndi\Interfaces,            UpperRange, 0, "ndis5"
HKR, Ndi\Interfaces,            LowerRange, 0, "wlan,ethernet,vwifi"

;*******************************************************************************************
; Registry for both Vista & Win7
;*******************************************************************************************
[RT2860.reg]

;
; CCX drastic roaming use
;
HKR, ,                            CCXPktLossLimitTime, 0, "30"

;
; CCX Dbm offset
;
HKR, ,                            CCXDbmOffset,    0, "4"

;
; CCX VO/VI Drop Period, 3 or 5 is recommanded
;
HKR, ,                            CACDropPeriod,   0, "0"

;
; CCX VO/VI Drop Criteria
;
HKR, ,                            CACDropCriteria, 0, "1700"

;
; WirelessMode
;
HKR, ,                            WirelessMode,    0, "5"

;
; Channel
;
HKR, ,                            Channel,         0, %CHANNEL%
HKR, Default,                     Channel,         0, %CHANNEL%

;
; Channel list
; 
HKR, ,                            CountryRegion,   0, "0"
HKR, ,                            CountryRegionABand, 0, "0"

;
; Radio On/Off
;
HKR, ,                            Radio,           0, "0"
HKR, NDI\params\Radio,            ParamDesc,       0, %RadioOnOff%
HKR, NDI\params\Radio,            type,            0, "enum"
HKR, NDI\params\Radio,            default,         0, "0"
HKR, NDI\params\Radio\enum,       1,               0, %Disable%
HKR, NDI\params\Radio\enum,       0,               0, %Enable%

;
; WMMCapable
;
HKR, ,                            WMMCapable,      0, "1"

;
; FrameAggregation
;
HKR, ,                            FrameAggregation,0, "0"

;
; IEEE80211H
;
HKR, ,                            IEEE80211H,      0, "0"

;
; CarrierDetect
;
HKR, ,                            CarrierDetect,   0, "0"

;
; WPS Device Name
;
HKR, ,                            WPSDevName,      0, %WPS_DEVNAME_DEF_STR%
HKR, Default,                     WPSDevName,      0, %WPS_DEVNAME_DEF_STR%

;
; OpMode
;
HKR, ,                            OpMode,          0, "0"

;
; Enable TX Burst
;
HKR, ,                            TXBurst,         0, "1"

;
; Use Short Slot Time
;
HKR, ,                            ShortSlot,       0, "1"

;
; Block ACK settings
;
HKR, ,                            BACapability,    0x10001, "0x0b034040"
HKR, Default,                     BACapability,    0x10001, "0x0b034040"

;
; Wifi Direct settings
;
HKR, ,                            WifiDirectControl, 0x10001, "0x04308078"
HKR, Default,                     WifiDirectControl, 0x10001, "0x04308078"

;
; Win8 WFD WFA
;
HKR, ,                            Win8WfdWfaControl,    0x10001, "0x00000000"
HKR, Default,                     Win8WfdWfaControl,    0x10001, "0x00000000"

;
; Enable P2P Video Boost within P2P Group
;
HKR, ,                            P2PVideoBoost,   0, "0"

;
; Transmit Rate setting
;
HKR, ,                            TransmitSetting,      0x10001, "0x22CA15"
HKR, Default,                     TransmitSetting,      0x10001, "0x22CA15"

;
; RDG
;
HKR, ,                            RDG,             0, "1"

;
; Network Type
;
HKR, ,                            NetworkType,     0, "1"
HKR, Default,                     NetworkType,     0, "1"

;
; Disable 5GHz adhoc mode
;
HKR, ,                            Adhoc5GDisable,  0, "0"

;
; SmartScan
;
HKR, ,                            SmartScan,       0, "0"
HKR, NDI\params\SmartScan,        ParamDesc,       0, %SmartScan%
HKR, NDI\params\SmartScan,        type,            0, "enum"
HKR, NDI\params\SmartScan,        default,         0, "0"
HKR, NDI\params\SmartScan\enum,   0,               0, %Disable%
HKR, NDI\params\SmartScan\enum,   1,               0, %Enable%

;
; Power Save control
;
HKR, ,                            PSControl,       0x00010001, 0x00000000

;
; ProhibitTKIPonHT
;
HKR, ,                            ProhibitTKIPonHT, 0, "1"

;
; Link Speed Status
;
HKR, ,                            LinkSpeedStatus,  0, "0"

;
; AdhocN40MHzAllowed
;
HKR, ,                            AdhocN40MHzAllowed, 0, "0"

;
; WSC Version2 
HKR, ,                            WSCVersion2,     0x00010001, 0x00000020

;
; WSC 2.0 Testbed for some test items. 
HKR, ,                            WSC20Testbed,    0x00010001, 0x00000008

;
; PMF On/Off
;
HKR, ,                            MFPC,            0, "1"

;
; Test WHCK Usage
;
HKR, ,				OnTestingWHQL,		0,	"0"
HKR, ,				OnTestingCPUUtil,	0,	"0"

;
; Enable P2P Video Boost within P2P Group
;
HKR, ,				InBoxMode,		0, 	"0"

;
; FWupdated check
;
HKR, ,              FWUpdated,    0x00010001, 0x0

;*******************************************************************************************
[SingleBand.reg]
;
; 2.4G Band
;
HKR, ,                                 CountryRegion,      0, "0"
HKR, NDI\params\CountryRegion,         ParamDesc,          0, %CountryRegion24G%
HKR, NDI\params\CountryRegion,         type,               0, "enum"
HKR, NDI\params\CountryRegion,         default,            0, "0"
HKR, NDI\params\CountryRegion\enum,    0,                  0, %CountryRegion24G_0%
HKR, NDI\params\CountryRegion\enum,    1,                  0, %CountryRegion24G_1%
HKR, NDI\params\CountryRegion\enum,    2,                  0, %CountryRegion24G_2%
HKR, NDI\params\CountryRegion\enum,    3,                  0, %CountryRegion24G_3%
HKR, NDI\params\CountryRegion\enum,    4,                  0, %CountryRegion24G_4%
HKR, NDI\params\CountryRegion\enum,    5,                  0, %CountryRegion24G_5%
HKR, NDI\params\CountryRegion\enum,    6,                  0, %CountryRegion24G_6%
HKR, NDI\params\CountryRegion\enum,    7,                  0, %CountryRegion24G_7%

[AdhocNMode.reg]
;
; AdhocNMode
;
HKR, ,                            AdhocNMode,      0, "0"
HKR, NDI\params\AdhocNMode,       ParamDesc,       0, %AdhocNMode%
HKR, NDI\params\AdhocNMode,       type,            0, "enum"
HKR, NDI\params\AdhocNMode,       default,         0, "0"
HKR, NDI\params\AdhocNMode\enum,  0,               0, %Disable%
HKR, NDI\params\AdhocNMode\enum,  1,               0, %Enable%

[Customer2.reg]
; D-Link Request
; WMMCapable
HKR, ,                            WMMCapable,      0, "1"
; Enable TX Burst
HKR, ,                            TXBurst,         0, "1"
; FrameAggregation
HKR, ,                            FrameAggregation,0, "1"
; DLSCapable
HKR, ,                            DLSCapable,      0, "1"
; DirectMode
HKR, ,                            DirectMode,      0, "0"

; Remove registry
;
[RegRemove.delReg]
; Remove CountryRegion
HKR, NDI\params\CountryRegion
HKR, NDI\params\CountryRegionABand

; Remove IEEE80211H
HKR, NDI\params\IEEE80211H

[PowerContrl_F2.reg]
HKR, ,               PSControl, 0x00010001, 0x000000df

[FastRoaming.reg]
HKR, ,                                 FastRoamingSensitivity, 0, "2"
HKR, NDI\params\FastRoamingSensitivity,    ParamDesc,          0, %FAST_ROAMING_SENSITIVITY_STR%
HKR, NDI\params\FastRoamingSensitivity,    type,               0, "enum"
HKR, NDI\params\FastRoamingSensitivity,    default,            0, "2"
HKR, NDI\params\FastRoamingSensitivity\enum,1,                 0, %LOWEST_STR3%
HKR, NDI\params\FastRoamingSensitivity\enum,2,                 0, %MEDIUM_STR3%
HKR, NDI\params\FastRoamingSensitivity\enum,4,                 0, %HIGHEST_STR3%

[FastRoaming5range.reg]
HKR, ,                                 FastRoamingSensitivity, 0, "0"
HKR, NDI\params\FastRoamingSensitivity,    ParamDesc,          0, %FAST_ROAMING_SENSITIVITY_STR%
HKR, NDI\params\FastRoamingSensitivity,    type,               0, "enum"
HKR, NDI\params\FastRoamingSensitivity,    default,            0, "0"
HKR, NDI\params\FastRoamingSensitivity\enum,         "0",      0, %DISABLE_STR%
HKR, NDI\params\FastRoamingSensitivity\enum,         "1",      0, %LOWEST_STR%
HKR, NDI\params\FastRoamingSensitivity\enum,         "2",      0, %MEDIUM_LOW_STR%
HKR, NDI\params\FastRoamingSensitivity\enum,         "3",      0, %MEDIUM_STR%
HKR, NDI\params\FastRoamingSensitivity\enum,         "4",      0, %MEDIUM_HIGH_STR%
HKR, NDI\params\FastRoamingSensitivity\enum,         "5",      0, %HIGHEST_STR%

;*******************************************************************************************
;Seperate Settings
[WOWLAN.reg]
HKR, ,                WakeUpCapabilities,   0x00010001, 0
HKR, ,                WowFuncCapability,	0x00010001,	0x0002
HKR, ,                WoWLANWakeupEvent,	0x00010001,	0x0000
HKR, ,				LoadExtFW,	0x00010001,	0x0001

[PM4Beacon.reg]
;
; PM4 Power Check
;
HKR, ,                            PM4BeaconListen,    0, "3"

[SmartScan.reg]                   
HKR, ,                            SmartScan,       0, "1"

[MSI.Reg]
HKR, "Interrupt Management\MessageSignaledInterruptProperties", MSISupported, 0x00010001, 1

[CoInstaller_AddReg]
HKR,,CoInstallers32,0x00010000, "RaCoInstx.dll,ClassCoInstaller"

; CoInstaller Options , Enable 11n feature in Morocco, Russia, Ukraine.
[CoInstOpt_DLink.reg]
HKR, ,                            RaCoInstOpt,      0,"00001111"
; WirelessMode
HKR, ,                            WirelessMode,    0, "5"
; CountryWirelessMode
HKR, ,                            CountryWirelessMode,    0x10001, "0x11101110"

;*******************************************************************************************
; DestinationDirs
;*******************************************************************************************

[NT.CopyFiles]
Dnetr28x.sys,,,2

[CoInstaller.CopyFiles]
RaCoInstx.dll,,,2
RaCoInst.dat,,,2

[SourceDisksNames]
1 = %INSTALL_DISK_STR%,,,

[SourceDisksFiles]
Dnetr28x.sys                = 1,,
RaCoInstx.dll              = 1,,
RaCoInst.dat              = 1,,

[DestinationDirs]
NT.CopyFiles     = 12     ; system32\drivers subdirectory on NT
DefaultDestDir   = 11
CoInstaller.CopyFiles = 11

;*******************************************************************************************
; NT specific
;*******************************************************************************************

[Generic.Service]
DisplayName                 = %Generic.Service.DispName%
ServiceType                 = 1                             ;%SERVICE_KERNEL_DRIVER%
StartType                   = 3                             ;%SERVICE_AUTO_START%
ErrorControl                = 1                             ;%SERVICE_ERROR_NORMAL%
ServiceBinary               = %12%\Dnetr28x.sys
LoadOrderGroup              = NDIS


[common.EventLog]
AddReg = common.AddEventLog.reg

[common.AddEventLog.reg]
HKR, , EventMessageFile, 0x00020000, "%%SystemRoot%%\System32\netevent.dll"
HKR, , TypesSupported,   0x00010001, 7

;*******************************************************************************************
; Strings
;*******************************************************************************************
[Strings]
D-Link                      = "D-Link Corporation"

;*******************************************************************************************
; Device description
;*******************************************************************************************
Generic.DeviceDesc          = "802.11n Wireless LAN Card"

D-Link_3C04.DeviceDesc      = "D-Link DWA-525 Wireless N 150 Desktop Adapter"
D-Link_3C05.DeviceDesc      = "D-Link DWA-525 Wireless N 150 Desktop Adapter(rev.A2)"
D-Link_3C06.DeviceDesc      = "D-Link DWA-548 Wireless N PCIe Desktop Adapter"

INSTALL_DISK_STR            = "D-Link 802.11n Wireless LAN Installation Disk"

Generic.Service.DispName    = "D-Link 802.11n Extensible Wireless Driver"

;
; Parameters
;
RadioOnOff                  = "Radio On/Off"
Disable                     = "Disable"
Enable                      = "Enable"
CountryRegion24G            = "Country Region (2.4GHz)"
CountryRegion24G_0          = "#0 (1 - 11)"
CountryRegion24G_1          = "#1 (1 - 13)"
CountryRegion24G_2          = "#2 (10 - 11)"
CountryRegion24G_3          = "#3 (10 - 13)"
CountryRegion24G_4          = "#4 (14)"
CountryRegion24G_5          = "#5 (1 - 14)"
CountryRegion24G_6          = "#6 (3 - 9)"
CountryRegion24G_7          = "#7 (5 - 13)"
CountryRegion5G             = "Country Region (5GHz)"
CountryRegion5G_0           = "#0 (36 - 64,149 - 165)"
CountryRegion5G_1           = "#1 (36 - 140)"
CountryRegion5G_2           = "#2 (36 - 64)"
CountryRegion5G_3           = "#3 (52 - 64,149 - 161)"
CountryRegion5G_4           = "#4 (149 - 165)"
CountryRegion5G_5           = "#5 (149 - 161)"
CountryRegion5G_6           = "#6 (36 - 48)"
CountryRegion5G_7           = "#7 (36 - 165)"
CountryRegion5G_8           = "#8 (52 - 64)"
CountryRegion5G_9           = "#9 (36 - 116,132 - 165)"
CountryRegion5G_10          = "#10 (36 - 48,149 - 165)"
CountryRegion5G_11          = "#11 (36 - 120,149 - 161)"
CountryRegion5G_12          = "#12 (36 - 140)"
CountryRegion5G_13          = "#13 (52 - 161)"
CountryRegion5G_14          = "#14 (36 - 116,136 - 165)"
CountryRegion5G_15          = "#15 (149 - 173)"
CountryRegion5G_16          = "#16 (36 - 173)"
IEEE802_11h                 = "IEEE802.11h"
SmartScan                   = "Multimedia/Gaming Environment"
PSMode                      = "Power Saving Mode"
CAM                         = "CAM"
MAXPSP                      = "Max_PSP"
AdhocNMode                  = "Adhoc support 802.11n"

CHANNEL                     = "6"
WPS_DEVNAME_DEF_STR         = "D-Link Client"
WMMCapable		    = "WMM Capable"
APSDCapable                 = "APSD Capable"
APSDAC_BE                   = "AC_BE support APSD"
APSDAC_BK                   = "AC_BK support APSD"
APSDAC_VI                   = "AC_VI support APSD"
APSDAC_VO                   = "AC_VO support APSD"

FAST_ROAMING_SENSITIVITY_STR = "Roaming Sensitivity"
LOWEST_STR3                 = "Lowest"
MEDIUM_STR3                 = "Medium"
HIGHEST_STR3                = "Highest"

DISABLE_STR                 = "6.Disable"
LOWEST_STR                  = "5.Lowest"
MEDIUM_LOW_STR              = "4.Low"
MEDIUM_STR                  = "3.Medium"
MEDIUM_HIGH_STR             = "2.High"
HIGHEST_STR                 = "1.Highest"