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

📄 pendview.h

📁 上次我传的倒立摆的控制程序,不是我的最终的程序,本程序采用VC++编程,定时器为多媒体控制器,(控制时间可到达5ms),控制算法用的是最优控制,
💻 H
字号:
// PendView.h : interface of the CPendView class
//
/////////////////////////////////////////////////////////////////////////////

#if !defined(AFX_PENDVIEW_H__9A8D59DF_226C_450C_A3CA_B21EBF6444F4__INCLUDED_)
#define AFX_PENDVIEW_H__9A8D59DF_226C_450C_A3CA_B21EBF6444F4__INCLUDED_

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

class CPendView : public CView
{
protected: // create from serialization only
	CPendView();
	DECLARE_DYNCREATE(CPendView)

// Attributes
public:
	CPendDoc* GetDocument();

// Operations
public:

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CPendView)
	public:
	virtual void OnDraw(CDC* pDC);  // overridden to draw this view
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	protected:
	virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);
	virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);
	virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);
	//}}AFX_VIRTUAL

// Implementation
public:
	long wznum;
    long jdnum;
	UINT TimerID_7ms;
	UINT wAccuracy;
	virtual ~CPendView();
#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

protected:

// Generated message map functions
protected:
	//{{AFX_MSG(CPendView)
	afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
	afx_msg void OnStart();
	afx_msg void OnStop();
	afx_msg void OnChar(UINT nChar, UINT nRepCnt, UINT nFlags);
	afx_msg void OnPaint();
	afx_msg void OnLeft();
	afx_msg void OnRight();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

#ifndef _DEBUG  // debug version in PendView.cpp
inline CPendDoc* CPendView::GetDocument()
   { return (CPendDoc*)m_pDocument; }
#endif

/////////////////////////////////////////////////////////////////////////////

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

#endif // !defined(AFX_PENDVIEW_H__9A8D59DF_226C_450C_A3CA_B21EBF6444F4__INCLUDED_)

⌨️ 快捷键说明

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