原文地址:http://hi.baidu.com/very_knight/blog/item/40eed415a7588d00c93d6dbf.html #include<pic.h>
#define uchar unsigned char
#define uint unsigned int
__CONFIG(0x3B31);
const uchar table[]={0x3f,0x06,0x5b,0x4f,0x66,0x6d,0x7d,
0x07,0x7f,0x6f,0x77,0x7c,0x39,0x5e,0x79,0x71};
uchar key_num;
void delay(uint x);
void init();
void scan();
void didi(uchar num);
void disp();
|