I would like to create a list of COM port on my computer (COM port + description). I want to create a list of COM ports for communicating with the switch using a USB / RS232 converter.
What I'm trying so far:
Get-WMIObject Win32_SerialPort | Select-Object DeviceID,Description
But the whole COM port does not appear (example: COM11 is missing)
another attempt:
[System.IO.Ports.SerialPort]::getportnames()
there is a port that I need, but no description. (example: COM11 is present, but without any details)
source share