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

📄 dlgmf.cpp

📁 基于wince系统的RFID识别程序 支持多种RFID协议自动转化
💻 CPP
字号:
// DlgMF.cpp : implementation file
//

#include "stdafx.h"
#include "mf_pad_demo.h"
#include "DlgMF.h"
#include "mi.h"

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// DlgMF dialog


DlgMF::DlgMF(CWnd* pParent /*=NULL*/)
	: CDialog(DlgMF::IDD, pParent)
{
	//{{AFX_DATA_INIT(DlgMF)
		// NOTE: the ClassWizard will add member initialization here
	//}}AFX_DATA_INIT
}


void DlgMF::DoDataExchange(CDataExchange* pDX)
{
	CDialog::DoDataExchange(pDX);
	//{{AFX_DATA_MAP(DlgMF)
	DDX_Control(pDX, IDC_EDIT_DISP, m_editDisp);
	//}}AFX_DATA_MAP
}


BEGIN_MESSAGE_MAP(DlgMF, CDialog)
	//{{AFX_MSG_MAP(DlgMF)
	ON_BN_CLICKED(IDC_BTN_CLEAR, OnBtnClear)
	ON_BN_CLICKED(IDC_BTN_MF_READ, OnBtnMfRead)
	ON_BN_CLICKED(IDC_BTN_MFWRITE, OnBtnMfwrite)
	ON_BN_CLICKED(IDC_BTN_MF_INITVAL, OnBtnMfInitval)
	ON_BN_CLICKED(IDC_BTN_MF_DEC, OnBtnMfDec)
	ON_BN_CLICKED(IDC_BTN_INC, OnBtnInc)
	ON_BN_CLICKED(IDC_BTN_MF_GETSNR, OnBtnMfGetsnr)
	ON_BN_CLICKED(IDC_BTN_MF_VALUE, OnBtnMfValue)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// DlgMF message handlers

void DlgMF::OnBtnClear() 
{
	// TODO: Add your control notification handler code here
	m_editDisp.SetWindowText(_T(""));	
}

extern HANDLE g_hComm ;
void DlgMF::OnBtnMfRead() 
{
								
}

void DlgMF::OnBtnMfwrite() 
{
	// TODO: Add your control notification handler code here

}

void DlgMF::OnBtnMfInitval() 
{
	// TODO: Add your control notification handler code here
	int ret;
	int DeviceAddress = 0;
	unsigned char mode = 0 ;
	unsigned char SectNum = 1;
	int value=1000;

	unsigned char snr[7] = {0xff,0xff,0xff,0xff,0xff,0xff,0xff};
	CString strDsp=_T("");
	unsigned char buffer[100];
	int i,j;

	memset(buffer,0,sizeof(buffer));

	ret = API_PCDInitVal(g_hComm, DeviceAddress,mode,SectNum,
		              (unsigned char*)snr,value);	
	if(ret==0)
	{
		m_editDisp.SetWindowText(_T("API_PCDInitVal 1000 ok"));
	}else {
		m_editDisp.SetWindowText(_T("API_PCDInitVal fail"));
	}	
}

void DlgMF::OnBtnMfDec() 
{
	// TODO: Add your control notification handler code here
		
}

void DlgMF::OnBtnInc() 
{
	// TODO: Add your control notification handler code here
	
}

void DlgMF::OnBtnMfGetsnr() 
{
	// TODO: Add your control notification handler code here
	
}

void DlgMF::OnBtnMfValue() 
{
	// TODO: Add your control notification handler code here
	
}

⌨️ 快捷键说明

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