eregister prüfung abschlus ~
This commit is contained in:
@@ -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()
|
||||
|
||||
Reference in New Issue
Block a user