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

📄 led.h

📁 485通讯接口模块的编程应用
💻 H
字号:
#if !defined(AFX_LED_H__34495244_444B_4FCC_A3FA_02500EE8AF59__INCLUDED_)
#define AFX_LED_H__34495244_444B_4FCC_A3FA_02500EE8AF59__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// Led.h : header file
//

/////////////////////////////////////////////////////////////////////////////
// CLed window
//void CALLBACK TimerProc(HWND hWnd,UINT nMsg,UINT nTimerid,DWORD dwTime);
class CLed : public CStatic
{
// Construction
public:
	CLed();

// Attributes
public:

// Operations
public:

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CLed)
	//}}AFX_VIRTUAL

// Implementation
public:
	CString GetCurValue();
	CString GetStrText();
	int GetControlStatus();

 	

	CString SetText(CString str);
	void SetCurValue(float fvalue);
	void SetLowerValue(float fLower);
	void SetUpperValue(float fUpper);
	void SetStatus(int istatus);
	void RefreshCircle();
	void CalStatus();
	
	virtual ~CLed();

	// Generated message map functions
protected:
	COLORREF colorText2;
	COLORREF colorText1;
 	COLORREF colorBK;
	COLORREF colorCircle1 ; 	
	COLORREF colorCircle2 ;
	COLORREF colorCircle3 ;
	CRect rcRefresh ; //刷新的窗口
	float fScale ; 
	float fWarnupper ; 
	float fWarnlower ; 
	float fCurrentvalue ; 
	CString strText   ; //标题下显示的文字
	int iStatus ; //
	bool bTimer ; //0 未开启 1 开启
	bool bRed  ;   //红灯闪烁
	//{{AFX_MSG(CLed)
	afx_msg void OnPaint();
	afx_msg void OnTimer(UINT nIDEvent);
	//}}AFX_MSG

	DECLARE_MESSAGE_MAP()
};

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

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

#endif // !defined(AFX_LED_H__34495244_444B_4FCC_A3FA_02500EE8AF59__INCLUDED_)

⌨️ 快捷键说明

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