求两位数码管显示一个倒数时间的单片机程序,比如显示从99到0答://两位数码管显示倒计数99~00,51单片机。include<reg52.h> // 倒计数 define uint unsigned int define uchar unsigned char uchar code table[]={0x3f,0x06,0x5b,0x4f,0x66,0x6d,0x7d,0x07,0x7f,0x6f,0x77,0x7c,0x39,0x5e,0x79,0x71};uchar bai,shi;uint a1,a2;sbit D1=P3^...
求用单片机汇编语言帮我写一个数码管倒计时程序,用中断延时50ms循环20...答:;误差 0us MOV R6,#10 DL0: MOV R5,#50 DJNZ R5,$ DJNZ R6,DL0 RET TABLE: DB 0C0H,0F9H,0A4H,0B0H,99H ;共阳极0-9显示代码 DB 92H,82H,0F8H,80H,90H END 中断方式: ORG 00H AJMP MAIN ORG 0BH AJMP T0INT ORG 30H MAIN: MOV TMOD,#01H MOV TH0,#3CH MOV TL0,...
求基于AT89C52单片机共阴数码管0到59秒循环计时器c语言代码答:include<reg51.h>#include<INTRINS.h>#define u16 unsigned int#define u8 unsigned char/***/u8 ds[2]; //数码管显示缓存//共阴code u8 w[]={~0x01,~0x02,~0x04,~0x08};//位码code u8 d[]={~0xc0,~0xf9,~0xa4,~0xb0,~0x99,~0x92,~0x82,~0xf8,~0x80,~0x90,};//断...