
// VTK_RELAY_01_UtilityDlg.h : header file
//

#pragma once
#include "afxwin.h"


// CVTK_RELAY_01_UtilityDlg dialog
class CVTK_RELAY_01_UtilityDlg : public CDialog
{
// Construction
public:
	CVTK_RELAY_01_UtilityDlg(CWnd* pParent = NULL);	// standard constructor

// Dialog Data
	enum { IDD = IDD_VTK_RELAY_01_UTILITY_DIALOG };

	protected:
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support


// Implementation
protected:
	HICON m_hIcon;

	// Generated message map functions
	virtual BOOL OnInitDialog();
	afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	DECLARE_MESSAGE_MAP()

	afx_msg void OnClose();
	afx_msg void OnTimer(UINT_PTR nIDEvent);

public:
	CEdit m_CEdit_Message;
	CEdit m_CEdit_MCUversion;
	CEdit m_CEdit_Ignition;
	CEdit m_CEdit_SupplyVoltage;
	CEdit m_CEdit_GPI12Level;
	CEdit m_CEdit_GPI34Level;
	CComboBox m_CComboBox_GPI12Level;
	CComboBox m_CComboBox_GPI34Level;
	CEdit m_CEdit_GPO12PullUp;
	CEdit m_CEdit_GPO34PullUp;
	CEdit m_CEdit_GPI1;
	CEdit m_CEdit_GPI2;
	CEdit m_CEdit_GPI3;
	CEdit m_CEdit_GPI4;
	CEdit m_CEdit_GPO1;
	CEdit m_CEdit_GPO2;
	CEdit m_CEdit_GPO3;
	CEdit m_CEdit_GPO4;
	CComboBox m_CComboBox_GPO1;
	CComboBox m_CComboBox_GPO2;
	CComboBox m_CComboBox_GPO3;
	CComboBox m_CComboBox_GPO4;
	CEdit m_CEdit_Relay1;
	CEdit m_CEdit_Relay2;
	CEdit m_CEdit_Relay3;
	CEdit m_CEdit_Relay4;
	CComboBox m_CComboBox_Relay1;
	CComboBox m_CComboBox_Relay2;
	CComboBox m_CComboBox_Relay3;
	CComboBox m_CComboBox_Relay4;
	CEdit m_CEdit_InputCurrent;
	CEdit m_CEdit_InputVoltage;
	CEdit m_CEdit_InputFrequency;
	CComboBox m_CComboBox_GPO12PullUp;
	CComboBox m_CComboBox_GPO34PullUp;
	CComboBox m_CComboBox_PortNum;

	afx_msg void OnBnClickedButton1();
	afx_msg void OnBnClickedButton2();
	afx_msg void OnBnClickedButton3();
	afx_msg void OnBnClickedButton4();
	afx_msg void OnBnClickedButton5();
	afx_msg void OnBnClickedButton6();
	afx_msg void OnBnClickedButton7();
	afx_msg void OnBnClickedButton8();
	afx_msg void OnBnClickedButton9();
	afx_msg void OnBnClickedButton10();
	afx_msg void OnBnClickedButton11();

	void fnGetMCUVersion();
	void fnGetIgnitionStatus();
	void fnGetSupplyVoltage();
	void fnGetExtGPILevel();
	void fnGetExtGPOPullUp();
	void fnGetExtGPIStatus();
	void fnGetExtGPOStatus();
	void fnGetRelayStatus();
	void fnGetInputCurrent();
	void fnGetInputVoltage();
	void fnGetInputFrequency();

	void DisableButtonWhenClose();
	void EnableButtonWhenOpen();

public:
	unsigned int m_nStep;
};
