/// <summary> /// 连接设备 /// </summary> /// <returns>是否连接成功</returns> public override async Task <bool> ConnectAsync() { ProtocalLinker = new OpcDaProtocalLinker(_host, _isRegexOn); if (!await ProtocalLinker.ConnectAsync()) { return(false); } return(true); }
public override async Task <bool> ConnectAsync() { _connectTryCount++; ProtocalLinker = new OpcDaProtocalLinker(_host); if (!await ProtocalLinker.ConnectAsync()) { return(false); } _connectTryCount = 0; return(true); }