/// <summary> /// 获取机器串口list /// </summary> public void GetPorts() { string[] slist = TSerialPortController.GetPorts(); foreach (string name in slist) { // comslist.Add(new COM(name)); COMS.Add(name); } }
/// <summary> /// 初始化 /// </summary> private void Initealize() { COMS = new List <string>(); GetPorts(); LoadViewInfo(); port = new TSerialPortController(portInfo); SerialPortInitealize(); SendString = "绑定测试"; }