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