Article translated with the assistance of AI tools. Images and parts of the content will still be reviewed.
In this tutorial, you will learn how to communicate with the Nexto XP340 using the IEC104 protocol with various types of clients, utilizing the TestHarness software.
Components
Software: MasterTool IEC XE 3.34 ; Test Harness 32-bit version
PLC: XP340; Firmware: 1.11.10.0
Ethernet cable
Tutorial Section
1. ARCHITECTURE
2. DEVELOPMENT
2.1 Creating a new project in Mastertool
2.2 Add GVL
2.3 Add device
2.4 IEC 104 Configuration
2.5 Test Harness Configuration
2.6 Tag Configuration
3. VIDEOS
1. ARCHITECTURE
2. DEVELOPMENT
We will monitor the variables communicating through the Test Harness software
2.1. Creating a new project in Mastertool
Create a new project by clicking on "New Project", enter the name and the folder path where you want to save it.
For this simulation with Mastertool and Test Harness, we will use the XP 340 and the programming language will be LADDER; click next ensuring that all languages are set to ladder until "FINISH" appears, then the program will open
2.2 Add GVL
We will start by creating a list of global variables. To do this, right-click on Application >> Add objects >> Variable list. Name the list as you wish, without spaces or special characters, then click "Add"
When the list opens on your screen, change the declaration type to textual mode, then delete the parameter above VAR_GLOBAL (optional) if you want to use the global variable list throughout the project without having to declare the list name. Then declare the variables as shown in the image below.
2.3. Add device
Right-click on the word NET1, then click on Add Device. A window will appear, click on the "+" symbol to the left of IEC60870-5-104, then do the same as shown; double-click on IEC60870-5-104 Server and close the window.
Right-click on the word IEC60870-5-104 Server, then click on Add Device. A window will appear, click on the "+" symbol to the left of IEC60870-5-104, then do the same as shown; double-click on Client and close the window.
Close the device window; open the Client tab and declare the variables that were declared in the GVL. (in the example shown, the GVL variable call parameter was not deleted, so it was necessary to show the GVL path) Next, it will be configured according to the IEC104 protocol.
After declaring the variables, declare the variable type according to the IEC104 protocol. The address must be different for all.
2.4. IEC 104 Configuration
TYPES OF VARIABLES IN THE IEC 104 PROTOCOL
The variables highlighted in gray will be the variables used in the project
Finally, download the project to the PLC >> in Login click "yes" in the next conversation windows >> then set it to run.
2.5 Test Harness Configuration
Open the Test Harness simulator as administrator; then, click on the icon, select the IEC104 channel and Master mode, then click Open. In the next window, the ASDU address is the address.
Still in the same window, in the Channel tab under TCP Parameters, enter your PLC's IP number and check if the selected port is port 2404. Finally, click Open.
Two other windows will appear. In the command window, click on the drawing of the General Interrogation Command option.
The screen will display the name of the variables and their state. To write to the variables, open the General Interrogation Command tab again
Double-click on the type of variable you want to send the command to. In the IOA field, enter the variable address used in MasterTool and in value enter the value you want to set the variable to, then click Once. This pattern applies to all commands.
Split the screen between TestHarness and MasterTool to be able to view the variable state changes.
3. VIDEOS
Part 1
Part 2
Comments
0 comments
Please sign in to leave a comment.