1394 WDM Device Driver

General Situation -
I am writing a Windows XP WDM device driver to communicate from PC-to-PC
over IEEE-1394.

Specifics -

  • My goal is to communicate in native 1394 and NOT to use TCP/IP over 1394
    (though I know this is available).
  • This driver is for “demo purposes only” (ie. it does not have to be
    robust enough for a wide-distribution).
  • My questions are not really 1394 related, but specifically about WDM.
  • I am new to the universe of “Windows Drivers”, especially WDM. That
    said, I HAVE read a lot on this subject and dug in fairly deep (or so I
    think). I now think I’m ready to ask some specific questions…

Questions -

  1. I understand the concept of the 1394 Driver Stack and the WDM driver
    stack in general. What I’m having trouble with is in this area is how
    SPECIFICALLY to attach to the 1394 driver stack. The way I see it, once I
    plug-in the other PC, the PnP Manager should somehow enumerate it and find
    my driver somehow through the inf files. I’m having trouble getting this
    to happen. I’ve read about using the Hardware ID of the device being
    added to the bus, but what would the Hardware ID be for just another PC
    hosting 1394?

  2. I’ve also thought of not going through the PnP Manager and just using
    the Add New Hardware Wizard. But once again, how SPECIFICALLY in this
    case would I attach to the 1394 driver stack. I understand the role of
    the AddDevice() routine to create my device object and attach it to the
    stack. And the way I understand it, the PnP Manager will pass in a PDO to
    AddDevice(). But how can I get the PNP Manager to recognize that the PDO
    I need is for the 1394 PDO (1394bus.sys) ?

I could ask a million more, but just the answers to these would get me
over a big hurdle. I’d GREATLY appreciate ANY help.

Thanks,
Sean

>1) I understand the concept of the 1394 Driver Stack and the WDM >driver

stack in general. What I’m having trouble with is in this area is >how
SPECIFICALLY to attach to the 1394 driver stack. The way I see it, >once I
plug-in the other PC, the PnP Manager should somehow enumerate it and >find
my driver somehow through the inf files. I’m having trouble getting >this
to happen. I’ve read about using the Hardware ID of the device being
added to the bus, but what would the Hardware ID be for just another >PC
hosting 1394?

This is normally how it is done, but as it turns out, for 1394 it won’t
quite work this way, at least on XP. On 2000 and Me when you connected two
1394 host controllers together, a 1394 device was enumerated and you got
prompted for a driver on each side of the wire. The bus and PnP ID for this
device == 1394\MICROSOFT&1394_PC. You could stick this in an INF and load a
driver up for the host controller on the other end of the wire.

With XP, this has all changed. Now, the 1394 bus takes over this
MICROSOFT&1394_PC device and loads its own driver. And, there is no
automatic way to load a driver in this situation anymore. What you can do
on XP and later, which is pretty cool, is create a Virtual 1394 device.
With this you even create your own synthetic config ROM which makes the
Virtual device look and act like a real piece of 1394 hardware. Its really
cool for prototyping software. Too bad USB can’t do this :slight_smile:

Take a look in the DDK documentation at IOCTL_IEEE1394_API_REQUEST for more
information on this. Unfortunately there are no samples today that show how
to use this that I am aware of.


Bill McKenzie
Windows DDK MVP
OSR - Windows System Software Development, Training, and Consulting

wrote in message news:xxxxx@ntdev…
>
> In DDK source code,have a sample code about 1394,you can take a look at
> here.
>
>
>
>
> “Sean Bentley”
> ÊÕ¼þÈË£º “NT
Developers Interest List”
> ·¢¼þÈË£º
> xxxxx@lis ³­ËÍ£º
> ts.osr.com Ö÷Ì⣺ [ntdev] 1394 WDM
Device Driver
>
>
> 02-09-20 12:34
> Çë´ð¸´ ¸ø “NT
> Developers Interest
> List”
>
>
>
>
>
>
> General Situation -
> I am writing a Windows XP WDM device driver to communicate from PC-to-PC
> over IEEE-1394.
>
> Specifics -
> - My goal is to communicate in native 1394 and NOT to use TCP/IP over 1394
> (though I know this is available).
> - This driver is for “demo purposes only” (ie. it does not have to be
> robust enough for a wide-distribution).
> - My questions are not really 1394 related, but specifically about WDM.
> - I am new to the universe of “Windows Drivers”, especially WDM. That
> said, I HAVE read a lot on this subject and dug in fairly deep (or so I
> think). I now think I’m ready to ask some specific questions…
>
> Questions -
> 1) I understand the concept of the 1394 Driver Stack and the WDM driver
> stack in general. What I’m having trouble with is in this area is how
> SPECIFICALLY to attach to the 1394 driver stack. The way I see it, once I
> plug-in the other PC, the PnP Manager should somehow enumerate it and find
> my driver somehow through the inf files. I’m having trouble getting this
> to happen. I’ve read about using the Hardware ID of the device being
> added to the bus, but what would the Hardware ID be for just another PC
> hosting 1394?
>
> 2) I’ve also thought of not going through the PnP Manager and just using
> the Add New Hardware Wizard. But once again, how SPECIFICALLY in this
> case would I attach to the 1394 driver stack. I understand the role of
> the AddDevice() routine to create my device object and attach it to the
> stack. And the way I understand it, the PnP Manager will pass in a PDO to
> AddDevice(). But how can I get the PNP Manager to recognize that the PDO
> I need is for the 1394 PDO (1394bus.sys) ?
>
> I could ask a million more, but just the answers to these would get me
> over a big hurdle. I’d GREATLY appreciate ANY help.
>
> Thanks,
> Sean
>
> —
> You are currently subscribed to ntdev as: xxxxx@sunplus.com.cn
> To unsubscribe send a blank email to %%email.unsub%%
>
>
>

>Unfortunately there are no samples today that show how

to use this that I am aware of.

I take it back, if you look in \src\wdm\1394\dll\1394api\1394main.c in one
of the latest DDKs, there is an example function AddVirtualDriver which
demos creating a virtual device.


Bill McKenzie
Windows DDK MVP
OSR - Windows System Software Development, Training, and Consulting

“Bill McKenzie” wrote in message news:xxxxx@ntdev…
>
> >1) I understand the concept of the 1394 Driver Stack and the WDM >driver
> >stack in general. What I’m having trouble with is in this area is >how
> >SPECIFICALLY to attach to the 1394 driver stack. The way I see it, >once
I
> >plug-in the other PC, the PnP Manager should somehow enumerate it and
>find
> >my driver somehow through the inf files. I’m having trouble getting
>this
> >to happen. I’ve read about using the Hardware ID of the device being
> >added to the bus, but what would the Hardware ID be for just another >PC
> >hosting 1394?
>
> This is normally how it is done, but as it turns out, for 1394 it won’t
> quite work this way, at least on XP. On 2000 and Me when you connected
two
> 1394 host controllers together, a 1394 device was enumerated and you got
> prompted for a driver on each side of the wire. The bus and PnP ID for
this
> device == 1394\MICROSOFT&1394_PC. You could stick this in an INF and load
a
> driver up for the host controller on the other end of the wire.
>
> With XP, this has all changed. Now, the 1394 bus takes over this
> MICROSOFT&1394_PC device and loads its own driver. And, there is no
> automatic way to load a driver in this situation anymore. What you can do
> on XP and later, which is pretty cool, is create a Virtual 1394 device.
> With this you even create your own synthetic config ROM which makes the
> Virtual device look and act like a real piece of 1394 hardware. Its really
> cool for prototyping software. Too bad USB can’t do this :slight_smile:
>
> Take a look in the DDK documentation at IOCTL_IEEE1394_API_REQUEST for
more
> information on this. Unfortunately there are no samples today that show
how
> to use this that I am aware of.
>
> –
> Bill McKenzie
> Windows DDK MVP
> OSR - Windows System Software Development, Training, and Consulting
>
>
> wrote in message news:xxxxx@ntdev…
> >
> > In DDK source code,have a sample code about 1394,you can take a look at
> > here.
> >
> >
> >
> >
> > “Sean Bentley”
> > ÊÕ¼þÈË£º “NT
> Developers Interest List”
> > ·¢¼þÈË£º
> > xxxxx@lis ³­ËÍ£º
> > ts.osr.com Ö÷Ì⣺ [ntdev] 1394
WDM
> Device Driver
> >
> >
> > 02-09-20 12:34
> > Çë´ð¸´ ¸ø “NT
> > Developers Interest
> > List”
> >
> >
> >
> >
> >
> >
> > General Situation -
> > I am writing a Windows XP WDM device driver to communicate from PC-to-PC
> > over IEEE-1394.
> >
> > Specifics -
> > - My goal is to communicate in native 1394 and NOT to use TCP/IP over
1394
> > (though I know this is available).
> > - This driver is for “demo purposes only” (ie. it does not have to be
> > robust enough for a wide-distribution).
> > - My questions are not really 1394 related, but specifically about WDM.
> > - I am new to the universe of “Windows Drivers”, especially WDM. That
> > said, I HAVE read a lot on this subject and dug in fairly deep (or so I
> > think). I now think I’m ready to ask some specific questions…
> >
> > Questions -
> > 1) I understand the concept of the 1394 Driver Stack and the WDM driver
> > stack in general. What I’m having trouble with is in this area is how
> > SPECIFICALLY to attach to the 1394 driver stack. The way I see it, once
I
> > plug-in the other PC, the PnP Manager should somehow enumerate it and
find
> > my driver somehow through the inf files. I’m having trouble getting
this
> > to happen. I’ve read about using the Hardware ID of the device being
> > added to the bus, but what would the Hardware ID be for just another PC
> > hosting 1394?
> >
> > 2) I’ve also thought of not going through the PnP Manager and just using
> > the Add New Hardware Wizard. But once again, how SPECIFICALLY in this
> > case would I attach to the 1394 driver stack. I understand the role of
> > the AddDevice() routine to create my device object and attach it to the
> > stack. And the way I understand it, the PnP Manager will pass in a PDO
to
> > AddDevice(). But how can I get the PNP Manager to recognize that the
PDO
> > I need is for the 1394 PDO (1394bus.sys) ?
> >
> > I could ask a million more, but just the answers to these would get me
> > over a big hurdle. I’d GREATLY appreciate ANY help.
> >
> > Thanks,
> > Sean
> >
> > —
> > You are currently subscribed to ntdev as: xxxxx@sunplus.com.cn
> > To unsubscribe send a blank email to %%email.unsub%%
> >
> >
> >
>
>
>
>

> added to the bus, but what would the Hardware ID be for just another
PC

hosting 1394?

IIRC the config ROM strings are “1394 PC” and “Microsoft”, don’t
remember the other config ROM values for a 1394 PC just off-head.
1394BUS emulates a config ROM for a PC by handling incoming 1394
transactions which target the config ROM.
There is also a xxx_MODIFY_CROM IRB, which allows the upper drivers to
control the “appearance” of PC’s config ROM exposed to the rest of
1394 devices.

You can also go non-PnP way and open \Device\1394BUS0.

Max

> Virtual device look and act like a real piece of 1394 hardware. Its
really

cool for prototyping software. Too bad USB can’t do this :slight_smile:

…due to electrical reasons I think.

Max

Its due to a lack of peer-to-peer support.

Bill M.

“Maxim S. Shatskih” wrote in message
news:xxxxx@ntdev…
>
> > Virtual device look and act like a real piece of 1394 hardware. Its
> really
> > cool for prototyping software. Too bad USB can’t do this :slight_smile:
>
> …due to electrical reasons I think.
>
> Max
>
>
>
>
>

…and this in turn is due to USB being electrically oriented.

“Bill McKenzie” wrote in message
news:LYRIS-542-75937-2002.09.23-01.35.28–maxim#xxxxx@lists
.osr.com…
> Its due to a lack of peer-to-peer support.
>
> Bill M.
>
>
> “Maxim S. Shatskih” wrote in message
> news:xxxxx@ntdev…
> >
> > > Virtual device look and act like a real piece of 1394 hardware.
Its
> > really
> > > cool for prototyping software. Too bad USB can’t do this :slight_smile:
> >
> > …due to electrical reasons I think.
> >
> > Max
> >
> >
> >
> >
> >
>
>
>
> —
> You are currently subscribed to ntdev as: xxxxx@storagecraft.com
> To unsubscribe send a blank email to %%email.unsub%%
>