3.写入代码
#include <reg51.h>
void delay(void)
{
unsigned char i ,j;
for(i=0;i<250;i++)
for(j=0;j<250;j++);
}
void main(void)
{
while(1)
{
P0=0xfe;
delay();
P0=0xfd;
delay();
P0=0xfb;
delay();
P0=0xf7;
delay();
P0=0xef;
delay();
P0=0xdf;
delay();
P0=0xbf;
delay();
P0=0x7f;
delay();
}
}
|