K1: Mode group, channel, program operation, reset response
9.15 Replacing functions by subprograms
Basic Functions
Function Manual, 09/2011, 6FC5397-0BP40-2BA0
643
9.15.2.4
Example: Replacement of an M function
Example 1
The function M6 is replaced by calling the subprogram "SUB_M6".
The information relevant for a tool change should be transferred using system variables.
Parameterization
Main program
Subprogram "SUB_M6"
Machine data
Meaning
MD10715 $MN_M_NO_FCT_CYCLE[2] = 6
Tool change with M6
MD10716 $MN_M_NO_FCT_CYCLE_NAME[2] = "SUB_M6"
Replacement
subprogram for M6
MD10718 $MN_M_NO_FCT_CYCLE_PAR = 2
Information transfer
using system
variables
Programming
Comment
PROC MAIN
...
;
N10 T1 D1 M6
;
;
M6 is replaced by subroutine "SUB_M6"
...
;
N90 M30
Programming
Comment
PROC SUB_M6
N110 IF $C_T_PROG==TRUE
; IF address T is programmed
N120 T[$C_TE]=$C_T
; Execute T selection
N130 ENDIF
; ENDIF
N140 M[$C_ME]=6
; Execute tool change.
N150 IF $C_D_PROG==TRUE
; IF address D is programmed
N160 D=$C_D
; Execute D selection
N170 ENDIF
; ENDIF
N190 M17
Содержание SINUMERIK 828D Turning
Страница 34: ...Basic Functions 34 Function Manual 09 2011 6FC5397 0BP40 2BA0 ...
Страница 146: ...A3 Axis Monitoring Protection Zones 2 6 Data lists Basic Functions 146 Function Manual 09 2011 6FC5397 0BP40 2BA0 ...
Страница 328: ...F1 Travel to fixed stop 6 5 Data lists Basic Functions 328 Function Manual 09 2011 6FC5397 0BP40 2BA0 ...
Страница 816: ...K2 Axis Types Coordinate Systems Frames 10 9 Data lists Basic Functions 816 Function Manual 09 2011 6FC5397 0BP40 2BA0 ...
Страница 1198: ...P4 PLC for SINUMERIK 828D 14 6 Function interface Basic Functions 1198 Function Manual 09 2011 6FC5397 0BP40 2BA0 ...
Страница 1752: ...Appendix 20 2 Overview Basic Functions 1752 Function Manual 09 2011 6FC5397 0BP40 2BA0 ...
Страница 1774: ...Glossary Basic Functions 1774 Function Manual 09 2011 6FC5397 0BP40 2BA0 ...