基于PROTEUS仿真的频率计数器(顾加柱)改

  • 格式:doc
  • 大小:1.24 MB
  • 文档页数:25

南京大学金陵学院 毕业论文(设计) 南京大学金陵学院

毕 业 论 文(设 计)

作 者: 顾加柱 学 号: 2009020200014 系 部: 信息工程学院 专 业: 电子信息科学与技术 题 目: 基于Proteus仿真的频率计数器

指导老师 张益男 (职称/学位):讲师 提交日期 南京大学金陵学院 毕业论文(设计) 摘 要

传统的频率计数器由组合电路和时序电路等大量的硬件电路组成。我们知道这种开发费时费力且成本高昂,所以本文以频率计数器为研究对象,利用Proteus强大的微机处理器仿真功能,结合Keil编译器,给出了简易且容易操作的频率计数器的设计方案并完成仿真测试。本文设计了一种以单片机AT89C51为核心的数字频率计数器,其中硬件部分主要是由整形电路、单片机最小系统和显示单元组成的,软件设计是由一些功能模块来实现的,例如有初始化模块、晶振模块、数据显示模块以及复位模块等等。这种方法很好地弥补了传统开发模式的各种缺点。该频率计数器由6位数码管显示器和单片机AT89C51,以及信号时钟发生器等构成,可测量频率范围为1Hz到100KHz之间。

关键词:频率计数器; PROTEUS仿真; 单片机; 1~100kHz 南京大学金陵学院 毕业论文(设计) ABSTRACT Traditional frequency counter by combinational circuits and sequential circuits, etc. A lot of hardware circuit. We know that this development laborious and costly, so based on the frequency counter as the research object, the use of Proteus powerful microcomputer processor simulation, combining with Keil compiler, presents a simple and easy to operate the frequency counter design and complete the simulation test. In this paper, we design a microcontroller AT89C51 as the core of the digital frequency counter, the hardware part mainly by shaping circuit, single chip microcomputer minimum system and display units, the software design is composed of some functional modules, such as initialization module, crystal vibration module, data display module as well as the reset module and so on. This method is good enough to make up the flaws of the traditional development mode. The frequency counter by the LCD display and a single chip microcomputer AT89C51, and clock signal generator, the measured frequency range between 1 HZ and 100 KHZ.

Key words:Frequency counter; PROTEUS simulation and single-chip

microcomputer; 1~ 100KHZ 南京大学金陵学院 毕业论文(设计) 目录 摘 要 .............................................................................................................................................. 2 ABSTRACT ...................................................................................................................................... 3 目录 .................................................................................................................................................. 4 第一章 引言及目标 ......................................................................................................................... 5 1.1引言 ..................................................................................................................................... 5 1.1.1简单介绍频率计数器 ............................................................................................ 5 1.1.2研究意义 ................................................................................................................ 6 1.2要实现的目标 ..................................................................................................................... 7 第二章 工具介绍 ............................................................................................................................. 8 2.1 PROTEUS仿真软件 .......................................................................................................... 8 2.1.1简介 .......................................................................................................................... 8 2.1.2 功能特点 ................................................................................................................. 8 2.1.3 proteus的使用 ......................................................................................................... 9 2.2 keil uvision4软件 ............................................................................................................. 10 2.2 .1 keil uvision4软件的介绍 ..................................................................................... 10 2.2.2 keil uvision4软件的使用 ...................................................................................... 10 2.3 关于C语言 ..................................................................................................................... 11 第三章 硬件和软件设计 ............................................................................................................... 11 3.1硬件设计 ........................................................................................................................... 11 3.1.1 AT89C51单片机 ................................................................................................... 12 3.1.2 AT89C51的晶振接法 ........................................................................................... 13 3.1.3单片机的复位 ........................................................................................................ 13 3.1.4显示电路 ................................................................................................................ 14 3.1.5系统总体电路图 .................................................................................................... 16 3.2软件设计 ........................................................................................................................... 16 3.2.1关于信号处理的介绍 ............................................................................................ 16 3.2.2关于终端控制 ........................................................................................................ 17 3.2.3关于控制寄存器 .................................................................................................... 17 第四章 调试测试 ........................................................................................................................... 18 4.1软件的编译调试 ............................................................................................................... 18 4.2载入单片机后的测试 ....................................................................................................... 18 4.3误差分析 ........................................................................................................................... 21 致谢 ................................................................................................................................................ 21 参考文献......................................................................................................................................... 22 附录 ................................................................................................................................................ 23