Arrays - Siemens SIMATIC S7-1500 Function Manual

Web server
Hide thumbs Also See for SIMATIC S7-1500:
Table of Contents

Advertisement

3.16.1.5

Arrays

Arrays
The Web server provides the user program commands AWP_Start_Array and
AWP_End_Array for accessing all values of an array.
Only one-dimensional arrays are supported.
Multidimensional arrays of the form array[x][y] are not supported.
Syntax
<!-- AWP_Start_Array Name='"<DB name>".<array name>' -->
... Content of the array, utilized keywords: ArrayIndex and value..
<!-- AWP_End_Array -->
Parameter
● <Name> defines the name of the array with the elements you want to access.
– You require the DB name and the name of the array corresponding to the data block
– The name must be within single or double quotation marks.
– The DB name is within double quotation marks.
● <ArrayIndex> Index of an array element
● <value> Value of an array element
Example
The example reads all elements of the "MyArray" structure in the "DB_Name" data block of
the CPU and displays the index and the values of the tags on the user-defined web page.
<!-- AWP_Start_Array Name='"DB_Name".MyArray' -->
Index: :=ArrayIndex: Value: :=value:
<!-- AWP_End_Array -->
The code indicated above generates the following display:
Index: 1 Value: 42
Index: 2 Value: 43
Index: 3 Value: 44
Web server
Function Manual, 11/2019, A5E03484625-AG
structure defined in STEP 7.
Web pages
3.16 User pages
135

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Simatic et 200proSimatic et 200sp

Table of Contents