my_base.h
上传用户:shyuanyi
上传日期:2008-05-24
资源大小:69k
文件大小:1k
- #ifndef _MyBasic_H_
- #define _MyBasic_H_
- /*********************************************/
- sbit P0_0=P0^0;
- sbit P0_1=P0^1;
- sbit P0_2=P0^2;
- sbit P0_3=P0^3;
- sbit P0_4=P0^4;
- sbit P0_5=P0^5;
- sbit P0_6=P0^6;
- sbit P0_7=P0^7;
- sbit P1_0=P1^0;
- sbit P1_1=P1^1;
- sbit P1_2=P1^2;
- sbit P1_3=P1^3;
- sbit P1_4=P1^4;
- sbit P1_5=P1^5;
- sbit P1_6=P1^6;
- sbit P1_7=P1^7;
- sbit P2_0=P2^0;
- sbit P2_1=P2^1;
- sbit P2_2=P2^2;
- sbit P2_3=P2^3;
- sbit P2_4=P2^4;
- sbit P2_5=P2^5;
- sbit P2_6=P2^6;
- sbit P2_7=P2^7;
- sbit P3_0=P3^0;
- sbit P3_1=P3^1;
- sbit P3_2=P3^2;
- sbit P3_3=P3^3;
- sbit P3_4=P3^4;
- sbit P3_5=P3^5;
- sbit P3_6=P3^6;
- sbit P3_7=P3^7;
- //--------------
- sfr P4 =0xD8;
- sbit P4_0=P4^0;
- sbit P4_1=P4^1;
- sbit P4_2=P4^2;
- sbit P4_3=P4^3;
- //================================
- typedef unsigned char BYTE;
- typedef unsigned short WORD;
- typedef unsigned long LWORD;
- //================================
- #undef NULL
- #define NULL 0
- #define TRUE 1
- #define FALSE 0
- #define YES 1
- #define NO 0
- #define ON 0
- #define OFF 1
- #define OPEN 0
- #define CLOSE 1
- /*********************************************/
- #endif