*** WARNING L2: REFERENCE MADE TO UNRESOLVED EXTERNAL
SYMBOL: _DELAY
MODULE: zy.obj (ZY)
ADDRESS: 0A3AH
- #include<reg51.h>
- #define LED P1
- void delay( int x);
- main()
- {
- unsigned char i,j;
- unsigned char dis1[]={0xfe,0xfd,0xfb,0xf7,0xef,0xdf,0xbf,0x7f};
- unsigned char dis2[]={0x7f,0xbf,0xdf,0xef,0xf7,0xfb,0xfd,0xfe};
- unsigned char dis3[]={0xfe,0xfc,0xf8,0xf0,0xe0,0xc0,0x80,0x00};
- unsigned char dis4[]={0x00,0x80,0xc0,0xe0,0xf0,0xf8,0xfc,0xfe};
- unsigned char dis5[]={0x7f,0x3f,0x1f,0x0f,0x07,0x03,0x01,0x00};
- unsigned char dis6[]={0x00,0x01,0x03,0x07,0x0f,0x1f,0x3f,0x7f};
- unsigned char dis7[]={0xe7,0xdb,0xbd,0x7e,0x7e,0xbd,0xdb,0xe7};
- unsigned char dis8[]={0xf0,0x0f,0xf0,0x0f,0xf0,0x0f,0xf0,0x0f};
- unsigned char dis9[]={0x3f,0xcf,0xf3,0xfc,0xfc,0xf3,0xcf,0x3f};
- unsigned char dis10[]={0x33,0xcc,0x33,0xcc,0x33,0xcc,0x33,0xcc};
- while(1)
- {
- for(j=0;j<2;j++)
- {
- for(i=0;i<8;i++)
- {
- LED=dis1[i];
- delay(100);
- }
- }
- for(j=0;j<3;j++)
- {
- for(i=0;i<8;i++)
- {
- LED=dis2[i];
- delay(100);
- }
- }
- for(j=0;j<4;j++)
- {
- for(i=0;i<8;i++)
- {
- LED=dis3[i];
- delay(100);
- }
- }
- for(j=0;j<2;j++)
- {
- for(i=0;i<8;i++)
- {
- LED=dis4[i];
- delay(100);
- }
- }
- for(j=0;j<3;j++)
- {
- for(i=0;i<8;i++)
- {
- LED=dis5[i];
- delay(100);
- }
- }
- for(j=0;j<4;j++)
- {
- for(i=0;i<8;i++)
- {
- LED=dis6[i];
- delay(100);
- }
- }
- for(j=0;j<2;j++)
- {
- for(i=0;i<8;i++)
- {
- LED=dis7[i];
- delay(100);
- }
- }
- for(j=0;j<3;j++)
- {
- for(i=0;i<8;i++)
- {
- LED=dis8[i];
- delay(100);
- }
- }
- for(j=0;j<4;j++)
- {
- for(i=0;i<8;i++)
- {
- LED=dis9[i];
- delay(100);
- }
- }
- for(j=0;j<2;j++)
- {
- for(i=0;i<8;i++)
- {
- LED=dis10[i];
- delay(100);
- }
- }
- }
- }
复制代码
|