Learn PROFIdrive drive control protocol (1)
Learn PROFIdrive drive control protocol (1)
The previous article on S7-1200 motion control has said: According to the different connection drive modes, S7-1200 has three motion control modes, namely: PTO, analog and PROFIdrive protocol. The PROFIdrive protocol is widely used in Siemens motion control. It is actually a standard protocol for connecting drives/inverters/encoders. In today's article, let's get to know this protocol. This article includes the following topics:
Introduction to PROFIdrive;
Data exchange between controller and drive;
Introduction to PROFIdrive common messages;
/Learn PROFIdrive drive control protocol (1).jpg)
1. Introduction to PROFIdrive
PROFIdrive is a standard drive control protocol introduced by PI International (PROFIBUS and PROFINET International), which is used for data exchange between controllers and drives. The bottom layer can use PROFIBUS or PROFINET.
PI international organization divides the occasion of driving control into several different application classes (ApplicationClass, AC), including: AC1~AC5. among them:
AC1 and AC2 are used for speed control, such as the control of fans, pumps, conveyor belts, etc.;
AC3 is a common position control and torque control occasion;
AC4 and AC5 are advanced motion control, isochronous communication control, such as servo, CNC system and other occasions;
2.Data exchange between the controller and the drive The controller and the drive can exchange data periodically through the PROFIdrive protocol. The controller sends a control command, and the drive returns the status of the command execution and its own status. The schematic diagram is as follows:
/Learn PROFIdrive drive control protocol (1)2.jpg)
By periodically exchanging PROFIdrive messages, the controller can start and stop the drive The PROFIdrive message is composed of three parts: the head, the tail and the middle data area, as shown in the figure below:
/Learn PROFIdrive drive control protocol (1)3.jpg)
The data area is composed of two parts: PKW and PZD. among them:
PKW is parameter data, used for reading and writing of inverter parameters (not all messages have PKW area);
PZD is process data, including the command sent by the controller, the status value of the inverter, the data of the encoder, etc.;
The PROFIdrive protocol defines specific messages for typical applications and assigns fixed message numbers. Below we will introduce the commonly used messages.
3. Introduction to common PROFIdrive messages
Commonly used PROFIdrive messages include: standard messages 1, 2, 3, 4, 20, etc. Let's get to know the first three:
3.1, standard message 1
Standard message 1 is used for speed control and includes two parts:
The control word STW1 and speed setting value (NSOLL_A) sent by the controller;
The status word (ZSW1) and actual speed (NACT_A) fed back by the drive;
As shown in the following table:
Standard message 1
/Learn PROFIdrive drive control protocol (1)4.jpg)
Note: STW and ZSW are both 16-bit unsigned integers, NSOLL_A and NACT_A are 16-bit integers
number;
3.2. Standard message 2
Standard telegram 2 is also used for speed control. The difference from standard message 1 is that its speed setting value (NSOLL_B) and actual speed value (NACT_B) are 32-bit integers; in addition, it adds control word STW3 and status word ZSW3, as shown in the following table :
Standard message 2
/Learn PROFIdrive drive control protocol (1)5.jpg)
(G1_STW), status word (G1_ZSW), actual position 1 (G1_XIST1) and actual position 2 (G1_XIST2), its message length is 9 PZD, as shown in the following table:
Standard message 3
/Learn PROFIdrive drive control protocol (1)6.jpg)
/Learn PROFIdrive drive control protocol (1)7.jpg)
Since there are many common messages in PROFIdrive, this article will stop here first. Will continue to introduce PROFdrive message and PROFIdrive communication between Siemens PLC and drive in the following article.