现代电子技术Issue(23):41-43,46,4.
STC单片机波特率自适应方法
Baud rate adaptive method for STC single-chip microcomputer
赵培宇1
作者信息
- 1. 江汉大学 机电与建筑工程学院,湖北 武汉 430056
- 折叠
摘要
Abstract
To reduce circuit volume and hardware cost,and at the same time,guarantee the stable and reliable serial port communication,a baud rate adaptive method is proposed. This method makes full use of STC microcontroller′s characteristics of high-speed running,on-chip oscillator,rich on-chip resources. In the serial communication program,the microcontroller′s I/O port and timer are utilized to detect and calculate the fixed character transmitted by host for getting the right baud rate constant, so as to realize the baud rate self-adaption. The design principle and realization method,error analysis,flow chart and part of the program are also given in this paper. The feasibility of the method was verified by a true example.关键词
STC单片机/串口通信/波特率选择/自适应方法Key words
STC single-chip microcomputer/serial communication/baud rate selection/self-adaptive method分类
信息技术与安全科学引用本文复制引用
赵培宇..STC单片机波特率自适应方法[J].现代电子技术,2013,(23):41-43,46,4.