📄 regtestdlg.cpp
字号:
// RegTestDlg.cpp : implementation file
//
#include "stdafx.h"
#include "SMT5K.h"
#include "RegTestDlg.h"
#include "WriteReg.h"
#include "WriteParam.h"
#include "WriteDrvCmd.h"
#include "WriteIPLCmd.h"
#include "Monitor.h"
#include "ReadReg.h"
#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif
/////////////////////////////////////////////////////////////////////////////
// CRegTestDlg dialog
extern CDialog * pReadRegisterDlg;
CRegTestDlg::CRegTestDlg(CWnd* pParent /*=NULL*/)
: CDialog(CRegTestDlg::IDD, pParent)
{
//{{AFX_DATA_INIT(CRegTestDlg)
// NOTE: the ClassWizard will add member initialization here
//}}AFX_DATA_INIT
TRACE("TRACE Output\n");
afxDump<<"afxDump\n";
}
void CRegTestDlg::DoDataExchange(CDataExchange* pDX)
{
CDialog::DoDataExchange(pDX);
//{{AFX_DATA_MAP(CRegTestDlg)
// NOTE: the ClassWizard will add DDX and DDV calls here
//}}AFX_DATA_MAP
}
BEGIN_MESSAGE_MAP(CRegTestDlg, CDialog)
//{{AFX_MSG_MAP(CRegTestDlg)
ON_BN_CLICKED(IDC_WriteParameter, OnWriteParameter)
ON_BN_CLICKED(IDC_WriteRegister, OnWriteRegister)
ON_BN_CLICKED(IDC_WriteDrvCmd, OnWriteDrvCmd)
ON_BN_CLICKED(IDC_WriteIPLCmd, OnWriteIPLCmd)
ON_BN_CLICKED(ID_MONITOR, OnMonitor)
ON_BN_CLICKED(IDC_READ_REG, OnReadReg)
//}}AFX_MSG_MAP
END_MESSAGE_MAP()
/////////////////////////////////////////////////////////////////////////////
// CRegTestDlg message handlers
void CRegTestDlg::OnWriteParameter()
{
// TODO: Add your control notification handler code here
CWriteParam WriteParameterDlg;
WriteParameterDlg.DoModal();
}
void CRegTestDlg::OnWriteRegister()
{
// TODO: Add your control notification handler code here
CWriteReg WriteRegisterDlg;
WriteRegisterDlg.DoModal();
}
void CRegTestDlg::OnWriteDrvCmd()
{
// TODO: Add your control notification handler code here
CWriteDrvCmd WriteDrvCommandDlg;
WriteDrvCommandDlg.DoModal();
}
void CRegTestDlg::OnWriteIPLCmd()
{
// TODO: Add your control notification handler code here
CWriteIPLCmd WriteIPLCommandDlg;
WriteIPLCommandDlg.DoModal();
}
void CRegTestDlg::OnMonitor()
{
CMonitor MonitorSheet("查看运行状态");
/* CPropertyPage PageAxisX(IDD_MONITOR_AXIS_DLG, IDS_AXIS_X);
CPropertyPage PageAxisY(IDD_MONITOR_AXIS_DLG, IDS_AXIS_Y);
CPropertyPage PageAxisZ(IDD_MONITOR_AXIS_DLG, IDS_AXIS_Z);
CPropertyPage PageAxisU(IDD_MONITOR_AXIS_DLG, IDS_AXIS_U);*/
CMonitorIPL PageIPL;
/* MonitorSheet.AddPage(&PageAxisX);
MonitorSheet.AddPage(&PageAxisY);
MonitorSheet.AddPage(&PageAxisZ);
MonitorSheet.AddPage(&PageAxisU);*/
MonitorSheet.AddPage(&PageIPL);
//MonitorSheet.m_psh.dwSize= 26215000;
MonitorSheet.SetActivePage(&PageIPL);
MonitorSheet.DoModal();
}
void CRegTestDlg::OnReadReg()
{
// TODO: Add your control notification handler code here
CReadReg ReadRegisterDlg;
pReadRegisterDlg = &ReadRegisterDlg;
ReadRegisterDlg.DoModal();
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -