Esempio n. 1
0
        private async void _State_Elapsed(object sender, ElapsedEventArgs e)
        {
            if (false == _bConected)
            {
                return;
            }
            _StateChk.Stop();
            var status = await _PwrBus.ReadItemsAll();

            RoportUpdateData(status);
            _StateChk.Start();
        }
Esempio n. 2
0
        private async void _State_Elapsed(object sender, ElapsedEventArgs e)
        {
            if (false == _bConected)
            {
                return;
            }
            _StateChk.Stop();
            PWRSTATUS status = new PWRSTATUS();

            if (false == bUseModbus)
            {
                RequestData();
            }
            else
            {
                status = await _PwrBus.ReadItemsAll();
            }
            RoportUpdateData(status);
            _StateChk.Start();
        }