Scientific Journal of Control Engineering June 2013, Volume 3 Issue 3, PP.236-241
The Extension and Implementation of MultiUART Based on FPGA Ming Lu1#, Yuansheng Liu2, Jishi Shu3 1. College of Applied Science and Technology, Beijing Union University, Beijing 102200, China 2. Beijing Key Laboratory of Information Service Engineering, Beijing Union University, Beijing 100101, China 3. College of Information College, Beijing Union University, Beijing 100101, China #
Email: yykjtluming@buu.edu.cn
Abstract UART (Universal Asynchronous Receiver Transmitter) is broadly used in embedded communication system because of its programmable ability and high stability in working. A UART communication interface system is presented in this paper used Verilog HDL language. In this system, baud rate of each UART is configured through the external bus, and parity bit is added in UART communication protocol in order to reduce the error rate. The whole design is simulated and verified by Modelsim, and synthesized and Placement and routing by Quartus. The FPGA-based experimental results show that the proposed system is a good candidate with accuracy and reliability. Keywords: UART; State Machine; FPGA; Counter
基于 FPGA 的多 UART 扩展与实现* 路铭 1,刘元盛 2,舒济世 3 1. 北京联合大学 应用科技学院,北京 102200 2. 北京联合大学 北京市信息服务工程重点实验室,北京 100101 3. 北京联合大学 信息学院,北京 100101 摘
要:通用异步接收发送器 UART(Universal Asynchronous Receiver Transmitter),具有可编程性和高度稳定性,在嵌入
式通信系统中得到了广泛的应用。本文采用硬件描述语言(HDL)设计了一个简单的多 UART 通信接口系统,此系统可以通 过外部总线配置每个 UART 的波特率,同时为了降低通信中的误码率,在 UART 的通信协议上加入了奇偶校验位。整个 设计在 Modelsim 软件下仿真验证通过,然后利用 Quartus II 软件进行综合以及布局布线,并最终下载到 FPGA(Field Programmable Gate Array)测试系统中验证了本系统的正确性和可靠性。 关键词:UART;状态机;FPGA;计数器
引言 在嵌入式系统、工业控制和计算机外设等领域中,通用异步收发器支持串行链路上的全双工通信,以及拥 有资源简单、操作方便、抗干扰强、易于实现等优点成为最为普及应用的一种通用串行通信协议。在实际电路 开发中,往往只需要 UART 的简单通信协议,但在数量上可能需要多个 UART 接口。常用的扩展方式有三种, ①时分复用,多个设备在不同时间占用串行总线;②软件编程实现,通过对处理器的通用输入输出接口编程实 现,UART 通信时序;③专用芯片扩展,8250 和 8251 等芯片进行总线扩展。三种方法有的占用处理器的大量 处理时间,有的增加外围电路板设计的复杂度,而且不易进行硬件系统升级。现在,随着半导体和 EDA 技术 的发展,FPGA 这种可编程逻辑芯片,以其资源丰富、工作效率高和设计灵活等特点,常用于数据采集、并行 *
基金资助:受北京市属高等学校高层次人才引进与培养计划项目支持资助(IDHT201304074) 。 - 236 http://www.sj-ce.org/