iPerlCommunication simultaneously with purging, STOP button function fixed, version 1.5.106

This commit is contained in:
Milan Hanajik
2015-09-05 09:58:01 +02:00
parent 7827fa4e5b
commit d5cb6ca71b
13 changed files with 474 additions and 239 deletions
+28 -17
View File
@@ -416,7 +416,6 @@ namespace TBF.BenchControl
pfeed = null;
pben = null;
pout = null;
pmtrs = null;
transitionBefore = null;
transitionAfter = null;
@@ -435,22 +434,7 @@ namespace TBF.BenchControl
if (test.OutputPath == path.Name) { pout = new OutputPath(path, components); break; }
}
foreach (var path in metersPaths)
{
if (test.MetersPath == path.Name) { pmtrs = new MetersPath(path, components); break; }
}
if (pmtrs != null)
{
int count = Math.Min(Program.WMsCount, pmtrs.RegisterReaders.Length);
for (int i = 0; i < count; i++)
{
if ((pmtrs.RegisterReaders[i] != null) &&
(pmtrs.RegisterReaders[i].Cfg.DebugLevel == Entities.DebugMode.DetectedOff))
{
pmtrs.RegisterReaders[i] = null;
}
}
}
pmtrs = GetMetersPath(test);
foreach (var tr in TransitionSequences)
{
@@ -480,6 +464,33 @@ namespace TBF.BenchControl
return true;
}
/// <summary>
/// Updates paths based on the selected test
/// </summary>
public static MetersPath GetMetersPath(Entities.Test test)
{
MetersPath pmtrs = null;
foreach (var path in metersPaths)
{
if (test.MetersPath == path.Name) { pmtrs = new MetersPath(path, components); break; }
}
if (pmtrs != null)
{
int count = Math.Min(Program.WMsCount, pmtrs.RegisterReaders.Length);
for (int i = 0; i < count; i++)
{
if ((pmtrs.RegisterReaders[i] != null) &&
(pmtrs.RegisterReaders[i].Cfg.DebugLevel == Entities.DebugMode.DetectedOff))
{
pmtrs.RegisterReaders[i] = null;
}
}
}
return pmtrs;
}
/// <summary>
/// Stops the state machine (and the worker thread)
/// </summary>