;*   Copyright 2000-2013 Golden Tulip
;**     File:   Sbserial.inf
;**		      
;**	Description:
;**             Installs the serial ports behind a PCI bridge
;**      
;************************************************************/

[Version]
signature="$Windows NT$"
Class=Ports
ClassGuid={4D36E978-E325-11CE-BFC1-08002BE10318}
Provider=%mfg%
CatalogFile=sbmp.cat		
DriverVer=10/24/2014, 1.716.01.002

[DestinationDirs]
DefaultDestDir  = 11        		;LDID_SYS


[SourceDisksFiles]
sb_coinstall.dll=1


; Install class "Ports"
;----------------------------------------------------------
[ClassInstall]
AddReg=PortsClass.AddReg

[PortsClass.AddReg]
HKR,,,,%PortsClassName%

[ClassInstall.NT]
AddReg=PortsClass.NT.AddReg

[PortsClass.NT.AddReg]
HKR,,,,%PortsClassName%
HKR,,Icon,,"-23"
HKR,,Installer32,,"MsPorts.Dll,PortsClassInstaller"

; Drivers
;----------------------------------------------------------
[Manufacturer]
%mfg%=mfg,NTamd64

[mfg.NTamd64]
%ComPort.DeviceDesc% =	ComPort,	SBMP\*PNP0501
%ECPPortName%        =	ECPPort,	SBMP\*PNP0503

[ControlFlags]
ExcludeFromSelect=*



;----------------------------------------
; ECPPort Install
;----------------------------------------
[ECPPort.NT]
AddReg=ECPPort.AddReg,LptPort.NT.AddReg

[ECPPort.NT.HW]
AddReg=ECPPort.NT.HW.AddReg

[ECPPort.NT.HW.AddReg]
HKR,,"UpperFilters",	0x00010008,	"Sbmpf"	;;APPEND
HKR,,"ModeSelected",0x00000000,"1"

[ECPPort.NT.Services]
AddService = SBPar, 0x00000002, SBPar_Service_Inst, SBPar_EventLog_Inst ; Port Driver (function driver for this device)
AddService = Sbmpf,,SBPar_Sbmpf_Service_Inst

;----------------------------------------
; other sections
;----------------------------------------

[ECPPort.AddReg]
HKR,,PortSubClass,1,00
HKR,,ECPDevice,1,01

[LptPort.NT.AddReg]
HKR,,EnumPropPages32,,"msports.dll,ParallelPortPropPageProvider" 



; -------------- Parallel Port Driver install sections

[SBPar_Service_Inst]
DisplayName    = %ECPPortName%
ServiceType    = 1                ; SERVICE_KERNEL_DRIVER
StartType      = 1                ; SERVICE_DEMAND_START 
ErrorControl   = 0                ; SERVICE_ERROR_IGNORE 
ServiceBinary  = %12%\SBPar.sys
LoadOrderGroup = Parallel arbitrator

[SBPar_Sbmpf_Service_Inst]
DisplayName    = %Sbmpf.SVCDESC%
ServiceType    = 1               ; SERVICE_KERNEL_DRIVER
StartType      = 3               ; SERVICE_DEMAND_START
ErrorControl   = 1               ; SERVICE_ERROR_NORMAL
ServiceBinary  = %12%\Sbmpf.sys
LoadOrderGroup = PNP Filter

[SBPar_EventLog_Inst]
AddReg = SBPar_EventLog_AddReg

[SBPar_EventLog_AddReg]
HKR,,EventMessageFile,0x00020000,"%%SystemRoot%%\System32\IoLogMsg.dll;%%SystemRoot%%\System32\drivers\SBPar.sys"
HKR,,TypesSupported,0x00010001,7

; ************** install serial ports ***********************
[ComPort]
DriverVer=10/24/2014, 1.716.01.002
CopyFiles=ComPort.Copy
AddReg=ComPort.AddReg, ComPort.W95.AddReg

[ComPort.NT]
AddReg=ComPort.AddReg, ComPort.NT.AddReg

[ComPort.NT.HW]
AddReg=ComPort.NT.HW.AddReg

[ComPort.NT.HW.AddReg]
HKR,,"UpperFilters",	0x00010000,	"serenum" 	;;MULTI_SZ
HKR,,"UpperFilters",	0x00010008,	"Sbmpf"	;;APPEND
HKR,,"95xSpecific",	0x00000001,01,00,00,00,00,00,c9,16,20,00,01,00,04,64,10,70,08,00,00,00,00,00,00,10
HKR,,"ClockRate",	0x00010001, 1843200
HKR,,"MultiportProperties",0x00010001, 1
;HKR,,"SkipEnumerations",0x00010001, -1

[ComPort.AddReg]
HKR,,PortSubClass,1,01

[ComPort.W95.AddReg]
HKR,,DevLoader,,*vcomm
HKR,,Enumerator,,serenum.vxd
HKR,,PortDriver,,sbser.vxd
HKR,,ConfigDialog,,sbserui.dll
HKR,,DCB,3,1c,00,00,00,80,25,00,00,11,33,00,00,00,00,0a,00,0a,00,08,00,00,11,13,00,00,00
HKR,,950Specific,3,00,01,08,10,04,40,40,78,12,14,00,00,00,01,00,00
HKR,,EnumPropPages,,"sbserui.dll,EnumPropPages"

[ComPort.NT.AddReg]
;HKR,,EnumPropPages32,,"Sbui.dll,SerialPropPageProvider"
HKR,,EnumPropPages32,,"msports.dll,SerialPortPropPageProvider"
HKLM,%ParametersSubKey%, SysbasFlags,   0x00010001,     0

;-------------- Coinstaller installation
[ComPort.NT.CoInstallers]
AddReg=CoInstaller_AddReg
CopyFiles=CoInstaller_CopyFiles

[CoInstaller_CopyFiles]
sb_coinstall.dll

[CoInstaller_AddReg]
HKR,,CoInstallers32,0x00010000,"sb_coinstall.dll,Serial_CoInstaller"



[ToastCoInfo]
OriginalInfSourcePath = %1%

;-------------- Service installation
; Port Driver (function driver for this device)
[ComPort.NT.Services]
AddService = Sbserial, 0x00000002, Sbserial_Service_Inst, Sbserial_EventLog_Inst
AddService = Sbmpf,,Sbmpf_Service_Inst
AddService = Serenum,,Serenum_Service_Inst

; -------------- Serial Port Driver install sections
[Sbserial_Service_Inst]
DisplayName    = %Sbserial.SVCDESC%
ServiceType    = 1               ; SERVICE_KERNEL_DRIVER
StartType      = 1               ; SERVICE_SYSTEM_START (this driver may do detection)
ErrorControl   = 0               ; SERVICE_ERROR_IGNORE
ServiceBinary  = %12%\Sbserial.sys
LoadOrderGroup = Extended base

; -------------- Serenum Driver install section
[Serenum_Service_Inst]
DisplayName    = %Serenum.SVCDESC%
ServiceType    = 1               ; SERVICE_KERNEL_DRIVER
StartType      = 3               ; SERVICE_DEMAND_START
ErrorControl   = 1               ; SERVICE_ERROR_NORMAL
ServiceBinary  = %12%\serenum.sys
LoadOrderGroup = PNP Filter

[Sbmpf_Service_Inst]
DisplayName    = %Sbmpf.SVCDESC%
ServiceType    = 1               ; SERVICE_KERNEL_DRIVER
StartType      = 3               ; SERVICE_DEMAND_START
ErrorControl   = 1               ; SERVICE_ERROR_NORMAL
ServiceBinary  = %12%\Sbmpf.sys
LoadOrderGroup = PNP Filter

[Sbserial_EventLog_Inst]
AddReg = Sbserial_EventLog_AddReg

[Sbserial_EventLog_AddReg]
HKR,,EventMessageFile,0x00020000,"%%SystemRoot%%\System32\IoLogMsg.dll;%%SystemRoot%%\System32\drivers\Sbserial.sys"
HKR,,TypesSupported,0x00010001,7


[ComPort.PosDup]
*PNP0501

[SourceDisksNames]
1=%drvdisk%,,



[Strings]
mfg 				= " "
PortsClassName 		= "Ports (COM & LPT)"
drvDisk				= "High-performance ports driver disk"
ComPort.DeviceDesc 	= "Enhanced/PCI - Serial Port"
ComPort.DeviceDesc2	= "High Speed Communications Port"
Sbserial.SVCDESC    = "Enhanced Serial driver 1.716"
Serenum.SVCDESC 	= "Serenum Filter Driver"
Sbmpf.SVCDESC 		= "Filter driver for Enhanced 1.716"
ParametersSubKey    = "SYSTEM\CurrentControlSet\Services\Sbserial\Parameters"
ECPPortName			= "Enhanced/PCI - Parallel Port"