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

📄 crc_uidlg.h

📁 该工具用于数字电路仿真中的usb数据文件转换: 1.可以把11比特的令牌包数据(crc5)或者任意字节的数据包数据(crc16)转换为可以作为仿真输入的dn dp文件。 2.可以根据仿真接收到的d
💻 H
字号:
// crc_uiDlg.h : header file
//

#if !defined(AFX_CRC_UIDLG_H__46315CEC_373E_4BC0_9207_D706D7C4A1DD__INCLUDED_)
#define AFX_CRC_UIDLG_H__46315CEC_373E_4BC0_9207_D706D7C4A1DD__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include	"crc_func.h"
#include	"Resource.h"
#include "afxwin.h"
#define	SELECT_ALREADY		1
#define UNSELECT_ALREADY	0

#define TX	1
#define	RX	0

#define	CRC16_FLAG	0
#define CRC5_FLAG	1

#define	FROM_DLG	0
#define	FROM_FILE	1

#define HIGH_SP		1
#define FULL_SP		0

#define FILE_FOR_TMP_DATA  "data_tmp.txt"
/////////////////////////////////////////////////////////////////////////////
// CCrc_uiDlg dialog

class CCrc_uiDlg : public CDialog
{
// Construction
public:
	CCrc_uiDlg(CWnd* pParent = NULL);	// standard constructor
	
	// global var
	char file_input_select;
	char dlg_input_select;
	
	crc_func* crc_feature;
// Dialog Data
	//{{AFX_DATA(CCrc_uiDlg)
	enum { IDD = IDD_CRC_UI_DIALOG };
	CComboBox	m_mode;
	CComboBox	m_direction;
	CComboBox	m_speed_mode;
	CString	m_data_to_trans;
	CString	m_pathname;
	BOOL	m_dlg_input;
	BOOL	m_file_input;
	CString	m_file_rx;
	CString	m_dns;
	CString	m_dps;
	CString	m_rxd;
	CString	m_delay;
	//}}AFX_DATA
	void debug( char* info,int dat);
	void debug_string( char* info );
	void move_to_tmp_file_for_editbox(void);
	void move_to_tmp_file_for_rx(void);
	int Transfer_handler(void);
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CCrc_uiDlg)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support
	//}}AFX_VIRTUAL

// Implementation
protected:
	HICON m_hIcon;

	// Generated message map functions
	//{{AFX_MSG(CCrc_uiDlg)
	virtual BOOL OnInitDialog();
	afx_msg void OnSysCommand(UINT nID, LPARAM lParam);
	afx_msg void OnDestroy();
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	afx_msg void OnGetFile();
	afx_msg void OnTransfer();
	afx_msg void OnFileInputSelected();
	afx_msg void OnDlgInputSelected();
	afx_msg void OnFileForRX();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
public:
	afx_msg void OnCbnSelchangeCombo1();
	
	
};

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

#endif // !defined(AFX_CRC_UIDLG_H__46315CEC_373E_4BC0_9207_D706D7C4A1DD__INCLUDED_)

⌨️ 快捷键说明

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