public override void DeInitialize() { DIOWnd.InputChangedEvent -= new DIOControlWindow.InputChangedHandler(InputChangeEventFunction); if (IsDIOInitialize) { DIOWnd.DeInitialize(); } SerialWnd.SerialReceiveEvent -= new SerialWindow.SerialReceiveHandler(SeraialReceiveEventFunction); if (IsSerialInitialize) { SerialWnd.DeInitialize(); } }
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(); } }