Loops - Siemens SIMATIC S5 Manual

Positioning module 1p 247 for stepper motors
Hide thumbs Also See for SIMATIC S5:
Table of Contents

Advertisement

A "flying change" cannot be executed under the following conditions. The program is then
stopped with the error message "flying change could not be executed":
when the statement following the flying change specifies the opposite direction,
when the statement following the flying change contains a dwell time,
when the statement following the flying change only contains an M02,
when the traversing distance following the flying change is shorter than the braking dis-
tance of the previous statement,
when the statement following the flying change is too short to achieve the required final
speed,
when the statement following the execution of the statement containing G1 O could not be
interpreted or
when the statement following the flying change contains a switchover, tool offset or zero
offset.
* Note the following points with a rotary axis*
If individual target positions cannot all be reached via the shortest route, then the direction in
which the flying change is to be executed should be stipulated with G26 or G27. If you do not do
this, the flying change is aborted with the message "Change of direction illegal with flying
change".
2.6.6.4

Loops

Loops can be nested within each other. Subroutines containing further loops can be called in
loops. The nesting depth for subroutines and loops must not exceed a total value of 5. Closed
(endless) loops can only be programmed at the highest level, A closed loop cannot therefore be
included in a program called with an L-function.
G20: loop end
A statement containing G20 is the end of a repetitive loop and must not contain any other func-
tions.
Example
N80G20
G24: loop start
A statement containing G24 is the start of a loop. The number of repetitions is specified by the F-
Functions. FO means a closed loop, The statement must not contain any further functions, includ-
ing M-functions,
Machining Programs and their Structure
end of the repetitive loop.
2 - 3 7

Advertisement

Table of Contents
loading

Table of Contents