dapplo/Dapplo.Windows

Device Name / Ids ... weirdly formatted / Device Class Guids different than in Windows Device Manager?

Opened this issue ยท 5 comments

When I use devcon.exe, WMI and so on to query for a particular graphics card in my system I get the following identifier(s):

PCI\VEN_10DE&DEV_1FB8&SUBSYS_09061028&REV_A1\4&32AF3F68&0&0008

image

However, using your library (๐Ÿ‘) I do get a similar id.. but.. only similar & not the same, i.e. when listenting for removal events (read: enabling/disabling the device via Windows' device manager):

\?\PCI#VEN_10DE&DEV_1FB8&SUBSYS_09061028&REV_A1#4&32af3f68&0&0008#{1ca05180-a699-450a-9a0c-de4fbe3ddd89}

image

I am a bit confused why there are #s in the .Name and also the DeviceClassGuid.. is this an encoding issue.. or on purpose?

And a slightly related note: the graphics card(s) in my system all have the very same (Device) Class Guid (in the device manager's details) which is "{4d36e968-e325-11ce-bfc1-08002be10318}", however none of the DeviceNotification.OnDeviceArrival() / DeviceNotification.OnDeviceRemoved() events fired (and there are 6 or so per enabling/disabling in the device manager) has that DeviceClassGuid set.

So I am again a bit puzzled why I see info a) in Windows its tools etc but b) the info not matching with the info of the events. I think I must be missing something here, some missing link / mapping or something.. but if you had any ideas / suggestions what might be going on it would be highly appreciated!

Thanks and thanks especially for all your work on this library!!

Just so you know, I didn't get to this yet...

Thanks Robin & please, no hurry.. thanks for considering looking at it.. much appreciated ๐Ÿ‘

When I wrote it, I didn't have any specs on what I needed, so it's not worked out into every detail.

My first analysis, without going into details would be that I delive the path to the device.
It should not be an issue to have a property which generates exactly the same value as the one in the device manager. This would be: Cut off the begining and every # must be translated to a . The last part, I'm not even sure if this is added or already there, but can be cut off too.

I just need to think about what to name the property and look into some details about if there are any other things I should consider. My current biggest issue is that someone Visual Studio 2019 doesn't want to open the project on my laptop.... it hangs.

I actually need another laptop, it's broken, but it still works... I have some special wishes to make some of my OSS development possible. These make it a bit expensive and in the middle class I don't like any compromises, so I'm still waiting for the right combination and price. Btw... I should move to paid open source.... ๐Ÿคทโ€โ™‚๏ธ

A few days ago, I finally received a new laptop so I was able to continue my work at last.

I've added a DisplayName property, which should show the device name as you know it.

I still need to look at your other question, which was about the DeviceClassGuid...