From c5c3e4e538a11f2a6391e6b2613375b1f92eb20a Mon Sep 17 00:00:00 2001
From: wanshenmean <cathay_xy@163.com>
Date: 星期三, 15 四月 2026 14:39:18 +0800
Subject: [PATCH] feat: 添加Quartz日志助手类并重构任务服务日志记录

---
 Code/测试工具/WIDESEAWCS_S7Simulator/WIDESEAWCS_S7Simulator.Server/Data/protocol-templates.json |  316 ++++++++++++++++++++++++---------------------------
 1 files changed, 149 insertions(+), 167 deletions(-)

diff --git "a/Code/\346\265\213\350\257\225\345\267\245\345\205\267/WIDESEAWCS_S7Simulator/WIDESEAWCS_S7Simulator.Server/Data/protocol-templates.json" "b/Code/\346\265\213\350\257\225\345\267\245\345\205\267/WIDESEAWCS_S7Simulator/WIDESEAWCS_S7Simulator.Server/Data/protocol-templates.json"
index 43c14cf..b695037 100644
--- "a/Code/\346\265\213\350\257\225\345\267\245\345\205\267/WIDESEAWCS_S7Simulator/WIDESEAWCS_S7Simulator.Server/Data/protocol-templates.json"
+++ "b/Code/\346\265\213\350\257\225\345\267\245\345\205\267/WIDESEAWCS_S7Simulator/WIDESEAWCS_S7Simulator.Server/Data/protocol-templates.json"
@@ -5,7 +5,7 @@
     "version": "1.0",
     "fields": [
       {
-        "fieldKey": "GWSC01_InputTaskNum",
+        "fieldKey": "GWSC1_InputTaskNum",
         "dbNumber": 100,
         "offset": 194,
         "bit": 1,
@@ -14,7 +14,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_WorkAction",
+        "fieldKey": "GWSC1_WorkAction",
         "dbNumber": 100,
         "offset": 192,
         "bit": 1,
@@ -23,7 +23,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_InputWorkType",
+        "fieldKey": "GWSC1_InputWorkType",
         "dbNumber": 100,
         "offset": 198,
         "bit": 1,
@@ -32,7 +32,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_InputPickRow",
+        "fieldKey": "GWSC1_InputPickRow",
         "dbNumber": 100,
         "offset": 208,
         "bit": 1,
@@ -41,7 +41,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_InputPickColumn",
+        "fieldKey": "GWSC1_InputPickColumn",
         "dbNumber": 100,
         "offset": 210,
         "bit": 1,
@@ -50,7 +50,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_InputPickLayer",
+        "fieldKey": "GWSC1_InputPickLayer",
         "dbNumber": 100,
         "offset": 212,
         "bit": 1,
@@ -59,7 +59,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_InputPlaceRow",
+        "fieldKey": "GWSC1_InputPlaceRow",
         "dbNumber": 100,
         "offset": 214,
         "bit": 1,
@@ -68,7 +68,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_InputPlaceColumn",
+        "fieldKey": "GWSC1_InputPlaceColumn",
         "dbNumber": 100,
         "offset": 216,
         "bit": 1,
@@ -77,7 +77,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_InputPlaceLayer",
+        "fieldKey": "GWSC1_InputPlaceLayer",
         "dbNumber": 100,
         "offset": 218,
         "bit": 1,
@@ -86,7 +86,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_StackerCraneAutoStatus",
+        "fieldKey": "GWSC1_StackerCraneAutoStatus",
         "dbNumber": 100,
         "offset": 2,
         "bit": 1,
@@ -95,7 +95,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_StackerCraneWorkStatus",
+        "fieldKey": "GWSC1_StackerCraneWorkStatus",
         "dbNumber": 100,
         "offset": 4,
         "bit": 1,
@@ -104,7 +104,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_OutputFaultHigh",
+        "fieldKey": "GWSC1_OutputFaultHigh",
         "dbNumber": 100,
         "offset": 12,
         "bit": 1,
@@ -113,7 +113,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_OutputFaultMid",
+        "fieldKey": "GWSC1_OutputFaultMid",
         "dbNumber": 100,
         "offset": 16,
         "bit": 1,
@@ -122,7 +122,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_OutputFaultLow",
+        "fieldKey": "GWSC1_OutputFaultLow",
         "dbNumber": 100,
         "offset": 20,
         "bit": 1,
@@ -131,7 +131,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_CurrentTaskNum",
+        "fieldKey": "GWSC1_CurrentTaskNum",
         "dbNumber": 100,
         "offset": 24,
         "bit": 1,
@@ -140,7 +140,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_StackerCraneCompleted",
+        "fieldKey": "GWSC1_StackerCraneCompleted",
         "dbNumber": 100,
         "offset": 28,
         "bit": 1,
@@ -149,7 +149,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_OutputCurrentColumn",
+        "fieldKey": "GWSC1_OutputCurrentColumn",
         "dbNumber": 100,
         "offset": 46,
         "bit": 1,
@@ -158,7 +158,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_OutputCurrentLayer",
+        "fieldKey": "GWSC1_OutputCurrentLayer",
         "dbNumber": 100,
         "offset": 48,
         "bit": 1,
@@ -167,7 +167,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "GWSC01_StackerCraneStatus",
+        "fieldKey": "GWSC1_StackerCraneStatus",
         "dbNumber": 100,
         "offset": 96,
         "bit": 1,
@@ -183,62 +183,17 @@
     "version": "1.0",
     "fields": [
       {
-        "fieldKey": "HCSC01_StackerCraneHeartBeat",
-        "dbNumber": 910,
+        "fieldKey": "HCSC1_InputTaskNum",
+        "dbNumber": 510,
         "offset": 0,
         "bit": 1,
-        "dataType": 1,
+        "dataType": 2,
         "length": 1,
         "direction": 2
       },
       {
-        "fieldKey": "HCSC01_StackerCraneStatus",
-        "dbNumber": 910,
-        "offset": 6,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_StackerCraneFaultCode",
-        "dbNumber": 910,
-        "offset": 8,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_StackerCraneWorkStatus",
-        "dbNumber": 910,
-        "offset": 20,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_StackerCraneRow",
-        "dbNumber": 910,
-        "offset": 22,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_StackerCraneColumn",
-        "dbNumber": 910,
-        "offset": 24,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_StackerCraneLayer",
-        "dbNumber": 910,
+        "fieldKey": "HCSC1_WorkAction",
+        "dbNumber": 510,
         "offset": 26,
         "bit": 1,
         "dataType": 1,
@@ -246,107 +201,125 @@
         "direction": 2
       },
       {
-        "fieldKey": "HCSC01_CurrentTaskNum",
-        "dbNumber": 910,
+        "fieldKey": "HCSC1_InputWorkType",
+        "dbNumber": 510,
+        "offset": 4,
+        "bit": 1,
+        "dataType": 1,
+        "length": 1,
+        "direction": 2
+      },
+      {
+        "fieldKey": "HCSC1_InputPickRow",
+        "dbNumber": 510,
+        "offset": 14,
+        "bit": 1,
+        "dataType": 1,
+        "length": 1,
+        "direction": 2
+      },
+      {
+        "fieldKey": "HCSC1_InputPickColumn",
+        "dbNumber": 510,
+        "offset": 16,
+        "bit": 1,
+        "dataType": 1,
+        "length": 1,
+        "direction": 2
+      },
+      {
+        "fieldKey": "HCSC1_InputPickLayer",
+        "dbNumber": 510,
+        "offset": 18,
+        "bit": 1,
+        "dataType": 1,
+        "length": 1,
+        "direction": 2
+      },
+      {
+        "fieldKey": "HCSC1_InputPlaceRow",
+        "dbNumber": 510,
+        "offset": 20,
+        "bit": 1,
+        "dataType": 1,
+        "length": 1,
+        "direction": 2
+      },
+      {
+        "fieldKey": "HCSC1_InputPlaceColumn",
+        "dbNumber": 510,
+        "offset": 22,
+        "bit": 1,
+        "dataType": 1,
+        "length": 1,
+        "direction": 2
+      },
+      {
+        "fieldKey": "HCSC1_InputPlaceLayer",
+        "dbNumber": 510,
+        "offset": 24,
+        "bit": 1,
+        "dataType": 1,
+        "length": 1,
+        "direction": 2
+      },
+      {
+        "fieldKey": "HCSC1_StackerCraneAutoStatus",
+        "dbNumber": 510,
         "offset": 28,
         "bit": 1,
-        "dataType": 2,
+        "dataType": 1,
         "length": 1,
         "direction": 2
       },
       {
-        "fieldKey": "HCSC01_StackerCraneWorkAction",
-        "dbNumber": 910,
-        "offset": 40,
+        "fieldKey": "HCSC1_StackerCraneWorkStatus",
+        "dbNumber": 510,
+        "offset": 30,
         "bit": 1,
         "dataType": 1,
         "length": 1,
         "direction": 2
       },
       {
-        "fieldKey": "HCSC01_StackerCraneCompleted",
-        "dbNumber": 910,
-        "offset": 42,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_HeartBeat",
-        "dbNumber": 900,
-        "offset": 0,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_TaskNum",
-        "dbNumber": 900,
-        "offset": 2,
+        "fieldKey": "HCSC1_OutputFaultHigh",
+        "dbNumber": 510,
+        "offset": 32,
         "bit": 1,
         "dataType": 2,
         "length": 1,
         "direction": 2
       },
       {
-        "fieldKey": "HCSC01_WorkAction",
-        "dbNumber": 900,
+        "fieldKey": "HCSC1_OutputFaultMid",
+        "dbNumber": 510,
+        "offset": 36,
+        "bit": 1,
+        "dataType": 2,
+        "length": 1,
+        "direction": 2
+      },
+      {
+        "fieldKey": "HCSC1_OutputFaultLow",
+        "dbNumber": 510,
         "offset": 40,
         "bit": 1,
-        "dataType": 1,
+        "dataType": 2,
         "length": 1,
         "direction": 2
       },
       {
-        "fieldKey": "HCSC01_FireAlarm",
-        "dbNumber": 900,
-        "offset": 42,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_WorkType",
-        "dbNumber": 900,
-        "offset": 44,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_StartRow",
-        "dbNumber": 900,
-        "offset": 46,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_StartColumn",
-        "dbNumber": 900,
+        "fieldKey": "HCSC1_CurrentTaskNum",
+        "dbNumber": 510,
         "offset": 48,
         "bit": 1,
-        "dataType": 1,
+        "dataType": 2,
         "length": 1,
         "direction": 2
       },
       {
-        "fieldKey": "HCSC01_StartLayer",
-        "dbNumber": 900,
-        "offset": 50,
-        "bit": 1,
-        "dataType": 1,
-        "length": 1,
-        "direction": 2
-      },
-      {
-        "fieldKey": "HCSC01_EndRow",
-        "dbNumber": 900,
+        "fieldKey": "HCSC1_StackerCraneCompleted",
+        "dbNumber": 510,
         "offset": 52,
         "bit": 1,
         "dataType": 1,
@@ -354,8 +327,8 @@
         "direction": 2
       },
       {
-        "fieldKey": "HCSC01_EndColumn",
-        "dbNumber": 900,
+        "fieldKey": "HCSC1_OutputCurrentColumn",
+        "dbNumber": 510,
         "offset": 54,
         "bit": 1,
         "dataType": 1,
@@ -363,8 +336,8 @@
         "direction": 2
       },
       {
-        "fieldKey": "HCSC01_EndLayer",
-        "dbNumber": 900,
+        "fieldKey": "HCSC1_OutputCurrentLayer",
+        "dbNumber": 510,
         "offset": 56,
         "bit": 1,
         "dataType": 1,
@@ -372,12 +345,21 @@
         "direction": 2
       },
       {
-        "fieldKey": "HCSC01_Barcode",
-        "dbNumber": 900,
+        "fieldKey": "HCSC1_StackerCraneStatus",
+        "dbNumber": 510,
         "offset": 58,
         "bit": 1,
-        "dataType": 3,
-        "length": 26,
+        "dataType": 1,
+        "length": 1,
+        "direction": 2
+      },
+      {
+        "fieldKey": "HCSC1_OutputFaultLow1",
+        "dbNumber": 510,
+        "offset": 44,
+        "bit": 1,
+        "dataType": 2,
+        "length": 1,
         "direction": 2
       }
     ]
@@ -388,7 +370,7 @@
     "version": "1.0",
     "fields": [
       {
-        "fieldKey": "CWSC01_InputTaskNum",
+        "fieldKey": "CWSC1_InputTaskNum",
         "dbNumber": 100,
         "offset": 194,
         "bit": 1,
@@ -397,7 +379,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_WorkAction",
+        "fieldKey": "CWSC1_WorkAction",
         "dbNumber": 100,
         "offset": 192,
         "bit": 1,
@@ -406,7 +388,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_InputWorkType",
+        "fieldKey": "CWSC1_InputWorkType",
         "dbNumber": 100,
         "offset": 198,
         "bit": 1,
@@ -415,7 +397,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_InputPickRow",
+        "fieldKey": "CWSC1_InputPickRow",
         "dbNumber": 100,
         "offset": 208,
         "bit": 1,
@@ -424,7 +406,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_InputPickColumn",
+        "fieldKey": "CWSC1_InputPickColumn",
         "dbNumber": 100,
         "offset": 210,
         "bit": 1,
@@ -433,7 +415,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_InputPickLayer",
+        "fieldKey": "CWSC1_InputPickLayer",
         "dbNumber": 100,
         "offset": 212,
         "bit": 1,
@@ -442,7 +424,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_InputPlaceRow",
+        "fieldKey": "CWSC1_InputPlaceRow",
         "dbNumber": 100,
         "offset": 214,
         "bit": 1,
@@ -451,7 +433,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_InputPlaceColumn",
+        "fieldKey": "CWSC1_InputPlaceColumn",
         "dbNumber": 100,
         "offset": 216,
         "bit": 1,
@@ -460,7 +442,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_InputPlaceLayer",
+        "fieldKey": "CWSC1_InputPlaceLayer",
         "dbNumber": 100,
         "offset": 218,
         "bit": 1,
@@ -469,7 +451,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_StackerCraneAutoStatus",
+        "fieldKey": "CWSC1_StackerCraneAutoStatus",
         "dbNumber": 100,
         "offset": 2,
         "bit": 1,
@@ -478,7 +460,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_StackerCraneWorkStatus",
+        "fieldKey": "CWSC1_StackerCraneWorkStatus",
         "dbNumber": 100,
         "offset": 4,
         "bit": 1,
@@ -487,7 +469,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_OutputFaultHigh",
+        "fieldKey": "CWSC1_OutputFaultHigh",
         "dbNumber": 100,
         "offset": 12,
         "bit": 1,
@@ -496,7 +478,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_OutputFaultMid",
+        "fieldKey": "CWSC1_OutputFaultMid",
         "dbNumber": 100,
         "offset": 16,
         "bit": 1,
@@ -505,7 +487,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_OutputFaultLow",
+        "fieldKey": "CWSC1_OutputFaultLow",
         "dbNumber": 100,
         "offset": 20,
         "bit": 1,
@@ -514,7 +496,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_CurrentTaskNum",
+        "fieldKey": "CWSC1_CurrentTaskNum",
         "dbNumber": 100,
         "offset": 24,
         "bit": 1,
@@ -523,7 +505,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_StackerCraneCompleted",
+        "fieldKey": "CWSC1_StackerCraneCompleted",
         "dbNumber": 100,
         "offset": 28,
         "bit": 1,
@@ -532,7 +514,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_OutputCurrentColumn",
+        "fieldKey": "CWSC1_OutputCurrentColumn",
         "dbNumber": 100,
         "offset": 46,
         "bit": 1,
@@ -541,7 +523,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_OutputCurrentLayer",
+        "fieldKey": "CWSC1_OutputCurrentLayer",
         "dbNumber": 100,
         "offset": 48,
         "bit": 1,
@@ -550,7 +532,7 @@
         "direction": 2
       },
       {
-        "fieldKey": "CWSC01_StackerCraneStatus",
+        "fieldKey": "CWSC1_StackerCraneStatus",
         "dbNumber": 100,
         "offset": 96,
         "bit": 1,

--
Gitblit v1.9.3