Feeding regulation valves functionality implemented, ver. 2.11.367

This commit is contained in:
Milan Hanajik 2016-10-13 15:02:33 +02:00
parent 45e0f50562
commit 0fb3a74879
10 changed files with 151 additions and 152 deletions

View File

@ -13,35 +13,29 @@ namespace TBF.BenchControl.Operations
private static readonly ILog log = LogManager.GetLogger(typeof(SetAllRegulValvesOp)); private static readonly ILog log = LogManager.GetLogger(typeof(SetAllRegulValvesOp));
public override string ToString() { return string.Format("SetAllRegulValvesOp()"); } public override string ToString() { return string.Format("SetAllRegulValvesOp()"); }
IList<IRegulValve> regulValves;
int rvCount; int rvCount;
IOperation[] setRVPosOps; IOperation[] setRVPosOps;
public SetAllRegulValvesOp(IList<IRegulValve> regulValves, string encodedPositions, int timeout) public SetAllRegulValvesOp(IList<IRegulValve> regulValves, IList<float> positions, int timeout)
{
if (regulValves == null || regulValves.Count == 0)
{
rvCount = 0;
}
else
{ {
if (regulValves == null) throw new ArgumentNullException("regulValves");
this.regulValves = regulValves;
rvCount = regulValves.Count; rvCount = regulValves.Count;
if (positions == null || positions.Count != rvCount) throw new ArgumentNullException("positions");
// Parse the positions
float[] positions = new float[rvCount];
string[] rvPosStr = (encodedPositions != null) ? encodedPositions.Split(new char[] { ';' }) : new string[0];
for (int i = 0; i < Math.Min(rvCount, rvPosStr.Length); i++)
{
float posPct;
if (float.TryParse(rvPosStr[i], out posPct) && posPct >= 0 && posPct <= 100.0f)
{
positions[i] = posPct;
}
}
setRVPosOps = new IOperation[rvCount]; setRVPosOps = new IOperation[rvCount];
for (int i = 0; i < rvCount; i++) for (int i = 0; i < rvCount; i++)
{ {
float posLo = Math.Max(positions[i] - 5.0f, 0); float posLo = Math.Max(positions[i] - 3.0f, 0);
float posHi = Math.Min(positions[i] + 5.0f, 100.0f); float posHi = Math.Min(positions[i] + 3.0f, 100.0f);
setRVPosOps[i] = regulValves[i].SetRegulValvePositionOp(posLo, posHi, timeout); setRVPosOps[i] = regulValves[i].SetRegulValvePositionOp(posLo, posHi, timeout);
} }
} }
}
/// <summary>Start this operation</summary> /// <summary>Start this operation</summary>
public void Start() public void Start()
@ -60,6 +54,7 @@ namespace TBF.BenchControl.Operations
{ {
Event evnt = setRVPosOps[i].Run(); Event evnt = setRVPosOps[i].Run();
if (evnt == Event.Error) anyError = true; if (evnt == Event.Error) anyError = true;
else if (evnt == Event.OpArgumentError) anyTimeout = true;
else if (evnt == Event.RegulValveTimeOut) anyTimeout = true; else if (evnt == Event.RegulValveTimeOut) anyTimeout = true;
else if (evnt != Event.PositionReached) allDone = false; else if (evnt != Event.PositionReached) allDone = false;
} }

View File

@ -337,8 +337,8 @@ namespace TBF.BenchControl.Sequences
} }
else else
{ {
float lo = Math.Max(0, allRegvPositions[i] - 0.05f); float lo = Math.Max(0, allRegvPositions[i] - 3.0f);
float hi = Math.Min(100.0f, allRegvPositions[i] + 0.05f); float hi = Math.Min(100.0f, allRegvPositions[i] + 3.0f);
rvPosOps.Add(RegulValves[i].SetRegulValvePositionOp(lo, hi, 60)); rvPosOps.Add(RegulValves[i].SetRegulValvePositionOp(lo, hi, 60));
rvPosStr.Add(string.Format("RV{0}.SetRegulValvePositionOp({1}, {2}, 60s)", i, lo, hi)); rvPosStr.Add(string.Format("RV{0}.SetRegulValvePositionOp({1}, {2}, 60s)", i, lo, hi));
} }

View File

@ -95,28 +95,15 @@ namespace TBF.BenchControl.TestMethods.Adjustment
int flowSetTime0 = StateMachine.Time; int flowSetTime0 = StateMachine.Time;
//------------------------------------------------ //------------------------------------------------
Bridge.OnActivity(this, Strings.Setting_the_flow); Bridge.OnActivity(this, Strings.Starting_the_pump);
//------------------------------------------------ //------------------------------------------------
if (inPath.Pump is GenericDevices.IPumpFM) (inPath.Pump as GenericDevices.IPumpFM).TurnOn(test.PumpPower); if (inPath.Pump is GenericDevices.IPumpFM) (inPath.Pump as GenericDevices.IPumpFM).TurnOn(test.PumpPower);
///
State.Create("Adjustment : Waiting 5 sec")
.AddOperation(checkUiOp)
.AddOperation(new Operations.TimerOp(5))
.EnterState();
do
{
e = StateMachine.WaitRunDevsRunOps();
Bridge.OnProcessData(this, new ProcessDataEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
if (TestAndLogUiCmdStop(test,e)) { retVal = Event.UiCmdStop; goto stopTest; }
}
while (!e.Contains(Event.TimerExpired));
State.Create("Adjustment : Starting the pump") State.Create("Adjustment : Starting the pump")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(cBrd.SetValvesOp(inPath.Pump, null)) .AddOperation(StateMachine.ControlBoard.UpdateTankWeightOp())
.AddOperation(new Operations.SetAllRegulValvesOp(inPath.RegulValves, inPath.RegulValvesPct, 60))
.AddOperation(inPath.Pump != null ? cBrd.SetValvesOp(inPath.Pump, null) : null)
.EnterState(); .EnterState();
do do
{ {
@ -124,11 +111,35 @@ namespace TBF.BenchControl.TestMethods.Adjustment
Bridge.OnProcessData(this, new ProcessDataEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting)); Bridge.OnProcessData(this, new ProcessDataEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting)); Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
if (TestAndLogUiCmdStop(test,e)) { retVal = Event.UiCmdStop; goto stopTest; } if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
} if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
while (!e.Contains(Event.ValvesSet));
//-------------------------------- }
while (e.Contains(Event.ValvesBusy) || !e.Contains(Event.AllPositionsReached));
if (test.TimeBeforeFlow > 0)
{
State.Create("Adjustment : Waiting before flow setting process starts")
.AddOperation(checkUiOp)
.AddOperation(new Operations.TimerOp(test.TimeBeforeFlow))
.AddOperation(StateMachine.ControlBoard.UpdateTankWeightOp())
.EnterState();
do
{
e = StateMachine.WaitRunDevsRunOps();
Bridge.OnProcessData(this, new ProcessDataEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
}
while (!e.Contains(Event.TimerExpired));
}
//------------------------------------------------
Bridge.OnActivity(this, Strings.Setting_the_flow);
//------------------------------------------------
State.Create("Adjustment : Setting the flow") State.Create("Adjustment : Setting the flow")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(outPath.RegulValve.SetFlowOp(outPath.FlowMeter, test.Qfrom, test.Qto, outPath.PidCoef, RefFlow, 600)) /// timeout = 10 min. .AddOperation(outPath.RegulValve.SetFlowOp(outPath.FlowMeter, test.Qfrom, test.Qto, outPath.PidCoef, RefFlow, 600)) /// timeout = 10 min.

View File

@ -73,12 +73,22 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting)); Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
int flowSetTime0 = StateMachine.Time; int flowSetTime0 = StateMachine.Time;
///
/// Optionally display prompt to emerge temperature meters to appropriate baths for heat meters test
///
IOperation heatMetersPromptOp = null;
if (heatMetersTestParams != null && !string.IsNullOrEmpty(heatMetersTestParams.Prompt))
{
heatMetersPromptOp = new Operations.MessageBoxOp(heatMetersTestParams.Prompt);
}
//------------------------------------------------ //------------------------------------------------
Bridge.OnActivity(this, Strings.Setting_the_flow); Bridge.OnActivity(this, Strings.Starting_the_pump);
//------------------------------------------------ //------------------------------------------------
if (inPath.Pump is GenericDevices.IPumpFM) (inPath.Pump as GenericDevices.IPumpFM).TurnOn(test.PumpPower); if (inPath.Pump is GenericDevices.IPumpFM) (inPath.Pump as GenericDevices.IPumpFM).TurnOn(test.PumpPower);
State.Create("FixedStartMassCollection : Starting the pump") State.Create("FixedStartMassCollection : Waiting before starting the pump")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(new Operations.TimerOp(5)) .AddOperation(new Operations.TimerOp(5))
.EnterState(); .EnterState();
@ -91,11 +101,13 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; } if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
} }
while (!e.Contains(Event.TimerExpired)); while (!e.Contains(Event.TimerExpired));
///
State.Create("FixedStartMassCollection : Starting the pump") State.Create("FixedStartMassCollection : Starting the pump")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(cBrd.SetValvesOp(inPath.Pump, null)) .AddOperation(StateMachine.ControlBoard.UpdateTankWeightOp())
.AddOperation(new Operations.SetAllRegulValvesOp(inPath.RegulValves, inPath.RegulValvesPct, 60))
.AddOperation(heatMetersPromptOp)
.AddOperation(inPath.Pump != null ? cBrd.SetValvesOp(inPath.Pump, null) : null)
.EnterState(); .EnterState();
do do
{ {
@ -104,17 +116,10 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting)); Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; } if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
} if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
while (!e.Contains(Event.ValvesSet));
///
/// Optionally display prompt to emerge temperature meters to appropriate baths for heat meters test
///
IOperation heatMetersPrompt = null;
if (heatMetersTestParams != null && !string.IsNullOrEmpty(heatMetersTestParams.Prompt))
{
heatMetersPrompt = new Operations.MessageBoxOp(heatMetersTestParams.Prompt);
} }
while (e.Contains(Event.ValvesBusy) || !e.Contains(Event.AllPositionsReached));
if (!test.Emptying) /// If condition met => skip measuring and force emptying if (!test.Emptying) /// If condition met => skip measuring and force emptying
@ -125,7 +130,7 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
State.Create("FixedStartMassCollection : Measuring the mass of water in the tank") State.Create("FixedStartMassCollection : Measuring the mass of water in the tank")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(outPath.Balance.ReadMassOp(ref Mass)) .AddOperation(outPath.Balance.ReadMassOp(ref Mass))
.AddOperation(heatMetersPrompt) .AddOperation(heatMetersPromptOp)
.EnterState(); .EnterState();
do do
{ {
@ -148,7 +153,7 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
/// ///
/// Empty the water tank /// Empty the water tank
/// ///
switch (EmptyTheTank(outPath.EmptyTankValve, outPath.Balance, heatMetersPrompt)) switch (EmptyTheTank(outPath.EmptyTankValve, outPath.Balance, heatMetersPromptOp))
{ {
case Event.Error: { retVal = Event.Error; goto stopTest; } case Event.Error: { retVal = Event.Error; goto stopTest; }
case Event.UiCmdStop: { retVal = Event.UiCmdStop; goto stopTest; } case Event.UiCmdStop: { retVal = Event.UiCmdStop; goto stopTest; }
@ -163,7 +168,7 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
State.Create("FixedStartMassCollection : Starting the pump") State.Create("FixedStartMassCollection : Starting the pump")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(cBrd.SetValvesOp(inPath.Pump, null)) .AddOperation(cBrd.SetValvesOp(inPath.Pump, null))
.AddOperation(heatMetersPrompt) .AddOperation(heatMetersPromptOp)
.EnterState(); .EnterState();
do do
{ {
@ -179,7 +184,7 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
State.Create("FixedStartMassCollection : Setting the flow") State.Create("FixedStartMassCollection : Setting the flow")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(outPath.RegulValve.SetFlowOp(outPath.FlowMeter, test.Qfrom, test.Qto, outPath.PidCoef, RefFlow, 600)) /// timeout = 10 min. .AddOperation(outPath.RegulValve.SetFlowOp(outPath.FlowMeter, test.Qfrom, test.Qto, outPath.PidCoef, RefFlow, 600)) /// timeout = 10 min.
.AddOperation(heatMetersPrompt) .AddOperation(heatMetersPromptOp)
.EnterState(); .EnterState();
do do
{ {
@ -219,7 +224,7 @@ namespace TBF.BenchControl.TestMethods.FixedStartMassCollection
.AddOperation(heatMetersPath.TMeterRefWarm2.ReadTempOp(ref TempRefWarm2)) .AddOperation(heatMetersPath.TMeterRefWarm2.ReadTempOp(ref TempRefWarm2))
.AddOperation(heatMetersPath.TMeterRefCold1.ReadTempOp(ref TempRefCold1)) .AddOperation(heatMetersPath.TMeterRefCold1.ReadTempOp(ref TempRefCold1))
.AddOperation(heatMetersPath.TMeterRefCold2.ReadTempOp(ref TempRefCold2)) .AddOperation(heatMetersPath.TMeterRefCold2.ReadTempOp(ref TempRefCold2))
.AddOperation(heatMetersPrompt) .AddOperation(heatMetersPromptOp)
.EnterState(); .EnterState();
do do
{ {

View File

@ -137,19 +137,17 @@ namespace TBF.BenchControl.TestMethods.FlyingStart
heatMetersPromptOp = new Operations.MessageBoxOp(heatMetersTestParams.Prompt); heatMetersPromptOp = new Operations.MessageBoxOp(heatMetersTestParams.Prompt);
} }
//------------------------------------------------ //------------------------------------------------
Bridge.OnActivity(this, Strings.Setting_the_flow); Bridge.OnActivity(this, Strings.Starting_the_pump);
//------------------------------------------------ //------------------------------------------------
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
int flowSetTime0 = StateMachine.Time;
if (inPath.Pump is GenericDevices.IPumpFM) (inPath.Pump as GenericDevices.IPumpFM).TurnOn(test.PumpPower); if (inPath.Pump is GenericDevices.IPumpFM) (inPath.Pump as GenericDevices.IPumpFM).TurnOn(test.PumpPower);
///
State.Create("FlyingStart : Starting the pump") State.Create("FlyingStart : Starting the pump")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(cBrd.SetValvesOp(inPath.Pump, null)) .AddOperation(StateMachine.ControlBoard.UpdateTankWeightOp())
.AddOperation(new Operations.SetAllRegulValvesOp(inPath.RegulValves, inPath.RegulValvesPct, 60))
.AddOperation(heatMetersPromptOp) .AddOperation(heatMetersPromptOp)
.AddOperation(inPath.Pump != null ? cBrd.SetValvesOp(inPath.Pump, null) : null)
.EnterState(); .EnterState();
do do
{ {
@ -157,11 +155,16 @@ namespace TBF.BenchControl.TestMethods.FlyingStart
Bridge.OnProcessData(this, new ProcessDataEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting)); Bridge.OnProcessData(this, new ProcessDataEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting)); Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
if (TestAndLogUiCmdStop(test,e)) { retVal = Event.UiCmdStop; goto stopTest; } if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
} if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
while (!e.Contains(Event.ValvesSet));
//-------------------------------- }
while (e.Contains(Event.ValvesBusy) || !e.Contains(Event.AllPositionsReached));
//------------------------------------------------
Bridge.OnActivity(this, Strings.Setting_the_flow);
//------------------------------------------------
int flowSetTime0 = StateMachine.Time;
State.Create("FlyingStart : Setting the flow") State.Create("FlyingStart : Setting the flow")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(outPath.RegulValve.SetFlowOp(outPath.FlowMeter, test.Qfrom, test.Qto, outPath.PidCoef, RefFlow, 990)) /// timeout = 16.5 min. .AddOperation(outPath.RegulValve.SetFlowOp(outPath.FlowMeter, test.Qfrom, test.Qto, outPath.PidCoef, RefFlow, 990)) /// timeout = 16.5 min.

View File

@ -177,30 +177,6 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollection
heatMetersPromptOp = new Operations.MessageBoxOp(heatMetersTestParams.Prompt); heatMetersPromptOp = new Operations.MessageBoxOp(heatMetersTestParams.Prompt);
} }
///
/// Start the pump, set feeding regulation valves
///
IList<IOperation> startFeedingOperations = new List<IOperation>();
if (inPath.Pump != null) startFeedingOperations.Add(cBrd.SetValvesOp(inPath.Pump, null));
//for (int i = 0; i < inPath.RegulValves.Count; i++)
//{
// GenericDevices.IRegulValve rv = inPath.RegulValves[i];
// float position = inPath.RegulValvesPct[i];
// if (rv.IsCoax)
// {
// startFeedingOperations.Add(rv.SetRegulValvePositionOp(position, position, 60));
// }
// else
// {
// float lo = Math.Max(0, position - 2.0f);
// float hi = Math.Min(100.0f, position + 2.0f);
// startFeedingOperations.Add(rv.SetRegulValvePositionOp(lo, hi, 60));
// }
//}
if (startFeedingOperations.Count > 0)
{
//------------------------------------------------ //------------------------------------------------
Bridge.OnActivity(this, Strings.Starting_the_pump); Bridge.OnActivity(this, Strings.Starting_the_pump);
//------------------------------------------------ //------------------------------------------------
@ -209,8 +185,9 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollection
State.Create("FlyingStartMassCollection : Starting the pump") State.Create("FlyingStartMassCollection : Starting the pump")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(StateMachine.ControlBoard.UpdateTankWeightOp()) .AddOperation(StateMachine.ControlBoard.UpdateTankWeightOp())
.AddOperation(new Operations.SetAllRegulValvesOp(inPath.RegulValves, inPath.RegulValvesPct, 60))
.AddOperation(heatMetersPromptOp) .AddOperation(heatMetersPromptOp)
.AddOperations(startFeedingOperations) .AddOperation(inPath.Pump != null ? cBrd.SetValvesOp(inPath.Pump, null) : null)
.EnterState(); .EnterState();
do do
{ {
@ -219,9 +196,9 @@ namespace TBF.BenchControl.TestMethods.FlyingStartMassCollection
Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting)); Bridge.OnTestProgress(this, new TestProgressEventArgs(test, repetitionNr, Config.Entities.Progress.FlowSetting));
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; } if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
} }
while (!e.Contains(Event.ValvesSet)); while (e.Contains(Event.ValvesBusy) || !e.Contains(Event.AllPositionsReached));
}
if (test.TimePump2StartV > 0) if (test.TimePump2StartV > 0)

View File

@ -60,18 +60,21 @@ namespace TBF.BenchControl.TestMethods.LeakTest
State.Create("LeakTest : Starting the pump") State.Create("LeakTest : Starting the pump")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(cBrd.SetValvesOp(inPath.Pump, null))
.AddOperation(benchPath.TempIn.ReadTempOp(ref TempIn)) .AddOperation(benchPath.TempIn.ReadTempOp(ref TempIn))
.AddOperation(benchPath.TempOut.ReadTempOp(ref TempOut)) .AddOperation(benchPath.TempOut.ReadTempOp(ref TempOut))
.AddOperation(benchPath.PressIn.ReadPressureOp(ref PressureUp)) .AddOperation(benchPath.PressIn.ReadPressureOp(ref PressureUp))
.AddOperation(benchPath.PressOut.ReadPressureOp(ref PressureDown)) .AddOperation(benchPath.PressOut.ReadPressureOp(ref PressureDown))
.AddOperation(new Operations.SetAllRegulValvesOp(inPath.RegulValves, inPath.RegulValvesPct, 60))
.AddOperation(inPath.Pump != null ? cBrd.SetValvesOp(inPath.Pump, null) : null)
.EnterState(); .EnterState();
do do
{ {
e = StateMachine.WaitRunDevsRunOps(); e = StateMachine.WaitRunDevsRunOps();
if (TestAndLogUiCmdStop(test,e)) { retVal = Event.UiCmdStop; goto stopTest; } if (TestAndLogUiCmdStop(test,e)) { retVal = Event.UiCmdStop; goto stopTest; }
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
} }
while (e.Contains(Event.ValvesBusy)); while (e.Contains(Event.ValvesBusy) || !e.Contains(Event.AllPositionsReached));
//------------------------------------------------ //------------------------------------------------
Bridge.OnActivity(this, Strings.Setting_the_water_pressure); Bridge.OnActivity(this, Strings.Setting_the_water_pressure);

View File

@ -61,18 +61,21 @@ namespace TBF.BenchControl.TestMethods.PMaxTest
State.Create("PMaxTest : Starting the pump") State.Create("PMaxTest : Starting the pump")
.AddOperation(checkUiOp) .AddOperation(checkUiOp)
.AddOperation(cBrd.SetValvesOp(inPath.Pump, null))
.AddOperation(benchPath.TempIn.ReadTempOp(ref TempIn)) .AddOperation(benchPath.TempIn.ReadTempOp(ref TempIn))
.AddOperation(benchPath.TempOut.ReadTempOp(ref TempOut)) .AddOperation(benchPath.TempOut.ReadTempOp(ref TempOut))
.AddOperation(benchPath.PressIn.ReadPressureOp(ref PressureUp)) .AddOperation(benchPath.PressIn.ReadPressureOp(ref PressureUp))
.AddOperation(benchPath.PressOut.ReadPressureOp(ref PressureDown)) .AddOperation(benchPath.PressOut.ReadPressureOp(ref PressureDown))
.AddOperation(new Operations.SetAllRegulValvesOp(inPath.RegulValves, inPath.RegulValvesPct, 60))
.AddOperation(inPath.Pump != null ? cBrd.SetValvesOp(inPath.Pump, null) : null)
.EnterState(); .EnterState();
do do
{ {
e = StateMachine.WaitRunDevsRunOps(); e = StateMachine.WaitRunDevsRunOps();
if (TestAndLogUiCmdStop(test,e)) { retVal = Event.UiCmdStop; goto stopTest; } if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
} }
while (e.Contains(Event.ValvesBusy)); while (e.Contains(Event.ValvesBusy) || !e.Contains(Event.AllPositionsReached));
//------------------------------------------------ //------------------------------------------------
Bridge.OnActivity(this, Strings.Setting_the_water_pressure); Bridge.OnActivity(this, Strings.Setting_the_water_pressure);

View File

@ -29,5 +29,5 @@ using System.Runtime.InteropServices;
// Build Number // Build Number
// Revision // Revision
// //
[assembly: AssemblyVersion("2.11.365.1")] [assembly: AssemblyVersion("2.11.367.1")]
[assembly: AssemblyFileVersion("2.11.365.1")] [assembly: AssemblyFileVersion("2.11.367.1")]

View File

@ -1,5 +1,7 @@
rmdir /s /q Config\bin rmdir /s /q Config\bin
rmdir /s /q Config\obj rmdir /s /q Config\obj
rmdir /s /q DeviceTest\bin
rmdir /s /q DeviceTest\obj
rmdir /s /q Results\bin rmdir /s /q Results\bin
rmdir /s /q Results\obj rmdir /s /q Results\obj
rmdir /s /q ResultsBrowser\bin rmdir /s /q ResultsBrowser\bin