private void Ps_NewMessageEvent(string Message)
        {
            AnalysisDataHelper analysisDataHelper = new AnalysisDataHelper();
            var model = analysisDataHelper.AnalysisData(Message);
            TimeFormatHelper timeHelper = new TimeFormatHelper();

            Dispatcher.Invoke(new Action(delegate
            {
                var model2 = HuiZhongModels.Where(m => m.SIM == model.Data0).FirstOrDefault();
                int index  = HuiZhongModels.IndexOf(model2);
                HuiZhongModels[index].CollectTime    = timeHelper.HexTimeToDecTime(model.Data3);
                HuiZhongModels[index].FlowRate       = model.Data1;
                HuiZhongModels[index].AccumulateFlow = model.Data2;
            }));
            //--- 分页
            ShowData(TreeViewSelectedDisplayName);
        }
Example #2
0
        private void Button_Click(object sender, RoutedEventArgs e)
        {
            TimeFormatHelper timeFormatHelper = new TimeFormatHelper();

            Debug.WriteLine(timeFormatHelper.HexTimeToDecTime("12091108201B"));
        }