#include
#include<12864.h>
#include
#include<24C01.h>
#define uchar unsigned char
#define uint unsigned int
sbit LED1=P1^5;
sbit LED2=P1^6;
sbit INIT=P2^2;
sbit SOUND=P1^7;
uchar idata key[6]={0,0,0,0,0,0};
uchar idata iic[6]={0,1,2,3,4,5};
void press(uchar *s)
{
uchar dat;
//**************************************************
P3=0xf0; //保存第一位密码
while(P3==0xf0);
dat=key_scan();
if((dat!=0x0a)&&(dat!=0x0b))
{ *s=dat;
Left();
star_12864(star,0x05,16);
}
s++;
//**************************************************
P3=0xf0;