From febcd0c73b51b17f484ff9a9a189b1f85130c2f7 Mon Sep 17 00:00:00 2001
From: wangxinhui <wangxinhui@hnkhzn.com>
Date: 星期二, 17 三月 2026 13:52:06 +0800
Subject: [PATCH] 更新自动门,新增切卷卷绕缓存架
---
wcs-server-hbf/WIDESEA_WCS/WCSClient/Melsec/MelsecPLCClient.cs | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
diff --git a/wcs-server-hbf/WIDESEA_WCS/WCSClient/Melsec/MelsecPLCClient.cs b/wcs-server-hbf/WIDESEA_WCS/WCSClient/Melsec/MelsecPLCClient.cs
index e0e8e1b..05b2cd1 100644
--- a/wcs-server-hbf/WIDESEA_WCS/WCSClient/Melsec/MelsecPLCClient.cs
+++ b/wcs-server-hbf/WIDESEA_WCS/WCSClient/Melsec/MelsecPLCClient.cs
@@ -64,6 +64,7 @@
{
MelsecMcNetClient.IpAddress = PLCIPAddress;
MelsecMcNetClient.Port = Port;
+ this.MelsecMcNetClient.ReceiveTimeout = 2000;
//MelsecMcNetClient.ConnectTimeOut = 2000;
//MelsecMcNetClient?.ConnectClose();
@@ -72,7 +73,7 @@
result.IsSuccess = true;
if (!result.IsSuccess)
{
- WIDESEA_Common.Tools.WriteLog.GetLog().Write($"Error锛歿PLCName}杩炴帴澶辫触{Environment.NewLine}閿欒淇℃伅锛歿result.Message}", PLCName);
+ WIDESEA_Common.Tools.WriteLog.GetLog().Write($"Error锛歿PLCName}杩炴帴澶辫触---{DateTime.Now}{Environment.NewLine}閿欒淇℃伅锛歿result.Message}", PLCName);
IsConnected = false;
return $"杩炴帴澶辫触,閿欒淇℃伅锛歿result.Message}";
}
@@ -80,7 +81,7 @@
{
IsConnected = true;
readWriteNet = MelsecMcNetClient;
- WIDESEA_Common.Tools.WriteLog.GetLog().Write($"Info锛歿PLCName}杩炴帴鎴愬姛锛�", PLCName);
+ WIDESEA_Common.Tools.WriteLog.GetLog().Write($"Info锛歿PLCName}杩炴帴鎴愬姛锛�---{DateTime.Now}", PLCName);
return $"杩炴帴鎴愬姛";
}
}
--
Gitblit v1.9.3