Siemens S7–1500 PLC

This article is about setting up and configuring Siemens S7–1500 Controller. The S7 Controller having CPU1512C-1PN is suitable for medium applications like controlling pumps, fans mixers, conveyor belts, and lifting platforms.

In this article, communicating with S7 controller using Siemens Totally Integrated Automation (TIA) Portal is explained. The article is divided into three sections, Wiring the Hardware, Configuring CPU1512C-1PN, and Programming using TIA Portal.

Wiring the Hardware

The S7-Controller requires power supply of 24V DC. Simatic PM1507 is used to power up the S7-Controller that converts input 230 V AC to output 24V DC. The power supply consist of small connector for connecting input 230 V AC. The connector has to be removed from the unit using suitable tool as shown in Fig.1.

1*CNtY8VlLYHC-tlHp8QbH7Q

Fig.1. Simatic Power Supply Unit

Once the connector has been removed from the unit, open the front cover of connector and connect input AC supply and tighten the screw as shown in Fig.2.

1*2Aq2JbP4O5nWyzKQtjLNrQ

Fig.2. Input Power Supply

Close the cover and connect the connector to the power supply unit again.

1*77cSIWt5Qo_HEDewm-0xAQ

Fig.3. Closing Connector Cover

After wiring input AC supply, now connect output 24V DC of power supply unit to S7–1500 Controller as shown in Fig.4.

1*wsqenTXaX4N4vobuql32Lg

Fig.4. Connecting output DC supply to S7–1500

After completing the wiring, switch on the power supply unit. S7-Controller initializes in STOP Mode as shown in Fig.5.

1*vKecZ7UYzr6sjCmFX-YhoQ

Fig.5. CPU1512C-1PN Initializes in STOP Mode

Configuring CPU1512C-1PN

Assign IP address to the CPU by navigating to

Settings -> Select Addresses -> Select Interface X1 -> Select the IP Addresses from menu -> Assign IP Address 192.168.0.10 -> Set Subnet mask 255.255.255.0 -> Apply -> OK

Now the interface X1 has assigned with IP Address 192.168.0.10

1*QUlYuG3RGEPSUAU-RtHMYg

Fig.6. Setting IP Address

Programming using TIA Portal

TIA Portal V15.1 is used for programming. Open TIA Portal -> Click Create new project -> Give name to the project -> Click Create -> Click configure a device -> Add new device -> Select S7–1500 -> CPU -> CPU1512C-1PN.

Fig.7. TIA Portal

If you are not sure about the version of S7 Controller you are using, then TIA Portal can detect the type of Controller you are using. To do this, connect ethernet cable to X1 port of Controller and other end to your PC. After choosing add new device, select unspecified CPU. TIA Portal opens with unspecified CPU. Goto, Online in menu -> Hardware Detection -> CPU from network -> Select PN/IE entry as type of PG/PC Interface -> Select PG/PC Interface -> Select CPU from compatible devices -> Click Detect to replace unspecified CPU with your CPU type.

Fig.8. Hardware Detection

1*vruFqpVuSfQBmNKQ5WH3Vg

Fig.9. CPU1512C-1PN Device View

In the project tree,

  1. Select project blocks and click Organization Block Main [OB1]. Here you will create circuit to control digital LEDS of Simatic S7-Controller.
  2. Insert Normally Open Contact into Network and assign ALWAYS TRUE Tag.
  3. Insert Assignment into Network.
  4. Every digital pin of S7-Controller has a TAG, that particular has to be assigned to the Assignment in the Network for controlling.

1*f33ZKR9RcAO_WV0EyT6hKQ

Fig.10. Circuit

Once the Tags are assigned to the Digital board of S7-Controller, you can view it in the device view as shown in Fig.11.

1*r9eclsppXGiknLkUFFpYRw

Fig.11. Assigned Tags to Digital Pins

Save the project and compile, after compiling, download the project to S7-Controller. The leds turns ON and you can monitor the status of network in TIA Portal by clicking on Monitor on/off button as shown in Fig.12 and 13.

Fig.12. S7–1500 Digital Pins Control

Fig.13. Network Status on TIA Portal

Author: Karthik Muthineni

2 Likes