【完整版】自行车简易数字里程表设计毕业论文设计 下载本文

内容发布更新时间 : 2024/5/4 18:05:18星期一 下面是文章的全部内容请认真阅读。

毕业设计论文

自行车简易数字里程表

班 级 姓 名 学 号

指导教师 提交日期 2013 年 月 日

I

摘 要

随着居民生活水平的不断提高,自行车已经不仅仅是普通的代步、运输工具,而是成为人们娱乐、休闲、锻炼的首选。自行车简易数字里程表能够满足人们最基本的需求,让人们能清楚地知道当前的速度、里程等物理量。本论文主要阐述一种基于霍尔元件的自行车速度里程表的设计。以 STC89C52单片机为核心,A44E 霍尔传感器测转数,实现对自行车里程速度的测量,采用1602LCD显示自行车的里程数及速度。文章详细介绍了自行车的速度里程表的硬件电路。硬件部分利用霍尔元件将自行车每转一圈的脉冲数传入单片机系统,然后单片机系统将信号经过处理送显示。软件部分用C语言进行编程,采用模块化设计思想。该系统硬件电路简单,子程序具有通用性,完全符合设计要求。

关键字:里程速度;霍尔元件;单片机;LCD显示

ABSTRACT

With the developing of people’s life, the bicycle is not only the universal tool of transportation and substitute for walking, but becomes the first choice of entertainment and exercising. The bicycle mileagespeed can fulfill the basic need of people’s life, so that they can learn the speed and the mileage of the bicycle. In this paper, the bicycle mileagespeed design based on the Hall element is elaborated. By STC89C52as kernel, using A44E Hall element to measure revolution, the measure and statistic are achieved. (Saved by 1602LCD , the bicycle speed can be displayed on LED. )In this article, the of bicycle mileagespeed instrument are introduced in detail. About the the signal processed by Single Chip Microcomputer system is sent to display scream. About the software, in C language; the program is designed in the mode of modules. The system sub-program, and meets the demand of design.

KEY WORDS: Mileage speed; Hall element; Single chip microcomputer; LCD

III

目录

引 言 ................................................................................................................................................ 5 第一部分 设计任务 ........................................................................................................................ 6

1.1 设计要求 .......................................................................................................................... 6 1.2 方案设计 .......................................................................................................................... 6 第二部分 系统硬件平台的设计..................................................................................................... 6

2.1 总体设计方案说明........................................................................................................... 6 2.2 单片机最小系统............................................................................................................... 7

2.2.1 STC89C52单片机 ................................................................................................. 7 2.2.2 时钟电路............................................................................................................... 7 2.2.3 复位电路............................................................................................................... 8 2.3 显示模块 .......................................................................................................................... 8 2.4 霍尔传感器的测量原理................................................................................................. 10 2.5 DS1302时钟芯片 ........................................................................................................... 10 第三部分 系统软件的设计与实现............................................................................................... 11

3.1 主程序流程图................................................................................................................. 11 3.2 显示流程图..................................................................................................................... 11 3.3 速度处理流程图............................................................................................................. 12 3.4 电路仿真 ........................................................................................................................ 13

3.4.1 仿真软件简介 ..................................................................................................... 13 3.4.2 仿真结果............................................................................................................. 13

第四部分 安装调试与性能测量................................................................................................... 14 第五部分 设计总结 ...................................................................................................................... 14 参考文献 ........................................................................................................................................ 14

5