(1) ProcessTabPageEx: TRefHi, TRefLo (2) Ambient vals. written directly to ProcessData (3) Sequences changed:'readTempPressOps', ver. 2.18.1171
This commit is contained in:
@@ -30,13 +30,43 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
string enduranceCycleStr,
|
||||
Config.Entities.DebugMode debugLevel)
|
||||
{
|
||||
IList<Event> e = new List<Event>(); /// Events from currently running operations
|
||||
Event retVal = Event.Done;
|
||||
checkUiOp = new Operations.CheckUIOp(true); /// Runs in more then one state
|
||||
int rangeIx = 0; /// Default range, used for non-Elde flowmeters
|
||||
if (outPath.FlowMeter is Elde.FlowMeter.FlowMeter)
|
||||
{
|
||||
Elde.FlowMeter.FlowMeter eldeFM = outPath.FlowMeter as Elde.FlowMeter.FlowMeter;
|
||||
rangeIx = -1; /// Indicates invalid range
|
||||
for (int r = 0; r <= 5; r++)
|
||||
{
|
||||
if (eldeFM.RangeEnabled(r) && eldeFM.GetTempLo(r) <= test.TempLimLo
|
||||
&& eldeFM.GetTempHi(r) >= test.TempLimHi)
|
||||
{
|
||||
rangeIx = r;
|
||||
}
|
||||
}
|
||||
|
||||
if (rangeIx == -1)
|
||||
{
|
||||
Bridge.OnError(this, Strings.Flow_meter_temperature_range_does_not_fit_this_test_conditions);
|
||||
return new List<Event> { Event.ConfigurationError };
|
||||
}
|
||||
}
|
||||
|
||||
Elde.ControlBoardDev cBrd = StateMachine.ControlBoard;
|
||||
checkUiOp = new Operations.CheckUIOp(true); /// Runs in more then one state
|
||||
processDataLoggingOp = new TBF.BenchControl.Operations.ProcessDataLoggingOp(processDataLogger, this, false);
|
||||
|
||||
IList<IOperation> readTempPressOps = new List<IOperation>();
|
||||
if (benchPath.TempMtrUp != null) readTempPressOps.Add(benchPath.TempMtrUp.ReadTempOp(ref TempUp));
|
||||
if (benchPath.TempMtrDown != null) readTempPressOps.Add(benchPath.TempMtrDown.ReadTempOp(ref TempDown));
|
||||
if (outPath.TempDiv != null) readTempPressOps.Add(outPath.TempDiv.ReadTempOp(ref TempDiv));
|
||||
if (benchPath.PressMtrUp != null) readTempPressOps.Add(benchPath.PressMtrUp.ReadPressureOp(ref PressUp));
|
||||
if (benchPath.PressMtrDown != null) readTempPressOps.Add(benchPath.PressMtrDown.ReadPressureOp(ref PressDown));
|
||||
if (benchPath.PressMtrDelta != null) readTempPressOps.Add(benchPath.PressMtrDelta.ReadPressureOp(ref PressDelta));
|
||||
if (heatMetersPath != null) readTempPressOps.Add(heatMetersPath.TMeterRefWarm1.ReadTempOp(ref TempRefHi1));
|
||||
if (heatMetersPath != null) readTempPressOps.Add(heatMetersPath.TMeterRefWarm2.ReadTempOp(ref TempRefHi2));
|
||||
if (heatMetersPath != null) readTempPressOps.Add(heatMetersPath.TMeterRefCold1.ReadTempOp(ref TempRefLo1));
|
||||
if (heatMetersPath != null) readTempPressOps.Add(heatMetersPath.TMeterRefCold2.ReadTempOp(ref TempRefLo2));
|
||||
|
||||
|
||||
string enduranceLogDir = string.Format("C:\\TBF\\Results\\{0:yyyy}\\{0:MM}\\{0:dd}\\", BatchRslts.Batch.StartTime);
|
||||
string enduranceLogName = string.Format("{0}{1:HHmm}.txt", enduranceLogDir, BatchRslts.Batch.StartTime);
|
||||
@@ -54,41 +84,28 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
enduranceDataLoggingOp = null;
|
||||
}
|
||||
|
||||
|
||||
LtrPerRefPulse = outPath.FlowMeter.LtrPerPulse; /// [ltr/pulse], nominal flow in [m3/h]
|
||||
|
||||
/// Notes:
|
||||
/// float timeHr = volumeLtr / (1000.0f * targetFlow);
|
||||
/// float timeSec = 3600.0f * timeHr;
|
||||
/// int refPulses = (int)(timeSec * (2000.0f * targetFlow / pOut.FlowMeter.NominalFlow));
|
||||
int totalPulses = (int)(test.Volume / LtrPerRefPulse + 0.5f);
|
||||
|
||||
int rangeIx = 0; /// Default range, used for non-Elde flowmeters
|
||||
if (outPath.FlowMeter is Elde.FlowMeter.FlowMeter)
|
||||
{
|
||||
Elde.FlowMeter.FlowMeter eldeFM = outPath.FlowMeter as Elde.FlowMeter.FlowMeter;
|
||||
rangeIx = -1; /// Indicates invalid range
|
||||
for (int r = 0; r <= 5; r++)
|
||||
{
|
||||
if (eldeFM.RangeEnabled(r) && eldeFM.GetTempLo(r) <= test.TempLimLo
|
||||
&& eldeFM.GetTempHi(r) >= test.TempLimHi)
|
||||
{
|
||||
rangeIx = r;
|
||||
}
|
||||
}
|
||||
|
||||
if (rangeIx == -1)
|
||||
{
|
||||
Bridge.OnError(this, Strings.Flow_meter_temperature_range_does_not_fit_this_test_conditions);
|
||||
retVal = Event.UiCmdStop;
|
||||
goto stopTestWOStoppingDivGateEtc;
|
||||
}
|
||||
}
|
||||
Event retVal = Event.Done;
|
||||
IList<Event> e; /// Events from currently running operations
|
||||
|
||||
//====================================
|
||||
loop:
|
||||
/// Read pressure and temperature once before calling Bridge.OnTestSelected(...)
|
||||
State.Create(string.Format("{0}({1}) : Measuring process data", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(readTempPressOps)
|
||||
.EnterState();
|
||||
do {
|
||||
e = StateMachine.WaitRunDevsRunOps();
|
||||
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
|
||||
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
|
||||
}
|
||||
while (e.Contains(Event.Busy));
|
||||
|
||||
/// Start the test, initialize test results
|
||||
Bridge.OnTestSelected(this, new TestSelectedEventArgs(test, repetitionNr, inPath, benchPath, outPath, sensPath, totalPulses));
|
||||
Bridge.OnTestSelected(this, new TestSelectedEventArgs(test, repetitionNr, inPath, benchPath, outPath, sensPath, heatMetersPath, totalPulses));
|
||||
string testName = Results.Utils.GetTestName(test.Name, test.Repeats, repetitionNr);
|
||||
TestStartTime = DateTime.Now;
|
||||
|
||||
@@ -99,12 +116,12 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
if (inPath.Pump is GenericDevices.IPumpFM) (inPath.Pump as GenericDevices.IPumpFM).TurnOn(test.PumpPower);
|
||||
///
|
||||
State.Create(string.Format("{0}({1}) : Starting the pump", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
// .AddOperation(new Operations.SetAllRegulValvesOp(inPath.RegulValves, inPath.RegulValvesPct, 60))
|
||||
.AddOperation(inPath.Pump != null ? cBrd.SetValvesOp(inPath.Pump, null) : null)
|
||||
.EnterState();
|
||||
do
|
||||
{
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(readTempPressOps)
|
||||
//.AddOperation(new Operations.SetAllRegulValvesOp(inPath.RegulValves, inPath.RegulValvesPct, 60))
|
||||
.AddOperation(inPath.Pump != null ? cBrd.SetValvesOp(inPath.Pump, null) : null)
|
||||
.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));
|
||||
@@ -120,11 +137,11 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
//------------------------------------------------
|
||||
int flowSetTime0 = StateMachine.Time;
|
||||
State.Create(string.Format("{0}({1}) : Setting the flow", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperation(outPath.RegulValve.SetFlowOp(outPath.FlowMeter, test.Qfrom, test.Qto, outPath.PidCoef, RefFlow, FlowSettingTimeoutSec))
|
||||
.EnterState();
|
||||
do
|
||||
{
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(readTempPressOps)
|
||||
.AddOperation(outPath.RegulValve.SetFlowOp(outPath.FlowMeter, test.Qfrom, test.Qto, outPath.PidCoef, RefFlow, FlowSettingTimeoutSec))
|
||||
.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));
|
||||
@@ -155,17 +172,15 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
|
||||
State.Create(string.Format("{0}({1}) : Wait until the water temperature is within limits", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperation(benchPath.TempMtrUp.ReadTempOp(ref TempUp))
|
||||
.AddOperation(benchPath.TempMtrDown.ReadTempOp(ref TempDown))
|
||||
.AddOperations(readTempPressOps)
|
||||
.EnterState();
|
||||
do
|
||||
{
|
||||
do {
|
||||
e = StateMachine.WaitRunDevsRunOps();
|
||||
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
|
||||
if (e.Contains(Event.Next)) goto temperature_set;
|
||||
|
||||
if (TempUp.Val >= test.TempLimLo && TempUp.Val <= test.TempLimHi &&
|
||||
TempDown.Val >= test.TempLimLo && TempDown.Val <= test.TempLimHi)
|
||||
if ((test.TempLimLo <= TempUp.Val) && (TempUp.Val <= test.TempLimHi) &&
|
||||
(test.TempLimLo <= TempDown.Val) && (TempDown.Val <= test.TempLimHi))
|
||||
{
|
||||
goto temperature_set;
|
||||
}
|
||||
@@ -231,27 +246,14 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
Bridge.OnActivity(this, Strings.Test_in_progress);
|
||||
//------------------------------------------------
|
||||
State.Create(string.Format("{0}({1}) : Starting the test", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(measureOperations)
|
||||
.AddOperation(benchPath.TempMtrUp == null ? null : benchPath.TempMtrUp.ReadTempOp(ref TempUp))
|
||||
.AddOperation(benchPath.TempMtrDown == null ? null : benchPath.TempMtrDown.ReadTempOp(ref TempDown))
|
||||
.AddOperation(outPath.TempDiv == null ? null : outPath.TempDiv.ReadTempOp(ref TempDiv))
|
||||
.AddOperation(benchPath.PressMtrUp == null ? null : benchPath.PressMtrUp.ReadPressureOp(ref PressUp))
|
||||
.AddOperation(benchPath.PressMtrDown == null ? null : benchPath.PressMtrDown.ReadPressureOp(ref PressDown))
|
||||
.AddOperation(benchPath.PressMtrDelta == null ? null : benchPath.PressMtrDelta.ReadPressureOp(ref PressDelta))
|
||||
.AddOperation(heatMetersPath == null ? null : heatMetersPath.TMeterRefWarm1.ReadTempOp(ref TempRefHi1))
|
||||
.AddOperation(heatMetersPath == null ? null : heatMetersPath.TMeterRefWarm2.ReadTempOp(ref TempRefHi2))
|
||||
.AddOperation(heatMetersPath == null ? null : heatMetersPath.TMeterRefCold1.ReadTempOp(ref TempRefLo1))
|
||||
.AddOperation(heatMetersPath == null ? null : heatMetersPath.TMeterRefCold2.ReadTempOp(ref TempRefLo2))
|
||||
.AddOperation((StateMachine.Ambient != null)
|
||||
? StateMachine.Ambient.ReadAmbientOp(AmbTemp, AmbPress, AmbHumi) : null)
|
||||
.AddOperation(processDataLoggingOp)
|
||||
.AddOperation(enduranceDataLoggingOp)
|
||||
.AddOperation(cBrd.StartMeasurementOp(outPath, Elde.TestMethods.Synchro,
|
||||
test.Qfrom, test.Qto, totalPulses, filters))
|
||||
.EnterState();
|
||||
do
|
||||
{
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(readTempPressOps)
|
||||
.AddOperations(measureOperations)
|
||||
.AddOperation(enduranceDataLoggingOp)
|
||||
.AddOperation(cBrd.StartMeasurementOp(outPath, Elde.TestMethods.Synchro, test.Qfrom, test.Qto, totalPulses, filters))
|
||||
.AddOperation(processDataLoggingOp)
|
||||
.EnterState();
|
||||
do {
|
||||
e = StateMachine.WaitRunDevsRunOps();
|
||||
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
|
||||
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
|
||||
@@ -280,28 +282,15 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
|
||||
/// Measurement loop - begin
|
||||
State.Create(string.Format("{0}({1}) : Reading watermeters", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(measureOperations)
|
||||
.AddOperation(readRegistersOp)
|
||||
.AddOperation(benchPath.TempMtrUp == null ? null : benchPath.TempMtrUp.ReadTempOp(ref TempUp))
|
||||
.AddOperation(benchPath.TempMtrDown == null ? null : benchPath.TempMtrDown.ReadTempOp(ref TempDown))
|
||||
.AddOperation(outPath.TempDiv == null ? null : outPath.TempDiv.ReadTempOp(ref TempDiv))
|
||||
.AddOperation(benchPath.PressMtrUp == null ? null : benchPath.PressMtrUp.ReadPressureOp(ref PressUp))
|
||||
.AddOperation(benchPath.PressMtrDown == null ? null : benchPath.PressMtrDown.ReadPressureOp(ref PressDown))
|
||||
.AddOperation(benchPath.PressMtrDelta == null ? null : benchPath.PressMtrDelta.ReadPressureOp(ref PressDelta))
|
||||
.AddOperation(heatMetersPath == null ? null : heatMetersPath.TMeterRefWarm1.ReadTempOp(ref TempRefHi1))
|
||||
.AddOperation(heatMetersPath == null ? null : heatMetersPath.TMeterRefWarm2.ReadTempOp(ref TempRefHi2))
|
||||
.AddOperation(heatMetersPath == null ? null : heatMetersPath.TMeterRefCold1.ReadTempOp(ref TempRefLo1))
|
||||
.AddOperation(heatMetersPath == null ? null : heatMetersPath.TMeterRefCold2.ReadTempOp(ref TempRefLo2))
|
||||
.AddOperation((StateMachine.Ambient != null)
|
||||
? StateMachine.Ambient.ReadAmbientOp(AmbTemp, AmbPress, AmbHumi)
|
||||
: null)
|
||||
.AddOperation(queryEnd1)
|
||||
.AddOperation(processDataLoggingOp)
|
||||
.AddOperation(enduranceDataLoggingOp)
|
||||
.EnterState();
|
||||
do
|
||||
{
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(readTempPressOps)
|
||||
.AddOperations(measureOperations)
|
||||
.AddOperation(readRegistersOp)
|
||||
.AddOperation(queryEnd1)
|
||||
.AddOperation(processDataLoggingOp)
|
||||
.AddOperation(enduranceDataLoggingOp)
|
||||
.EnterState();
|
||||
do {
|
||||
e = StateMachine.WaitRunDevsRunOps();
|
||||
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
|
||||
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
|
||||
@@ -495,11 +484,11 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
//------------------------------------------------
|
||||
|
||||
State.Create(string.Format("{0}({1}) : Stopping diverter, gate, etc.", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperation(cBrd.StopPreviousOp())
|
||||
.EnterState();
|
||||
do
|
||||
{
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(readTempPressOps)
|
||||
.AddOperation(cBrd.StopPreviousOp())
|
||||
.EnterState();
|
||||
do {
|
||||
e = StateMachine.WaitRunDevsRunOps();
|
||||
if (TestAndLogUiCmdStop(test, e)) { if (retVal == Event.Done) retVal = Event.UiCmdStop; break; }
|
||||
}
|
||||
@@ -535,20 +524,13 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
cBrd.CyclePar = cyclePar;
|
||||
///
|
||||
State.Create(string.Format("{0}({1}) : Uploading cycle parameters", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperation(benchPath.TempMtrUp.ReadTempOp(ref TempUp))
|
||||
.AddOperation(benchPath.TempMtrDown.ReadTempOp(ref TempDown))
|
||||
.AddOperation(outPath.TempDiv.ReadTempOp(ref TempDiv))
|
||||
.AddOperation(benchPath.PressMtrUp.ReadPressureOp(ref PressUp))
|
||||
.AddOperation(benchPath.PressMtrDown.ReadPressureOp(ref PressDown))
|
||||
.AddOperation(benchPath.PressMtrDelta == null ? null : benchPath.PressMtrDelta.ReadPressureOp(ref PressDelta))
|
||||
.AddOperation((StateMachine.Ambient != null) ? StateMachine.Ambient.ReadAmbientOp(AmbTemp, AmbPress, AmbHumi) : null)
|
||||
.AddOperation(processDataLoggingOp)
|
||||
.AddOperation(enduranceDataLoggingOp)
|
||||
.AddOperation(cBrd.ExecuteCommandOp(Elde.Command.EnduranceCycleParamsUpload, Elde.Command.None, 0))
|
||||
.EnterState();
|
||||
do
|
||||
{
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(readTempPressOps)
|
||||
.AddOperation(cBrd.ExecuteCommandOp(Elde.Command.EnduranceCycleParamsUpload, Elde.Command.None, 0))
|
||||
.AddOperation(processDataLoggingOp)
|
||||
.AddOperation(enduranceDataLoggingOp)
|
||||
.EnterState();
|
||||
do {
|
||||
e = StateMachine.WaitRunDevsRunOps();
|
||||
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
|
||||
if (TestAndLogUiCmdStop(test, e)) { retVal = Event.UiCmdStop; goto stopTest; }
|
||||
@@ -564,21 +546,14 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
bool stopInProgress = false;
|
||||
///
|
||||
State.Create(string.Format("{0}({1}) : Executing the cycle", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperation(new Operations.TimerOp((int)test.TstTime, Event.TimerExpired))
|
||||
.AddOperation(benchPath.TempMtrUp.ReadTempOp(ref TempUp))
|
||||
.AddOperation(benchPath.TempMtrDown.ReadTempOp(ref TempDown))
|
||||
.AddOperation(outPath.TempDiv.ReadTempOp(ref TempDiv))
|
||||
.AddOperation(benchPath.PressMtrUp.ReadPressureOp(ref PressUp))
|
||||
.AddOperation(benchPath.PressMtrDown.ReadPressureOp(ref PressDown))
|
||||
.AddOperation(benchPath.PressMtrDelta == null ? null : benchPath.PressMtrDelta.ReadPressureOp(ref PressDelta))
|
||||
.AddOperation((StateMachine.Ambient != null) ? StateMachine.Ambient.ReadAmbientOp(AmbTemp, AmbPress, AmbHumi) : null)
|
||||
.AddOperation(processDataLoggingOp)
|
||||
.AddOperation(enduranceDataLoggingOp)
|
||||
.AddOperation(cBrd.ExecuteCommandOp(Elde.Command.EnduranceCycleStart, Elde.Command.EnduranceCycleStop, 0))
|
||||
.EnterState();
|
||||
do
|
||||
{
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(readTempPressOps)
|
||||
.AddOperation(new Operations.TimerOp((int)test.TstTime, Event.TimerExpired))
|
||||
.AddOperation(cBrd.ExecuteCommandOp(Elde.Command.EnduranceCycleStart, Elde.Command.EnduranceCycleStop, 0))
|
||||
.AddOperation(processDataLoggingOp)
|
||||
.AddOperation(enduranceDataLoggingOp)
|
||||
.EnterState();
|
||||
do {
|
||||
e = StateMachine.WaitRunDevsRunOps();
|
||||
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
|
||||
if (TestAndLogUiCmdStop(test, e))
|
||||
@@ -614,20 +589,13 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
Bridge.OnActivity(this, Strings.Last_cycle_wait_please);
|
||||
//------------------------------------------------
|
||||
State.Create(string.Format("{0}({1}) : Delay to make sure the last endu.cycle completed", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperation(new Operations.TimerOp((int)(duration / 1000) + 1, Event.TimerExpired))
|
||||
.AddOperation(benchPath.TempMtrUp.ReadTempOp(ref TempUp))
|
||||
.AddOperation(benchPath.TempMtrDown.ReadTempOp(ref TempDown))
|
||||
.AddOperation(outPath.TempDiv.ReadTempOp(ref TempDiv))
|
||||
.AddOperation(benchPath.PressMtrUp.ReadPressureOp(ref PressUp))
|
||||
.AddOperation(benchPath.PressMtrDown.ReadPressureOp(ref PressDown))
|
||||
.AddOperation(benchPath.PressMtrDelta == null ? null : benchPath.PressMtrDelta.ReadPressureOp(ref PressDelta))
|
||||
.AddOperation((StateMachine.Ambient != null) ? StateMachine.Ambient.ReadAmbientOp(AmbTemp, AmbPress, AmbHumi) : null)
|
||||
.AddOperation(processDataLoggingOp)
|
||||
.AddOperation(enduranceDataLoggingOp)
|
||||
.EnterState();
|
||||
do
|
||||
{
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperations(readTempPressOps)
|
||||
.AddOperation(new Operations.TimerOp((int)(duration / 1000) + 1, Event.TimerExpired))
|
||||
.AddOperation(processDataLoggingOp)
|
||||
.AddOperation(enduranceDataLoggingOp)
|
||||
.EnterState();
|
||||
do {
|
||||
e = StateMachine.WaitRunDevsRunOps();
|
||||
if (e.Contains(Event.Error)) { retVal = Event.Error; goto stopTest; }
|
||||
if (TestAndLogUiCmdStop(test, e))
|
||||
@@ -665,11 +633,10 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
|| retVal == Event.Error || retVal == Event.ConfigurationError)
|
||||
{
|
||||
State.Create(string.Format("{0}({1}) : Stopping diverter, gate, etc.", test.Method, test.Name))
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperation(cBrd.StopPreviousOp())
|
||||
.EnterState();
|
||||
do
|
||||
{
|
||||
.AddOperation(checkUiOp)
|
||||
.AddOperation(cBrd.StopPreviousOp())
|
||||
.EnterState();
|
||||
do {
|
||||
e = StateMachine.WaitRunDevsRunOps();
|
||||
if (TestAndLogUiCmdStop(test, e)) { if (retVal == Event.Done) retVal = Event.UiCmdStop; break; }
|
||||
}
|
||||
@@ -678,10 +645,7 @@ namespace TBF.BenchControl.TestMethods.Endurance
|
||||
|
||||
stopTestWOStoppingDivGateEtc:
|
||||
|
||||
/// Create a list with one item 'retVal' (default is Event.Done) and return it
|
||||
IList<Event> retList = new List<Event>(1);
|
||||
retList.Add(retVal);
|
||||
return retList;
|
||||
return new List<Event> { retVal };
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user