예제 #1
0
        private void UserControl_Loaded(object sender, RoutedEventArgs e)
        {
            timer_Pulse.Interval = TimeSpan.FromSeconds(2);
            timer_Pulse.Tick    += new EventHandler(timer_Pulse_Tick);

            if (Config.Mac.PLCIsEnable == "Y")
            {
                tbPulse.Text = PLC.ReadNowPulse().ToString();
                tbLayer.Text = PLC.ReadNowLay().ToString();
                timer_Pulse.Start();
            }

            ShowLayerSet();
            ShowLayerTurn();
            ShowLasers();
        }
예제 #2
0
 void timer_Pulse_Tick(object sender, EventArgs e)
 {
     tbPulse.Text = PLC.ReadNowPulse().ToString();
     tbLayer.Text = PLC.ReadNowLay().ToString();
 }