吉林大学学报(信息科学版) ›› 2020, Vol. 38 ›› Issue (2): 148-153.

• • 上一篇    下一篇

基于 32 位 MCU 的 XLPE 生产线中 Modbus 的实现

胡科幻1 ,石景龙 1 ,苗政1 ,徐 信2 ,王向超 2 ,齐文斌 2 ,张军3
  

  1. 1. 吉林大学 电子科学与工程学院,长春 130012; 2. 白城福佳科技有限公司 工程技术部,吉林 白城 137000;
    3. 吉林电子信息职业技术学院 信息中心,吉林 吉林 132001
  • 收稿日期:2019-11-29 出版日期:2020-03-24 发布日期:2020-05-20
  • 作者简介:胡科幻(1995— ),男,安徽宿州人,吉林大学硕士研究生,主要从事嵌入式系统开发与应用研究,(Tel)86-18844131996(E-mail)hukh17@ qq. com; 石景龙(1963— ),男,长春人,吉林大学研究员,主要从事应用电子技术与智能系统研究,(Tel)86-13039200266(E-mail)shijl@ jlu. edu. cn。
  • 基金资助:
    吉林省科技发展计划重点科技研发基金资助项目(20180201065GX)

Implementation of MODBUS Protocol in 32-Bit MCU-Based Cross-Linked Cable Production Line#br#

HU Kehuan 1 ,SHI Jinglong 1 ,MIAO Zheng 1 ,XU Xin 2 ,WANG Xiangchao 2 ,QI Wenbin 2 ,ZHANG Jun 3   

  1. 1. College of Electronic Science and Engineering,Jilin University,Changchun 130012,China;
    2. Department of Engineering,Baicheng Fujia Technology Company Limited,Baicheng 137000,China;
    3. Information Center,Jilin Technical College of Electronic Information,Jilin 132001,China
  • Received:2019-11-29 Online:2020-03-24 Published:2020-05-20

摘要: 为解决 32 位 MCU(Microcontroller Unit)与直流调速器的通讯问题,提出一种基于 Modbus 总线协议的通
讯方法以及实现过程。其中 32 位 MCU 选用 STM32F103 芯片并作为通讯主机,直流调速器选用 ETD DC790P
并作为通讯从机。该方法可以实现一主机多从机的通讯结构,实现一个 32 位 MCU 主机与多个直流调速器从
机通讯。主机通过协议发送指令给从机,从机接到指令做出动作并通过协议回应主机。实验证明,基于Modbus
协议的通讯方法能精准实现主机与多个从机的通讯以及 32 位 MCU 对电机转速转矩等控制,并且 Modbus 实现
方法具有稳定性高、抗干扰能力强、可移植性高等优点。

关键词: Modbus 总线协议, 直流调速器, STM32 芯片, 主从通讯

Abstract: In order to solve the communication problem between the 32-bit MCU(Microcontroller Unit) and the DC
(Direct Current) governor,a communication method and implementation process based on the Modbus bus protocol
is proposed. The 32-bit MCU selects the STM32F103 chip as the communication host,and the DC governor uses
the ETD DC790P as the communication slave. The method can realize the communication structure of a host multi-
slave,and realizes communication between a 32-bit MCU host and a plurality of DC governor slaves. The host
sends a command to the slave through the protocol,and the slave receives the command to make an action and
responds to the host through the protocol. Repeated experiments have proved that the communication method based on Modbus protocol can accurately realize the communication between the host and multiple slaves,and can
accurately realize the control of the motor speed and torque of the 32-bit MCU. And the Modbus implementation
method has the advantages of high stability,strong anti-interference ability and high portability.

Key words: Modbus bus protocol, direct current (DC) governor, STM32 chip, master-slave communication

中图分类号: 

  •