阅读:1666回复:1
Win2K下过滤驱动的Inf文件问题
各位大虾我在尝试使用过滤驱动程序获得USB事件时出现下一个问题,我使用DS做了下一个过滤程序在编译成功后,用Inf安装时在Win98下没有问题。但Win2K下安装后总是提示注册表错误,错误代码为19。Inf文件附后请指教。
; ; INF.TXT ; ; This file is part of the FILTER sample filter driver in the ; Windows 2000 DDK. It is not a complete INF file. ; It lists the sections of your INF file that you need to ; change in order to have a filter driver loaded for your device. ; [Version] Signature=\"$CHICAGO$\" Class=HID ClassGUID={745a17a0-74d3-11d0-b6fe-00a0c90f57da} Provider=%USBDBE% LayoutFile=layout.inf DriverVer=11/12/2001,4.10.2222.12 [Manufacturer] \"ThisVendor\"=THIS_VENDOR [THIS_VENDOR] ; ; Generic HID Interface (HidUsb as service) ; \"My device description\" = My_Install_Section, USB\\VID_05FD&PID_0101 [My_Install_Section.NT] ; ; This section name\'s prefix matches \'My_Install_Section\' above. ; The appended \".NT\" indicates Windows NT -specific processing. ; Copyfiles = MyCopyFiles AddReg = MyAddReg [My_Install_Section.NT.HW] ; ; Because of the \".HW\" suffix, ; the \'AddReg\' entries in this section apply to the device\'s ; hardware key (rather than the software key, as usual). ; AddReg = My_HW_AddReg [MyCopyFiles] ; mydriver.sys hidusb.sys hidparse.sys hidclass.sys usbfilt.sys [MyAddReg] ; ; Insert regular (software-branch) registry entries here ; HKLM,,DevLoader,,*ntkern HKLM,,NTMPDriver,,\"hidusb\" [My_Install_Section.NT.Services] ; ; The inf should already include a service entry for the device class. ; It\'ll look something like the line below. Keep that line in the inf. ; ; AddService = MyDriver,2,My_Service ; This is the filter service we\'re adding. AddService = FilterService,,Filter_Service_Inst [My_HW_AddReg] ; ; This HW-branch AddReg section adds values to the hardware-branch ; registry key of the device (under HKLM\\System\\CurrentControlSet\\Enum). ; ; \"LowerFilters\" and \"UpperFilters\" are special values that indicate ; to the kernel that one or more filter drivers should be loaded along ; with the driver for this device. ; ; You may also include other values here. These values can be read ; by the driver. The \'SampleFilterParam\' value is read by the filter.sys ; sample driver as an example. ; HKLM,,\"LowerFilters\",0x00010000,\"usbfilt.sys\" ; or HKR,,\"UpperFilters\",0x00010000,\"FilterService\" ; HKR,,\"SampleFilterParam\",0x00010001,512 [Filter_Service_Inst] DisplayName = \"Filter Service\" ServiceType = 1 ;%SERVICE_KERNEL_DRIVER% StartType = 3 ;%SERVICE_DEMAND_START% ErrorControl = 0 ;%SERVICE_ERROR_IGNORE% ServiceBinary = %12%\\usbfilt.sys LoadOrderGroup = PnP Filter |
|
最新喜欢:![]() |
沙发#
发布于:2002-12-05 15:28
自个回复自个
; ; INF.TXT ; ; This file is part of the FILTER sample filter driver in the ; Windows 2000 DDK. It is not a complete INF file. ; It lists the sections of your INF file that you need to ; change in order to have a filter driver loaded for your device. ; [Version] Signature=\"$CHICAGO$\" Class=HID ClassGUID={745a17a0-74d3-11d0-b6fe-00a0c90f57da} Provider=%USBDBE% LayoutFile=layout.inf DriverVer=11/12/2001,4.10.2222.12 [Manufacturer] \"ThisVendor\"=THIS_VENDOR [THIS_VENDOR] ; ; Generic HID Interface (HidUsb as service) ; \"My device description\" = My_Install_Section, USB\\VID_05FD&PID_0101 [My_Install_Section.NT] ; ; This section name\'s prefix matches \'My_Install_Section\' above. ; The appended \".NT\" indicates Windows NT -specific processing. ; Copyfiles = MyCopyFiles AddReg = MyAddReg [My_Install_Section.NT.HW] ; ; Because of the \".HW\" suffix, ; the \'AddReg\' entries in this section apply to the device\'s ; hardware key (rather than the software key, as usual). ; AddReg = My_HW_AddReg [MyCopyFiles] ; mydriver.sys hidusb.sys hidparse.sys hidclass.sys usbfilt.sys [MyAddReg] ; ; Insert regular (software-branch) registry entries here ; HKLM,,DevLoader,,*ntkern HKLM,,NTMPDriver,,\"hidusb\" [My_Install_Section.NT.Services] ; ; The inf should already include a service entry for the device class. ; It\'ll look something like the line below. Keep that line in the inf. ; ; AddService = MyDriver,2,My_Service ; This is the filter service we\'re adding. AddService = FilterService,,Filter_Service_Inst [My_HW_AddReg] ; ; This HW-branch AddReg section adds values to the hardware-branch ; registry key of the device (under HKLM\\System\\CurrentControlSet\\Enum). ; ; \"LowerFilters\" and \"UpperFilters\" are special values that indicate ; to the kernel that one or more filter drivers should be loaded along ; with the driver for this device. ; ; You may also include other values here. These values can be read ; by the driver. The \'SampleFilterParam\' value is read by the filter.sys ; sample driver as an example. ; HKLM,,\"LowerFilters\",0x00010000,\"FilterService\" ; or HKR,,\"UpperFilters\",0x00010000,\"FilterService\" ; HKR,,\"SampleFilterParam\",0x00010001,512 [Filter_Service_Inst] DisplayName = \"Filter Service\" ServiceType = 1 ;%SERVICE_KERNEL_DRIVER% StartType = 3 ;%SERVICE_DEMAND_START% ErrorControl = 0 ;%SERVICE_ERROR_IGNORE% ServiceBinary = %12%\\usbfilt.sys LoadOrderGroup = PnP Filter |
|