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

📄 prd_rf_comm.h

📁 读RF卡的源代码
💻 H
字号:
//=============================================================================
//                  Copyright (C) INSIDE Contactless 1998-2005
//
// INSIDE Contactless reserves the right to make changes, without notice,
// to any product (including application note) herein to improve
// reliability, functionality, or design. INSIDE Contactless advises its
// customers to obtain the latest version of device data sheets to verify,
// before placing orders, that the information being relied upon by the
// customer is current.
//
// INSIDE Contactless makes no warranty that the use will not infringe any
// third party patent, copyright or trademark.
//
// Information furnished by INSIDE Contactless is believed to be accurate
// and reliable. However, INSIDE Contactless does not assume any liability
// resulting from the application or use of any product described within.
//
// All rights are reserved. Reproduction in whole or in part is prohibited
// without the written consent of the copyright owner.
//
//      Bat 11a,
//      Parc Club du Golf,
//      Z.A.C. du Pichaury                      Tel :   +33 (0)4.42.39.33.00
//      13856 Aix-en-Provence Cedex 3           Fax :   +33 (0)4.42.39.63.19
//      FRANCE                                  Email : info@insidefr.com
//
//-----------------------------------------------------------------------------
// Project Code : PICOREAD_RF C LIBRARY
// Project Name : PICOREAD_RF C LIBRARY
// Module Name  : PRD_RF_COMM.h
// Platform dev : Keil 礦ision 3 (IDE ) + Keil ARM Compiler
// Target       : LPC2129 (ARM7TDMI Core)
// Language     : C ANSI
// Revision     : 1.1
// Description  : Low level communication protocol with Picoread RF chip
//=============================================================================
// When		Who	Ver		What
// 06-04-24	MCY	1.1		Added #ifndef __TARGET_FUNCTION_H 	
//=============================================================================
#ifndef __PRD_RF_COMM_H__
#define __PRD_RF_COMM_H__

#define PICOREADRF_LIBRARY_MODULE_VERSION 0x30313032

// Reader behaviour
#define LIB_RASR  // Standard
//#define LIB_RASC   // Reader as a chip (not useable in this code)

#define v_fnSPI_reset() v_fnCS_reset()
extern void 			v_fnCS_reset();
extern void 			v_fnSPI_WaitForEOT();
extern void 			v_fnSPI_SendBuffer(unsigned char p_bBytesLength, unsigned char p_bBitsLength,unsigned char * p_pabBuffer);
extern void				v_fnSPI_SendByte(unsigned char p_bData);
extern unsigned char 	b_fnSPI_ReceiveByte();
extern unsigned char 	b_fnSPI_GetBuffer(unsigned char* p_pabBuffer,unsigned char* p_pbPicoReadStatus,unsigned short* p_pwRFPicoReadByteCounter,unsigned char* p_pbRFPicoReadBitCounter, unsigned char* p_pbRFReceiveEOF);
extern unsigned char 	b_fnCheckCRCValid(unsigned char p_lbPicoReadStatus,unsigned short* p_pwRFPicoReadByteCounter);

#ifdef LIB_RASR
extern void			 	v_fnSendRFCommand(unsigned char p_bSendOption,unsigned char* p_pabBuffer, unsigned short* p_pwRFPicoReadByteCounter, unsigned char* p_pbRFPicoReadBitCounter);
extern unsigned char 	b_fnReceiveRFResponse(unsigned char p_bReceiveOption,unsigned char* p_pabBuffer,unsigned short* p_pwRFPicoReadByteCounter,unsigned char* p_pbRFPicoReadBitCounter,unsigned char* p_pbPicoReadStatus,unsigned char* p_pbRFReceiveEOF,unsigned char p_bBitsToReceive);

#endif  // LIB_RASR

#ifdef LIB_RASC
extern void 			v_fnReceiveRFCommand(unsigned char p_bReceiveOption, unsigned char* p_pabBuffer,unsigned short* p_pwRFPicoReadByteCounter,unsigned char* p_pbRFPicoReadBitCounter, unsigned char* p_pbPicoReadStatus, unsigned char* p_pbRFReceiveEOF);
extern void				v_fnSendRFResponse(unsigned char p_bSendOption, unsigned char* p_pabBuffer, unsigned short* p_pwRFPicoReadByteCounter, unsigned char* p_pbRFPicoReadBitCounter);
#endif  // LIB_RASC

#endif // __RFCOM_H

⌨️ 快捷键说明

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