第一范文网 - 专业文章范例文档资料分享平台

基于单片机的数字电子秤设计

来源:用户分享 时间:2020-06-24 本文由独木森林 分享 下载这篇文档 手机版
说明:文章内容仅供预览,部分内容可能不全,需要完整文档或者需要复制内容,请下载word后使用。下载word有问题请添加微信号:xxxxxx或QQ:xxxxxx 处理(尽可能给您提供完整文档),感谢您的支持与谅解。

基于单片机的数字电子秤设计

摘 要

随着微电子技术的应用,市场上使用的传统称重工具已经满足不了人们的要求。为了改变传统称重工具在使用上存在的问题,在本设计中将智能化、自动化、人性化用在了电子秤重的控制系统中。本系统主要由单片机来控制,测量物体重量部分由称重传感器及A/D转换器组成,加上显示单元,此电子秤俱备了功能多、性能价格比高、功耗低、系统设计简单、使用方便直观、速度快、测量准确、自动化程度高等特点。

本系统以AT89S52单片机为主控芯片,外围附以称重电路、显示电路、报警电路、键盘电路等构成智能称重系统电路板,从而实现自动称重系统的各种控制功能。可以说,此设计所完成的电子秤很大程度上满足了应用需求。

关键词:SP20C-G501;AT89S52;称重传感器;A/D转换器;LCD显示器

I

The electronic scale design based on microcontroller

Abstract

With the application of micro-electronics technology, tradition ponderation instrument used in market has been not satisfaction with hunman requirements already. In order to make up for the traditional apparatus shortcoming, we improve the apparatus's control system with intelligence and automation. This system is mainly controlled by microcontroller, the section of height measurement accomplish by supersonic sensor, the section of weight measurement accomplish by weight sensor and A/D transformer, this apparatus have many characteristic such as having more function, consume less energy, small and move easily, low price, measure precisely, the speed is quick, automatic work without people and so on.

The system is mainly controlled by the microcontroller AT89S52, the periphery is consist of the circuit of clock and calendar, the circuit of measure height and weight, the circuit of display and print, all of these comprise the circuit board of the intelligent apparatus of height and weight. It can achieve all function of the apparatus.

Keywords:SP20C-G501;AT89S52;ponderation –sensor;A / D converter;LCDDisplay

II

目 录

摘要 .................................................................................................................................................. I Abstract ......................................................................................................................................... II 1 绪论 ........................................................................................................................................... 1 1.1 称重技术的发展 ...................................................................................................................... 1 1.2 电子秤的工作原理 .................................................................................................................. 1 1.3 设计思路 .................................................................................................................................. 2 2 系统方案论证与选型 ............................................................................................................... 3 2.1 控制器部分 .............................................................................................................................. 3 2.2 数据采集部分 .......................................................................................................................... 4 2.2.1 传感器的选择 ....................................................................................................................... 4 2.2.2 放大电路选择 ....................................................................................................................... 5 2.2.3 A/D转换器的选择 ................................................................................................................ 8 2.2.4 键盘处理部分方案论证 ....................................................................................................... 9 2.3 显示电路部分的选择 ............................................................................................................ 10 2.4 超量程报警部分选择 ............................................................................................................ 10 3 硬件电路设计 ......................................................................................................................... 10 3.1 单片机芯片AT89S52介绍 ................................................................................................... 11 3.1.1 AT89S52引脚图 .................................................................................................................. 11 3.1.2 单片机管脚说明 ................................................................................................................. 12 3.2 电源电路设计 ........................................................................................................................ 14 3.3 数据采集部分电路设计 ........................................................................................................ 14 3.3.1 传感器和其外围以及放大电路设计 ................................................................................. 14 3.3.2 A/D转换芯片与AT89S52单片接口电路设计 ................................................................. 16 3.3.3 测量算法 ............................................................................................................................. 17 3.4 显示电路与AT89S52单片机接口电路设计 ....................................................................... 18 3.5 键盘电路与AT89S52单片机接口电路设计 ....................................................................... 19 3.6 报警电路的设计 .................................................................................................................... 21 4 系统软件设计 ......................................................................................................................... 23

III

4.1主程序设计 ............................................................................................................................. 23 4.2 子程序设计 ............................................................................................................................ 24 4.2.1 A/D转换启动及数据读取程序设计 .................................................................................. 24 4.2.2 数制转换子程序设计 ......................................................................................................... 25 4.2.3 显示子程序设计 ................................................................................................................. 26 4.2.4 键盘扫描子程序的设计 ..................................................................................................... 27 4.2.5 报警子程序的设计 ............................................................................................................. 28 结论 ............................................................................................................................................... 30 致谢 ............................................................................................................................................... 31 参考文献 ....................................................................................................................................... 32 附录 ............................................................................................................................................... 33

IV

搜索“diyifanwen.net”或“第一范文网”即可找到本站免费阅读全部范文。收藏本站方便下次阅读,第一范文网,提供最新高中教育基于单片机的数字电子秤设计 全文阅读和word下载服务。

基于单片机的数字电子秤设计 .doc 将本文的Word文档下载到电脑,方便复制、编辑、收藏和打印
本文链接:https://www.diyifanwen.net/wenku/1101428.html(转载请注明文章来源)
热门推荐
Copyright © 2018-2022 第一范文网 版权所有 免责声明 | 联系我们
声明 :本网站尊重并保护知识产权,根据《信息网络传播权保护条例》,如果我们转载的作品侵犯了您的权利,请在一个月内通知我们,我们会及时删除。
客服QQ:xxxxxx 邮箱:xxxxxx@qq.com
渝ICP备2023013149号
Top