IoGetDeviceObjectPointer for HID

Is It Possible to call IoGetDEviceObjectPointer for HID DEvices? if so,
where will i get the ObjectName Parameter for the HID DEvice? i already know
the VID and PID of the device… And another thing, how do i detect that a
certain device is plugged in (Without layering a driver on top of the
device’s stack)…

Yes, it is possible. You need to register for interface arrival and
departure notifications on the HID device interface. Once you open the
device, you must register for handle notifications so that you can close
the handle when the device is removed (either through query remove or
surprise removal) from the system.

You can register for both types of notifications through
IoRegisterPlugPlayNotifcation. See the toastmon example in the latest
DDK (server 2003) for an example on how to use this API.

Please note that if you open the keyboard or mouse before the raw input
thread does, you can make these devices useless for the user.

d


From: xxxxx@lists.osr.com
[mailto:xxxxx@lists.osr.com] On Behalf Of Rikki
Sent: Sunday, June 13, 2004 7:45 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] IoGetDeviceObjectPointer for HID

Is It Possible to call IoGetDEviceObjectPointer for HID DEvices? if so,
where will i get the ObjectName Parameter for the HID DEvice? i already
know the VID and PID of the device.. And another thing, how do i detect
that a certain device is plugged in (Without layering a driver on top of
the device's stack)...

Questions? First check the Kernel Driver FAQ at
http://www.osronline.com/article.cfm?id=256

You are currently subscribed to ntdev as: xxxxx@windows.microsoft.com
To unsubscribe send a blank email to xxxxx@lists.osr.com