基于单片机的低频信号发生器的设计毕业论文

燕山大学本科生毕业设计(论文)

摘要

本文是基于单片机的低频信号发生器的设计。我所设计的信号发生器是由单片机AT89C51,D/A转换器DAC0832,低频放大器LM324和四位一体数码管实现的。本系统输出的电压范围是0~5V,频率范围是1~1000Hz,以电压的方式输出正弦波、三角波和方波信号,用数码管显示信号的频率。可通过键盘选择输出波形和调节频率的大小。该信号发生器具有操作简便、灵活,性价比高和智能化的特点,可广泛用于电子测量、调试工程中。

本文首先对信号发生器的原理,发展历史进行了较全面的介绍,为本次设计奠定了扎实的基础。其次,介绍了信号发生器的种类,通过对几种不同低频信号发生器的比较从中确定本次设计方案,并介绍其基本设计原理。其次,通过学习AT89C51和DAC0832的主要结构和功能,设计了一种以这两个芯片为核心的低频信号发生器。本次设计主要是通过软件控制整个电路系统,最后通过软件的主程序流程图和子程序流程图介绍本系统软件的工作过程。

关键词 信号发生器;单片机AT89C51;D/A转换;低频放大器

I

燕山大学本科生毕业设计(论文)

Abstract

This article is according to the low-frequency signal generator single-chip design. I designed the signal generator is made up with a single-chip microcomputer of AT89C51, D/A converter of DAC0832, low-frequency amplifier of LM324 and four-in-one digital control to achieve. The system can output the electric voltage biggest be worth for the 0-5 V. The frequency is a 1-1000 Hz Of rectangle wave, triangle wave, and sine wave,for third kinds of form signal.,output voltage waveform signal with a digital display signal frequency. The signal generator is simple, flexible, cost-effective and intelligent features, can be widely used in electronic measurement and testing work.

This article first introduce signal generating device principle, the historical development has been carrying on the comprehensive introduction, has laid the solid foundation for this design. Secondly, introduced signal generating device's type, through to several kind of different low-frequency signal generator's comparison definite this design proposal, and introduces its important job principle. Thridly, through studies AT89C51 and the DAC0832 primary structure and the function, has designed one kind of these two chips as the core low-frequency signal generator. This design is mainly through the software control entire circuitry, finally introduces this system software work process through software's master routine flow chart and the subroutine flow chart.

Keywords The signal occurrence machine;Monolithic machine AT89C51;

D/A conversion;low noise amplifier

II

目 录

摘要 ....................................................................................................................... I Abstract ................................................................................................................ II 第1章 绪论 ........................................................................................................ 1

1.1 课题背景 ............................................................................................... 1

1.2 信号发生器的发展历史 ....................................................................... 1 1.3 信号发生器发展趋势及现状 ............................................................... 3 1.4 课题主要内容和章节安排 ................................................................... 4 第2章 低频信号发生器的设计原理 ................................................................ 6

2.1 信号发生器的种类 ............................................................................... 6 2.1.1 按输出信号频率范围分类 ............................................................ 6 2.1.2 按输出波形分类 ............................................................................ 6 2.1.3 按信号发生器的性能分类 ............................................................ 7 2.2 低频信号发生器的方案设计 ............................................................... 7 2.2.1 方案一 ............................................................................................ 7 2.2.2 方案二 ............................................................................................ 8 2.2.3 方案三 ............................................................................................ 9 2.3 基于AT89C51信号发生器的方案设计及原理 ................................. 9 2.3.1 信号发生器的硬件电路设计方案 ................................................ 9 2.3.2 信号发生器的软件电路设计方案 ............................................... 11 2.4 本章小结 ............................................................................................. 12 第3章 信号发生器的硬件部分 ...................................................................... 13

3.1 主要器件 ............................................................................................. 13 3.1.1 单片机芯片AT89C51 ................................................................. 13 3.1.2 数模转换器DAC0832 ................................................................ 16 3.1.3 LM324的结构与功能 .................................................................. 18 3.2 单元电路设计 ..................................................................................... 19 3.2.1时钟电路 ....................................................................................... 19 3.2.2复位电路 ....................................................................................... 20 3.2.3 电源电路 ...................................................................................... 20

III

联系客服:779662525#qq.com(#替换为@) 苏ICP备20003344号-4