Example #1
0
        public override void DeInitialize()
        {
            int _AutoCmdBit     = DIOWnd.DioBaseCmd.OutputBitIndexCheck((int)DIO_DEF.OUT_AUTO);
            int _CompleteCmdBit = DIOWnd.DioBaseCmd.OutputBitIndexCheck((int)DIO_DEF.OUT_COMPLETE);
            int _ReadyCmdBit    = DIOWnd.DioBaseCmd.OutputBitIndexCheck((int)DIO_DEF.OUT_READY);
            int _LiveCmdBit     = DIOWnd.DioBaseCmd.OutputBitIndexCheck((int)DIO_DEF.OUT_LIVE);

            if (_AutoCmdBit >= 0)
            {
                DIOWnd.SetOutputSignal((short)_AutoCmdBit, false);
            }
            if (_CompleteCmdBit >= 0)
            {
                DIOWnd.SetOutputSignal((short)_CompleteCmdBit, false);
            }
            if (_ReadyCmdBit >= 0)
            {
                DIOWnd.SetOutputSignal((short)_ReadyCmdBit, false);
            }
            if (_LiveCmdBit >= 0)
            {
                DIOWnd.SetOutputSignal((short)_LiveCmdBit, false);
            }

            DIOWnd.InputChangedEvent -= new DIOControlWindow.InputChangedHandler(InputChangeEventFunction);
            DIOWnd.DeInitialize();

            EthernetServWnd.ReceiveStringEvent -= new EthernetWindow.ReceiveStringHandler(ReceiveStringEventFunction);
            EthernetServWnd.DeInitialize();

            if (ThreadAckSignalCheck != null)
            {
                IsThreadAckSignalCheckExit = true; Thread.Sleep(200); ThreadAckSignalCheck.Abort(); ThreadAckSignalCheck = null;
            }
        }
Example #2
0
        public override void DeInitialize()
        {
            DIOWnd.InputChangedEvent -= new DIOControlWindow.InputChangedHandler(InputChangeEventFunction);
            if (IsDIOInitialize)
            {
                DIOWnd.DeInitialize();
            }

            SerialWnd.SerialReceiveEvent -= new SerialWindow.SerialReceiveHandler(SeraialReceiveEventFunction);
            if (IsSerialInitialize)
            {
                SerialWnd.DeInitialize();
            }
        }
Example #3
0
        public override void DeInitialize()
        {
            int _CompleteCmdBit = DIOWnd.DioBaseCmd.OutputBitIndexCheck((int)DIO_DEF.OUT_COMPLETE);
            int _ReadyCmdBit    = DIOWnd.DioBaseCmd.OutputBitIndexCheck((int)DIO_DEF.OUT_READY);
            int _ResultCmdBit   = DIOWnd.DioBaseCmd.OutputBitIndexCheck((int)DIO_DEF.OUT_RESULT_1);
            int _LiveCmdBit     = DIOWnd.DioBaseCmd.OutputBitIndexCheck((int)DIO_DEF.OUT_LIVE);

            if (_CompleteCmdBit >= 0)
            {
                DIOWnd.SetOutputSignal((short)_CompleteCmdBit, false);
            }
            if (_ReadyCmdBit >= 0)
            {
                DIOWnd.SetOutputSignal((short)_ReadyCmdBit, false);
            }
            if (_ResultCmdBit >= 0)
            {
                DIOWnd.SetOutputSignal((short)_ResultCmdBit, false);
            }
            if (_LiveCmdBit >= 0)
            {
                DIOWnd.SetOutputSignal((short)_LiveCmdBit, false);
            }

            if (UseDIOCommFlag)
            {
                DIOWnd.InputChangedEvent -= new DIOControlWindow.InputChangedHandler(InputChangeEventFunction);
                DIOWnd.DeInitialize();
            }

            if (UseSerialCommFlag)
            {
                SerialWnd.SerialReceiveEvent -= new SerialWindow.SerialReceiveHandler(SeraialReceiveEventFunction);
                SerialWnd.DeInitialize();
            }
        }