From 5ef5b7db2fde53ba73120ec1069035053fb70653 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=88=91=E5=8F=AB=E9=94=84=E5=A4=B4?= Date: Tue, 9 Jan 2024 14:04:43 +0800 Subject: [PATCH] DB2107WriteHelper.CleanSpare(deviceno); --- .../Mesnac.Action.ChemicalWeighing/Report/ReportReadDb.cs | 6 ++++-- DataBlockHelper/DBHelpers/DB2107WriteHelper.cs | 3 +++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Report/ReportReadDb.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Report/ReportReadDb.cs index c4074f3..99d7733 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Report/ReportReadDb.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Report/ReportReadDb.cs @@ -43,6 +43,7 @@ namespace Mesnac.Action.ChemicalWeighing.Report if (nornalStatus.spare1) { FeededDry(1, dB2111Helper.DryDosing_A); + } if (nornalStatus.spare2) @@ -133,7 +134,7 @@ namespace Mesnac.Action.ChemicalWeighing.Report private static void FeededDry(int deviceno, ReportDosEntity entity) { - DB2107WriteHelper.CleanSpare(deviceno); + int no = deviceno * 2; if (entity.eqNo == 1) { @@ -143,7 +144,8 @@ namespace Mesnac.Action.ChemicalWeighing.Report string logName = $"用户[{UserInfo.Instance.UserName}] 螺旋{deviceno}向湿混机 [{no}] 投料 {actValue}"; LoggingService.Info(logName); LjLogControl.ManualLogControl(logName, actValue, 4, no, 2); - + DB2107WriteHelper.CleanSpare(deviceno); + } public static void ReadReport() diff --git a/DataBlockHelper/DBHelpers/DB2107WriteHelper.cs b/DataBlockHelper/DBHelpers/DB2107WriteHelper.cs index d3843b9..6aec78c 100644 --- a/DataBlockHelper/DBHelpers/DB2107WriteHelper.cs +++ b/DataBlockHelper/DBHelpers/DB2107WriteHelper.cs @@ -16,6 +16,9 @@ namespace DataBlockHelper.DBHelpers siemensS7Net.Write($"{DbName}.8.{dian}", false); } + + + public static void CleanWater(int no) { int dian = no + 1;