Technical data

Creating STL Source Files
13.2 Rules for Programming in STL Source Files
Programming with STEP 7
282 Manual, 05/2010, A5E02789666-01
13.2.3 Rules for Block Order in STL Source Files
Called blocks precede the calling blocks. This means:
The OB1 used in most cases, which calls other blocks, comes last. Blocks that are called from
OB1 must precede it.
User-defined data types (UDT) precede the blocks in which they are used.
Data blocks with an associated user-defined data type (UDT) follow the user-defined data type.
Shared data blocks precede all blocks from which they are called.
Instance data blocks follow the associated function block.
DB0 is reserved. You cannot create a data block with this name.
13.2.4 Rules for Setting System Attributes in STL Source Files
System attributes can be assigned to blocks and parameters. They control the message
configuration and connection configuration, operator interface functions, and process control
configuration.
The following applies when entering system attributes in source files:
The keywords for system attributes always start with S7_.
The system attributes are placed in braces (curly brackets).
Syntax: {S7_identifier := 'string'}
a number of identifiers are separated by ";".
System attributes for blocks come before the block properties and after the keywords
ORGANIZATION_ and TITLE.
System attributes for parameters are included with the parameter declaration, meaning before
the colon for the data declaration.
A distinction is made between upper and lower case characters. This means that the correct
use of upper and lower case characters is important when entering system attributes.
The system attributes for blocks can be checked or changed in incremental input mode using the
menu command File > Properties under the "Attributes" tab.
The system attributes for parameters can be checked or changed in incremental input mode using
the menu command Edit > Object Properties. The cursor must be positioned in the name field of
the parameter declaration.