51单片机的八个LED循环点亮,如何写代码?答:// 51单片机控制八个发光二极管 左右循环。include<reg52.h> define uchar unsigned char define uint unsigned int unsigned char TAB[]= {0xff,0xfe,0xfd,0xfb,0xf7,0xef,0xdf,0xbf,0x7f,0xff,0x7f,0xbf,0xdf,0xef,0xf7,0xfb,0xfd,0xfe,0xff}; // 改变这里 LED 各种花样 uchar t...
求一个用C语言编写的51单片机音乐程序代码。答:include <reg52.h> sbit speaker=P2^2;unsigned char timer0h,timer0l,time;//生日歌 code unsigned char sszymmh[]={5,1,1, 5,1,1, 6,1,2, 5,1,2, 1,2,2, 7,1,4,5,1,1, 5,1,1, 6,1,2, 5,1,2, 2,2,2, 1,2,4,5,1,1, 5,1,1, 5,2,2, 3,2,2,...