📄 commtestdlg.h
字号:
// CommTestDlg.h : header file
//
#if !defined(AFX_COMMTESTDLG_H__BCEE0B76_4775_4991_9A2A_E8A150F16936__INCLUDED_)
#define AFX_COMMTESTDLG_H__BCEE0B76_4775_4991_9A2A_E8A150F16936__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "MyCom.h"
#include "EditHex.h"
#include "MPGB.h"
/////////////////////////////////////////////////////////////////////////////
// CCommTestDlg dialog
class CCommTestDlg : public CDialog
{
// Construction
public:
void TestMeterItem();
BOOL Execute();
CCommTestDlg(CWnd* pParent = NULL); // standard constructor
COMM_STRUCT m_ComSet;
BYTE address[6];
BYTE MeterClass;
BYTE m_TestItem;
// Dialog Data
//{{AFX_DATA(CCommTestDlg)
enum { IDD = IDD_COMMTEST_DIALOG };
CEditHex m_hex_edit;
CString m_display;
CString m_input;
BOOL m_hex;
CString m_err_info;
CString m_command;
//}}AFX_DATA
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CCommTestDlg)
public:
virtual BOOL DestroyWindow();
protected:
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
// Implementation
void UpDateData(WPARAM wParam, LPARAM lParam);
BOOL FormatMeterAddr(CString lpszAddr,BYTE bt[]);
BOOL CloseThread();
BOOL InitThread();
BOOL HexCString(BYTE *buf,DWORD &Len,CString m_String);
protected:
CMyCom *pMyCom;
HICON m_hIcon;
HANDLE hThread;
//##ModelId=3BDCCE3E0089
DWORD TimeOut_id;
BOOL RunFlag;
// Generated message map functions
//{{AFX_MSG(CCommTestDlg)
virtual BOOL OnInitDialog();
afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
afx_msg void OnPaint();
afx_msg HCURSOR OnQueryDragIcon();
afx_msg void OnButtonSend();
afx_msg void OnButtonClear();
afx_msg void OnMenuitem645();
afx_msg void OnMenuTest();
afx_msg void OnMenuComSet();
afx_msg void OnButtonClear2();
afx_msg void OnButtonCom();
afx_msg void OnCheckHex();
afx_msg void OnButtonStop();
afx_msg void OnChangeEditIn();
afx_msg void OnButtonSettime();
afx_msg void OnButtonSetaddress();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_COMMTESTDLG_H__BCEE0B76_4775_4991_9A2A_E8A150F16936__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -