Wsprintf(sLogicalDeviceID, L'%s', vtProp. Hr = pclsObj3->Get(L'DeviceID', 0, &vtProp, 0, 0) Hr = pWbemEnum3->Next(WBEM_INFINITE, 1, &pclsObj3, &uReturn3) You can find the PID and VID of Synology's supported Wi-Fi and LTE dongles listed in the Synology Products Compatibility. Find your desired USB device in the list to see your PID and VID. To find PID & VID on Linux: Run the lsusb command to list details of your connected USB devices.
StrReplace(wsQuery, L'\\', L'\\\\', ARRAYSIZE(wsQuery)) Find your USB device and select it to view its PID and VID. WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pWbemEnum3)
On my Windows system this shows up under 'Portable Devices' in 'Device Manager'.ĭevice SWD\WPDBUSENUM_?_USBSTOR#Disk&Ven_Logger&Prod_&Rev_1.00#9&319384a2&0&24842CB953324D5946202020FF170720&0# WHERE AssocClass = Win32_LogicalDiskToPartition') The drive, letter D:// is a UF2, fat filesystem which I am using to flash upgrade an embedded device. From this how am I able to find which drive letter the USB storage has mounted on?
I have written a C++ application which is able to detect multiple USB VID and PID devices upon insertion and removal by matching 'USB\VID_%04X&PID_%04X'.