반응형 Python - pywin32를 이용한 USB device 검색1 Python - pywin32를 이용한 USB device 검색 Code 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 import win32com.client def check_fw_update_device(): wmi = win32com.client.GetObject ("winmgmts:") devices = [] for usb in wmi.InstancesOf ("Win32_PnPEntity"): find_device = 'USB Input Device' if find_device in str(usb.Description): print(f"DeviceID: + {str(usb.DeviceID)}") print(f"PNPDevic.. 2022. 12. 29. 이전 1 다음 반응형