#include "waaagh.h"
#include "lsl.h"
#define w=0
//u8 code smgduan[]={0x3f,0x06,0x5b,0x4f,0x66,0x6d,0x7d,0x07,0x7f,0x6f,0x77,0x7c,
// 0x39,0x5e,0x79,0x71};
//sbit key1=P1^2;
//sbit key2=P1^3;
//sbit key3=P1^4;
//sbit key4=P1^5;*/
void main()
{
wagh();
w=0;
while(1)
{
if(key3==0)
{
delay_ms(1);
if(key3==0)
{
w=w+1;
}
while(!key3);
}
if (w==0)
{
}
{
}
else if (w==1)
{
panduan0 ();
}
else if (w==2)
{
panduan1 ();
}
else if (w==3)
{
panduan2 ();
}
else if (w==4)
{
panduan3();
}
else if (w==5)
{
led1=0;
delay_ms(1000);
led1=1;
led2=0;
delay_ms(1000);
led2=1;
led3=0;
delay_ms(1000);
led3=1;
led4=0;
delay_ms(1000);
led4=1;
led5=0;
delay_ms(1000);
led5=1;
led6=0;
delay_ms(1000);
led6=1;
led7=0;
delay_ms(1000);
led7=1;
led8=0;
delay_ms(1000);
}
else w=1;
}
}
|