#ifndef _common_h
#define _common_h
#include
#include
#include
#define uint unsigned int
#define uchar unsigned char
#define ulong unsigned long
//set RF401 into transmit mode; RF module is default receive mode
#define TRANSMIT
#define SUCCESS 0xaa
#define FAILURE 0x55
#define YES 0xaa
#define NO 0x55
#define LED PORT2_5
#define TXD PORT2_6
#define RXD PORT2_7
//#define TXD DIN
//#define RXD DOUT
sbit DOUT = P1^0;
sbit DIN = P1^1;
sbit RFCS = P3^3;
sbit PWR_UP = P3^4;
sbit TXEN = P3^5;
sbit PORT2_5 = P2^5;
sbit PORT2_6 = P2^6;
sbit PORT2_7 = P2^7;
extern uchar COMFlag;
extern uint delay;
extern uchar RecBuf[3];
extern void InitUART_T1(void);
//extern void InitUART_T2(void);
extern void SendUART(uchar DataSend);
//extern uchar RecUART(void);
extern void extendUARTsend(uchar DataToSend);
extern uchar extendUARTreceive(void);
//extern uchar RFtransceive(uchar RFdata);
暂无评论