📄 rtmdemodlg.h
字号:
// RtmDemoDlg.h : header file
//
#if !defined(AFX_RTMDEMODLG_H__E880C0ED_9982_45DA_A66B_6A7F0D29A2FD__INCLUDED_)
#define AFX_RTMDEMODLG_H__E880C0ED_9982_45DA_A66B_6A7F0D29A2FD__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "..\\..\\include\\pci.h"
/////////////////////////////////////////////////////////////////////////////
// CRtmDemoDlg dialog
typedef struct _tagRTMDIG {
unsigned short port;
unsigned mask;
BOOL bbyte;
BOOL inout;
unsigned nvalue;
unsigned quantum;
unsigned curquantum;
unsigned dbgtm;
}RTM_DIG;
typedef struct _tagRTANL {
unsigned short port;
unsigned mask;
BOOL bbyte;
BOOL inout;
unsigned nvalue;
unsigned quantum;
unsigned curquantum;
unsigned dbgtm;
}RTM_ANL;
extern "C" {
int WINAPI RTXEntry(int);
int WINAPI StartTimer(RTM_DIG *sto, RTM_ANL *sti );
int WINAPI StopTimer();
int WINAPI GetQuantum();
int WINAPI CloseRTM();
int WINAPI GetValue(RTM_DIG *sto, RTM_ANL *sti );
int WINAPI ScanPci(char *pcibuff);
int WINAPI PCIResource(BOOL,PCIINFO *pci);//int bus,int slot,unsigned nVendor,unsigned nDeviceID);
int WINAPI StartDebug(BOOL);
void ReadPhysicalAddress(int,unsigned naddr,void *nvalue,int count,int nsize);
void WritePhysicalAddress(int,unsigned naddr,void *nvalue,int count,int nsize);
}
class CRtmDemoDlg : public CDialog
{
CString m_dport;
CString m_aport;
CString m_dmask;
CString m_arange;
unsigned int m_dquantum;
unsigned int m_aquantum;
BOOL m_bdebug ;
BOOL m_bdbyte ;
BOOL m_babyte ;
BOOL m_bdoutput ;
BOOL m_baoutput ;
BOOL m_breadwrite;
RTM_DIG std;
RTM_ANL sta;
BOOL bStartStop;
// BOOL bInit;
int m_pciiItem;
int m_resiItem;
int m_tmresolution;
CListCtrl m_listpci;
CListCtrl m_listres;
// Construction
public:
CRtmDemoDlg(CWnd* pParent = NULL); // standard constructor
~CRtmDemoDlg(); // standard destructor
// Dialog Data
//{{AFX_DATA(CRtmDemoDlg)
enum { IDD = IDD_RTMDEMO_DIALOG };
// NOTE: the ClassWizard will add data members here
//}}AFX_DATA
// ClassWizard generated virtual function overrides
//{{AFX_VIRTUAL(CRtmDemoDlg)
public:
protected:
virtual void OnOK();
virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
//}}AFX_VIRTUAL
public:
BOOL SetRWValue(BOOL bmode = TRUE,unsigned *naddr = NULL,unsigned *nsize = NULL);
void FillPCI(char *pcib,int count);
void FillPciResource(PCIINFO *pci);
void FillListCtrl();
void SetCombobox(CComboBox* pBox);
void PCIButtonEnable(BOOL);
// Implementation
protected:
HICON m_hIcon;
// Generated message map functions
//{{AFX_MSG(CRtmDemoDlg)
virtual BOOL OnInitDialog();
afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
afx_msg void OnPaint();
afx_msg HCURSOR OnQueryDragIcon();
afx_msg void OnChangeDeditMask();
afx_msg void OnStarttimer();
afx_msg void OnStoptimer();
afx_msg void OnAradioOutput();
afx_msg void OnDradioInput();
afx_msg void OnDradioOutput();
afx_msg void OnAradioInput();
afx_msg void OnTimer(UINT nIDEvent);
afx_msg void OnClose();
afx_msg void OnSelDChangeCombo();
afx_msg void OnSelAChangeCombo();
afx_msg void OnSelChangePCIList(NMHDR* pNMHDR, LRESULT* pResult );
afx_msg void OnSelChangePCIResList(NMHDR* pNMHDR, LRESULT* pResult );
afx_msg void OnAbout();
afx_msg void OnButtonPciread();
afx_msg void OnButtonPciwrite();
afx_msg void OnButtonAssignRes();
afx_msg void OnButtonReleaseRes();
afx_msg void OnRtmDebug();
afx_msg void OnButtonUpdatepci();
//}}AFX_MSG
DECLARE_MESSAGE_MAP()
};
//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
#endif // !defined(AFX_RTMDEMODLG_H__E880C0ED_9982_45DA_A66B_6A7F0D29A2FD__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -