From 451c1e6d1f87262a2525cc4a2c2427b6fe348c4e Mon Sep 17 00:00:00 2001
From: hwh <332078369@qq.com>
Date: 星期四, 22 八月 2024 15:38:27 +0800
Subject: [PATCH] `

---
 Admin.NET/Admin.NET.Web.Entry/.config/dotnet-tools.json |   13 +++++++++++++
 Admin.NET/WCS.Application/PLC/PLCTaskAction.cs          |    5 ++---
 2 files changed, 15 insertions(+), 3 deletions(-)

diff --git a/Admin.NET/Admin.NET.Web.Entry/.config/dotnet-tools.json b/Admin.NET/Admin.NET.Web.Entry/.config/dotnet-tools.json
new file mode 100644
index 0000000..9fab42f
--- /dev/null
+++ b/Admin.NET/Admin.NET.Web.Entry/.config/dotnet-tools.json
@@ -0,0 +1,13 @@
+{
+  "version": 1,
+  "isRoot": true,
+  "tools": {
+    "dotnet-ef": {
+      "version": "8.0.8",
+      "commands": [
+        "dotnet-ef"
+      ],
+      "rollForward": false
+    }
+  }
+}
\ No newline at end of file
diff --git a/Admin.NET/WCS.Application/PLC/PLCTaskAction.cs b/Admin.NET/WCS.Application/PLC/PLCTaskAction.cs
index ee09096..2269b30 100644
--- a/Admin.NET/WCS.Application/PLC/PLCTaskAction.cs
+++ b/Admin.NET/WCS.Application/PLC/PLCTaskAction.cs
@@ -82,9 +82,7 @@
                         //寰幆璇昏澶�
                         foreach (var modDevice in listDevice)
                         {
-                            var b = modPlcUtil.Connected();
                             var (result, value) = modPlcUtil.GetPlcDBValue(modDevice.PosType.Value, modDevice.DbNumber, modDevice.PlcPos);
-                            var c = modPlcUtil.Connected();
                             if (result.IsSucceed)
                             {
                                 if (value != 0)
@@ -101,12 +99,13 @@
                             else
                             {
                                 //鍒犻櫎褰撳墠杩炴帴 涓嬩竴娆″惊鐜噸鏂拌繛鎺�
+                                Console.WriteLine("杩炴帴鏂紑...");
                                 modPlcUtil.Close();
                                 listPlcUtil.Remove(modPlcUtil);
                             }
                         }
 
-                        Thread.Sleep(100);
+                        Thread.Sleep(3000);
                     }
                     catch (Exception ex)
                     {

--
Gitblit v1.8.0