EasyManua.ls Logo

Siemens SINUMERIK 808D ADVANCED

Siemens SINUMERIK 808D ADVANCED
508 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Commissioning Manual
01/2017
307
Tag identifier
Meaning
FOR
For loop
for (initialization; test; continuation) instruction(s)
Syntax:
<FOR>
<INIT>…</INIT>
<CONDITION>…</CONDITION>
<INCREMENT>…</INCREMENT>
Instructions
</FOR>
The For loop is executed as follows:
1. Evaluation of the expression
initialization
(INIT).
2. Evaluation of the expression
test
(CONDITION) as a Boolean expression.
If the value is false, the For loop is exited.
3. Execution of the following instructions.
4. Evaluation of the expression
continuation
(INCREMENT).
5. Continue with 2.
All the variables within the INIT, CONDITION, and INCREMENT branches are declared
and initialized outside the FOR loop.
Example:
<LET name = "count">0</LET>
<FOR>
<INIT>
<OP> count = 0</OP>
</INIT>
<CONDITION> count <= 7 </CONDITION>
<INCREMENT>
<OP> count = count + 1 </OP>
</INCREMENT>
<OP> "plc/qb10" = 1+ count </OP>
</FOR>

Table of Contents

Other manuals for Siemens SINUMERIK 808D ADVANCED

Related product manuals