Inst ToolsInst ToolsInst Tools
  • Courses
  • Automation
    • PLC
    • Control System
    • Safety System
    • Communication
    • Fire & Gas System
  • Instrumentation
    • Design
    • Pressure
    • Temperature
    • Flow
    • Level
    • Vibration
    • Analyzer
    • Control Valve
    • Switch
    • Calibration
    • Erection & Commissioning
  • Interview
    • Instrumentation
    • Electrical
    • Electronics
    • Practical
  • Q&A
    • Instrumentation
    • Control System
    • Electrical
    • Electronics
    • Analog Electronics
    • Digital Electronics
    • Power Electronics
    • Microprocessor
  • Request
Search
  • Books
  • Software
  • Projects
  • Process
  • Tools
  • Basics
  • Formula
  • Power Plant
  • Root Cause Analysis
  • Electrical Basics
  • Animation
  • Standards
  • 4-20 mA Course
  • Siemens PLC Course
Reading: PUT Command in Siemens PLC – TIA Portal Basics
Share
Font ResizerAa
Inst ToolsInst Tools
Font ResizerAa
  • Courses
  • Design
  • PLC
  • Interview
  • Control System
Search
  • Courses
  • Automation
    • PLC
    • Control System
    • Safety System
    • Communication
    • Fire & Gas System
  • Instrumentation
    • Design
    • Pressure
    • Temperature
    • Flow
    • Level
    • Vibration
    • Analyzer
    • Control Valve
    • Switch
    • Calibration
    • Erection & Commissioning
  • Interview
    • Instrumentation
    • Electrical
    • Electronics
    • Practical
  • Q&A
    • Instrumentation
    • Control System
    • Electrical
    • Electronics
    • Analog Electronics
    • Digital Electronics
    • Power Electronics
    • Microprocessor
  • Request
Follow US
All rights reserved. Reproduction in whole or in part without written permission is prohibited.
Inst Tools > Blog > PLC Tutorials > PUT Command in Siemens PLC – TIA Portal Basics

PUT Command in Siemens PLC – TIA Portal Basics

We will talk about the PUT command in Siemens PLC which can be used to send or put data from one PLC into a second PLC.

Last updated: January 3, 2024 2:31 pm
Mahmoud Salama
PLC Tutorials
No Comments
Share
10 Min Read
SHARE

In this article, we will discuss yet another way of communicating between two PLCs, whether they are in the same project or two different PLC projects. In this article, we will talk about the PUT command in Siemens PLC which can be used to send or put data from one PLC into a second PLC.

Contents
What is the PUT Command?PUT Command in Siemens PLCSample PLC project

What is the PUT Command?

In general, the PUT command is a TIA Portal built-in function block FB that is used exclusively for S7-Family CPUs to put data from a local PLC to a remote partner PLC.

When using the PUT command, I would have two PLCs, where I need to send data from one PLC called local to another PLC called partner.

Some configurations must be done to the partner PLC, to enable it to be accessed by the other PLC. In addition to a Profinet connection between the PLCs.

We will create a sample project to show how to use the PUT command.

PUT Command in Siemens PLC

We will assume a sample project where we have two PLCs in the same project, PLC_1 which will act as the local PLC and PLC_2 which is the partner PLC.

We want to write an integer from the local to the partner PLC.

Sample PLC project

First, let’s create a new project and add the two PLCs. See picture 1.

S7 PLC-PLC communication using PUT Command

picture 1. Add the local and partner PLCs.

What I need now is to configure PLC_2, the one that will receive the data to be able to receive this data. And PLC_1 will be used with the PUT command.

The 1st thing I need to do is allow the access of the PUT command to the PLC_2 that will receive the data. See picture 2.

What is the PUT Command

picture 2. Allow PUT command access.

As you see from the picture, we allow the PUT command to access the PLC_2 from the Properties of the PLC_2, in the Protection and Security option, click on the

“Permit access with PUT/GET communication from the remote partner”

Now, I am allowed to put data from any remote partner to PLC_2 using the PUT command.

The 2nd thing is to prepare a space or memory in PLC_2 to the data that will be put in it. We will assume that we want to PUT an integer value into that PLC, so I will prepare a memory according to that. See picture 3.

S7 PLC PUT Command

picture 3. Prepare area to receive data.

And that is it; this is the entire configuration you need to prepare from the PLC_2 side to be able to receive data through PUT command.

Next, we set up the data being sent from the PLC_1. We will create a data block to hold the data sent to PLC_2 and inside this data block, we will define an integer tag to be PUT into PLC_2. See picture 4.

PLC-PLC Communication PUT

picture 4. Create a data block to hold the sent data.

We defined an integer tag “SendMeToPLC_2” that we want to send to PLC_2. See picture 5.

Siemens S7 PUT Tutorial

picture 5. Define the data to be sent.

Note that, for PLC_1, we don’t need to allow the access with PUT command option. We activate this feature in the PLC that will receive data, not the PLC that will send it.

Now, let’s use the PUT command in our programming, in the main OB1 we will drag and drop the PUT command FB. See picture 6.

S7-1200 PUT Communication

picture 6. Add the PUT command to OB1.

Note that, the PUT command is found in the S7 communication folder, as it is an exclusive function for S7 family PLC, because it involves safety issues. Remember in picture 2 when we allowed the use of PUT command it was in the Security and Protection attribute of the PLC properties as it is related to PLC safety and protection.

The PUT command is essentially a function block, so when adding it to my logic I will be asked to create a data instance. See picture 7.

Siemens S7 PLC Data Transfer

picture 7. Create a data instance for the PUT command.

After you press OK, the PUT command is now added to your PLC logic. See picture 8.

Advanced S7 PLC Communication

picture 8. PUT command

After we added the PUT command, now we need to configure it, we have two parameters to configure for the PUT command.

  • The connection between PLCs
  • The block that will be PUT from PLC_1 to PLC_2

To go to the configuration view of the PUT command, press the small blue icon shown in last picture.

In the connection parameter, you will set the communication between the local (PLC_1) and partner (PLC_2) PLCs. See picture 9.

PLC to PLC communication Siemens

picture 9. Connection parameter.

As you can see, the Local PLC is set to PLC_1 which is the PLC where the PUT command is used. The partner side is still empty and that is where we should assign PLC_2.

If you click on the drop-down list you will have two options for a partner. See picture 10.

S7 PLC Data Exchange

picture 10. Partner connection

The partner is the PLC that will receive the data; you will find that you have two options to select from:

  • PLC_2 [CPU 1516-3 PN/DP]
  • Unspecified

Because both PLCs are in the same project, when I choose the PLC_2 option, all connection parameters will be automatically filled in. see picture 11.

Siemens Network Communication

picture 11. PLC_2 as a partner

On the other hand, if the partner PLC is from a different project, then I will choose the Unspecified option, and in that case, I will have to fill in some data such as the Partner PLC’s IP address. See picture 12.

PLC to PLC Communication TIA Portal

picture 12. Unspecified Partner

As you can see, in that case, I need to fill in some data, such as the IP address and also I need to add a subnet for PLC_1.

To add a subnet for PLC_1 we will go to Profinet properties of the PLC_1 and select add subnet option. See picture 13.

Put Get PLC communication

picture 13. Add subnet.

Once that is done, the connection parameter configuration will be done. See picture 14.

The connection name should be Unique for each PUT command you make, TIA Portal will automatically give it a new name, but it is maybe better for you to assign a more proper name for the connection in your project. We here kept it as it is.

How to communicate with a Siemens PLC

picture 14. Connection parameter is done

The next step in the PUT command configuration is the Block parameter setup.

In these parameters we specify the trigger for the PUT command, meaning what signal will start the PUT command action. And also what data will be put from PLC_1 and where will it be stored in the PLC_2. See picture 15.

steps to establish communication between the two PLCs

picture 15. Block parameter setup

For the Start Request (REQ) signal we have defined an input tag (SendData %I0.0). And as we mentioned before we have already defined the tag that will be send to PLC_2 and where it will be stored inside the PLC.

Completing the block parameter configuration will conclude the configuration of the PUT command. See picture 16.

PLC To PLC Communication Tutorial

picture 16. Calling of a PUT command

So, in summary, when the REQ signal is triggered, the data in SD_1 will be sent to ADDR_1.

Download the project files.

  • PLC Logic
  • PLC Code

If you liked this article, then please subscribe to our YouTube Channel for Instrumentation, Electrical, PLC, and SCADA video tutorials.

You can also follow us on Facebook and Twitter to receive daily updates.

Read Next:

  • Free PLC Training for Students
  • Top Embedded Systems Projects
  • How to Choose a PLC for a Project?
  • What is Multi-touch Technology?
  • Cybersecurity Projects for Students
Don't Miss Our Updates
Be the first to get exclusive content straight to your email.
We promise not to spam you. You can unsubscribe at any time.
Invalid email address
You've successfully subscribed !

Continue Reading

PLC Programming for Multi-Color Sorting Conveyor System
What is the Firmware Version of a PLC? – Siemens PLC Hardware
Introducing PLC Programming using LogixPro Simulator Software
PLC Logic Example on Multiple Switches and Motors
PLC Program for Trash Compactor
PLC Output Types
Share This Article
Facebook Whatsapp Whatsapp LinkedIn Copy Link
Share
Leave a Comment

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Stay Connected

128.3kFollowersLike
69.1kFollowersFollow
210kSubscribersSubscribe
38kFollowersFollow

Categories

Explore More

Industrial Networking and Wireless Interview Questions
Water Fountain Control Logic – PLC Exercises and Solutions
Upload Option Disabled in Siemens PLC
PLC Memory Organization – Data Files and Program Files
FIFO Instruction in Allen Bradley PLC Programming
What is a GSD File and Why it is required?
Basic PLC Ladder Programming Example
Wiring Diagrams of PLC and DCS Systems – DI, DO, AI, AO

Keep Learning

Siemens CPU Clock Memory

Alarm Acknowledge using PLC

PLC Program for Conditional Control Logic

PLC Program for Conditional Control Logic

Studio 5000 Logix Emulate

Simulation of Studio 5000 and FactoryTalk View Studio

Safety PLC Programming steps

Safety Door Interlock PLC Program

PLC Motor Control Circuit

Motor Trip Logic using PLC Programming

Run 4 Motors Sequentially from Same Push button PLC Program

Run 4 Motors Sequentially from Same Push button PLC Program

Automated Garage Gate Control - PLC Ladder Logic

Automated Garage Gate Control – PLC Ladder Logic

Analog Inputs in Siemens TIA Portal

What are Analog Inputs? – Analog Signals Processing in PLC

Learn More

Orifice plate with vent and drain holes

Basics of Orifice Plates

Classification of Steam Turbines

Classification of Steam Turbines

Purpose of Flow Ratio Controller

Identify the Purpose of Flow Ratio Controller

Safety PLC Coding Practices

Safety PLC Coding Practices – Programming Recommendations

Ingress Protection Standard

Ingress Protection Rating

Static and Temp Variables in PLC

Static and Temp Variables in PLC

Ccomparator in PLC Programming

Comparator in PLC Programming

input-output-relationships-of-transmitters

Input-Output Relationships of Transmitters

Menu

  • About
  • Privacy Policy
  • Copyright

Quick Links

  • Learn PLC
  • Helping Hand
  • Part Time Job

YouTube Subscribe

Follow US
All rights reserved. Reproduction in whole or in part without written permission is prohibited.
Welcome Back!

Sign in to your account

Username or Email Address
Password

Lost your password?