Added labels to scada,

Remove network card monitor
This commit is contained in:
Lucio Maranta
2019-01-21 09:29:03 +01:00
parent 6d25dcc55e
commit d9a22655b8
10 changed files with 61 additions and 184 deletions
-18
View File
@@ -151,24 +151,6 @@ namespace Step.UI
//ShowMessage on UI
TXTstatus.Text = "[" + DateTime.Now.ToString("T") + "] " + message.Message;
});
}),
MessageServices.Current.Subscribe(NETWORK_USAGE, (a, b) =>
{
DTONetworkMonitorModel NICMonitor = (DTONetworkMonitorModel)a;
if (!IsDisposed)
Invoke((MethodInvoker)delegate ()
{
labelNetworkSpeed.Text = NICMonitor.Value + " %";
labelNetworkName.Text = NICMonitor.Name;
if(NICMonitor.Bandwidth >= Math.Pow(10,9))
labelNetworkBand.Text = (NICMonitor.Bandwidth * Math.Pow(10,-9)).ToString() + " Gb/s";
else
labelNetworkBand.Text = (NICMonitor.Bandwidth * Math.Pow(10,-6)).ToString() + " Mb/s";
if(NICMonitor.Value > 95.0)
StepNotifyIcon.ShowBalloonTip(30000, "Network Card Warning", "Network Card - Bandwith Overload", ToolTipIcon.Error);
});
}),
// NC status handler
MessageServices.Current.Subscribe(SEND_NC_STATUS, (a, b) =>