Flexible NC programming
1.2 Indirect programming
Job planning
Programming Manual, 07/2010, 6FC5398-2BP40-0BA0
61
Example
For an active synchronous spindle coupling between the leading spindle S1 and the
following spindle S2, the following replacement cycle to position the spindle is called using
the
SPOS command in the main program.
Positioning is realized using the instruction in
N2230:
SPOS[1]=GP($P_SUB_SPOSIT,$P_SUB_SPOSMODE)
SPOS[2]=GP($P_SUB_SPOSIT,$P_SUB_SPOSMODE)
The position to be approached is read from the system variable $P_SUB_SPOSIT; the
position approach mode is read from the system variable $P_SUB_SPOSMODE.
Program code Comments
N1000 PROC LANG_SUB DISPLOF SBLOF
...
N2100 IF($P_SUB_AXFCT==2)
N2110 ; Replacement of the SPOS / SPOSA / M19
command for an active synchronous
spindle coupling
N2185 DELAYFSTON ; Start Stop Delay Area
N2190 COUPOF(S2,S1) ; Deactivate synchronous spindle
coupling
N2200 ; Position leading and following spindle
N2210 IF($P_SUB_SPOS==TRUE) OR ($P_SUB_SPOSA==TRUE)
N2220 ; Positioning the spindle with SPOS:
N2230 SPOS[1]=GP($P_SUB_SPOSIT,$P_SUB_SPOSMODE)
SPOS[2]=GP($P_SUB_SPOSIT,$P_SUB_SPOSMODE)
N2250 ELSE
N2260 ; Positioning the spindle using M19:
N2270 M1=19 M2=19 ; Position leading and following spindle
N2280 ENDIF
N2285 DELAYFSTOF ; End of Stop Delay Area
N2290 COUPON(S2,S1) ; Activate synchronous spindle coupling
N2410 ELSE
N2420 ; Query on further replacements
...
N3300 ENDIF
...
N9999 RET
Supplementary conditions
● The indirect programming of position attributes is not possible in synchronized actions.
References
Function Manual Basic Functions; BAG, Channel, Program Operation, Reset Response
(K1), Chapter: Replacement of NC functions by subprograms