From 9fa025caa437068e6693ddd69f130164ccf51fc2 Mon Sep 17 00:00:00 2001 From: Milan Hanajik Date: Thu, 28 Sep 2017 17:11:41 +0200 Subject: [PATCH] Diverter and start/stop valve switch time logging in ms, ver. 2.17.679 --- .../CombinedWithDetection/CombinedWithDetectionSeq.cs | 6 ++++-- .../FixedStartMassCollectionSeq.cs | 6 ++++-- .../FlyingStartMassCollectionSeq.cs | 8 ++++---- .../ReferenceFlowmeterCalibrationSeq.cs | 6 ++++-- TestBenchFramework/Properties/AssemblyInfo.cs | 4 ++-- 5 files changed, 18 insertions(+), 12 deletions(-) diff --git a/TestBenchFramework/BenchControl/TestMethods/CombinedWithDetection/CombinedWithDetectionSeq.cs b/TestBenchFramework/BenchControl/TestMethods/CombinedWithDetection/CombinedWithDetectionSeq.cs index 0e7b0687e..ed57521ec 100644 --- a/TestBenchFramework/BenchControl/TestMethods/CombinedWithDetection/CombinedWithDetectionSeq.cs +++ b/TestBenchFramework/BenchControl/TestMethods/CombinedWithDetection/CombinedWithDetectionSeq.cs @@ -509,7 +509,8 @@ namespace TBF.BenchControl.TestMethods.CombinedWithDetection int estimtdEndTime = StateMachine.Time + (int)test.TstTime; /// Read the diverter switch time - switchTimeStart = (float)cBrd.DivTime / 1000.0f; + switchTimeStart = 0.001f * (float)cBrd.DivTime; + log.WarnFormat("Diverter switch time on test start = {0} ms", cBrd.DivTime); /// Measurement loop - begin while (true) @@ -571,7 +572,8 @@ namespace TBF.BenchControl.TestMethods.CombinedWithDetection TestEndTime = DateTime.Now; /// Read the diverter switch time - switchTimeEnd = (float)cBrd.DivTime / 1000.0f; + switchTimeEnd = 0.001f * (float)cBrd.DivTime; + log.WarnFormat("Diverter switch time on test end = {0} ms", cBrd.DivTime); //------------------------------------------------ Bridge.OnActivity(this, Strings.Test_completed); diff --git a/TestBenchFramework/BenchControl/TestMethods/FixedStartMassCollection/FixedStartMassCollectionSeq.cs b/TestBenchFramework/BenchControl/TestMethods/FixedStartMassCollection/FixedStartMassCollectionSeq.cs index 157c2c023..702cdfad6 100644 --- a/TestBenchFramework/BenchControl/TestMethods/FixedStartMassCollection/FixedStartMassCollectionSeq.cs +++ b/TestBenchFramework/BenchControl/TestMethods/FixedStartMassCollection/FixedStartMassCollectionSeq.cs @@ -539,7 +539,8 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection } while (!e.Contains(Event.ValvesSet)); - switchTimeStart = cBrd.ValveOpenCloseTime / 1000.0f; + switchTimeStart = 0.001f * cBrd.ValveOpenCloseTime; + log.WarnFormat("Start valve switch time on test start = {0} ms", cBrd.ValveOpenCloseTime); /// Measurement loop - preparation readRegistersOp = new Operations.ReadMoreRegistersOp(sensPath.RegisterReaders); @@ -648,7 +649,8 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection } while (e.Contains(Event.ValvesBusy)); - switchTimeEnd = cBrd.ValveOpenCloseTime / 1000.0f; + switchTimeEnd = 0.001f * cBrd.ValveOpenCloseTime; + log.WarnFormat("Start valve switch time on test end = {0} ms", cBrd.ValveOpenCloseTime); State.Create(string.Format("{0}({1}) : Waiting before 2nd mass measurement", test.Method, test.Name)) .AddOperation(checkUiOp) diff --git a/TestBenchFramework/BenchControl/TestMethods/FlyingStartMassCollection/FlyingStartMassCollectionSeq.cs b/TestBenchFramework/BenchControl/TestMethods/FlyingStartMassCollection/FlyingStartMassCollectionSeq.cs index 7981dfe1d..74fae4fe8 100644 --- a/TestBenchFramework/BenchControl/TestMethods/FlyingStartMassCollection/FlyingStartMassCollectionSeq.cs +++ b/TestBenchFramework/BenchControl/TestMethods/FlyingStartMassCollection/FlyingStartMassCollectionSeq.cs @@ -597,8 +597,8 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollection ClearAllStatistics(StateMachine.Time); /// Read the diverter switch time - switchTimeStart = (float)cBrd.DivTime / 1000.0f; - log.WarnFormat("Diverter switch time on test start = {0} ms", switchTimeStart); + switchTimeStart = 0.001f * (float)cBrd.DivTime; + log.WarnFormat("Diverter switch time on test start = {0} ms", cBrd.DivTime); /// Measurement loop - begin State.Create(string.Format("{0}({1}) : Reading watermeters", test.Method, test.Name)) @@ -724,8 +724,8 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollection else LogProcessDataHeaderHeatMeters(processDataLogger, "End mass"); /// Read the diverter switch time - switchTimeEnd = (float)cBrd.DivTime / 1000.0f; - log.WarnFormat("Diverter switch time on test end = {0} ms", switchTimeEnd); + switchTimeEnd = 0.001f * (float)cBrd.DivTime; + log.WarnFormat("Diverter switch time on test end = {0} ms", cBrd.DivTime); State.Create(string.Format("{0}({1}) : Measuring the end mass", test.Method, test.Name)) .AddOperation(checkUiOp) diff --git a/TestBenchFramework/BenchControl/TestMethods/ReferenceFlowmeterCalibration/ReferenceFlowmeterCalibrationSeq.cs b/TestBenchFramework/BenchControl/TestMethods/ReferenceFlowmeterCalibration/ReferenceFlowmeterCalibrationSeq.cs index d449cb6ee..d8ebf3418 100644 --- a/TestBenchFramework/BenchControl/TestMethods/ReferenceFlowmeterCalibration/ReferenceFlowmeterCalibrationSeq.cs +++ b/TestBenchFramework/BenchControl/TestMethods/ReferenceFlowmeterCalibration/ReferenceFlowmeterCalibrationSeq.cs @@ -223,7 +223,8 @@ namespace TBF.BenchControl.TestMethods.ReferenceFlowmeterCalibration ClearAllStatistics(StateMachine.Time); /// Read the diverter switch time - switchTimeStart = (float)cBrd.DivTime / 1000.0f; + switchTimeStart = 0.001f * (float)cBrd.DivTime; + log.WarnFormat("Diverter switch time on test start = {0} ms", cBrd.DivTime); /// Measurement loop - begin while (true) @@ -271,7 +272,8 @@ namespace TBF.BenchControl.TestMethods.ReferenceFlowmeterCalibration while (!e.Contains(Event.TimerExpired)); /// Read the diverter switch time - switchTimeEnd = (float)cBrd.DivTime / 1000.0f; + switchTimeEnd = 0.001f * (float)cBrd.DivTime; + log.WarnFormat("Diverter switch time on test end = {0} ms", cBrd.DivTime); //------------------------------------------------ Bridge.OnActivity(this, Strings.Measuring_the_weight); diff --git a/TestBenchFramework/Properties/AssemblyInfo.cs b/TestBenchFramework/Properties/AssemblyInfo.cs index 5d5e6d386..a89ebf120 100644 --- a/TestBenchFramework/Properties/AssemblyInfo.cs +++ b/TestBenchFramework/Properties/AssemblyInfo.cs @@ -29,5 +29,5 @@ using System.Runtime.InteropServices; // Build Number // Revision // -[assembly: AssemblyVersion("2.17.678.1")] -[assembly: AssemblyFileVersion("2.17.678.1")] +[assembly: AssemblyVersion("2.17.679.1")] +[assembly: AssemblyFileVersion("2.17.679.1")]