public ProbeConnectionForm()
 {
     InitializeComponent();
     _lightControlManager = new CCSLightControlManager();            //DeviceController.GetCCSLightControlManagerInstance();
     _lightControlManager.On_ProbeConnectionWorked += _lightControlManager_On_Disconnected;
     _lightControlManager.On_SafetyClosed          += _lightControlManager_On_SafetyClosed;
 }
        private void CCSLightControlForm_Load(object sender, EventArgs e)
        {
            CCSLightControlForm_LocationChanged(sender, e);
            _lightControlManager = DeviceController.GetCCSLightControlManagerInstance();
            _lightControlManager.On_SafetyClosed += _lightControlManager_On_SafetyClosed;
            _lightControlManager.StartProbeConnetion(_heartbeatInterval);

            _lightControlAssistant = new CCSLightControlAssistant(_lightControlManager);
            initializeLightControl();
        }
Пример #3
0
 public static CCSLightControlManager GetCCSLightControlManagerInstance()
 {
     if (_lightControlManager == null)
     {
         _lightControlManager = new CCSLightControlManager();
     }
     else
     {
         _lightControlManager.RemoveAllRegisterEvent();
     }
     _lightControlInstanceUsed = (_lightControlManager != null);
     return(_lightControlManager);
 }
Пример #4
0
 public static void ReleaseCCSLightControlManagerInstance()
 {
     _lightControlInstanceUsed = false;
     _lightControlManager      = null;
 }