Writing Traversing Programs
10-14
FM 353 Stepper Drive Positioning Module
6ES7 353-1AH01-8BG0
M functions
Up to three M functions can be programmed in one traversing block, with any as-
signment of M1, M2 and M3. The output sequence of the M functions is always
M1M2M3 (for information about output see Section 9.1).
The following figure shows an example.
/ N
G1
G2 G3 X/t F M1
M2
M3 D
400 00
10
100 00010 90
4334 11
12
1
Table 10-2 M functions
M No.
M Function M Function
group
0 Stop at end of block
2, 30 End of program
1, 3...17 User functions
18 Endless loop (skip back to start of program)
19...29,
31...96
User functions
,
,
97, 98 Change signal programmable as digital output
99 User functions
M0, M2, M18 and M30 are always output at the end of the traversing movement.
M0, M2, M18 and M30 are mutually exclusive within a single block.
Stop at end of block M0
If M no. 0 is programmed in a traversing block, the program stops at the end of the
traversing block and M0 is output. Only a new START edge causes the traversing
program to be continued.
End of program M2, M30
If M2 or M30 is programmed in a block, then after positioning is complete the M
function is output with a subsequent programmed stop and a jump back to the start
of the program. The Start edge can restart the program. M2 or M30 is always the
last output in the block.
If the program is called up as a subprogram, the action skips to the main program.
In this case M2 or M30 is not output.