Hi,
I want to enumerate all present devices irrespective of their GUID. Hence I used SetupDiEnumDeviceInfo().
It works except that device path can only be retrieved via
SetupDiGetDeviceInterfaceDetail < needs PSP_DEVICE_INTERFACE_DATA < needs calling SetupDiEnumDeviceInterfaces () < needs device Interface Class GUID.
I don’t want only one type of devices. Rather I have USB hubs and then some serial USB devices. I want to walk through all the devices and get their details. Is it possible via SetupDiEnumDeviceInfo. I am ble to do it except for the Device Path/Device Instance Id.
The other way that seems possible is that I separately enumerate all types of USB (HUB, HOST CONTROLLER, DEVICE) and SERIAL devices and later correlate them using DevInst.
Please suggest shortest path.
Thanks
You want to use the CM_Xxxx APIs then. They allow you to walk the tree.
d
-----Original Message-----
From: xxxxx@lists.osr.com [mailto:xxxxx@lists.osr.com] On Behalf Of xxxxx@gmail.com
Sent: Saturday, August 8, 2015 6:39 PM
To: Windows System Software Devs Interest List
Subject: [ntdev] Using SetupDixxx to enumerate all+present devices and get device path
Hi,
I want to enumerate all present devices irrespective of their GUID. Hence I used SetupDiEnumDeviceInfo().
It works except that device path can only be retrieved via SetupDiGetDeviceInterfaceDetail < needs PSP_DEVICE_INTERFACE_DATA < needs calling SetupDiEnumDeviceInterfaces () < needs device Interface Class GUID.
I don’t want only one type of devices. Rather I have USB hubs and then some serial USB devices. I want to walk through all the devices and get their details. Is it possible via SetupDiEnumDeviceInfo. I am ble to do it except for the Device Path/Device Instance Id.
The other way that seems possible is that I separately enumerate all types of USB (HUB, HOST CONTROLLER, DEVICE) and SERIAL devices and later correlate them using DevInst.
Please suggest shortest path.
Thanks
—
NTDEV is sponsored by OSR
Visit the list at: http://www.osronline.com/showlists.cfm?list=ntdev
OSR is HIRING!! See http://www.osr.com/careers
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