欢迎来到天天文库
浏览记录
ID:10540910
大小:476.00 KB
页数:35页
时间:2018-07-07
《单片机串行通信功能设计》由会员上传分享,免费在线阅读,更多相关内容在学术论文-天天文库。
1、分类号:编号:BY1510/11/214-0701沈阳化工学院本科毕业论文题目:单片机串行通信功能设计院系:科亚学院电气信息专业:电气及其自动化班级:科电器0701班学生姓名:于小文指导教师:王贵成论文提交日期:2011年6月21日论文答辩日期:2011年6月23日摘要现代的单片机测控系统中通常以PC机作为控制中心,单片机将采集到的数据通过串口送给PC机进行各种处理,为保证数据传送的及时性和正确性,就必须建立可靠的通讯。在开发控制系统时,信号的测控及采集均由单片机系统自行完成,然后通过异步串行通信口将信号实时地传送给PC机
2、进行处理。上位PC机使用VB进行串口通信的编程,下位单片机使用C51进行编程。本文详述了使用VB和C51实现PC机和单片机串行通信的开发方法,并简要地介绍了VB通讯控件及其使用方法,给出了调试程序。采用将置于现场MCS一51单片机应用系统挂在主机PC的串行通信上,通过串行通信电路及系统控制软件与PC机和单片机进行数据交换的方式,实现了对现场数据的接收与发送。串行通信系统主机采用标准接口。该系统的通信是由PC机主动进行发信访问,各个MCS一51单片机处于被动通信状态,对PC机与单片机数据通信的校验采用奇校验方式。关键词:单片
3、机;串行通信;VB程序设计;上位机AbstractModernmicrocontrollermeasure-controlsystemusuallyregardPCasthecontrolcenter,themicrocontrollerwillsendthecollecteddatatoaPCforaserialport,toensurethatthetransmissionofallthetimelinessandaccuracydata,Itmustestablishreliablecommunication.Int
4、hedevelopmentofthecontrolsystem,signalcontrolandcollectionofmicrocomputersystemitself,thenthroughasynchronousserialcommunicationtothereal-timesignaltransmittedPC.PCusingVBprogrammingforserialcommunication,SCMC51useforprogramming.ThepaperdescribesusingVBC51andPCmac
5、hineandMCUdevelopmentmethodofserialcommunication,andbrieflyintroducesthemethodofusingVBcommunicationcontrolispresented,anddebugging.UsingplacedonsiteMCSa51SCMsysteminthePChosthangingontheserialcommunication,throughserialcommunicationcircuitandcontrolsystemsoftware
6、andPCandMCUexchangedataonsite,receivingandsendingdata.Serialcommunicationsystemisusingstandardinterfacehost.ThesystemofcommunicationbythePCisactiveonavisiteachMCSkindheartedpassivecommunication51-seriesmicrocomputer.ForPCandcalibrationadoptssingle-chipdatacommunic
7、ation'sparity.Keywords:SingleChip;Serialcommunication;VBprogramdesign;Hostcomputer目录第一章绪论11.1单片机技术介绍11.2课题背景与意义21.3课题研究内容3第二章串行通信基础42.1串行通信协议42.2通信方式52.2.1串行通信52.2.2并行通信62.3串行通信方式62.3.1异步串行通信方式62.3.2同步串行通信方式72.4串行通信的制式82.4.1单工82.4.2半双工82.4.3全双工92.5波特率92.6串行通信的错误校验
8、102.6.1奇偶校验102.6.2代码和校验102.6.3循环冗余校验102.7串行通信的工作方式112.7.1方式0112.7.2方式1122.7.3方式2和方式3132.8本章小结14第三章系统开发基础153.1系统硬件153.1.1微处理器芯片89C51153.1.2显示芯片HD7279A173
此文档下载收益归作者所有