;/*++

;

;Copyright (c) 1990-1999 Microsoft Corporation All rights Reserved

;

;Module Name:

;

;    STATBUS.INF

;

;Abstract:

;    INF file for installing toaster bus enumerator driver

;

;Installation Notes:

;    Using Devcon: Type "devcon install statbus.inf root\statbus" to install

;

;--*/

 

;Version 節出現在inf中的第一個位置,每個inf文件都必須有。

[Version]

;指明那個系統上這個inf是有效的

Signature="$WINDOWS NT$"

 

;標準設備類的名字,在devguid.h中有定義,最好同時提供ClassGuid,方便系統查找。

如果定義新的設備類,那么必須使用新的名字,GUID.

Class=System

; 系統類的GUID

ClassGuid={4D36E97D-E325-11CE-BFC1-08002BE10318}

 

;指定inf文件的提供者

 

Provider=%MSFT%

;驅動版本信息

DriverVer=05/10/2011,6.1.7600.16385

指定驅動程序包含的在安裝包中的catalog文件。這些 文件由WQHL提供。

CatalogFile=KmdfSamples.cat

 

;指定了驅動文件將被拷貝到哪里

01

SourceDrive:\pathname (the directory from which the INF file was installed)

10

Windows directory
This is equivalent to %windir%.

11

System directory
This is equivalent to %windir%\system32 for NT-based systems, and to %windir%\system for Windows 9x/Me.

12

Drivers directory
This is equivalent to %windir%\system32\drivers for NT-based platforms, and to %windir%\system\IoSubsys on Windows 9x/Me platforms.

17

INF file directory

18

Help directory

20

Fonts directory

21

Viewers directory

23

Color directory (ICM) (not used for installing printer drivers)

24

Root directory of the system disk.
This is the root directory of the disk on which Windows files are installed. For example, if dirid 10 is "C:\winnt", then dirid 24 is "C:\".

25

Shared directory

30

Root directory of the boot disk, also known as "ARC system partition," for NT-based systems. (This might or might not be the same directory as the one represented by dirid 24.)

50

System directory for NT-based operating systems

This is equivalent to %windir%\system (NT-based systems only).

51

Spool directory (not used for installing printer drivers − see Printer Dirids)

52

Spool drivers directory (not used for installing printer drivers)

53

User profile directory

54

Directory where ntldr.exe and osloader.exe are located (NT-based systems only)

55

Print processors directory (not used for installing printer drivers)

-1

Absolute path

 

[DestinationDirs]

DefaultDestDir = 12

 

;指定使用什么分發媒體。

[SourceDisksNames]

diskid = disk-description[,[tag-or-cab-file],[unused,path],[flags][,tag-file]] Windows XP and later

如果有多個地方,需要指定1234,。。。

1 = %DiskId1%,,,""

 

;指定文件在那個分發媒體上。

[SourceDisksFiles]

statbus.sys = 1,,

 

 

;*****************************************

; ToasterStatBus Install Section

;*****************************************

 

Manufacturer章節用于識別這樣一些廠商,該廠商的一個或者多個設備能夠使用該inf文件進行安裝。

[Manufacturer]
manufacturer-identifier
[manufacturer-identifier]
[manufacturer-identifier]

 

manufacturer-identifier如下表示:

manufacturer-name |
%strkey%=models-section-name |
%strkey%=models-section-name [,TargetOSVersion] [,TargetOSVersion] ... (Windows XP and later versions of Windows)

 

 

該條目確定設備的廠商,并且在inf文件中必須有一個相應的同樣的名字的Models章節。

 

 

 

[Manufacturer]

%StdMfg%=Standard,NTx86

; For Win2K because it cannot parse decorated sections.

[Standard]

;

; These are the toaster bus pnp ids

; ToasterStatBus.DeviceDesc是設備描述

ToasterStatBus_Deviceinstall-section-name

; root\statbus是硬件ID

硬件ID有以下一些格式。

enumerator\enumerator-specific-device-id

Is the typical format for individual PnP devices reported to the PnP manager by a single enumerator. For example, USB\VID_045E&PID_00B identifies the Microsoft HID keyboard device on a USB bus. Depending on the enumerator, such a specification can even include the device's hardware revision number as, for example, PCI\VEN_1011&DEV_002&SUBSYS_00000000&REV_02.

*enumerator-specific-device-id

Indicates with the asterisk (*) that the device is supported by more than one enumerator. For example, *PNP0F01 identifies the Microsoft serial mouse, which also has a compatible-id specification of SERENUM\PNP0F01.

device-class-specific-ID

Is an I/O bus-specific format, as described in the hardware specification for the bus, for the hardware IDs of all peripheral devices on that type of I/O bus.

 

%ToasterStatBus.DeviceDesc%=ToasterStatBus_Device, root\statbus

 

; For XP and later

[Standard.NTx86]

%ToasterStatBus.DeviceDesc%=ToasterStatBus_Device, root\statbus

 

[ToasterStatBus_Device.NT]

CopyFiles=Drivers_Dir

 

[ToasterStatBus_Device.NT.HW]

AddReg=ToasterStatBus_Device.NT.AddReg

 

[ToasterStatBus_Device.NT.AddReg]                           

HKR,,DeviceCharacteristics,0x10001,0x0100         ; Use same security checks on relative opens

HKR,,Security,,"D:P(A;;GA;;;BA)(A;;GA;;;SY)"      ; Allow generic-all access to Built-in administrators and Local system

 

[Drivers_Dir]

statbus.sys

 

 

;-------------- Service installation

[ToasterStatBus_Device.NT.Services]

AddService = statbus,%SPSVCINST_ASSOCSERVICE%, Statbus_Service_Inst

 

; -------------- statbus driver install sections

[Statbus_Service_Inst]

DisplayName    = %statbus.SVCDESC%

ServiceType    = 1              ; SERVICE_KERNEL_DRIVER

StartType      = 3               ; SERVICE_DEMAND_START

ErrorControl   = 1               ; SERVICE_ERROR_NORMAL

ServiceBinary = %12%\statbus.sys

LoadOrderGroup = Extended Base

 

 

;

;--- ToasterStatBus_Device WDF Coinstaller installation ------

;

[DestinationDirs]

ToasterStatBus_Device_CoInstaller_CopyFiles = 11

 

[ToasterStatBus_Device.NT.CoInstallers]

AddReg=ToasterStatBus_Device_CoInstaller_AddReg

CopyFiles=ToasterStatBus_Device_CoInstaller_CopyFiles

 

[ToasterStatBus_Device_CoInstaller_AddReg]

HKR,,CoInstallers32,0x00010000, "WdfCoInstaller01009.dll,WdfCoInstaller"

 

[ToasterStatBus_Device_CoInstaller_CopyFiles]

WdfCoInstaller01009.dll

 

[SourceDisksFiles]

WdfCoInstaller01009.dll=1 ; make sure the number matches with SourceDisksNames

 

[ToasterStatBus_Device.NT.Wdf]

KmdfService = statbus, statbus_wdfsect

[statbus_wdfsect]

KmdfLibraryVersion = 1.9

 

 

 

[Strings]

SPSVCINST_ASSOCSERVICE= 0x00000002

MSFT = "Microsoft"

StdMfg = "(Standard system devices)"

DiskId1 = "Toaster Static Bus Installation Disk #1"

ToasterStatBus.DeviceDesc = "Toaster Static Bus Enumerator"

statbus.SVCDESC = "Toaster Static Bus Enumerator"