private void OnReloadCommandExecute() { new Thread(() => { SpeedportHybrid.initDSL(); if (lastReload.Equals(DateTime.MinValue).Equals(false)) { DateTime now = DateTime.Now; double difference = Math.Ceiling(Math.Ceiling((DateTime.Now - lastReload).TotalSeconds) / 60); double diffdCRC = Math.Ceiling((Line.dCRC - lastdCRC) / difference); double diffuCRC = Math.Ceiling((Line.uCRC - lastuCRC) / difference); lastCRC = string.Format("CRC/min (last {0} min) Upstream: {1} Downstream: {2}", difference, diffuCRC, diffdCRC); double diffdHEC = Math.Ceiling((Line.dHEC - lastdHEC) / difference); double diffuHEC = Math.Ceiling((Line.uHEC - lastuHEC) / difference); lastHEC = string.Format("HEC/min (last {0} min) Upstream: {1} Downstream: {2}", difference, diffuHEC, diffdHEC); double diffdFEC = Math.Ceiling((Line.dFEC - lastdFEC) / difference); double diffuFEC = Math.Ceiling((Line.uFEC - lastuFEC) / difference); lastFEC = string.Format("FEC/min (last {0} min) Upstream: {1} Downstream: {2}", difference, diffuFEC, diffdFEC); } lastReload = DateTime.Now; lastdCRC = Line.dCRC; lastuCRC = Line.uCRC; lastdHEC = Line.dHEC; lastuHEC = Line.uHEC; lastdFEC = Line.dFEC; lastuFEC = Line.uFEC; }).Start(); }
private void OnClearCommandExecute() { MessageBoxResult result = MessageBox.Show("Sollen die System-Informationen wirklich gelöscht werden?", "Confirmation", MessageBoxButton.YesNoCancel, MessageBoxImage.Question); if (result.Equals(MessageBoxResult.Yes)) { SpeedportHybridAPI.getInstance().clearSyslog(); SpeedportHybrid.initSyslog(); SearchText = string.Empty; } }
private void timer_Elapsed(object sender, ElapsedEventArgs e) { SpeedportHybrid.initDSL(); Application.Current.Dispatcher.BeginInvoke(new Action(() => { if (Log.Equals(true)) { //log string prepare = "State: {0}, Actual Data Rate: up: {1} down: {2}, Attainable Data Rate: up: {3} down: {4}, SNR Margin up: {5} down: {6}, CRC error count: up: {7} down: {8}, HEC error count: up: {9} down: {10}, FEC error count: up: {11} down: {12}"; log(string.Format(prepare, Connection.state, Line.uactual, Line.dactual, Line.uattainable, Line.dattainable, Line.uSNR, Line.dSNR, Line.uCRC, Line.dCRC, Line.uHEC, Line.dHEC, Line.uFEC, Line.dFEC)); log(string.Format("CRC/min up: {0} down: {1}, HEC/min up: {2} down: {3}, FEC/min up: {4} down: {5}", Line.uCRCsec, Line.dCRCsec, Line.uHECsec, Line.dHECsec, Line.uFECsec, Line.dFECsec)); } })); }
void timer_Elapsed(object sender, ElapsedEventArgs e) { new Thread(() => { SpeedportHybrid.initLtePopup(); Application.Current.Dispatcher.BeginInvoke(new Action(() => { LTECollection.Add(new LTEData() { Date = DateTime.Now, Data = rsrq.ToInt() }); LTECollection2.Add(new LTEData() { Date = DateTime.Now, Data = rsrp.ToInt() }); if (LogActive.Equals(true)) { // log log(string.Concat("Pysical Cell ID: ", phycellid, ", Cell ID: ", cellid, ", RSRP: ", rsrp, ", RSRQ: ", rsrq)); } })); }).Start(); }
private void OnReloadCommandExecute() { new Thread(() => { SpeedportHybrid.initLan(); }).Start(); }
private void OnSwitchToInterfacePageExecute() { changePage("interface"); new Thread(() => { SpeedportHybrid.initInterface(); }).Start(); }
private void OnSwitchToLanPageExecute() { changePage("lan"); new Thread(() => { SpeedportHybrid.initLan(); }).Start(); }
private void OnSwitchToPhonePageExecute() { changePage("phone"); new Thread(() => { SpeedportHybrid.initPhone(); }).Start(); }
private void OnSwitchToTR181PageExecute() { changePage("tr181"); new Thread(() => { SpeedportHybrid.initTR181(); }).Start(); }
private void OnSwitchToSyslogPageExecute() { changePage("syslog"); new Thread(() => { SpeedportHybrid.initSyslog(); }).Start(); }
private void OnSwitchToLteInfoPageExecute() { changePage("lte"); new Thread(() => { SpeedportHybrid.initLTE(); }).Start(); }
private void OnSwitchToDSLPageExecute() { changePage("dsl"); new Thread(() => { SpeedportHybrid.initDSL(); }).Start(); }
private void OnSwitchToOverviewPageExecute() { changePage("overview"); new Thread(() => { SpeedportHybrid.initOverview(); }).Start(); }
private void OnSwitchToStatusPageExecute() { changePage("status"); new Thread(() => { SpeedportHybrid.initStatus(); }).Start(); }