Esempio n. 1
0
        private void buttonCreateWatch_Click(object sender, System.EventArgs e)
        {
            _SampleWatch = new Samples.SampleWatch(_EventManager);
            _Hsm         = _SampleWatch; // use it as a straight on state machine
            _HsmSignals  = _SampleWatch; // use it as a source of signals -- instead of calling AsyncDispatch() on _Hsm

            SetupHsmEvents(_Hsm);
            _Hsm.Init();

            EnableEvents();
        }
Esempio n. 2
0
        private void buttonStartWatch_Click(object sender, System.EventArgs e)
        {
            buttonStartWatch.Enabled = false;

            _SampleWatch = _ExecutionModel.CreateHsm(_Id);
            _Hsm         = _SampleWatch;                    // use it as a straight on state machine
            _HsmSignals  = _Hsm as Samples.ISigSampleWatch; // use it as a source of signals -- instead of calling AsyncDispatch() on _Hsm

            SetupHsmEvents(_Hsm);
            _Hsm.Init();

            EnableEvents();
        }
		public void Execute (ILQHsm hsm) 
		{
			Prepare ();

			InitInstrumentation (hsm);

			_Hsm.Init ();

			if (_Hsm.EventManager.Runner == null)
			{
				new QGUITimerEventManagerRunner (_Hsm.EventManager, 200);
				_Hsm.EventManager.Runner.Start ();
			}
		}