您现在的位置:网站首页答辩论文工学论文电子论文

基于AT89C51单片机的电动小汽车

  • 简介:(页数:47字数:21315)摘 要: 本设计以AT89C51单片机为核心,以超微型红外线发射接收一体化管为数据采集器件,用三极管构成的电子开关电路驱动电机,组成了一个比较完整的自动往返电动小汽车的控制系统。系统通过设计一个巧妙的精密控制脉冲占空比算法,实现...
    • 请与管理员联系购买资料 QQ:5739126
  • 论文简介
  • 相关论文
  • 论文下载

(页数:47字数:21315)摘 要: 本设计以AT89C51单片机为核心,以超微型红外线发射接收一体化管为数据采集器件,用三极管构成的电子开关电路驱动电机,组成了一个比较完整的自动往返电动小汽车的控制系统。系统通过设计一个巧妙的精密控制脉冲占空比算法,实现了对电动小汽车自动往返的精密控制。系统的设计充分体现了价廉物美、简单实用的设计原则。
在系统结构上,我们所设计实现的自动往返电动小汽车的控制系统由四个模块组成:单片机微型控制系统模块、数据采集模块、电机驱动模块、信息显示模块。其中,数据采集模块负责采集路面信息;单片机微型控制系统模块负责对采集的信息进行处理,并通过程序完成复杂的控制;电机驱动模块主要根据单片机传入的信号控制小车的运动;信息显示模块则显示相应的信息(如行驶距离显示、倒计时显示等)
本设计的技术特色主要体现在以下几个方面:
(1) 在设计数据采集模块时,考虑到设计成本,我们没有采用昂贵的专用传感器,而是使用廉价的超大型红外线接收发射一体化管,通过外围电路来保证信息采集的可靠性。
(2) 在设计电机驱动模块时,没有使用专用的大功率电子集成开关,而是用三极管组成简单的开关电路,实现了电机的驱动控制。
(3) 用软件实现对小车运动的精密控制是本设计的一大特色。其原理是:用位运算的方法,逐位调整脉冲信号的的占空比,实现了对电机旋转速度的精密控制。为了进一步提高控制精度,我们通过检测车轮旋转的圈数来判断小车的行进速度,继而控制电机的旋转速度,使小车在我们指定的速度下稳定行进。这样,整个电机控制系统构成了一个速度负反馈环,从而完全实现了小车的精密速控。而且,通过检测单位时间车轮旋转的圈数,可以计算出小车的速度。这样,就为发挥部分的实现提供了技术条件和数据信息。
实测数据表明,本设计不仅完成了基本要求部分的各项任务,而且还实现了发挥部分的往返时间和行驶距离显示,以及倒计时显示等功能。系统采用的设计方案正确,电路设计和软件模块设计合理,技术路线基本可行。
关键词:AT89C51芯片 自动往返 电动 光电检测器


ABSTRACT

Design core of regarding AT89C51 one-chip computer as originally, it is gather the device with ultra miniature infrared ray for datum to in charge of integratively to receive to launch, urge electrical machinery with electronic switch circuit that triode form , make up one intact automatic journey to and fro little control system of automobile electronic. Through design one ingenious precision control pulse account for empty than the algorithm system, have realized that controls the precision that the electronic small automobile is automatic and round. The systematic design has fully reflected the good and cheap , simple and practical design principle.
Whether at system structure, we automatic journey to and fro little control system of automobile electronic realized to design made up of four pieces of module. One-chip computer miniature control system module , data gather module , electrical machinery urge module , message show the module. Among them , gather the module and is responsible for gathering road surface information in data; One-chip computer miniature control system module it is punish to go on to message that is gathered to responsible for, and finish complicated control through the procedure ; Electrical machinery urge module main foundation signal that one-chip computer introduce to control sports of the car; Information shows the module shows corresponding information ( Show etc. if going in the distance and shows , counts )
The technological characteristic originally designed reflects in several following respects mainly:
(1)While gathering the module in design data, considering the design cost, we have not adopted the expensive special-purpose sensor , but use the low-priced ultra large-scale infrared ray to receive and launch managing integratively, guarantee the dependability that information is gathered through the peripheral circuit.
(2)While designing the electrical machinery and driving the module , have not used the special-purpose integrated switch of high-power electron , make up the simple switch circuit with the triode , realize the drive control of the electrical machinery.
(3)It is a great characteristic originally designed to control with the precision that the software realizes moving to the car. Its principle is: By way of location operation,it is by turn take empty ones that adjust by pulse signal than,it is rotate electrical machinery there aren't precision of speed not to realize. In order to improve the precision of controlling further, we judge the speed of advancing of the car through measuring the whirling circle of wheel to count , then control the speed of rotation of the electrical machinery , make the car advance steadily under the speed that we appoint . In this way, the control system of the whole electrical machinery forms a tempo negative feedback ring , thus totally realized the precision of the car is accused of rapidly. And, count through measuring the whirling circle of time wheel of the unit, can calculate out the speed of the car . In this way, offer the technological condition and data information for giving play to some realization.
Surveying the data indicates, is it finish every task , basic demand of part to design originally, is it give play to some two-way time and go distance show to realize, and such functions as count-down shows. The design plan that the system adopts is correct, circuit design and software module are reasonable in design, the technological route is feasible basically
Key words: the clip of AT89C51 automatically back and forth car photoconductor measuring tube

摘要………………………………………………………………..3
第一章 MCS-51单片机的结构…………………………………………….6
1.1 MCS-51单片机内部结构……………………………………….6
1.2 MCS-51单片机主要应用特性…………………………………10
第二章 基于8051芯片控制的自动往返小车设计……………11
2.1关于小车的设计任务要求…………………………………….11
2.2对小车的设计期望…………………………………………….11
2.3小车设计的具体实施方案…………………………………….12
2.3.1小车硬件设计方案………………………………………….12
2.3.2小车软件设计方案………………………………………….18
2.4小车功能实现的具体内容…………………………………….19
2.4.1实现小车功能的硬件内容………………………………….19
2.4.2实现小车功能的软件内容………………………………...22
第三章 对于所设计的小车的总结…………………………….29
3.1设计的小车最终实现的功能………………………………….29
3.2本设计方案与其他设计方案比较所得优缺点………………..30
3.3本次设计经验的总结………………………………………….30
参考文献………………………………………………………….31
附录………………………………………………………….…..32
外文资料………………………………………………………...34
中文译文………………………………………………………….41

8051是MCS-51系列单片机的典型产品,我们以这一代表性的机型进行系统的讲解。
8051单片机包含中央处理器、程序存储器(ROM)、数据存储器(RAM)、定时/计数器、并行接口、串行接口和中断系统等几大单元及数据总线、地址总线和控制总线等三大总线,现在我们分别加以说明:
中央处理器:
中央处理器(CPU)是整个单片机的核心部件,是8位数据宽度的处理器,能处理8位二进制数据或代码,CPU负责控制、指挥和调度整个单元系统协调的工作,完成运算和控制输入输出功能等操作。
数据存储器(RAM):
8051内部有128个8位用户数据存储单元和128个专用寄存器单元,它们是统一编址的,专用寄存器只能用于存放控制指令数据,用户只能访问,而不能用于存放用户数据,所以,用户能使用的的RAM只有128个,可存放读写的数据,运算的中间结果或用户定义的字型表。
程序存储器(ROM):
8051共有4096个8位掩膜ROM,用于存放用户程序,原始数据或表格。
定时/计数器(ROM):
8051有两个16位的可编程定时/计数器,以实现定时或计数产生中断用于控制程序转向。
并行输入输出(I/O)口:
8051共有4组8位I/O口(P0、 P1、P2或P3),用于对外部数据的传输。
全双工串行口:
8051内置一个全双工串行通信口,用于与其它设备间的串行数据传送,该串行口既可以用作异步通信收发器,也可以当同步移位器使用。
中断系统:
8051具备较完善的中断功能,有两个外中断、两个定时/计数器中断和一个串行中断,可满足不同的控制要求,并具有2级的优先级别选择。
时钟电路:
8051内置最高频率达12MHz的时钟电路,用于产生整个单片机运行的脉冲时序,但8051单片机需外置振荡电容
存储器 :
8031单片机有4个存储器空间,分别用来安排4种不同功用的存储器:
一\内部数据存储器;二\特殊功能寄存器;三\程序存储器;四\外部数据存储器。
内部数据存储器和特殊功能寄存器集成于片内,程序存储器和外部数据存储器则安排在片外,用接口电路与单片机连接。4种存储器中,除内部数据存储器和特殊功能寄存器是统一编址的除外,各存储器均分开编址,并用不完全相同的寻址方式来访问它们

查看评论 已有0位网友发表了看法
  • 验证码: