📄 pcserialtestdlg.h
字号:
// PCSerialTestDlg.h : header file
//
//{{AFX_INCLUDES()
#include "mscomm.h"
//}}AFX_INCLUDES
#if !defined(AFX_PCSERIALTESTDLG_H__0CD76AC5_5869_4FA2_BAFA_BBE4F0E3FF84__INCLUDED_)
#define AFX_PCSERIALTESTDLG_H__0CD76AC5_5869_4FA2_BAFA_BBE4F0E3FF84__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "HexEdit.h"
#include "PortSetDlg.h"
/////////////////////////////////////////////////////////////////////////////
// CPCSerialTestDlg dialog
class CPCSerialTestDlg : public CDialog
{
// Construction
public:
void init();
char CPCSerialTestDlg::ConvertHexChar (char ch);
int String2Hex (CString str, CByteArray &senddata);
void OpenPort ();
CPCSerialTestDlg(CWnd* pParent = NULL); // standard constructor
CPortSetDlg m_ProDlg; //属性设置对话框类对象
BOOL m_bSend;
BOOL m_bReceive;
int m_nPort; //串口号
int m_nTime; //自动发送时间间隔
int m_nOutPutMode; //字符串发送格式
CString m_strSettings; //串口设置
CString m_strSendString; //欲发送的字符串
// Dialog Data
//{{AFX_DATA(CPCSerialTestDlg)
enum { IDD = IDD_PCSERIALTEST_DIALOG };
CSliderCtrl m_SendSlider;
CHexEdit m_ReceiveEdit;
CComboBox m_SendType;
CMSComm m_CommCtrl;
BOOL m_4Or8;
BOOL m_Address;
BOOL m_Ascii;
BOOL m_Hex;
//}}AFX_DATA
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CPCSerialTestDlg)
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
protected:
HICON m_hIcon;
// Generated message map functions
//{{AFX_MSG(CPCSerialTestDlg)
virtual BOOL OnInitDialog();
afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
afx_msg void OnPaint();
afx_msg HCURSOR OnQueryDragIcon();
afx_msg void OnSetPro();
afx_msg void OnOnCommMscomm1();
afx_msg void OnOpenPort();
afx_msg void OnHandOutput();
afx_msg void OnAutoOutput();
afx_msg void OnStopRec();
afx_msg void OnStartRec();
afx_msg void OnShutPort();
afx_msg void OnTimer(UINT nIDEvent);
afx_msg void OnDeleteReceive();
afx_msg void OnSelchangeComboSendtype();
afx_msg void OnCheckHex();
afx_msg void OnCheck48();
afx_msg void OnCheckAddress();
afx_msg void OnCheckAscii();
afx_msg void OnChangeEditSend();
afx_msg void OnHscrollEditReceive(UINT nSBcode, UINT nPos, CScrollBar* pScrollBar);
afx_msg void OnStart();
afx_msg void OnRecord();
DECLARE_EVENTSINK_MAP()
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_PCSERIALTESTDLG_H__0CD76AC5_5869_4FA2_BAFA_BBE4F0E3FF84__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -