;-----------------------------------------------------
; Installation file (.inf)
;
; Copyright (c) AVerMedia TECHNOLOGIES, Inc.
;-----------------------------------------------------

[Version]
signature="$CHICAGO$" ;all windows os
Class=MEDIA
ClassGUID={4d36e96c-e325-11ce-bfc1-08002be10318}
Provider=%ProviderName%
CatalogFile=AVerTM62.cat
DriverVer=06/26/2013,1.54.0.11

[Manufacturer]
%AVerMedia%=Trident

[Trident]
%TRIDCap.DeviceDesc%=TRIDCap,PCI\VEN_1A0A&DEV_6200&SUBSYS_62031461
%TRIDCap.DeviceDesc%=TRIDCap,PCI\VEN_1A0A&DEV_6202&SUBSYS_62031461

[DestinationDirs]
System32.CopyBins=10,system32
TRIDCap.CopyFiles=10,system32\drivers ; be aware not to use 12 as the drivers directory, 
                                         ; as driver will not work anymore in W98

[SourceDisksNames]
1 = %AVSTRM_INSTALLATION_DISK%,,

[SourceDisksFiles]
AVerTM62.sys=1
customer.bin=1
aver_custom_hdcp_protection.bmp=1
aver_custom_no_signal.bmp=1
aver_custom_out_of_range.bmp=1


[TRIDCap.CopyFiles]
AVerTM62.sys
aver_custom_hdcp_protection.bmp
aver_custom_no_signal.bmp
aver_custom_out_of_range.bmp

[System32.CopyBins]
customer.bin
;
;*** initialisation and registry entries
;

[TRIDCap.nt]
Include=ks.inf, kscaptur.inf, bda.inf, wdmaudio.inf
Needs=KS.Registration.NT,KSCAPTUR.Registration.NT,BDA.Registration.NT,bda.Installation.NT,bdacap.Installation.NT,wdmaudio.Registration.NT
CopyFiles=TRIDCap.CopyFiles,System32.CopyBins
AddReg=TRIDCap.AddReg

[TRIDCap.nt.Services]
AddService=TRIDCap, 0x00000002, TRIDCap.ServiceInstall

[TRIDCap.ServiceInstall]
DisplayName=%DISPLAY_NAME%
Description=%SERVICE_DESCRIPTION%
ServiceType=%SERVICE_KERNEL_DRIVER%
StartType=%SERVICE_DEMAND_START%
ErrorControl=%SERVICE_ERROR_NORMAL%
ServiceBinary=%12%\AVerTM62.sys
; [StartName=driver-object-name]
; [AddReg=add-registry-section[, add-registry-section] ...]
; [DelReg=del-registry-section[, del-registry-section] ...]
; [BitReg=bit-registry-section[,bit-registry-section] ...]
; [LoadOrderGroup=load-order-group-name]
; [Dependencies=depend-on-item-name[,depend-on-item-name]...]

[TRIDCap.AddReg]
HKR,,DevLoader,,*NTKERN
HKR,,NTMPDriver,,AVerTM62.sys

HKLM,SYSTEM\CurrentControlSet\Control\MediaInterfaces\{0A7AF963-6805-4f99-B284-29B680975542},,,"AVerMedia Macrovision Detection Property"
HKLM,SYSTEM\CurrentControlSet\Control\MediaInterfaces\{0A7AF963-6805-4f99-B284-29B680975542},IID,1,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00,00

; audio capture registry entries

HKR,,AssociatedFilters,,"wdmaud,swmidi,redbook"
HKR,,Driver,,AVerTM62.sys
HKR,Drivers,SubClasses,,"wave,mixer"
HKR,Drivers\wave\wdmaud.drv, Driver,,wdmaud.drv
HKR,Drivers\mixer\wdmaud.drv, Driver,,wdmaud.drv
HKR,Drivers\wave\wdmaud.drv,Description,,"AVerMedia audio capture device"
HKR,Drivers\mixer\wdmaud.drv,Description,,"AVerMedia audio capture device"

; add audio input and output pinnames

HKLM,SYSTEM\CurrentControlSet\Control\MediaCategories\%VAMP_ANLG_AUDIO_IN_PIN%,"Name",,"Analog Audioinput"
HKLM,SYSTEM\CurrentControlSet\Control\MediaCategories\%VAMP_ANLG_AUDIO_OUT_PIN%,"Name",,"Audio"
HKLM,SYSTEM\CurrentControlSet\Control\MediaCategories\%VAMP_ANLG_AUDIO_CAP_IN_PIN%,"Name",,%TRIDCap.AnlgAudioCaptureName%
HKLM,SYSTEM\CurrentControlSet\Control\MediaCategories\%VAMP_ANLG_AUDIO_CAP_IN_PIN2%,"Name",,%TRIDCap.AnlgAudioCapNameSnd%
HKLM,SYSTEM\CurrentControlSet\Control\MediaCategories\%VAMP_ANLG_AUDIO_CAP_OUT_PIN%,"Name",,"AVerAudio Capture"

; Driver behaveior
HKR, "Software\Default", "Digital Stream Support",             0x00010001, 0

; XBAR board defaults (two channel)
HKR, "BoardSetting\AnalogSrc1", "XBar Tuner Exist",            0x00010001, 0
HKR, "BoardSetting\AnalogSrc2", "XBar Tuner Exist",            0x00010001, 0

; VIDEO Decoder setting (two channel)
HKR, "Decoder\VideoDecoder1", "Preferred Video Standard",      0x00010001, 1
                                                               
HKR, "Decoder\VideoDecoder2", "Preferred Video Standard",      0x00010001, 1
HKR, "Decoder\VideoDecoder2", "Video Composite Decoder",       0x00000000, "ADI AD9983A"
HKR, "Decoder\VideoDecoder2", "Video S-Video Decoder",         0x00000000, "Silicon Image 9011"
                                                               
HKR, "Decoder\VideoDecoder2", "AD9983A I2C Address",           0x00010001, 0x98
HKR, "Decoder\VideoDecoder2", "GPIO AD9983A PwrDn",            0x00010001, 6
HKR, "Decoder\VideoDecoder2", "AD9983A Default Brightness",    0x00010001, 96
HKR, "Decoder\VideoDecoder2", "AD9983A Default Contrast",      0x00010001, 30

HKR, "Decoder\VideoDecoder2", "SiI9011 I2C Address 1",         0x00010001, 0x60
HKR, "Decoder\VideoDecoder2", "SiI9011 I2C Address 2",         0x00010001, 0x68
HKR, "Decoder\VideoDecoder2", "GPIO SiI9011 Reset",            0x00010001, 7
HKR, "Decoder\VideoDecoder2", "GPIO SiI9011 HotPlug",          0x00010001, 3
HKR, "Decoder\VideoDecoder2", "GPIO SiI9011 Int",              0x00010001, 0

HKR, "Decoder\VideoDecoder2", "IT6603 I2C Address",            0x00010001, 0x90
HKR, "Decoder\VideoDecoder2", "GPIO IT6603 Reset",             0x00010001, 7

; AUDIO Decoder setting (two channel)
HKR, "Decoder\AudioDecoder1", "Audio Decoder",                 0x00000000, "TAD"
                                                               
HKR, "Decoder\AudioDecoder2", "Audio Decoder Needed",          0x00010001, 1                                                               
HKR, "Decoder\AudioDecoder2", "Audio Decoder",                 0x00000000, "WM8739"
HKR, "Decoder\AudioDecoder2", "WM8739 I2C Address",            0x00010001, 0x34
HKR, "Decoder\AudioDecoder2", "TI3101 I2C Address",            0x00010001, 0x30
HKR, "Decoder\AudioDecoder2", "TI3101 Left Volume",            0x00010001, 0x04
HKR, "Decoder\AudioDecoder2", "TI3101 Right Volume",           0x00010001, 0x04
HKR, "Decoder\AudioDecoder2", "GPIO Reset TI3101",             0x00010001, 5

; VIDEO board defaults (two channel)
HKR, "BoardSetting\AnalogSrc1", "Video Tuner",                 0x00010001, 0
HKR, "BoardSetting\AnalogSrc1", "Video Composite",             0x00010001, 1
HKR, "BoardSetting\AnalogSrc1", "Video S-Video",               0x00010001, 2
HKR, "BoardSetting\AnalogSrc2", "Video Tuner",                 0x00010001, 3
HKR, "BoardSetting\AnalogSrc2", "Video Composite",             0x00010001, 4
HKR, "BoardSetting\AnalogSrc2", "Video S-Video",               0x00010001, 5
                                                               
;AUDIO board defaults (two channel)                            
HKR, "BoardSetting\AnalogSrc1", "Audio Tuner",                 0x00010001, 2
HKR, "BoardSetting\AnalogSrc1", "Audio Composite",             0x00010001, 0
HKR, "BoardSetting\AnalogSrc1", "Audio S-Video",               0x00010001, 0
HKR, "BoardSetting\AnalogSrc2", "Audio Tuner",                 0x00010001, 2
HKR, "BoardSetting\AnalogSrc2", "Audio Composite",             0x00010001, 2
HKR, "BoardSetting\AnalogSrc2", "Audio S-Video",               0x00010001, 2

;AUDIO I2S MUX defaults (channel 2)                            
HKR, "BoardSetting\AnalogSrc2", "Audio I2S MUX Type",          0x00000000, "ADI AD1871_A"
HKR, "BoardSetting\AnalogSrc2", "GPIO Audio Composite",        0x00010001, 3
HKR, "BoardSetting\AnalogSrc2", "GPIO Audio S-VIDEO",          0x00010001, 1

;Tuner board defaults
HKR, "BoardSetting\AnalogSrc1",  "Tuner Type",                 0x00000000, "NO TUNER"
                                                               
HKR, "BoardSetting\AnalogSrc2",  "Tuner Type",                 0x00000000, "NO TUNER"
                                                               
HKR, "BoardSetting\DigitalSrc1",  "Tuner Type",                0x00000000, "NO TUNER"

HKR, "BoardSetting\DigitalSrc2",  "Tuner Type",                0x00000000, "NO TUNER"

;IR TYPE 
HKR, "BoardSetting\Default",      "IR TYPE",                   0x00010001, 0


[TRIDCap.Interfaces]
AddInterface=%KSCATEGORY_CAPTURE%,%VAMP_ANLG_CAP_FILTER%,TRIDCap.AnlgCapture,0
AddInterface=%KSCATEGORY_VIDEO%,%VAMP_ANLG_CAP_FILTER%,TRIDCap.AnlgCapture,0
AddInterface=%KSCATEGORY_AUDIO%,%VAMP_ANLG_AUDIO_CAP_FILTER%,TRIDCap.AnlgACapture,0
AddInterface=%KSCATEGORY_CAPTURE%,%VAMP_ANLG_CAP_FILTER_SND%,TRIDCap.AnlgCapSnd,0
AddInterface=%KSCATEGORY_VIDEO%,%VAMP_ANLG_CAP_FILTER_SND%,TRIDCap.AnlgCapSnd,0
AddInterface=%KSCATEGORY_AUDIO%,%VAMP_ANLG_AUDIO_CAP_FILTER_2ND%,TRIDCap.AnlgACapSnd,0
AddInterface=%KSCATEGORY_CROSSBAR%,%VAMP_ANLG_XBAR_FILTER%,TRIDCap.AnlgXBar,0
AddInterface=%KSCATEGORY_CROSSBAR%,%VAMP_ANLG_XBAR_FILTER_SND%,TRIDCap.AnlgXBarSnd,0

[TRIDCap.nt.Interfaces]
AddInterface=%KSCATEGORY_CAPTURE%,%VAMP_ANLG_CAP_FILTER%,TRIDCap.AnlgCapture,0
AddInterface=%KSCATEGORY_VIDEO%,%VAMP_ANLG_CAP_FILTER%,TRIDCap.AnlgCapture,0
AddInterface=%KSCATEGORY_AUDIO%,%VAMP_ANLG_AUDIO_CAP_FILTER%,TRIDCap.AnlgACapture,0
AddInterface=%KSCATEGORY_CAPTURE%,%VAMP_ANLG_CAP_FILTER_SND%,TRIDCap.AnlgCapSnd,0
AddInterface=%KSCATEGORY_VIDEO%,%VAMP_ANLG_CAP_FILTER_SND%,TRIDCap.AnlgCapSnd,0
AddInterface=%KSCATEGORY_AUDIO%,%VAMP_ANLG_AUDIO_CAP_FILTER_2ND%,TRIDCap.AnlgACapSnd,0
AddInterface=%KSCATEGORY_CROSSBAR%,%VAMP_ANLG_XBAR_FILTER%,TRIDCap.AnlgXBar,0
AddInterface=%KSCATEGORY_CROSSBAR%,%VAMP_ANLG_XBAR_FILTER_SND%,TRIDCap.AnlgXBarSnd,0

[TRIDCap.AnlgCapture]
AddReg=TRIDCap.AnlgCapture.AddReg

[TRIDCap.AnlgCapture.AddReg]
HKR,,CLSID,,%KSProxy.CLSID%
HKR,,FriendlyName,,%TRIDCap.AnlgCaptureName%

;Name AnalogAudioCapture is too long for 98 SE.
[TRIDCap.AnlgACapture]
AddReg=TRIDCap.AnlgACapture.AddReg

[TRIDCap.AnlgACapture.AddReg]
HKR,,CLSID,,%KSProxy.CLSID%
HKR,,FriendlyName,,%TRIDCap.AnlgAudioCaptureName%
HKR,"EP\\0",%PKEY_AudioEndpoint_Association%,,%VAMP_ANLG_AUDIO_CAP_IN_PIN%
HKR,"EP\\0",%PKEY_AudioDevice_NeverSetAsDefaultEndpoint%,0x00010001,NeverSetAsDefaultEndpointMaskValue
HKR,"EP\\0",%PKEY_AudioEngine_OEMFormat%,0x00000001, 41,00,00,00,28,00,00,00,FE,FF,02,00,80,BB,00,00,00,EE,02,00,04,00,10,00,16,00,10,00,03,00,00,00,01,00,00,00,00,00,10,00,80,00,00,AA,00,38,9B,71
HKR,"EP\\0",%PKEY_AudioEndpoint_ControlPanelProvider%,,%AUDIOENDPOINT_EXT_UI_CLSID%

[TRIDCap.AnlgCapSnd]
AddReg=TRIDCap.AnlgCapSnd.AddReg

[TRIDCap.AnlgCapSnd.AddReg]
HKR,,CLSID,,%KSProxy.CLSID%
HKR,,FriendlyName,,%TRIDCap.AnlgCaptureNameSnd%

[TRIDCap.AnlgACapSnd]
AddReg=TRIDCap.AnlgACapSnd.AddReg

[TRIDCap.AnlgACapSnd.AddReg]
HKR,,CLSID,,%KSProxy.CLSID%
HKR,,FriendlyName,,%TRIDCap.AnlgAudioCapNameSnd%
HKR,"EP\\0",%PKEY_AudioEndpoint_Association%,,%VAMP_ANLG_AUDIO_CAP_IN_PIN2%
HKR,"EP\\0",%PKEY_AudioDevice_NeverSetAsDefaultEndpoint%,0x00010001,NeverSetAsDefaultEndpointMaskValue
HKR,"EP\\0",%PKEY_AudioEngine_OEMFormat%,0x00000001, 41,00,00,00,28,00,00,00,FE,FF,02,00,80,BB,00,00,00,EE,02,00,04,00,10,00,16,00,10,00,03,00,00,00,01,00,00,00,00,00,10,00,80,00,00,AA,00,38,9B,71
HKR,"EP\\0",%PKEY_AudioEndpoint_ControlPanelProvider%,,%AUDIOENDPOINT_EXT_UI_CLSID%

[TRIDCap.AnlgXBar]
AddReg=TRIDCap.AnlgXBar.AddReg

[TRIDCap.AnlgXBar.AddReg]
HKR,,CLSID,,%KSXBar.CLSID%
HKR,,FriendlyName,,%TRIDCap.AnlgXBarName%

[TRIDCap.AnlgXBarSnd]
AddReg=TRIDCap.AnlgXBarSnd.AddReg

[TRIDCap.AnlgXBarSnd.AddReg]
HKR,,CLSID,,%KSXBar.CLSID%
HKR,,FriendlyName,,%TRIDCap.AnlgXBarNameSnd%

;
;*** strings, GUIDs and names
;

[Strings]

; Proxy GUIDs

KSProxy.CLSID   = "{17CCA71B-ECD7-11D0-B908-00A0C9223196}"
KSXBar.CLSID    = "{71F96460-78F3-11d0-A18C-00A0C9118956}"

; Category GUIDs

KSCATEGORY_CAPTURE                = "{65E8773D-8F56-11D0-A3B9-00A0C9223196}"
KSCATEGORY_VIDEO                  = "{6994AD05-93EF-11D0-A3CC-00A0C9223196}"
KSCATEGORY_AUDIO                  = "{6994AD04-93EF-11D0-A3CC-00A0C9223196}"
KSCATEGORY_CROSSBAR               = "{a799a801-a46d-11d0-a18c-00a02401dcd4}"

; Our Pin GUIDs

VAMP_ANLG_AUDIO_IN_PIN  = "{93F851D6-502F-4fbe-AFA4-64B85C7AAEAA}"
VAMP_ANLG_AUDIO_OUT_PIN = "{A8724073-0158-45ee-AC38-309346B3016A}"
VAMP_ANLG_AUDIO_CAP_IN_PIN  = "{3cf1005e-ac1a-4031-a7f1-6318324e7151}"
VAMP_ANLG_AUDIO_CAP_IN_PIN2  = "{8410b4b3-c6b2-4ba1-96dd-7076d29d2f84}"
VAMP_ANLG_AUDIO_CAP_OUT_PIN = "{ba6e3349-a3d9-4c2c-b365-6a967321524f}"

; Our Filter GUIDs

VAMP_ANLG_CAP_FILTER         = "{CA465100-DEB0-4d59-818F-8C477184ADF6}"
VAMP_ANLG_CAP_FILTER_SND     = "{EDE957B0-EAA5-4bf4-ACF3-6E10CB4836C3}"
VAMP_ANLG_XBAR_FILTER        = "{8A0971B9-778F-40e5-885C-CD2E29C305EF}"
VAMP_ANLG_XBAR_FILTER_SND    = "{C0588636-3ADC-4a9a-9373-E9BB446F1AFB}"
VAMP_ANLG_AUDIO_CAP_FILTER      = "{A10648AD-0BFC-411e-B869-37799973B5FF}"
VAMP_ANLG_AUDIO_CAP_FILTER_2ND  = "{767E6B89-17D7-458b-BAA3-C480640B7F0E}"

AUDIOENDPOINT_EXT_UI_CLSID	= "{6C57B2A2-91F5-4B90-93D5-FAB82485ECA6}"
PKEY_AudioEndpoint_ControlPanelProvider = "{1DA5D803-D492-4EDD-8C23-E0C0FFEE7F0E},1"
PKEY_AudioEndpoint_Association          = "{1DA5D803-D492-4EDD-8C23-E0C0FFEE7F0E},2"
PKEY_AudioEngine_OEMFormat              = "{E4870E26-3CC5-4CD2-BA46-CA0A9A70ED04},3"
PKEY_AudioDevice_NeverSetAsDefaultEndpoint = "{F3E80BEF-1723-4FF2-BCC4-7F83DC5E46D4},3"

; Our Interface GUIDs

; system defines

SERVICE_BOOT_START   = 0x0 
SERVICE_SYSTEM_START = 0x1 
SERVICE_AUTO_START   = 0x2 
SERVICE_DEMAND_START = 0x3 
SERVICE_DISABLED     = 0x4 

SERVICE_KERNEL_DRIVER  = 0x1 
SERVICE_ERROR_IGNORE   = 0x0 
SERVICE_ERROR_NORMAL   = 0x1 
SERVICE_ERROR_SEVERE   = 0x2
SERVICE_ERROR_CRITICAL = 0x3 

FLG_REGSVR_DLLREGISTER = 0x00000001

;Our strings

ProviderName="AVerMedia TECHNOLOGIES, Inc."
AVerMedia="AVerMedia TECHNOLOGIES, Inc."
TRIDCap.DeviceDesc       = "AVerMedia C727 PCIe HD Capture Device"
AVSTRM_INSTALLATION_DISK = "AVStrm installation disk"
DISPLAY_NAME             = "AVerMedia service"
SERVICE_DESCRIPTION      = "The AVerMedia capture driver"

;Our Friendly Names

TRIDCap.AnlgCaptureName    = "AVerMedia SD Capture"
TRIDCap.AnlgCaptureNameSnd = "AVerMedia HD Capture"
TRIDCap.AnlgXBarName       = "AVerMedia SD Xbar"
TRIDCap.AnlgXBarNameSnd    = "AVerMedia HD Xbar"
TRIDCap.AnlgAudioCaptureName = "AVerMedia SD Audio Cap"
TRIDCap.AnlgAudioCapNameSnd  = "AVerMedia HD Audio Cap"
