From e091fb94e8dbcd71261b35a60f23a1e00ced8931 Mon Sep 17 00:00:00 2001 From: nodyang Date: Wed, 9 Aug 2023 08:57:26 +0800 Subject: [PATCH] demo --- .../Mesnac.Action.ChemicalWeighing/Global.cs | 2 +- .../LjMixManager/FrmMixB.cs | 17 +- .../LjMixManager/FrmMixC.cs | 44 +++- .../LjMixManager/LjMixManagerDb.cs | 34 ++- .../LjMixManager/LjMixManagerPlc.cs | 238 +++++++++++++++++- .../LjMixManager/RecipePlcView.cs | 14 ++ 6 files changed, 331 insertions(+), 18 deletions(-) diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Global.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Global.cs index f2b08e9..d9465e7 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Global.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/Global.cs @@ -58,7 +58,7 @@ namespace Mesnac.Action.ChemicalWeighing } } - private PublicVar() + private PublicVar() { } diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/FrmMixB.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/FrmMixB.cs index 7ce806b..249f351 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/FrmMixB.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/FrmMixB.cs @@ -122,10 +122,23 @@ namespace Mesnac.Action.ChemicalWeighing.LjMixManager LjMixManagerPlc.DownG2Recipe(rG1,rG2, recipeSteps); break; case 3 : - LjMixManagerPlc.DownG2Recipe(rG1,rG2, recipeSteps); + LjMixManagerPlc.DownG3Recipe(rG1,rG2, recipeSteps); break; case 4 : - LjMixManagerPlc.DownG2Recipe(rG1,rG2, recipeSteps); + LjMixManagerPlc.DownG4Recipe(rG1,rG2, recipeSteps); + break; + + case 5 : + LjMixManagerPlc.DownG5Recipe(rG1,rG2, recipeSteps); + break; + case 6 : + LjMixManagerPlc.DownG6Recipe(rG1,rG2, recipeSteps); + break; + case 7 : + LjMixManagerPlc.DownG7Recipe(rG1,rG2, recipeSteps); + break; + case 8 : + LjMixManagerPlc.DownG8Recipe(rG1,rG2, recipeSteps); break; } diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/FrmMixC.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/FrmMixC.cs index ccd10e6..e3305e5 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/FrmMixC.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/FrmMixC.cs @@ -4,12 +4,7 @@ using Mesnac.Action.ChemicalWeighing.LjPlanning; using System; using System.Collections.Generic; -using System.ComponentModel; -using System.Data; -using System.Drawing; -using System.Linq; -using System.Text; -using System.Threading.Tasks; + using System.Windows.Forms; namespace Mesnac.Action.ChemicalWeighing.LjMixManager @@ -70,6 +65,43 @@ namespace Mesnac.Action.ChemicalWeighing.LjMixManager _view.MixCName = DrpMixC.Text; LjMixManagerDb.UpdateMixC(_view); + + List recipeSteps = new List(); + recipeSteps=LjMixManagerDb.GetMixStep( _view.MixBId); + + + // 第一台干混机 + + switch (_id) + { + case 1 : + LjMixManagerPlc.DownM1Recipe(recipeSteps); + break; + case 2 : + LjMixManagerPlc.DownM2Recipe(recipeSteps); + break; + case 3 : + LjMixManagerPlc.DownM3Recipe(recipeSteps); + break; + case 4 : + LjMixManagerPlc.DownM4Recipe(recipeSteps); + break; + + case 5 : + LjMixManagerPlc.DownM5Recipe(recipeSteps); + break; + case 6 : + LjMixManagerPlc.DownM6Recipe(recipeSteps); + break; + case 7 : + LjMixManagerPlc.DownM7Recipe(recipeSteps); + break; + case 8 : + LjMixManagerPlc.DownM8Recipe(recipeSteps); + break; + } + + this.DialogResult = DialogResult.OK; } } diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/LjMixManagerDb.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/LjMixManagerDb.cs index 44502c8..2971cd9 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/LjMixManagerDb.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/LjMixManagerDb.cs @@ -280,7 +280,7 @@ namespace Mesnac.Action.ChemicalWeighing.LjMixManager return list; } - + public static List GetStep(string metageId) { string sql = @@ -301,6 +301,38 @@ namespace Mesnac.Action.ChemicalWeighing.LjMixManager step.MixTemp = Convert.ToInt32(tableRow["SecondTime"]); //速度 step.MixSpeed = Convert.ToInt32(tableRow["SecondTime"]); + + + list.Add(step); + } + + return list; + } + + + public static List GetMixStep(string metageId) + { + string sql = + $" select Id, MixId, ActionId, ActionName, SecondTime, Temperature, Speed, Weight, Difference, Remark " + + $" from lj_mix_detail where MixId='{metageId}'"; + + var table = GetTable(sql); + + List list = new List(); + foreach (DataRow tableRow in table.Rows) + { + MixStep step = new MixStep(); + //代码 + step.MixCode = Convert.ToInt32(tableRow["ActionId"]); + //时间 + step.MixTime = Convert.ToInt32(tableRow["SecondTime"]); + //温度 + step.MixTemp = Convert.ToInt32(tableRow["SecondTime"]); + //速度 + step.MixSpeed = Convert.ToInt32(tableRow["SecondTime"]); + + step.SetValue = Convert.ToSingle(tableRow["Weight"]); + step.Tolerance = Convert.ToSingle(tableRow["Difference"]); list.Add(step); } diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/LjMixManagerPlc.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/LjMixManagerPlc.cs index 800bb67..0434bac 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/LjMixManagerPlc.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/LjMixManagerPlc.cs @@ -2262,7 +2262,7 @@ if (i == 9) } - public static void DownM1Recipe(List recipeSteps) + public static void DownM1Recipe(List recipeSteps) { var basePlcHelper = BasePlcHelper.Instance; for (int i = 0; i < recipeSteps.Count; i++) @@ -2278,6 +2278,9 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step0_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step0_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step0_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step0_tolerance, view.Tolerance); } if (i == 1) { @@ -2289,6 +2292,10 @@ if (i == 1) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step1_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step1_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step1_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step1_tolerance, view.Tolerance); + } if (i == 2) { @@ -2300,6 +2307,10 @@ if (i == 2) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step2_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step2_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step2_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step2_tolerance, view.Tolerance); + } if (i == 3) { @@ -2311,6 +2322,10 @@ if (i == 3) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step3_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step3_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step3_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step3_tolerance, view.Tolerance); + } if (i == 4) { @@ -2322,6 +2337,10 @@ if (i == 4) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step4_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step4_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step4_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step4_tolerance, view.Tolerance); + } if (i == 5) { @@ -2333,6 +2352,10 @@ if (i == 5) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step5_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step5_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step5_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step5_tolerance, view.Tolerance); + } if (i == 6) { @@ -2344,6 +2367,11 @@ if (i == 6) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step6_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step6_mixSpeed, view.MixSpeed); + + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step6_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step6_tolerance, view.Tolerance); + } if (i == 7) { @@ -2355,6 +2383,10 @@ if (i == 7) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step7_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step7_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step7_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step7_tolerance, view.Tolerance); + } if (i == 8) { @@ -2366,6 +2398,9 @@ if (i == 8) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step8_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step8_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step8_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step8_tolerance, view.Tolerance); } if (i == 9) { @@ -2377,6 +2412,9 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step9_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step9_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step9_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M1Step9_tolerance, view.Tolerance); } @@ -2385,7 +2423,7 @@ if (i == 9) - public static void DownM2Recipe(List recipeSteps) + public static void DownM2Recipe(List recipeSteps) { var basePlcHelper = BasePlcHelper.Instance; for (int i = 0; i < recipeSteps.Count; i++) @@ -2401,6 +2439,10 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step0_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step0_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step0_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step0_tolerance, view.Tolerance); + } if (i == 1) { @@ -2412,6 +2454,10 @@ if (i == 1) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step1_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step1_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step1_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step1_tolerance, view.Tolerance); + } if (i == 2) { @@ -2423,6 +2469,10 @@ if (i == 2) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step2_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step2_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step2_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step2_tolerance, view.Tolerance); + } if (i == 3) { @@ -2434,6 +2484,10 @@ if (i == 3) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step3_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step3_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step3_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step3_tolerance, view.Tolerance); + } if (i == 4) { @@ -2445,6 +2499,10 @@ if (i == 4) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step4_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step4_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step4_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step4_tolerance, view.Tolerance); + } if (i == 5) { @@ -2456,6 +2514,10 @@ if (i == 5) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step5_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step5_mixSpeed, view.MixSpeed); + + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step5_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step5_tolerance, view.Tolerance); } if (i == 6) { @@ -2467,6 +2529,10 @@ if (i == 6) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step6_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step6_mixSpeed, view.MixSpeed); + + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step6_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step6_tolerance, view.Tolerance); } if (i == 7) { @@ -2478,6 +2544,8 @@ if (i == 7) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step7_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step7_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step7_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step7_tolerance, view.Tolerance); } if (i == 8) { @@ -2489,6 +2557,10 @@ if (i == 8) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step8_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step8_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step8_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step8_tolerance, view.Tolerance); + } if (i == 9) { @@ -2500,10 +2572,13 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step9_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step9_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step9_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M2Step9_tolerance, view.Tolerance); } } } - public static void DownM3Recipe(List recipeSteps) + public static void DownM3Recipe(List recipeSteps) { var basePlcHelper = BasePlcHelper.Instance; for (int i = 0; i < recipeSteps.Count; i++) @@ -2519,6 +2594,8 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step0_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step0_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step0_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step0_tolerance, view.Tolerance); } if (i == 1) { @@ -2530,6 +2607,8 @@ if (i == 1) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step1_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step1_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step1_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step1_tolerance, view.Tolerance); } if (i == 2) { @@ -2541,6 +2620,9 @@ if (i == 2) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step2_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step2_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step2_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step2_tolerance, view.Tolerance); + } if (i == 3) { @@ -2552,6 +2634,9 @@ if (i == 3) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step3_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step3_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step3_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step3_tolerance, view.Tolerance); } if (i == 4) { @@ -2563,6 +2648,8 @@ if (i == 4) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step4_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step4_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step4_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step4_tolerance, view.Tolerance); } if (i == 5) { @@ -2574,6 +2661,8 @@ if (i == 5) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step5_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step5_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step5_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step5_tolerance, view.Tolerance); } if (i == 6) { @@ -2585,6 +2674,9 @@ if (i == 6) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step6_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step6_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step6_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step6_tolerance, view.Tolerance); } if (i == 7) { @@ -2596,6 +2688,9 @@ if (i == 7) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step7_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step7_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step7_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step7_tolerance, view.Tolerance); } if (i == 8) { @@ -2607,6 +2702,8 @@ if (i == 8) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step8_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step8_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step8_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step8_tolerance, view.Tolerance); } if (i == 9) { @@ -2618,12 +2715,15 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step9_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step9_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step9_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M3Step9_tolerance, view.Tolerance); } } } - public static void DownM4Recipe(List recipeSteps) + public static void DownM4Recipe(List recipeSteps) { var basePlcHelper = BasePlcHelper.Instance; for (int i = 0; i < recipeSteps.Count; i++) @@ -2639,6 +2739,9 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step0_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step0_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step0_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step0_tolerance, view.Tolerance); } if (i == 1) { @@ -2650,6 +2753,9 @@ if (i == 1) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step1_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step1_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step1_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step1_tolerance, view.Tolerance); } if (i == 2) { @@ -2661,6 +2767,9 @@ if (i == 2) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step2_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step2_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step2_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step2_tolerance, view.Tolerance); } if (i == 3) { @@ -2672,6 +2781,8 @@ if (i == 3) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step3_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step3_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step3_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step3_tolerance, view.Tolerance); } if (i == 4) { @@ -2683,6 +2794,9 @@ if (i == 4) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step4_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step4_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step4_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step4_tolerance, view.Tolerance); } if (i == 5) { @@ -2694,6 +2808,8 @@ if (i == 5) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step5_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step5_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step5_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step5_tolerance, view.Tolerance); } if (i == 6) { @@ -2705,6 +2821,9 @@ if (i == 6) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step6_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step6_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step6_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step6_tolerance, view.Tolerance); } if (i == 7) { @@ -2716,6 +2835,9 @@ if (i == 7) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step7_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step7_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step7_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step7_tolerance, view.Tolerance); } if (i == 8) { @@ -2727,6 +2849,9 @@ if (i == 8) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step8_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step8_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step8_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step8_tolerance, view.Tolerance); } if (i == 9) { @@ -2738,11 +2863,14 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step9_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step9_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step9_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M4Step9_tolerance, view.Tolerance); } } } - public static void DownM5Recipe(List recipeSteps) + public static void DownM5Recipe(List recipeSteps) { var basePlcHelper = BasePlcHelper.Instance; for (int i = 0; i < recipeSteps.Count; i++) @@ -2758,6 +2886,9 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step0_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step0_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step0_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step0_tolerance, view.Tolerance); } if (i == 1) { @@ -2769,6 +2900,8 @@ if (i == 1) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step1_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step1_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step1_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step1_tolerance, view.Tolerance); } if (i == 2) { @@ -2780,6 +2913,8 @@ if (i == 2) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step2_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step2_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step2_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step2_tolerance, view.Tolerance); } if (i == 3) { @@ -2791,6 +2926,9 @@ if (i == 3) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step3_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step3_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step3_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step3_tolerance, view.Tolerance); } if (i == 4) { @@ -2802,6 +2940,8 @@ if (i == 4) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step4_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step4_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step4_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step4_tolerance, view.Tolerance); } if (i == 5) { @@ -2813,6 +2953,8 @@ if (i == 5) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step5_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step5_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step5_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step5_tolerance, view.Tolerance); } if (i == 6) { @@ -2824,6 +2966,10 @@ if (i == 6) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step6_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step6_mixSpeed, view.MixSpeed); + + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step6_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step6_tolerance, view.Tolerance); } if (i == 7) { @@ -2835,6 +2981,8 @@ if (i == 7) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step7_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step7_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step7_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step7_tolerance, view.Tolerance); } if (i == 8) { @@ -2846,6 +2994,8 @@ if (i == 8) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step8_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step8_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step8_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step8_tolerance, view.Tolerance); } if (i == 9) { @@ -2857,11 +3007,13 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step9_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step9_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step9_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M5Step9_tolerance, view.Tolerance); } } } - public static void DownM6Recipe(List recipeSteps) + public static void DownM6Recipe(List recipeSteps) { var basePlcHelper = BasePlcHelper.Instance; for (int i = 0; i < recipeSteps.Count; i++) @@ -2878,6 +3030,9 @@ if (i == 0) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step0_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step0_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step0_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step0_tolerance, view.Tolerance); } if (i == 1) { @@ -2889,6 +3044,8 @@ if (i == 1) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step1_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step1_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step1_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step1_tolerance, view.Tolerance); } if (i == 2) { @@ -2900,6 +3057,9 @@ if (i == 2) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step2_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step2_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step2_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step2_tolerance, view.Tolerance); } if (i == 3) { @@ -2911,6 +3071,9 @@ if (i == 3) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step3_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step3_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step3_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step3_tolerance, view.Tolerance); } if (i == 4) { @@ -2922,6 +3085,8 @@ if (i == 4) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step4_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step4_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step4_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step4_tolerance, view.Tolerance); } if (i == 5) { @@ -2933,6 +3098,8 @@ if (i == 5) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step5_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step5_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step5_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step5_tolerance, view.Tolerance); } if (i == 6) { @@ -2944,6 +3111,8 @@ if (i == 6) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step6_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step6_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step6_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step6_tolerance, view.Tolerance); } if (i == 7) { @@ -2955,6 +3124,9 @@ if (i == 7) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step7_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step7_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step7_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step7_tolerance, view.Tolerance); } if (i == 8) { @@ -2966,6 +3138,8 @@ if (i == 8) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step8_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step8_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step8_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step8_tolerance, view.Tolerance); } if (i == 9) { @@ -2977,12 +3151,15 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step9_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step9_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step9_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M6Step9_tolerance, view.Tolerance); } } } - public static void DownM7Recipe(List recipeSteps) + public static void DownM7Recipe(List recipeSteps) { var basePlcHelper = BasePlcHelper.Instance; for (int i = 0; i < recipeSteps.Count; i++) @@ -2998,6 +3175,8 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step0_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step0_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step0_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step0_tolerance, view.Tolerance); } if (i == 1) { @@ -3009,6 +3188,9 @@ if (i == 1) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step1_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step1_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step1_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step1_tolerance, view.Tolerance); } if (i == 2) { @@ -3020,6 +3202,9 @@ if (i == 2) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step2_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step2_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step2_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step2_tolerance, view.Tolerance); } if (i == 3) { @@ -3031,6 +3216,8 @@ if (i == 3) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step3_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step3_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step3_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step3_tolerance, view.Tolerance); } if (i == 4) { @@ -3042,6 +3229,8 @@ if (i == 4) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step4_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step4_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step4_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step4_tolerance, view.Tolerance); } if (i == 5) { @@ -3053,6 +3242,8 @@ if (i == 5) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step5_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step5_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step5_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step5_tolerance, view.Tolerance); } if (i == 6) { @@ -3064,6 +3255,8 @@ if (i == 6) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step6_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step6_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step6_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step6_tolerance, view.Tolerance); } if (i == 7) { @@ -3075,6 +3268,8 @@ if (i == 7) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step7_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step7_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step7_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step7_tolerance, view.Tolerance); } if (i == 8) { @@ -3086,6 +3281,8 @@ if (i == 8) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step8_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step8_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step8_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step8_tolerance, view.Tolerance); } if (i == 9) { @@ -3097,10 +3294,13 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step9_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step9_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step9_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M7Step9_tolerance, view.Tolerance); } } } - public static void DownM8Recipe(List recipeSteps) + public static void DownM8Recipe(List recipeSteps) { var basePlcHelper = BasePlcHelper.Instance; for (int i = 0; i < recipeSteps.Count; i++) @@ -3116,6 +3316,9 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step0_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step0_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step0_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step0_tolerance, view.Tolerance); } if (i == 1) { @@ -3127,6 +3330,8 @@ if (i == 1) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step1_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step1_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step1_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step1_tolerance, view.Tolerance); } if (i == 2) { @@ -3138,6 +3343,9 @@ if (i == 2) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step2_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step2_mixSpeed, view.MixSpeed); + + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step2_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step2_tolerance, view.Tolerance); } if (i == 3) { @@ -3149,6 +3357,8 @@ if (i == 3) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step3_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step3_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step3_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step3_tolerance, view.Tolerance); } if (i == 4) { @@ -3160,6 +3370,8 @@ if (i == 4) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step4_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step4_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step4_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step4_tolerance, view.Tolerance); } if (i == 5) { @@ -3171,6 +3383,8 @@ if (i == 5) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step5_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step5_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step5_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step5_tolerance, view.Tolerance); } if (i == 6) { @@ -3182,6 +3396,8 @@ if (i == 6) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step6_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step6_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step6_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step6_tolerance, view.Tolerance); } if (i == 7) { @@ -3193,6 +3409,8 @@ if (i == 7) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step7_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step7_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step7_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step7_tolerance, view.Tolerance); } if (i == 8) { @@ -3204,6 +3422,8 @@ if (i == 8) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step8_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step8_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step8_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step8_tolerance, view.Tolerance); } if (i == 9) { @@ -3215,6 +3435,8 @@ if (i == 9) basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step9_mixTemp, view.MixTemp); basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step9_mixSpeed, view.MixSpeed); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step9_setValue, view.SetValue); + basePlcHelper.PlcWriteFloatByDataKey(basePlcHelper.Weter_M8Step9_tolerance, view.Tolerance); } } } diff --git a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/RecipePlcView.cs b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/RecipePlcView.cs index cc4b1ac..a7d01aa 100644 --- a/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/RecipePlcView.cs +++ b/Actions/ChemicalWeighing/Mesnac.Action.ChemicalWeighing/LjMixManager/RecipePlcView.cs @@ -14,4 +14,18 @@ public float MixTemp { get; set; } public float MixSpeed { get; set; } } + + + public class MixStep : Step + { + /// + /// 设定重量 + /// + public float SetValue { get; set; } + + /// + /// 设定公差 + /// + public float Tolerance { get; set; } + } } \ No newline at end of file