低频信号发生器设计
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
基于单片机的超低频任意函数信号发生器
贾靓
指导教师 胡学武
摘要:超低频信号发生器是科研、教学、制造业中一种最常用的通用仪器,输出波形一般固定为正弦波、三角波、锯齿波和方波,不能实现有时在实验和工程应用中需要的特殊信号或自定义信号。而要实现这一要求,不是做成硬件式的专用信号发生器,就是用计算机系统来完成,前者仍然不灵活,后者费用太高。然而应用单片机技术,通过软件与硬件的有机结合由硬件电路搭成一个环境平台,再由软件程序把要求的“任意函数信号”数据表嵌入在单片机程序存储器内,通过软件程序更改输出波形数据表,即可方便实现输出任意函数信号,而无需变动硬件电路。本原理样机使用单片机AT89C51,对其进行一次固化,可以安排四种任意波形,频率范围为0.001~800Hz,幅值范围为0~±10V。本文中对原理样机的软硬件系统的性能和误差进行了定量分析,并设计了一套使用Intel公司的新一代16位单片机80296SA对该样机进行了性能提升的新型样机方案,然后对新型样机方案进行了原理分析和性能分析,并给出了误差的定量计算,表明此方案不但可使样机的原理频率范围提高至1500Hz,输出幅值不变,输出分辨率提高至212,使波形质量大为改善。希望这种性价比较高的函数信号发生器对科研、教学、制造业有所帮助。
关键词:单片机应用 MCS51 MCS296 超低频信号发生器
Realizing Ultra-Low-Frequency Arbitrary-Function Generator for
Using single-chip-microcomputer
JiaLiang
Advisor HU Xuewu
(College of Mechanical and Electronic Engineering of Soochow University)
Abstract:The ultra-low-frequency signal generator is a kind of general instrument which is wildly used in the field of scientific research, education and manufacturing. The output of common ultra-low-frequency signal generator has only a few fixed waveforms which can not be changed, but in the scientific research some special
signals could be needed. But the realization of the arbitrary-function is either difficult by the hardware circuit or expensive for the application of the computer system. Nevertheless, to take advantage of single-chip-microcomputer as a core, the ultra-low-frequency arbitrary-function generator can be designed by the organized combination of hardware and software systems. The data table of the output waveform is embedded in the single-chip-microcomputer by software program. The data of the output waveform can be changed by software program conveniently in order to output arbitrary-function signal, and it is not necessary to change hardware circuit. By the prototype model experiment, it has been proved that four arbitrary waveforms can be arranged through once solidifying to AT89C51. For the output signal of this signal generator, the frequency range is 0.001~800Hz and the value range is 0~±10V. This paper carries out the quantitative analysis to the error margin of the prototype model software and hardware system. Meanwhile ,it presents principle analysis of the promotion by the new generation 16 bit-single-chip-microcomputer 80296SA of the Intel company. In the promotion, the prototype model’s frequency scope will come up to 1.5 KHz, and the quality of the waveform will be improved greatly with no change of the value range .Maybe, it is of aid to scientific research, teaching and manufacturing industry.
Key words: application of single-chip-microcomputer MCS51 MCS296 Ultra-Low-Frequency Function Generator
1 引言
1.1 概述
超低频信号发生器是科研、教学、制造业中一种最常用的通用仪器,输出波
形一般固定为正弦波、三角波、锯齿波和方波,不能实现有时在实验或工程应用
中需要的特殊信号给用户使用带来不便。虽然目前市场上的高性能的任意信号发
生器已经出现,但是价格昂贵,对于一般机电控制的用户而言频带不需要很宽。所以一种既能满足一定频率和波形性能要求又价格低廉的超低频任意信号发生