help me creating setup information file

I am trying to create an INF file for the sample driver inside
src/usb/usbview directory.
I have written few sections following some sample .inf files like one
inside src\setup\DIFxPkgs\x86\ClsFilt directory.
although, I am not sure if i am following the right sample .inf file.
I have problem in filling the entries in following sections

[Classfilter.AddReg]

[DefaultInstall.NT.Services]

[dmi_ClassFilterUpperService]

[DestinationDirs]

[SourceDisksNames]

[SourceDisksFiles]

[Strings]

well, in this sample .inf file there are some numeric values given for example,
[DestinationDirs]
DefaultDestDir = 12

now, what does it mean by 12 here. can’t be there a path to default
destination directory?

am I going in a right way?

12 means \Drivers folder on WinNT platforms

Refer MSDN or OS online

http://www.osronline.com/ddkx/install/inf-format_8kfm.htm


From: “santosh tripathi”
Sent: Friday, April 24, 2009 10:34 AM
To: “Windows System Software Devs Interest List”
Subject: [ntdev] help me creating setup information file

> I am trying to create an INF file for the sample driver inside
> src/usb/usbview directory.
> I have written few sections following some sample .inf files like one
> inside src\setup\DIFxPkgs\x86\ClsFilt directory.
> although, I am not sure if i am following the right sample .inf file.
> I have problem in filling the entries in following sections
>
> [Classfilter.AddReg]
>
> [DefaultInstall.NT.Services]
>
> [dmi_ClassFilterUpperService]
>
> [DestinationDirs]
>
> [SourceDisksNames]
>
> [SourceDisksFiles]
>
> [Strings]
>
> well, in this sample .inf file there are some numeric values given for
> example,
> [DestinationDirs]
> DefaultDestDir = 12
>
> now, what does it mean by 12 here. can’t be there a path to default
> destination directory?
>
> am I going in a right way?
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

Take some existing INF from windows\inf as a sample.


Maxim S. Shatskih
Windows DDK MVP
xxxxx@storagecraft.com
http://www.storagecraft.com

“santosh tripathi” wrote in message news:xxxxx@ntdev…
>I am trying to create an INF file for the sample driver inside
> src/usb/usbview directory.
> I have written few sections following some sample .inf files like one
> inside src\setup\DIFxPkgs\x86\ClsFilt directory.
> although, I am not sure if i am following the right sample .inf file.
> I have problem in filling the entries in following sections
>
> [Classfilter.AddReg]
>
> [DefaultInstall.NT.Services]
>
> [dmi_ClassFilterUpperService]
>
> [DestinationDirs]
>
> [SourceDisksNames]
>
> [SourceDisksFiles]
>
> [Strings]
>
> well, in this sample .inf file there are some numeric values given for example,
> [DestinationDirs]
> DefaultDestDir = 12
>
> now, what does it mean by 12 here. can’t be there a path to default
> destination directory?
>
> am I going in a right way?
>

what all I need is, when a usb device is inserted in any usb hub the driver run immediatly showing the status of connected device(s) and its full description.
I mean, the sample driver I am writing INF file for, should be installed in such a way so that it do it’s function I have stated in above line.

One thing I can not understand, In this sample (I have given the path in first post) there is one .exe and few others like .obj, .moc files are produced but not a single .sys file. what does it mean?
is it a kinda driver that doesn’t have any .sys file?
is it an application like MS Word, Winamp…etc ?

So far, To fill my requirements I have written usbview.inf file as below:

[Version]
Class = USB
ClassGuid = {36fc9e60-c465-11cf-8056-444553540000}
Signature = “$WINDOWS NT$”
Provider = IPS Students
CatalogFile = usbview.cat
DriverPackageType = UsbView
DriverVer=04/30/2009 1.0

[SourceDisksNames.x86]
1 = “UsbViewInstall”,

[SourceDisksFiles.x86]
usbview.exe = 1

[ClassInstall32]
Addreg=UsbViewClassReg
CopyFiles=UsbViewClassInstallerCopyFiles

[UsbViewClassReg]
HKR,0,%ClassName%
HKR,Icon,100
HKR,Installer32,UsbViewClassInstaller"
HKR,DeviceCharacteristics,0x10001,0x100

[UsbViewClassInstallerCopyFiles]
usbview.exe

[ClassInstall32.Services]
AddService = usbview, usbview_Service_Inst

[usbview_Service_Inst]
DisplayName = “Usb Tree View Service”
ServiceType = 1 ; SERVICE_KERNEL_DRIVER
StartType = 3 ; SERVICE_DEMAND_START
ErrorControl = 1 ; SERVICE_ERROR_NORMAL
ServiceBinary = %12%\usbview.exe
LoadOrderGroup = Extended Base

its not complete though, I cant decide what entries should I make further to meet my requirements.

waiting for your help

Here’s an immense confusion…

[usbview_Service_Inst]
DisplayName = “Usb Tree View Service”
ServiceType = 1 ; SERVICE_KERNEL_DRIVER
StartType = 3 ; SERVICE_DEMAND_START
ErrorControl = 1 ; SERVICE_ERROR_NORMAL
ServiceBinary = %12%\usbview.exe
LoadOrderGroup = Extended Base

How a kernel driver can be exe. Where you’ve found such a sample?

Regards,
– pa

wrote in message news:xxxxx@ntdev…
> what all I need is, when a usb device is inserted in any usb hub the
> driver run immediatly showing the status of connected device(s) and its
> full description.
> I mean, the sample driver I am writing INF file for, should be installed
> in such a way so that it do it’s function I have stated in above line.
>
> One thing I can not understand, In this sample (I have given the path in
> first post) there is one .exe and few others like .obj, .moc files are
> produced but not a single .sys file. what does it mean?
> is it a kinda driver that doesn’t have any .sys file?
> is it an application like MS Word, Winamp…etc ?
>
> So far, To fill my requirements I have written usbview.inf file as below:
> ------------------------------------------------------
> [Version]
> Class = USB
> ClassGuid = {36fc9e60-c465-11cf-8056-444553540000}
> Signature = “$WINDOWS NT$”
> Provider = IPS Students
> CatalogFile = usbview.cat
> DriverPackageType = UsbView
> DriverVer=04/30/2009 1.0
>
> [SourceDisksNames.x86]
> 1 = “UsbViewInstall”,
>
> [SourceDisksFiles.x86]
> usbview.exe = 1
>
> [ClassInstall32]
> Addreg=UsbViewClassReg
> CopyFiles=UsbViewClassInstallerCopyFiles
>
> [UsbViewClassReg]
> HKR,0,%ClassName%
> HKR,Icon,100
> HKR,Installer32,UsbViewClassInstaller"
> HKR,DeviceCharacteristics,0x10001,0x100
>
> [UsbViewClassInstallerCopyFiles]
> usbview.exe
>
> [ClassInstall32.Services]
> AddService = usbview, usbview_Service_Inst
>
> [usbview_Service_Inst]
> DisplayName = “Usb Tree View Service”
> ServiceType = 1 ; SERVICE_KERNEL_DRIVER
> StartType = 3 ; SERVICE_DEMAND_START
> ErrorControl = 1 ; SERVICE_ERROR_NORMAL
> ServiceBinary = %12%\usbview.exe
> LoadOrderGroup = Extended Base
> --------------------------------------------------
>
> its not complete though, I cant decide what entries should I make further
> to meet my requirements.
>
> waiting for your help
>

From: “Pavel A.”
> Here’s an immense confusion…
> How a kernel driver can be exe. Where you’ve found such a sample?

It can’t. What you’re seeing are registry entries for a user-mode service
module. You can build ANY type of module with the WDK. But I don’t actually
think USBVIEW runs as a service. I’ve always used it as a standalone applet.

Walter Oney
Consulting and Training
www.oneysoft.com

It is an application. The OP is confused.

Mark Roddy

On Sat, Apr 25, 2009 at 2:22 PM, Walter Oney wrote:
> From: “Pavel A.”
>>
>> Here’s an immense confusion…
>> How a kernel driver can be exe. Where you’ve found such a sample?
>
> It can’t. What you’re seeing are registry entries for a user-mode service
> module. You can build ANY type of module with the WDK. But I don’t actually
> think USBVIEW runs as a service. I’ve always used it as a standalone applet.
>
> Walter Oney
> Consulting and Training
> www.oneysoft.com
>
> —
> NTDEV is sponsored by OSR
>
> For our schedule of WDF, WDM, debugging and other seminars visit:
> http://www.osr.com/seminars
>
> To unsubscribe, visit the List Server section of OSR Online at
> http://www.osronline.com/page.cfm?name=ListServer
>

On Sat, Apr 25, 2009 at 03:41:05AM -0400, xxxxx@gmail.com wrote:

what all I need is, when a usb device is inserted in any usb hub the
driver run immediatly showing the status of connected device(s) and its
full description.

“Show” it where? This information is certainly available in Device Manager.
Most people do not want to be bothered by popup windows every time a
device comes and goes.

I mean, the sample driver I am writing INF file for, should be installed
in such a way so that it do it’s function I have stated in above line.

What you ask could be done in several ways, but it’s going to be some work.
Probably the best way would be to write an application that uses
RegisterDeviceNotification to get notified on PnP events. Then, you could
go out and enumerate the whole USB tree again, using the techniques in
usbview.

You could also write an upper filter driver to the USB host controller and
watch for new device notifications, but it’s a bit tricky to filter a
bus driver.

is it an application like MS Word, Winamp…etc ?

Yes, it is an application. Are you really saying you couldn’t figure
this out without asking?

Tim Roberts, xxxxx@probo.com
Providenza & Boeklheide, Inc.

>Yes, it is an application.

ok, If it is then I must be able install it like MS Office, isn’t so?
If yes, then please guide me writing inf file for this. What are the sections and what exactly in those sections I should write.
Look at the inf file I posted above however, there are few mistakes spotted by forum members that I will make right.

This newsgroup is for driver developers. I would suggest you spend some
time reading MSDN Library on the installation of applications. INFs are for
drivers and NOT applications, though they can be used to copy a coinstaller
or possibly a support program in conjunction with a driver install.

wrote in message news:xxxxx@ntdev…
> >Yes, it is an application.
>
> ok, If it is then I must be able install it like MS Office, isn’t so?
> If yes, then please guide me writing inf file for this. What are the
> sections and what exactly in those sections I should write.
> Look at the inf file I posted above however, there are few mistakes
> spotted by forum members that I will make right.
>
>

On Sun, Apr 26, 2009 at 12:06:45AM -0400, xxxxx@gmail.com wrote:

>Yes, it is an application.

ok, If it is then I must be able install it like MS Office, isn’t so?
If yes, then please guide me writing inf file for this. What are the
sections and what exactly in those sections I should write.
Look at the inf file I posted above however, there are few mistakes
spotted by forum members that I will make right.

You don’t seem to have any idea what it is you want here. Until you do,
there is no point in asking for any more help. You are just going to
irritate the people here.

Usbview is an application. It is a developer tool. If you want to
run it, you just run it. No installation is required. After you build
usbview.exe, you just run it, either by typing its name at a command prompt,
or by double-clicking on it in Explorer. That’s all there is.

Applications are not installed using INF files. That’s why there is
no INF file in the sample. You don’t need to create an installer, because
you won’t be distributing this to your customers.

Tim Roberts, xxxxx@probo.com
Providenza & Boeklheide, Inc.