Siemens PLC Web Server for S71500 in TIA Portal – Accessing your PLC from the Web
Introduction to PLC Web Servers
IT/OT integration is one of the current trends in the industrial environment with the Industry 4.0 revolution. As a result, PLCs are also becoming more intelligent and have more sophisticated functions inbuilt into them. Webserver is a tool by Siemens in TIA Portal to remotely access your PLC and automation systems via a dedicated webpage in a browser. Functions include data logging, modification of tags, and changing the operating state of the PLC. This tutorial will provide an in-depth walkthrough of the Web Server using the S7-1500 PLC.
Prerequisites
To follow along with this tutorial, you will need the following:
- A basic understanding of Siemens TIA Portal. An excellent place to start will be to take the tutorial | An Introduction to Ladder Logic Programming in Siemens TIA Portal
- TIA Portal – TIA Portal V17 is used in this tutorial
- PLCSIM Advanced 4.0
Advantages of PLC Web Server
So what are the benefits of using the TIA Portal's web server feature? Let's examine more closely.
Remote access
The web server feature's ability to enable remote access to users' automation systems may be its most apparent benefit. This can be very helpful in various situations, such as when a user needs to update a system while working from home or when they need to monitor its status while they are away from the plant.
Thanks to the web server feature, users can remain connected to their automation systems wherever they are, which allows them to access their systems from any device with a web browser.
Customizable
The TIA Portal's web server feature's high degree of customizability is one of its main benefits. Users can customize the automation system to meet their unique requirements by creating their web pages that give them access to the components of the system that they need.
For instance, a user could design a unique web page that allows them to change the set points of a controller or shows real-time data from a particular sensor or motor. In addition, users can create a system tailored to their unique needs and processes thanks to the web server feature's ability to be customized, making it a powerful tool.
Easy to use
The TIA Portal's web server function also has the benefit of being very user-friendly. The web server function of the TIA Portal is also made to be simple to use and intuitive.
The web server object is easy to set up, and once it is, users can design unique websites that give them access to the particular components of the automation system they require. This allows users to find the necessary information by navigating convoluted options or user interfaces.
Security
The web server for TIA Portal has many security features to guard against unauthorized entry. Access can be limited to only authorized users if the server is configured with secure communication protocols like HTTPS.
Activation of Web Server
Launch TIA Portal and create a new project adding an S71500 PLC as shown below.
Navigate to Web server under general check the box to activate web server on this module.
For a secure web connection activating “Permit access only with HTTPS” will secure the connection.
User Management
To make the PLC accessible to different people, access levels can be created with passwords for users. Scroll down to "User Management" on the webserver page. An Everybody user is created by default with no password; however, the access level can be set. Let us create three users: ADMIN, SUPERVISOR, and OPERATOR, with their passwords.
The user rights for Admin access will be full access, as shown below.
The user access rights for all three users are set below
Startup PLC SIM Advanced. We are using the PLC's default IP address, 192.168.0.1. However, any IP address can be used so long as it is set in the PLC. We are using the PLC Sim Virtual Adapter for this tutorial.
Start the simulation. Set up S7-PLCSIM Virtual adapter in the same IP range as the PLC.
Download the PLC program into S7-PLCSIM Advanced and put the Simulator in run mode
Launch your web browser and type in the PLC address, in this case 192.168.0.1, and press enter. I am using Google Chrome as my web browser. The startup intro screen for S7-1500 comes up.
Click enter. Details about the PLC is shown the project details and status.
Enter the admin login details for the webserver. If the Login details are correct, the Menu for S7-1500 PLC comes up as shown below
Web Server Menu Descriptions
The PLC local time can be seen at the top right of the screen, the language option selection and a button to turn off the web server.
Start Page: This takes you to the start page, the current page we are in. If you are on another screen, it takes you to this page.
Diagnostics
The diagnostics page has various submenus, including identification, program protection, memory, runtime information, and fail-safe.
Identification Menu: The identification menu shows the serial number of the PLC, order number, and version information, as can be seen in Fig. 2.3.
Program Protection: The program protection menu shows the protection level of the PLC and memory card serial number information.
Memory Menu: The memory menu shows the different memory information of the PLC: the code work memory, the data work memory, load memory, retentive memory, etc.
Runtime Information: The runtime information menu shows the runtime information for the PLC, the cycle time, trend for program, load distribution.
Diagnostic Buffer
This menu displays the same information as the diagnostic buffer in online and diagnostics section in TIA Portal. A menu for diagnostic information for the PLC.
There is also a menu for motion control if you have motion control technology objects configured in your project.
There is an Alarm menu for alarms configured for the PLC in TIA Portal the alarm timestamp, status are shown
Communication Menu
Parameter: The parameter menu shows the PROFINET properties for the PLC. The network connection address, physical properties, host name and domain can also be seen in the image below.
Connection resources: The connection resources for the CPU can be seen in this menu. Web communication is currently using 6 connection resources.
Connection Status: All configured connection for the CPU can be seen in this menu.
Under the topology menu, the different devices in the CPU can be seen with options for table view, graphics view, and status overview.
Tag Status Menu
Let us create some tags. Navigate to PLC tags and create the following tags. Download it into the PLC after the creation of tags.
On web server, open Tag status and enter the tags created on the PLC.
As we can see from the value of the tags created on the PLC, modify the bool tags by typing ‘’1’’ for true into the modify value box and clicking on apply. Modify also the integer and click apply.
On TIA Portal monitor the tags to see if it has changed to the value we inputted on web server.
As we can see, the values have changed to correspond to what is on the web server. Remember, we are on the admin login, which has full access to read and modify tags. So any tags can be read and written to the PLC from the web server.
Watch Tables
Create a watch table on TIA portal with the existing tags as follows.
Select Web server from the device configuration menu. Scroll down the webserver options until you see the watch table. Select the watch table we created by clicking on the harbinger icon. The screen should look like Fig 3.7.
Access rights can be set for watch table either read or read/write. Download into the PLC. On webserver click on watch table.
The current watch table can be changed by the drop down on the top left if you have more than one watch table on your project. Tags can also be modified from the watch table.
There are also other functions of web server, such as creating a custom web page (user defined pages) using Java Scripts and HTML knowledge of those software programming languages will be essential.
Data logs can also be created by using the appropriate DataLog instructions in TIA Portal to save logs.
Conclusion on PLC Web Servers
In conclusion, users seeking to access and control their automation systems remotely can greatly benefit from the web server feature in the Siemens TIA Portal. Users can adapt the system to their unique requirements and workflows by creating custom web pages that provide access to particular areas of the system.
A powerful tool for industrial automation experts, the web server feature combines remote access to automation systems with ease of use and customization. Additionally, users can feel secure knowing that their systems are safe when viewed online using the web server feature of the TIA Portal because security was given top priority during design.