摘要:超声波是一种指向性强,能量消耗缓慢,在介质中传播距离较远的声波,因此在测距时不受光线、电磁波、粉尘等因素的影响,且成本低,速度快,检测元件可以不与被测介质接触,可测范围广,安装维护方便等,所以应用非常广泛。本设计是以单片机技术为基础,实现对前方物体距离的测量。该系统设计主要由主控制器模块、超声波发射模块、超声波接收模块和显示模块等四个基本模块构成。本设计利用两个中断,在发射信号时,打开定时器中断0和外部中断0使定时器计时,接收到发射超声波信号时,外部中断0关闭中断,这时定时器中断0计录的时间就为超声波传播经过测距仪到前方物体的来回时间,经过单片机处理得到距离值S并且通过显示器显示出来。此系统具有易控制、工作可靠,测距精度高的优点。60889

毕业论文关键词:单片机,超声波传感器,显示器

 Abstract: Ultrasonic is a kind of strong directivity, energy consumption slow, in the medium distance transmission of sound waves, So it is not affected by factors such as light,  electromagnetic waves, dust and so on when it was used to measure the distance. Besides that,  with the low cost, fast speed, detecting element can not contact with the measured medium, measurable range, easy installation and maintenance, etc., so the application is very broad. This design is based on single chip microcomputer technology, realizes the measurement of the front object distance. The system design is mainly composed of main controller module, ultrasonic launch module, ultrasonic receiving module and display module and so on four basic modules, with a receiving part receiving ultrasound. This design uses two interrupts, when transmitting, open the timer interrupt 0 timer and external interrupt 0 timer, receives the side of launch ultrasonic wave signal, the external interrupt 0 closed interrupted, then the timer interrupt 0 meter to record the time for the ultrasonic propagation through the range finder to the object in front of the time back and forth. And the result is treated with single chip microcomputer distance values S and through the display.This system is easy to control, reliable operation and with the advantage of high ranging accuracy. 

Keywords: single chip microcomputer, ultrasound sensor, display 

1 绪论 4

1.1选题的背景及研究意义 4

1.2超声波测距的发展趋势 4

2 超声波测距系统总体设计 5

2.1超声波测距系统设计的目的和要求 5

2.2 超声波测距系统的工作原理 5

3 超声波测距系统硬件设计 6

3.1 AT89S52单片机的概述 6

3.2 LCD1602液晶显示器 6

3.2.1 LCD1602模块的结构 7

3.2.2 LCD1602与单片机的连接方式 7

3.3 HC-SR04超声波测距模块 8

3.4 系统设计 9

4 超声波测距系统软件设计 9

4.1系统设计超声波测距仪的算法设计 10

4.2 主程序流程图 10

4.3 超声波发生子程序和超声波接收中断程序 11

5 超声波测距模块测试 11

结论 13

上一篇:线性调频脉冲压缩原理及其MATLAB仿真+程序
下一篇:HFSS基片集成波导单个纵向缝隙辐射特性研究

AT89C51单片机的简易脉搏测量系统设计+电路图

AT89C51单片机IIC总线的监控...

STC89C51单片机多功能数字频率计的设计+电路图

STC90C516单片机家用照明智能控制系统的设计

STC89C52单片机汽车倒车防撞报警器的设计

STM32单片机微气象监测终端的设计

单片机控制的人体检测智能节能路灯系统设计

老年2型糖尿病患者运动疗...

LiMn1-xFexPO4正极材料合成及充放电性能研究

网络语言“XX体”研究

我国风险投资的发展现状问题及对策分析

安康汉江网讯

张洁小说《无字》中的女性意识

新課改下小學语文洧效阅...

ASP.net+sqlserver企业设备管理系统设计与开发

互联网教育”变革路径研究进展【7972字】

麦秸秆还田和沼液灌溉对...