WinUSB: How to tell if the device has gone

B

Bill Davy

At present, I send a control port message and do not get a reply and the
error code is something about a device is not functoning. Is there anyway
to find out that this has happened without doing the control transfer? I'd
like to know so that (a) I can tell the user that the device has gone away,
and (b) perhaps relate its going away to something else happening in the
system at the same time.

From USBTrace I know that nothing goes down the stack to the USB bus.

TIA,
Bill
 
D

Doron Holan [MSFT]

register for pnp handle notifications on the HANDLE that you opened with
RegisterDeviceNotification. you will be told when the usb device has been
unplugged

d
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top