⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gps_commdlg.h

📁 一个GPS串口通讯的程序
💻 H
字号:
// GPS_CommDlg.h : header file
//

#if !defined(AFX_GPS_COMMDLG_H__63ABC736_AE38_45DB_A3CE_FF214D384C9C__INCLUDED_)
#define AFX_GPS_COMMDLG_H__63ABC736_AE38_45DB_A3CE_FF214D384C9C__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

/////////////////////////////////////////////////////////////////////////////
// CGPS_CommDlg dialog

#include "SetupDlg.h"
#include "SerialPort.h"  //串口类

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

// Dialog Data
	//{{AFX_DATA(CGPS_CommDlg)
	enum { IDD = IDD_GPS_COMM };
	CListBox	m_LSTMsg;
	CString	m_strFileName;  //保存的文件名
	BOOL	m_chkOutputFile;
	//}}AFX_DATA

	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CGPS_CommDlg)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support
	//}}AFX_VIRTUAL

// Implementation
protected:
	HICON m_hIcon;
	CSerialPortEx m_PortEx;  //串口类
	CString m_strReceived;  //接收字符串
		
	FILE* m_fp; 

	int m_nComm;
	int m_nBandRate;
	char m_cParity;
	int m_nDataBits;
	int m_nStopBits;
	
	// Generated message map functions
	//{{AFX_MSG(CGPS_CommDlg)
	virtual BOOL OnInitDialog();
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	afx_msg void OnSetup();
	afx_msg void OnStartReceive();
	afx_msg void OnStopReceive();
	afx_msg void OnTimer(UINT nIDEvent);
	afx_msg LONG OnCommunication(WPARAM ch, LPARAM portEx);//接收字符的消息传递函数,辅助线程传来,触发主线程
	afx_msg void OnClearList();
	afx_msg void OnBrower();
	afx_msg void OnChkOutputFile();
	afx_msg void OnSize(UINT nType, int cx, int cy);
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_GPS_COMMDLG_H__63ABC736_AE38_45DB_A3CE_FF214D384C9C__INCLUDED_)

⌨️ 快捷键说明

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