【数码管向左出现与消失滚动“456789Ab”】2022-4-25
缘由数码管自右向左滚动显示数字“456789Ab”,要求显示过程数字串从无到有自右边出现,直到从左边完全消失,然后再次循环显示该过程; (2)数字滚动速度由某定时器定时实现-嵌入式-CSDN问答
void main()
{unsigned char Xd=0,xz=255,cs=4,ss=0,s1=0,s2=0,s3=0,s4=3,
wy[]={0,0,0,0,0,0,0,0},sj[]={4,5,6,7,8,9,10,11};unsigned int wei=47474;unsigned long yw = 123; P0=P1=P2=P3=Js=0;ZhongDuanSheZhi();while(1){if(wy[s1]==0)wy[s1]=128;else ;s3=0;while(s3<8){smxs(sj[s3],wy[s3],1);++s3;}if(Js==10){while(s2<s1+1&&s2<8){wy[s2]/=2;++s2;}if(++s1>15)s1=0;else;s2=Js=0;}}
}