mirror of
https://github.com/meshtastic/python.git
synced 2026-09-16 07:20:23 -04:00
only show active windows ports
This commit is contained in:
1 parent
a0944961b5
commit
72326d467e
1 file changed
+1
-1
@@ -173,7 +173,7 @@ def detect_windows_port(sd):
|
||||
system = platform.system()
|
||||
|
||||
if system == "Windows":
|
||||
command = 'powershell.exe "Get-PnpDevice | Where-Object{ ($_.DeviceId -like '
|
||||
command = 'powershell.exe "Get-PnpDevice -PresentOnly | Where-Object{ ($_.DeviceId -like '
|
||||
command += f"'*{sd.usb_vendor_id_in_hex.upper()}*'"
|
||||
command += ')} | Format-List"'
|
||||
|
||||
|
||||
Reference in new issue
Block a user