inf添加新類硬件需要修改項(充分非必要條件)
1。類別項(Class)
2。硬件廠商(Manufacturer)
3。硬件設備號
4。各字符串項(ProviderName,MfgName,DeviceDesc,DeviceClassName,SvcDesc)
5。在[YouMark_DDI.Services]項中改為現有文件名
6。硬件廠商節(jié)中后續(xù)各項均不要有NT節(jié)
;--------- Version Section ---------------------------------------------------
[Version]
Signature="$
Provider=zenghui41
DriverVer=
; 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=zenghui41_01
ClassGUID={B
;--------- SourceDiskNames and SourceDiskFiles Section -----------------------
; These sections identify source disks and files for installation. They are
; shown here as an example, but commented out.
[SourceDisksNames]
0 = "SCUT"
[SourceDisksFiles]
HelloWDM.sys = 0,\Windows驅動開發(fā)技術詳解[1]\Windows驅動開發(fā)技術詳解\chapter15\Test5\NT_Driver\MyDriver_Check,
;--------- ClassInstall/ClassInstall32 Section -------------------------------
; Not necessary if using a standard class
; NT Style
[ClassInstall32]
Addreg=Class_AddReg
[Class_AddReg]
HKR,,,,%DeviceClassName%
HKR,,Icon,,"-5"
;--------- DestinationDirs Section -------------------------------------------
[DestinationDirs]
YouMark_Files_Driver = 12
;--------- Manufacturer and Models Sections ----------------------------------
[Manufacturer]
%MfgName%=Mfg4110
[Mfg4110]
; PCI hardware Ids use the form
; PCI\VEN_aaaa&DEV_bbbb&SUBSYS_cccccccc&REV_dd
;改成你自己的ID
%DeviceDesc%=YouMark_DDI, PCI\VEN_4444&DEV_4444
;---------- DDInstall Sections -----------------------------------------------
[YouMark_DDI]
CopyFiles=YouMark_Files_Driver
; --------- Windows NT -----------------
[YouMark_DDI.Services]
Addservice = HelloDDK, 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\HelloDDK.sys
; --------- Files (common) -------------
[YouMark_Files_Driver]
HelloDDK.sys
;--------- Strings Section ---------------------------------------------------
[Strings]
ProviderName="zenghui_01"
MfgName="zenghui_01"
DeviceDesc="Hello World DDK_01!"
DeviceClassName="zenghui_Device_01"
SvcDesc="zenghui_01"