基于单片机的电子八音盒设计.doc

  1. 1、本文档共32页,可阅读全部内容。
  2. 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
基于单片机的电子八音盒设计

摘 要 近年来随着科技的飞速发展,单片机的应用正在不断地走向深入。当今,利用单片机控制音乐播放举不胜举,而利用单片机存储音乐,控制播放最为广泛。它具有功能多﹑价格优﹑外围电路简单等特点,很受音乐爱好者及音乐芯片制造商的青睐。 本应用单片机原理和控制理论设计音乐器的硬件电路,并利用汇编语言进行程序设计。通过控制单片机内部的定时器产生不同频率的方波,驱动发出不同音调的音乐,再利用延迟来控制发音时间的长短。把乐谱转化成相应的定时常数就可以从发音设备中演奏出悦耳动听的音乐KeilC51和仿真软件PROTEUS对该音乐播放器进行仿真,完全实现所需功能。 关键词:单片机;蜂鸣器;音调;乐曲 Abstract In recent years, with the rapid development of science and technology, the application of SCM is continuously toward deeper. Today, using single-chip microcomputer control to play music examples are countless, but using single chip computer to storage music and control is the most widely used. It has the features of multi-function, optimal price, simple peripheral circuitry, very popular music lovers and music chip makers favor. This design is mainly applies single-chip principle and control theory to design the hardware circuit, and use assembly languages program design. Through the control of microcontroller timer to produce internal of different frequency, drive differ torque-current buzzer tones of music, reuse delay to control the pronunciation time length. My music into the corresponding time constant of pronunciation equipment can be playing in an euphonic hit music. Paper finally, using the KeilC51 and simulation software programming software for this music player PROTEUS simulation, complete implementation required functions. Keywords: SCM; Buzzer; Tones; music 目 录 引言 1 1 总体设计 2 1.1 设计意义和目的 2 1.2 设计功能要求 2 1.3 设计方案 2 1.4 设计原理 2 1.5 总体设计框图 3 2 硬件设计 4 2.1 电路组成及工作原理 4 2.1.1 电路组成 4 2.1.2 电路工作原理 4 2.2 AT89C51的简介 5 2.2.1 AT89C51功能概述 5 2.2.2 AT89C51的管脚图 5 2.2.3 AT89C51单片机的引脚介绍 5 2.3 晶振电路 6 2.4 扬声器电路 7 2.4.1 蜂鸣器简介 7 2.4.2 扬声器电路 7 2.5 显示电路 8 2.6 更换歌曲电路 9 2.7 复位电路 9 3 软件设计 10 3.1 软件系统介绍 10 3.2 编程语言的选择 10 3.3 演奏原理 10 3.3.1 如何产生音乐频率 10 3.3.2 如何产生节拍 12 3.4 歌谱 12 3.5 建立步骤 13 3.6 程序流程图 14 4 仿真和调试 15 4.1 常用调试工具 15 4.1.1 Keil C软件 15 4.1.2 PROTEUS软件 15 4.2系统调试及性能分析 16 4.3仿真结果 16 结束语 17 参考文献 18 谢 辞 19 附录1 元件明细表 20 附录2 源程序 21 引言 音乐盒的起源,可追溯至中世纪欧洲文艺复兴时期。

文档评论(0)

shenlan118 + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档