微波EDA网,见证研发工程师的成长!
首页 > 硬件设计 > 嵌入式设计 > 51单片机控制蜂鸣器播放5首歌曲汇编程序

51单片机控制蜂鸣器播放5首歌曲汇编程序

时间:11-28 来源:互联网 点击:

欢乐颂

DB 32,32,32,32,32,32,32,32,32,32,32,32,48,16,64

DB 32,32,32,32,32,16,16,32,32,32,16,16,32,32,32,32,32,64

DB 32,32,32,32,32,32,32,32,32,32,32,32,16,16,64

TAB_L2: DB 32,32,16,16,16,16,32,32,32,32,16,16,16,16,32,32,32 ;小步舞曲

DB 32,16,16,16,16,32,16,16,16,16,32,16,16,16,16,32,64,32

DB 32,16,16,16,16,32,32,32,32,16,16,16,16,32,32,32

DB 32,16,16,16,16,32,16,16,16,16,32,16,16,16,16,64,32,32

TAB_L3: DB 32,16,16,32,16,16,32,16,16,16,16,16,16,32 ;小蜜蜂

DB 16,16,32,16,16,32,16,16,16,16,64

DB 16,16,16,16,16,16,32,16,16,16,16,16,16,32

DB 16,16,32,16,16,32,16,16,16,16,32

TAB_L4: DB 32,16,16,32,32,32,64,16,16,32,32,32,64 ;生日快乐

DB 16,16,32,32,32,32,64,16,16,32,32,32,64

TAB_L5: DB 32,32,16,16,64,32,32,64,32,16,16,32,16,16,96+32 ;送别

DB 32,16,16,48,16,32,32,64,32,16,16,48,16,128

DB 32,32,64,32,16,16,64,16,16,16,16,16,16,16,16,96+32

DB 32,16,16,48,16,32,32,64,32,16,16,48,16,96,32

TAB_L6: DB 32,32,32,64,32,32,64,32,32,32,32,32,16,16,64 ;樱花

DB 32,32,32,32,32,16,16,64,32,32,32,32,32,16,16,64

DB 32,32,32,32,32,16,16,64,32,32,64,32,32,64

DB 32,32,16,16,32,96

TAB_L7: DB 32,32,16,16,32,16,16,16,32,16,64,32,16,16,32,16,16,16,32,16,64 ;虹彩妹妹

DB 32,16,16,16,16,16,16,16,32,16,64,32,16,16,32,32,16,32,16,48

TAB_L8: DB 32,16,16,48,16, 16,16,16,32,16,16,16, 32,16,16,16,16,16,16, 128+32 ;童年

DB 16,16,32,16,16, 16,16,16,32,16,16,16, 32,16,16,16,16,16,16, 128

DB 16,16,16,32,16,16,16, 32,16,16,16,16,16,16, 32,16,16,16,16,16,16, 128

DB 16,32,16,32,32, 16,32,16,16,16,16,16, 16,32,16,16,16,16,16, 128

TAB_L9: DB 32,00H

TAB_L10: DB 32,00H

;---------------播放音符表(0表示休止,1FH为结束标志)----------------

;从6开始,6——低6,7——低7,8——1,9——2 ,10——3,11——4,12——5,13——6,14——7,15——高1

; 16——高2,17——高3,18——高4,19——高5,20——高6

TAB_TONE0: DB 0,10+7,10+7,10+7, 10+7,10+7,10+7, 10+7,12+7,8+7,9+7, 10+7 ;《DINGO BELL 》

DB 11+7,11+7,11+7, 11+7,10+7,10+7, 10+7,9+7, 9+7,10+7, 9+7

DB 10+7,10+7,10+7, 10+7,10+7,10+7, 10+7,12+7,8+7,9+7, 10+7

DB 11+7,11+7,11+7, 11+7,10+7,10+7, 12+7,12+7,11+7,9+7, 8+7

DB 1FH

TAB_TONE1: DB 0,17,17,18,19,19,18,17,16,15,15,16,17,17,16,16 ;欢乐颂

DB 17,17,18,19,19,18,17,16,15,15,16,17,16,15,15

DB 16,16,17,15,16,17,18,17,15,16,17,18,17,16,15,16,12,17

DB 17,18,19,19,18,17,16,15,15,16,17,16,12,15,15

DB 1FH

TAB_TONE2: DB 0,19,15,16,17,18,19,15,15,20,18,19,20,21,22,15,15 ;小步舞曲

DB 18,19,18,17,16,17,18,17,16,15,14,15,16,17,15,17,16,0

DB 19,15,16,17,18,19,15,15,20,18,19,20,21,22,15,15

DB 18,19,18,17,16,17,18,17,16,15,16,17,16,15,14,15

DB 1FH

TAB_TONE3: DB 0,19,17,17,18,16,16,15,16,17,18,19,19,19 ;小蜜蜂

DB 19,17,17,18,16,16,15,16,17,19,17

DB 16,16,16,16,16,17,18,17,17,17,17,17,18,19

DB 19,17,17,18,16,16,15,16,17,19,15

DB 1FH

TAB_TONE4: DB 0,12,12,13,12,15,14,12,12,13,12,16,15 ;生日快乐

DB 12,12,19,17,15,14,13,18,18,17,15,16,15

DB 1FH

TAB_TONE5: DB 0,19,17,19,22,20,22,19,19,15,16,17,16,15,16 ;送别

DB 19,17,19,22,21,20,22,19,19,16,17,18,14,15

DB 20,22,22,21,20,21,22,20,21,22,20,20,19,17,15,16

DB 19,17,19,22,21,20,22,19,19,16,17,18,14,15

DB 1FH

;从6开始,6——低6,7——低7,8——1,9——2 ,10——3,11——4,12——5,13——6,14——7,15——高1

; 16——高2,17——高3,18——高4,19——高5,20——高6

TAB_TONE6: DB 0,20,20,21,20,20,21,20,21,22,21,20,21,20,18 ;樱花

DB 17,15,17,18,17,17,15,14,20,21,22,21,20,21,20,18

DB 17,15,17,18,17,17,15,14,20,20,21,20,20,21

DB 17,18,21,20,18,17

DB

Copyright © 2017-2020 微波EDA网 版权所有

网站地图

Top