WDM驱动安装

leftbackfielder 2014-01-12 04:30:14
一个键盘的过滤驱动,在控件面板里面,添加新硬件,总是提示

下面是INF文件:
;; The Win2K DDK documentation contains an excellent INF reference.

;--------- Version Section ---------------------------------------------------

[Version]
Signature="$CHICAGO$"
Provider=RenRen_Device
DriverVer=11/1/2007,3.0.0.3

; If device fits one of the standard classes, use the name and GUID here,
; otherwise create your own device class and GUID as this example shows.

Class=KGuardian
;ClassGUID={B988F087-B147-4626-9CC7-D83B7EB9D53A}

;IMPLEMENT_OLECREATE(<<class>>, <<external_name>>,
;0xb988f087, 0xb147, 0x4626, 0x9c, 0xc7, 0xd8, 0x3b, 0x7e, 0xb9, 0xd5, 0x3a);
;{B988F087-B147-4626-9CC7-D83B7EB9D53A}


;--------- SourceDiskNames and SourceDiskFiles Section -----------------------

; These sections identify source disks and files for installation. They are
; shown here as an example, but commented out.

[SourceDisksNames]
1 = "HelloWDMChapter01",Disk1,,

[SourceDisksFiles]
HelloWDMChapter01.sys = 1,objchk_win7_x86\i386,

;--------- ClassInstall/ClassInstall32 Section -------------------------------

; Not necessary if using a standard class

; 9X Style
[ClassInstall]
Addreg=Class_AddReg

; NT Style
[ClassInstall32]
Addreg=Class_AddReg

[Class_AddReg]
HKR,,,,%DeviceClassName%
HKR,,Icon,,"-19"

;--------- DestinationDirs Section -------------------------------------------

[DestinationDirs]
YouMark_Files_Driver = 10,System32\Drivers

;--------- Manufacturer and Models Sections ----------------------------------

[Manufacturer]
%MfgName%=Mfg0

[Mfg0]

; PCI hardware Ids use the form
; PCI\VEN_aaaa&DEV_bbbb&SUBSYS_cccccccc&REV_dd
;改成你自己的ID
%DeviceDesc%=YouMark_DDI, PCI\VEN_9999&DEV_9999

;---------- DDInstall Sections -----------------------------------------------
; --------- Windows 9X -----------------

; Experimentation has shown that DDInstall root names greater than 19 characters
; cause problems in Windows 98

[YouMark_DDI]
CopyFiles=YouMark_Files_Driver
AddReg=YouMark_9X_AddReg

[YouMark_9X_AddReg]
HKR,,DevLoader,,*ntkern
HKR,,NTMPDriver,,HelloWDMChapter01.sys
HKR, "Parameters", "BreakOnEntry", 0x00010001, 0

; --------- Windows NT -----------------

[YouMark_DDI.NT]
CopyFiles=YouMark_Files_Driver
AddReg=YouMark_NT_AddReg

[YouMark_DDI.NT.Services]
Addservice = HelloWDMChapter01, 0x00000002, YouMark_AddService

[YouMark_AddService]
DisplayName = %SvcDesc%
ServiceType = 1 ; SERVICE_KERNEL_DRIVER
StartType = 3 ; SERVICE_DEMAND_START
ErrorControl = 1 ; SERVICE_ERROR_NORMAL
ServiceBinary = %10%\System32\Drivers\HelloWDMChapter01.sys

[YouMark_NT_AddReg]
HKLM, "System\CurrentControlSet\Services\HelloWDMChapter01\Parameters",\
"BreakOnEntry", 0x00010001, 0


; --------- Files (common) -------------

[YouMark_Files_Driver]
HelloWDMChapter01.sys

;--------- Strings Section ---------------------------------------------------

[Strings]
ProviderName="RenRen."
MfgName="RenRen Soft"
DeviceDesc="My KGuardian"
DeviceClassName="RenRen_Device"
SvcDesc="RenRen"

哪位大神指点一下.
...全文
129 5 打赏 收藏 转发到动态 举报
写回复
用AI写文章
5 条回复
切换为时间正序
请发表友善的回复…
发表回复
曹大夯 2014-01-14
  • 打赏
  • 举报
回复
有可能是你的INF有问题,造成系统没法生成卸载菜单项。
leftbackfielder 2014-01-14
  • 打赏
  • 举报
回复
引用 3 楼 Huntercao 的回复:
这个有些不明白。 你在安装你的过滤驱动之前,键盘设备有卸载选项么? 有可能是你安装了一个Class驱动(Class=KGuardian)造成的。
其他的键盘设备都有卸载选项的。真心搞不明白了 上面的那个INF写的有问题。是点我再传那个INF,现在不太方便导。
曹大夯 2014-01-14
  • 打赏
  • 举报
回复
这个有些不明白。 你在安装你的过滤驱动之前,键盘设备有卸载选项么? 有可能是你安装了一个Class驱动(Class=KGuardian)造成的。
leftbackfielder 2014-01-13
  • 打赏
  • 举报
回复
引用 1 楼 Huntercao 的回复:

%DeviceDesc%=YouMark_DDI, PCI\VEN_9999&DEV_9999
这是什么?需要对应键盘的设备ID才可以安装的。
这个是ID,这块我自己随便写了一个,解决了。 现在有一新的问题:安装完驱动程序之后,在设备管理里面,显示正常,但是右键的时候,没有卸载选项 这上卸载选项,要怎么弄出来呢?
曹大夯 2014-01-13
  • 打赏
  • 举报
回复

%DeviceDesc%=YouMark_DDI, PCI\VEN_9999&DEV_9999
这是什么?需要对应键盘的设备ID才可以安装的。

21,595

社区成员

发帖
与我相关
我的任务
社区描述
硬件/嵌入开发 驱动开发/核心开发
社区管理员
  • 驱动开发/核心开发社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧