kevinapp001dlg.h

来自「一个在三星2440平台上测试串口的应用程序,附有源码,用VS2005进行编译,经」· C头文件 代码 · 共 64 行

H
64
字号
// KevinApp001Dlg.h : header file
//

#pragma once

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

// Dialog Data
	enum { IDD = IDD_KEVINAPP001_DIALOG };


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

// Implementation
protected:
	HICON m_hIcon;

	// Generated message map functions
	virtual BOOL OnInitDialog();
#if defined(_DEVICE_RESOLUTION_AWARE) && !defined(WIN32_PLATFORM_WFSP)
	afx_msg void OnSize(UINT /*nType*/, int /*cx*/, int /*cy*/);
#endif
	DECLARE_MESSAGE_MAP()

	CButton m_Btn_OpenCOM;
	CButton m_Btn_CloseCOM;

	CComboBox m_CbBox_SerialNum;
	CComboBox m_CbBox_Baudrate;
	CComboBox m_CbBox_Databit;
	CComboBox m_CbBox_Stopbit;
	CComboBox m_CbBox_Verify;

	CString m_Str_SendEdit;
	CString m_Str_ReceiveEdit;
	
	DCB dcb;
	HANDLE m_hComPort;
	HANDLE m_hExitThreadEvent;
	
	BOOL CloseComPort(void);
	
	BOOL OpenComPort(LPCTSTR Port,int Baudrate,int Databit,int Stopbit,int Parity);
	
	static DWORD ComPortReceiveThread(LPVOID lparam);
	
	static void CALLBACK onCommReceive(CWnd* pWnd,char *buf,int buflen);

public:
	afx_msg void OnBnClickedButton1();
	afx_msg void OnBnClickedButton2();
	afx_msg void OnBnClickedButton3();
	afx_msg void OnBnClickedButton4();
	afx_msg void OnBnClickedButton5();
protected:
	void OnOK(void);
};

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?