#include<reg52.h>
#include <intrins.h>
#define uint unsigned int
#define uchar unsigned char
void delay(uint z)
{
uint x,y;
for(x=z;x>0;x--)
for(y=110;y>0;y--);
}
void main()
{
uchar temp=0xfe;
while(1)
{
P1=temp;
temp=_crol_(temp,1);
if(temp==0xfe)
{
temp=0x7f;
while(1)
{
temp=_cror_(temp,1);
delay(200);
P1=temp;
if(temp==0xfe){temp=0xfe;break;}
}
continue;
}
delay(200);
}
}