#include<reg52.h>
#define uchar unsigned char
#define uint unsigned int
uchar numberx[]={
0x00,0x01,0x02,0x03,0x04,0x05,0x06,0x07};
uchar numbery[]={
0x1c,0x14,0x14,0xff,0x14,0x14,0x1c,0x00,
0xff,0xcb,0xcb,0xff,0xcb,0xeb,0xff,0x00,
0xff,0x06,0x1b,0x91,0x40,0x3f,0x40,0x80,
0x84,0x7f,0x84,0xfc,0x3c,0x24,0x3c,0x00,
0x89,0x52,0xf8,0xa8,0xff,0xa8,0xf8,0x00};
void delay( unsigned int z)
{
int i,j;
for(i=z;i>0;i--)
for(j=120;j>0;j--);
}
void main()
{ int x,a,b;
while(1)
{
for(a=0;a<50;a++)
{
for(x=0;x<8;x++)
{
P0=numberx[x];
P1=numbery[x+b];
delay(2);
}
}
b++;
if(b>32)b=0;
}
}