EV1000变频器的远程控制接口的编程

 2023-04-08 09:04

论文总字数:19889字

摘 要

随着科技的发展,各式各样的电机控制层出不穷。目前对变频器的控制方法有:直接通过变频器面板控制、通过端子控制、远程通信控制(使用PLC或单片机)等。东南大学成贤学院机电控制实验室采用的借助于PLC通过端子的控制方案,没有使用通讯控制功能。事实上,所配的变频器是具有通讯功能的。本文试图拓展实验室的控制方法,假想应用为一对多控制,这就要求实现联网的远程控制。本文的目标是以STM32单片机实现通信协议转换,使之可以连接到遵循MODBUS协议的RS-485总线上。这种控制方式,与工厂环境下实际使用通信一致。

本文首先研究了STM32系列单片机的串口应用,并通过实验方法,验证了变频器自带的通讯协议。在这些工作的基础上,以USART2串口实现了两者之间的相互通信,实现了以通信方式进行开机、设定频率、关机、点动、紧急停车、读取状态等功能。经过测试,能可靠工作。

其次,研究了MODBUS总线的协议架构,从中选择出最关键的基于寄存器的指令读写功能,并为了满足变频器的各种控制要求,规定了变频器参数和命令的地址,以USART3实现了MODBUS从机的编程。通信中严格使用Modbus的CRC校验,保证数据通信的可靠性。

配合同组同学的上位机MODBUS程序的实现过程,作者进行了大量的测试和调试工作。最后使EV1000变频器通过一块STM32单片机进行协议转换,可以遵循MODBUS这个工业标准的开放性通信协议。

经过调试,该控制系统运行正常,达到了预期的效果。通过MODBUS主机,可以对变频器进行参数设定,开机和停机等实现远程控制,主机也能随时读取变频器中的运行参数与状态。

关键词:STM32;Modbus;EV1000变频器;远程控制

Abstract

Along with the development of science and technology, the wide variety of motor control emerge in endlessly. At present, the control method of inverter is as direct as the inverter panel control, through terminal control, remote communication control (using PLC or SCM), etc.. Southeast University into Chengxian College of mechanical and electrical control laboratory with the help of PLC through the terminal control program, did not use communication control functions. In fact, the inverter is equipped with communication functions. This paper attempts to expand the laboratory control method, the imaginary application is a control, which requires the remote control of the network. The goal of this paper is to realize the conversion of communication protocol by STM32 microcontroller, so that it can be connected to the RS-485 bus based on MODBUS protocol. This control mode is consistent with the actual use of the factory environment.

In this paper, the serial port application of STM32 series microcontroller is studied, and the communication protocol of the converter is verified by experiment. On the basis of these work, by usart2 serial realized the mutual communication between the two, realized by the method of communication of boot, set the frequency, shutdown, move, emergency stop, read function.After testing, can work reliabl.

Secondly, the Modbus protocol architecture, from the selection of the most critical register instruction based on read write function, and in order to meet the requirements of the inverter control, the provisions of the inverter parameters and commands the address, to USART3 realized MODBUS slave machine programming. The reliability of data communication is ensured by CRC Modbus verification in communication.

With the process of the MODBUS program of the students in the contract group, a lot of testing and debugging are carried out.. Finally, the EV1000 converter can be converted by a single chip STM32 protocol, and can follow the open communication protocol of the industry standard of MODBUS.

After debugging, the control system runs normally and achieves the expected effect. Through the MODBUS host, it can carry out the parameters of the inverter, start up and down, etc., the host can read the operation parameters and state of the inverter at any time.

Keywords: STM32 ;Modbus;EV1000 frequency converter;remote control

目 录

摘 要 I

Abstract II

第一章 引言 1

1.1选题背景 1

1.2研究的目的与意义 1

1.3研究的内容及内容安排 1

1.4 研究的方案介绍 2

第二章 硬件简介 3

2.1 STM32系列单片机简介 3

2.2 EV1000通用变频器 5

2.2.1 变频器运行命令通道 6

2.2.2 变频器给定频率通道 6

2.2.3 EV1000变频器的通讯协议介绍 6

第三章 变频器通讯控制的实现及其模拟测试 10

3.1 USART串口 10

3.2运行控制与调节功能 11

3.3读取从机参数 13

3.4 CDT规约 14

3.5 测试环境的搭建 16

3.6 STM32单片机控制的测试 16

第四章、主机与STM32单片机的MODBUS通讯 18

4.1 通过MODBUS协议控制 18

4.1.1 MODBUS总线 18

4.1.2 MODBUS协议 18

4.2 测试环境的搭建 22

4.3 PC机控制的测试 23

第五章 总结与展望 25

5.1总结 25

5.2展望 25

致 谢 27

参考文献 28

第一章 引言

1.1选题背景

随着电子技术和自动控制技术的快速发展,电动机调速已经从原来的继电器调速发展到变频器控制调速,且在工业各个领域得到广泛应用。在现代工业自动化控制中,常用PLC控制变频器实现电动机调速控制。变频器的控制方法不仅有端子控制而且可以通过通信控制。而通信控制在机电系统集成中更加方便。鉴于本实验室早期购买的EMERSON EV1000变频器教学系统没有通信接口,利用本毕业设计,研制一块转接板,从而可以实现远程控制,丰富原先的实验。

此次任务需要编写转接板程序。通过通信接收远程的控制命令,利用板上的数字和模拟接口,去操作变频器的控制端子。转接板的微控制器采用STM32F103系列微核心,这个芯片在自动控制中应用也比较广泛。

1.2研究的目的与意义

随着科技的发展,变频器在工业生产中的应用越来越广泛。因此对变频器的控制就越发显得重要,目前对变频器的控制方法有:直接通过变频器面板控制、通过PLC控制、通过单片机控制等。但这些控制方法都存在明显的缺点,在工业现场直接通过变频器面板控制属于手工作业,而且操作麻烦。而PLC控制虽然可以极大的简化控制过程,但PLC编写的灵活度有限,而且PLC只能作为主机使用,而多联网控制时,用它做主机不够方便。我们采用了PC机的操作面板根据Modbus协议将命令发送给STM32单片机,利用STM32单片机间接控制变频器,实现了远程控制变频器的目的。

剩余内容已隐藏,请支付后下载全文,论文总字数:19889字

您需要先支付 80元 才能查看全部内容!立即支付

该课题毕业论文、开题报告、外文翻译、程序设计、图纸设计等资料可联系客服协助查找;

已经是最后一篇了