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(); }
public ltepopupModel() { PinCommand = new DelegateCommand(new Action(OnPinCommandExecute)); CloseWindowCommand = new DelegateCommand(new Action(OnCloseWindowCommandExecute)); LTECollection = new LTECollection(); LTECollection2 = new LTECollection(); DateTimeAxis1 = new HorizontalDateTimeAxis(); DateTimeAxis2 = new HorizontalDateTimeAxis(); var ds = new EnumerableDataSource<LTEData>(LTECollection); ds.SetXMapping(x => DateTimeAxis1.ConvertToDouble(x.Date)); ds.SetYMapping(y => y.Data); RsrqGraph = ds; var ds2 = new EnumerableDataSource<LTEData>(LTECollection2); ds2.SetXMapping(x => DateTimeAxis1.ConvertToDouble(x.Date)); ds2.SetYMapping(y => y.Data); RsrpGraph = ds2; }
public ltepopupModel() { PinCommand = new DelegateCommand(new Action(OnPinCommandExecute)); CloseWindowCommand = new DelegateCommand(new Action(OnCloseWindowCommandExecute)); LTECollection = new LTECollection(); LTECollection2 = new LTECollection(); DateTimeAxis1 = new HorizontalDateTimeAxis(); DateTimeAxis2 = new HorizontalDateTimeAxis(); var ds = new EnumerableDataSource <LTEData>(LTECollection); ds.SetXMapping(x => DateTimeAxis1.ConvertToDouble(x.Date)); ds.SetYMapping(y => y.Data); RsrqGraph = ds; var ds2 = new EnumerableDataSource <LTEData>(LTECollection2); ds2.SetXMapping(x => DateTimeAxis1.ConvertToDouble(x.Date)); ds2.SetYMapping(y => y.Data); RsrpGraph = ds2; }