首页 | 本学科首页   官方微博 | 高级检索  
     

基于嵌入式STM32的ModbusRTU协议实现
引用本文:宋磊,彭道刚,赵斌斌,黄丽.基于嵌入式STM32的ModbusRTU协议实现[J].仪表技术,2014(11):33-36.
作者姓名:宋磊  彭道刚  赵斌斌  黄丽
作者单位:上海电力学院自动化工程学院;
基金项目:上海市“科技创新行动计划”高新技术领域项目(14511101200);上海市部分地方院校能力建设专项项目(13160500700);上海市电站自动化技术重点实验室开放课题(13DZ2273800)
摘    要:随着工业现场总线技术的快速发展,Modbus协议以其高效性、可靠性,广泛应用于电力行业。为了提高电厂对数据采集的可靠性和实时性,提出了将Modbus通信协议与32位STM32F103ZE微处理器相结合的设计方案,介绍了系统的总体设计方案和Modbus通信协议的内容。在嵌入式实时操作系统μC/OS-Ⅱ上实现了基于ModbusRTu通信协议的主站和从站的通信,并详细讨论了Modbus通信协议中CRC校验码的生成。实验结果表明,该方案有效地实现了Modbus协议,可以广泛地应用于电厂和其他工业现场。

关 键 词:嵌入式系统  Modbus协议  数据采集  STM32处理器  μC/OS-Ⅱ

Implementation of Modbus RTU Communication Protocol Based on STM32
SONG Lei,PENG Dao-gang,ZHAO Bin-bin,HUANG Li.Implementation of Modbus RTU Communication Protocol Based on STM32[J].Instrumentation Technology,2014(11):33-36.
Authors:SONG Lei  PENG Dao-gang  ZHAO Bin-bin  HUANG Li
Affiliation:(School of Automation Engineering, Shanghai University of Electric Power, Shanghai 200090, China)
Abstract:With the rapid development of industrial field bus technology, the Modbus protocol is widely used in electric power industry because of its high efficiency and reliability. In order to improve the reliability and real-time performance of data acquisition of the power plant, this paper puts forward a design of Modbus communication protocol with a 32-bit STM32F103ZE microprocessor. The overall design scheme of the system and the content of Modbus Communication Protocol are introduced. The communication between master station and slave station is implemented based on the Modbus RTU communication protocol in the embedded real-time operating system μC/OS-Ⅱ.The generation of Cyclic Redundancy Check in the Modbus Communication Protocol is discussed. The experimental results show that the scheme has realized the Modbus protocol effectively, which can be widely used in power plants and other industrial field.
Keywords:embedded system  Modbus protocol  data acquisition  STM32 processor  μC/OS-Ⅱ
本文献已被 CNKI 维普 等数据库收录!
设为首页 | 免责声明 | 关于勤云 | 加入收藏

Copyright©北京勤云科技发展有限公司  京ICP备09084417号