;
; 5U877.inf - 5U877 UVC driver
;
; Copyright (c) 2010 Ricoh Co.,Ltd.  All rights reserved.

[Version]
Signature      = "$CHICAGO$"
Class          = Image
ClassGUID      = {6bdd1fc6-810f-11d0-bec7-08002be2092f}
Provider       = %Ricoh%
CatalogFile.NT = 5U877.cat
DriverVer      = 12/21/2010,1.1.0.41

[ControlFlags]
ExcludeFromSelect = *

[SourceDisksNames]
1 = %Package%

[SourceDisksFiles.x86]
5U877x32.sys = 1,,
5U877x32.ax  = 1,,
5U877x32.dll = 1,,

[SourceDisksFiles.amd64]
5U877x64.sys = 1,,
5U877x64.dll = 1,,
5U877x32.ax  = 1,,
5U877x64.ax  = 1,,

[DestinationDirs]
System32 = 11
System64 = 11
SysWoW32 = 10,SysWOW64
Drivers32 = 12
Drivers64 = 12

[System32]
%5U877ExtensionDLL%,5U877x32.ax

[System64]
%5U877ExtensionDLL%,5U877x64.ax

[SysWoW32]
%5U877ExtensionDLL%,5U877x32.ax

[Drivers32]
5U877.sys,5U877x32.sys

[Drivers64]
5U877.sys,5U877x64.sys

[CoInstaller32]
5U877.dll,5U877x32.dll,,0x00000004

[CoInstaller64]
5U877.dll,5U877x64.dll,,0x00000004

[Manufacturer]
%Ricoh% = Ricoh,NTx86.5.1,NTamd64.5.1,NTx86.6.0,NTamd64.6.0

[Ricoh.NTx86.5.1]
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480D
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480E
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480F
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_4816

[Ricoh.NTamd64.5.1]
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480D
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480E
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480F
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_4816

[Ricoh.NTx86.6.0]
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480D&MI_00
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480E&MI_00
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480F&MI_00
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_4816&MI_00

[Ricoh.NTamd64.6.0]
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480D&MI_00
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480E&MI_00
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_480F&MI_00
%5U877.DeviceDesc% = 5U877,    USB\Vid_17EF&Pid_4816&MI_00

; dshowext.inf is not in WindowsXP64
;  Interfaces of ICustomCameraProp, IStillStreamConfig and
;  propertypages of VideoProcAmp Property Page, CustomCamera Property Page, StillStreamConfig Property Page
;  are registered by DSHOWEXT.Registration of dshowext.inf.
; This driver dosen't use these.
[5U877.NTx86]
Include       = ks.inf, kscaptur.inf
Needs         = KS.Registration, KSCAPTUR.Registration.NT
AddReg        = 5U877.AddReg, 5U877.Settings
CopyFiles     = Drivers32, System32
;WIA
SubClass      = %DeviceSubClass%
DeviceType    = %DeviceType%
DeviceSubType = %DeviceSubType%
Capabilities  = %DeviceCap%
DeviceData    = 5U877.DeviceData
ICMProfiles   = %ICM_sRGB%

[5U877.NTx86.CoInstallers]
AddReg        = CoInstaller.AddReg
CopyFiles     = CoInstaller32

[5U877.NTamd64]
Include       = ks.inf, kscaptur.inf
Needs         = KS.Registration, KSCAPTUR.Registration.NT
AddReg        = 5U877.AddReg, 5U877.Plugins.Wow6432, 5U877.Settings
CopyFiles     = Drivers64, System64, SysWoW32
;WIA
SubClass      = %DeviceSubClass%
DeviceType    = %DeviceType%
DeviceSubType = %DeviceSubType%
Capabilities  = %DeviceCap%
DeviceData    = 5U877.DeviceData
ICMProfiles   = %ICM_sRGB%

[5U877.NTamd64.CoInstallers]
AddReg        = CoInstaller.AddReg
CopyFiles     = CoInstaller64

[CoInstaller.AddReg]
HKR,,CoInstallers32,0x10000,"5U877.dll,CoInstProc"
; FriendlyName for FS
HKR,,FriendlyName,0x10000,%5U877.DeviceDesc%

[5U877.DeviceData]
Server      = local
UI DLL      = sti.dll
UI Class ID = %CLSID_PSFactoryBuffer%

[5U877.AddReg]
; WIA
HKR,,HardwareConfig,1,1
HKR,,USDClass,,%CLSID_WIA_VideoSnapshotUSD%

; Interface Handler
HKCR,CLSID\%XU_GUID%,,,%InterfaceHandler%
HKCR,CLSID\%XU_GUID%\InprocServer32,,,%5U877ExtensionDLL%
HKCR,CLSID\%XU_GUID%\InprocServer32,ThreadingModel,,Both
; Media Interface
HKLM,System\CurrentControlSet\Control\MediaInterfaces\%XU_GUID%,,,%InterfaceHandler%
HKLM,System\CurrentControlSet\Control\MediaInterfaces\%XU_GUID%,IID,1,0a,3e,18,74,82,54,1a,48,b4,02,48,b8,b8,c4,9c,c8

; Property Page
HKCR,CLSID\%CLSID_PropPage%,,,%PlugIn_IExtensionUnit%
HKCR,CLSID\%CLSID_PropPage%\InprocServer32,,,%5U877ExtensionDLL%
HKCR,CLSID\%CLSID_PropPage%\InprocServer32,ThreadingModel,,Both
; Media Sets
HKLM,System\CurrentControlSet\Control\MediaSets\%XU_GUID%\PropertyPages\%CLSID_PropPage%,,,%PropPage%

[5U877.Plugins.Wow6432]
; Interface Handler
HKCR,Wow6432Node\CLSID\%XU_GUID%,,,%InterfaceHandler%
HKCR,Wow6432Node\CLSID\%XU_GUID%\InprocServer32,,,%5U877ExtensionDLL%
HKCR,Wow6432Node\CLSID\%XU_GUID%\InprocServer32,ThreadingModel,,Both

; Property Page
HKCR,Wow6432Node\CLSID\%CLSID_PropPage%,,,%PlugIn_IExtensionUnit%
HKCR,Wow6432Node\CLSID\%CLSID_PropPage%\InprocServer32,,,%5U877ExtensionDLL%
HKCR,Wow6432Node\CLSID\%CLSID_PropPage%\InprocServer32,ThreadingModel,,Both

[5U877.Settings]
; Driver loader setting
HKR,,DevLoader,,*ntkern
HKR,,NTMPDriver,,5U877.sys
HKR,,PageOutWhenUnopened,3,00
HKR,,PowerDownWhenUnopened,3,00

; Environment variables
HKR, DriverSettings, EnvironmentVariables, %FLG_ADDREG_TYPE_MULTI_SZ%, SystemDrive=%24%
HKR, DriverSettings, EnvironmentVariables, %FLG_APDREG_TYPE_MULTI_SZ%, SystemRoot=%10%
HKR, DriverSettings, EnvironmentVariables, %FLG_APDREG_TYPE_MULTI_SZ%, ProgramFiles=%16422%

; SRB timeout [sec.]
; default value = 5 (0=disable)
;HKR, DriverSettings, SrbTimeout,               %FLG_ADDREG_TYPE_DWORD%, 5

; Selective Suspend [sec.]
; default value = 25 (0=disable)
HKR, DriverSettings, SelectiveSuspendTime,     %FLG_ADDREG_TYPE_DWORD%, 2

; Direction of camera device installation
; The angle is direction of the installation of the camera device seen from the user.
;	Front side : user <) -><- (] camera
;HKR, DriverSettings, DeviceDirection,          %FLG_ADDREG_TYPE_DWORD%, 0 ;   0[degree] default
;HKR, DriverSettings, DeviceDirection,          %FLG_ADDREG_TYPE_DWORD%, 1 ;  90[degree]
;HKR, DriverSettings, DeviceDirection,          %FLG_ADDREG_TYPE_DWORD%, 2 ; 180[degree]
;HKR, DriverSettings, DeviceDirection,          %FLG_ADDREG_TYPE_DWORD%, 3 ; 270[degree]
;	Back side  : user <) ->[) -> camera
HKR, DriverSettings, DeviceDirection,          %FLG_ADDREG_TYPE_DWORD%, 4 ;   0[degree]
;HKR, DriverSettings, DeviceDirection,          %FLG_ADDREG_TYPE_DWORD%, 5 ;  90[degree]
;HKR, DriverSettings, DeviceDirection,          %FLG_ADDREG_TYPE_DWORD%, 6 ; 180[degree]
;HKR, DriverSettings, DeviceDirection,          %FLG_ADDREG_TYPE_DWORD%, 7 ; 270[degree]

; When the frame is processed, this value is an image update interval
; default value = 4
; - Image direction is 90[deg] or 270[deg]
; - Digital zoom by driver
HKR, DriverSettings, FrameProcessDenominator,  %FLG_ADDREG_TYPE_DWORD%, 2

; When the image format convert from YUY2 to RGB24, this value is an image update interval
; default value = 0(not support image format convert from YUY2 to RGB24)
HKR, DriverSettings, ConvertRGB24Denominator,  %FLG_ADDREG_TYPE_DWORD%, 1

; When the image format convert from YUY2 to I420, this value is an image update interval
; default value = 0(not support image format convert from YUY2 to I420)
;HKR, DriverSettings, ConvertI420Denominator,  %FLG_ADDREG_TYPE_DWORD%, 1

; When the image format convert from YUY2 to IYUV, this value is an image update interval
; default value = 0(not support image format convert from YUY2 to IYUV)
;HKR, DriverSettings, ConvertIYUVDenominator,  %FLG_ADDREG_TYPE_DWORD%, 1

; Zoom type
; ZoomType[Width]x[Height] : Image size specific setting
; 0=Disable / 1=Enable
; default value = 1
HKR, DriverSettings, ZoomType1600x1200,        %FLG_ADDREG_TYPE_DWORD%, 0

; Roll type
; 0 = reduce / 1 = zoom / 2=same magnification
; default value = 0
HKR, DriverSettings, RollType,                 %FLG_ADDREG_TYPE_DWORD%, 0
; Color of space when reduce or same magnification
; default value = 0
HKR, DriverSettings, PaddingColor_Red,          %FLG_ADDREG_TYPE_DWORD%, 0
HKR, DriverSettings, PaddingColor_Green,        %FLG_ADDREG_TYPE_DWORD%, 0
HKR, DriverSettings, PaddingColor_Blue,         %FLG_ADDREG_TYPE_DWORD%, 0

; Frame data recieve setting
HKR, DriverSettings, FrameDataSizeOverLimit,   %FLG_ADDREG_TYPE_DWORD%, 32
HKR, DriverSettings, DropUncompressSizeLess,   %FLG_ADDREG_TYPE_DWORD%, 0
HKR, DriverSettings, DropBrokenJPEG,           %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, DriverSettings, IsochPerRequest_YUY2,     %FLG_ADDREG_TYPE_DWORD%, 256
;HKR, DriverSettings, IsochRequestCount_YUY2,   %FLG_ADDREG_TYPE_DWORD%, 2
;HKR, DriverSettings, IsochPerRequest_MJPG,     %FLG_ADDREG_TYPE_DWORD%, 256
;HKR, DriverSettings, IsochRequestCount_MJPG,   %FLG_ADDREG_TYPE_DWORD%, 2

; Directory for replacement image data of privacy mode
; default value = (none)
HKR, DriverSettings, PrivacyImageDirectory,    %FLG_ADDREG_TYPE_EXPAND_SZ%, "%ProgramFiles%\Lenovo\CameraPrivacyImage\RICOH"
; Registry setting that selects replacement image data of privacy mode
HKR, DriverSettings, RegSelectPrivacyImagePath, %FLG_ADDREG_TYPE_SZ%, \Registry\machine\SOFTWARE\Lenovo\CameraPrivacyImage
HKR, DriverSettings, RegSelectPrivacyImageValue,%FLG_ADDREG_TYPE_SZ%, PrivacyImage

; Property control setting
; +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
; |ChgToManual|                               (reserved)                              |   Mode    |
; +--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+--+
;  31       28 27       24 23                   16 15                    8  7        4  3        0
;
; [ChgToManual] (ChgToManual is not referenced in this version)
; The manual setting value when the automatic setting is released is specified.
; (This setting is effective only to property with the automatic setting function.)
; 0=The value adjusted by the automatic setteing is used.
; 1=The value that had been set before the automatic setting is made effective is used.
; 2=The default value is used.
; (Set values from 3 to 15 is the same sa set value 0.)
;
; [Mode]
; The processing of the current value of property is set.
; 0=Disable
; 1=Use current value in device.
; 2=Use current value in registory.
; 3=When installing this package, the default values are set in current values.
;   (When 5U877.sys diver starts, this value is changed to 1)
; 4=When installing this package, the default values are set in current values.
;   (When 5U877.sys diver starts, change value to 2)
; 5=When 5U877.sys diver starts, the default values are set in current values.
; 6=When the movie capture begins, the default values are set in current values.
; (Set values from 7 to 15 are the same sa set value 0.)
;
; default value = 0x00000001
HKR, PropertySettings, PropertyControl,          %FLG_ADDREG_TYPE_DWORD%, 0x00000002

; Properties settings
; (PropertyName)Ctl : Property control setting
;                     default value = PropertyControl
; (PropertyName)Min : Minimum value
;                     default value = in device value
; (PropertyName)Max : Maximum value
;                     default value = in device value
; (PropertyName)Res : Stepping delta
;                     default value = in device value
; (PropertyName)Def : Default setting value
;                     default value = in device value
; (PropertyName)    : Current setting value (for PropertyControl = 1)
;                     default value = in device value
;HKR, PropertySettings, BrightnessDef,            %FLG_ADDREG_TYPE_DWORD%, 63
;HKR, PropertySettings, ContrastDef,              %FLG_ADDREG_TYPE_DWORD%, 63
;HKR, PropertySettings, SaturationDef,            %FLG_ADDREG_TYPE_DWORD%, 63
;HKR, PropertySettings, SharpnessDef,             %FLG_ADDREG_TYPE_DWORD%, 7
;HKR, PropertySettings, WhiteBalanceTempDef,      %FLG_ADDREG_TYPE_DWORD%, 5000
;HKR, PropertySettings, WhiteBalanceCompDef,      %FLG_ADDREG_TYPE_DWORD%, 127
;HKR, PropertySettings, AutoWhiteBalanceDef,      %FLG_ADDREG_TYPE_DWORD%, 1
;HKR, PropertySettings, HueDef,                   %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, AutoHueCtl,               %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, GammaDef,                 %FLG_ADDREG_TYPE_DWORD%, 100
;HKR, PropertySettings, ColorEnableDef,           %FLG_ADDREG_TYPE_DWORD%, 1
;HKR, PropertySettings, ExposureTimeDef,          %FLG_ADDREG_TYPE_DWORD%, 333
;HKR, PropertySettings, AutoExposureDef,          %FLG_ADDREG_TYPE_DWORD%, 1
HKR, PropertySettings, GainCtl,                  %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, GainDef,                  %FLG_ADDREG_TYPE_DWORD%, 63
;HKR, PropertySettings, AutoGainDef,              %FLG_ADDREG_TYPE_DWORD%, 1
;HKR, PropertySettings, FocusDef,                 %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, AutoFocusDef,             %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, PowerLineFrequencyCtl,    %FLG_ADDREG_TYPE_DWORD%, 6
;HKR, PropertySettings, PowerLineFrequencyDef,    %FLG_ADDREG_TYPE_DWORD%, 1
HKR, PropertySettings, AutoFlickerDetectionCtl,  %FLG_ADDREG_TYPE_DWORD%, 2
;HKR, PropertySettings, AutoFlickerDetectionDef,  %FLG_ADDREG_TYPE_DWORD%, 1
;HKR, PropertySettings, BacklightCompensationDef, %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, ZoomDef,                  %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, PanDef,                   %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, TiltDef,                  %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, FlipDef,                  %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, MirrorDef,                %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, PrivacyDef,               %FLG_ADDREG_TYPE_DWORD%, 0
HKR, PropertySettings, AutoExposurePriorityDef,  %FLG_ADDREG_TYPE_DWORD%, 1
;HKR, PropertySettings, Extension1Ctl,            %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, Extension2Ctl,            %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, Extension3Ctl,            %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, Extension4Ctl,            %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, Extension5Ctl,            %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, Extension6Ctl,            %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, Extension7Ctl,            %FLG_ADDREG_TYPE_DWORD%, 0
;HKR, PropertySettings, Extension8Ctl,            %FLG_ADDREG_TYPE_DWORD%, 0

; WhiteBalanceComponent type
; 0=Red+Blue(ProcessingUnit is used by priority) / 1=Red+Green+Blue(ExtensionUnit)
; default value = 0
HKR, PropertySettings, WhiteBalanceCompType,     %FLG_ADDREG_TYPE_DWORD%, 1

; Usage of low light setting
; 0=Auto setting by AutoExposure and ImageQuality / 1=GUI can be used
; default value = 1
HKR, PropertySettings, UseLowLightControl,       %FLG_ADDREG_TYPE_DWORD%, 0

[5U877.NTx86.Interfaces]
AddInterface = %KSCATEGORY_CAPTURE%,GLOBAL,5U877.Interface

[5U877.NTamd64.Interfaces]
AddInterface = %KSCATEGORY_CAPTURE%,GLOBAL,5U877.Interface

[5U877.Interface]
AddReg = 5U877.Interface.AddReg

[5U877.Interface.AddReg]
HKR,,CLSID,,%CLSID_ProxyVCap%
HKR,,FriendlyName,,%5U877.DeviceDesc%

HKR,,ExtensionDLL,,%5U877ExtensionDLL%
HKR,PinFactory\1\Interfaces\{D3ABC7E0-9A61-11d0-A40D-00A0C9223196},,,
HKR,PageAliases,"{71F96464-78F3-11d0-A18C-00A0C9118956}",1,E1,E5,93,91,33,6D,69,4C,8D,CD,38,84,44,2A,E5,5D
HKR,PageAliases,"{71F96465-78F3-11d0-A18C-00A0C9118956}",1,E1,E5,93,91,33,6D,69,4C,8D,CD,38,84,44,2A,E5,5D

[5U877.NTx86.Services]
AddService = 5U877, %SPSVCINST_ASSOCSERVICE%, 5U877.ServiceInstall

[5U877.NTamd64.Services]
AddService = 5U877, %SPSVCINST_ASSOCSERVICE%, 5U877.ServiceInstall

[5U877.ServiceInstall]
DisplayName   = %USBVideo.SvcDesc%
ServiceType   = %SERVICE_KERNEL_DRIVER%
StartType     = %SERVICE_DEMAND_START%
ErrorControl  = %SERVICE_ERROR_NORMAL%
ServiceBinary = %12%\5U877.sys

[Strings]
; (Non-localizable)
5U877ExtensionDLL                    = "5U877.ax"
SubKey_NodeInterface                 = "System\CurrentControlSet\Control\NodeInterfaces"
CLSID_PSFactoryBuffer                = "{4DB1AD10-3391-11D2-9A33-00C04FA36145}"
XU_GUID                              = "{74183E0A-5482-481A-B402-48B8B8C49CC8}"
CLSID_PropPage                       = "{9193E5E1-6D33-4c69-8DCD-3884442AE55D}"
CLSID_ProxyVCap                      = "{17CCA71B-ECD7-11D0-B908-00A0C9223196}"
KSCATEGORY_RENDER                    = "{65E8773E-8F56-11D0-A3B9-00A0C9223196}"
KSCATEGORY_CAPTURE                   = "{65E8773D-8F56-11D0-A3B9-00A0C9223196}"
KSCATEGORY_VIDEO                     = "{6994AD05-93EF-11D0-A3CC-00A0C9223196}"
DeviceSubClass                       = "StillImage"
DeviceType                           = 3
DeviceSubType                        = 0x1
DeviceCap                            = 0x00000031
ICM_sRGB                             = "sRGB Color Space Profile.icm"
CLSID_WIA_VideoSnapshotUSD           = "{0527d1d0-88c2-11d2-82c7-00c04f8ec183}"
FLG_ADDREG_TYPE_SZ                   = 0x00000000
FLG_ADDREG_TYPE_MULTI_SZ             = 0x00010000
FLG_APDREG_TYPE_MULTI_SZ             = 0x00010008
FLG_ADDREG_TYPE_EXPAND_SZ            = 0x00020000
FLG_ADDREG_TYPE_DWORD                = 0x00010001
WORKAROUNDS_VARIABLE_FRAME_RATE_MASK = 0x00000010
SPSVCINST_ASSOCSERVICE               = 0x00000002
SERVICE_KERNEL_DRIVER                = 1
SERVICE_DEMAND_START                 = 3
SERVICE_ERROR_NORMAL                 = 1
; (Localizable)
Ricoh                                = "Ricoh"
Package                              = "Ricoh 5U877 Installation Package"
5U877.DeviceDesc                     = "Integrated Camera"
USBVideo.SvcDesc                     = "USB Video Device"
PlugIn_IExtensionUnit                = "Ricoh 5U877 Extension Unit Interface"
InterfaceHandler                     = "Ricoh 5U877 Extension Unit Interface"
PropPage                             = "Ricoh 5U877 Property Page"
