eregister prüfung abschlus ~

This commit is contained in:
Stoyan Zlatev
2024-12-06 15:18:49 +01:00
parent a385f35efd
commit d8c2d776a5
48 changed files with 1368 additions and 413 deletions
@@ -126,7 +126,7 @@
private void AddSIRTs()
{
var portNames = Appsettings
.Get("SIRTComPortNames")
.Get("SIRTComPorts")
?.Split(new[] { ';', ',', ' ' })
?.Select(x => x?.Trim())
?.ToArray() ?? new string[0];
@@ -136,15 +136,21 @@
.Intersect(portNames)
.ToArray();
foreach (var portName in portNames)
Task.Run(async () =>
{
var connection = this.broadcaster.ConnectSIRT(portName);
var sirtVM = new SIRTConnectionVM(connection);
this.Connections.Add(sirtVM);
this.ClearEnabled = true;
foreach (var portName in portNames)
{
this.InvokeAsync(() =>
{
var connection = this.broadcaster.ConnectSIRT(portName);
var sirtVM = new SIRTConnectionVM(connection);
this.Connections.Add(sirtVM);
this.ClearEnabled = true;
});
Thread.Sleep(500);
}
await Task.Delay(500);
}
});
}
private void UpdatePortNames()