以下代码仅返回三个串行端口(com3、com4 和 com5)。我想访问的固件位于 USB 插头倍增器上。如何访问此乘法器的串行端口以及如何识别包含要向其发送信息的固件的特定 USB?
using System;
using System.IO.Ports;
namespace SerialPortExample
{
class SerialPortExample
{
public static void Main()
{
string[] ports = SerialPort.GetPortNames();
Console.WriteLine("The following serial ports were found:");
foreach (string port in ports)
{
Console.WriteLine(port);
}
Console.ReadLine();
}
}
}
提前谢谢了!