Change of main spindle
#MAIN SPINDLE [ [ <spindle_name> | <spindle_number>] ]
<spindle_name> Default spindle name in accordance with[1]-16.
<spindle_number> Logical axis number of the spindle in accordance with[1]-16.
Command #MAIN SPINDLE can be used to change the definition of the main spindle in the NC-program. The new main spindle is selected by specifying the default name [1]-16 or the related logical axis number..
The basic state (as after boot-up) can be restored without programming a spindle name, i.e. the spindle preset in the channel parameters list [1]-17 becomes the main spindle again.
Extract from channel parameters list [1]:
Example configuration of a single-channel system with three spindles. Spindle with axis number 6 is the main spindle:
:
# Spindle data
# ============
spdl_anzahl 3
main_spindle_ax_nr 6
main_spindle_name S
:
spindel[0].bezeichnung S1
spindel[0].log_achs_nr 6
:
spindel[1].bezeichnung S2
spindel[1].log_achs_nr 11
:
spindel[2].bezeichnung S3
spindel[2].log_achs_nr 30
:
Configuration after boot-up:
S1 is the main spindle with name S.
S2 and S3 are other spindles.
Programming example
%
N10 S100 M3 S2[REV200 M3] S3[REV300 M4]
N20 #MAIN SPINDLE [S2] (S2 is new main spindle "S")
N30 S110 M3 S1[REV210 M3] S3[REV310 M4]
N40 #MAIN SPINDLE [S3] (S3 is new main spindle "S")
N50 S120 M3 S1[REV220 M3] S2[REV320 M4]
N60 #MAIN SPINDLE (Back to default state S1 -> "S")
N70 S150 M3 S2[REV250 M3] S3[REV350 M4]
N80 M5 S2[M5] S3[M5] (All spindles STOP)
N99 M30
For as long as a spindle is a main spindle, either it can be programmed with the main spindle name[1]-18 or with the default name[1]-16. It can only be addressed exclusively under its default name again after selection of another main spindle with #MAIN SPINDLE[ ]. |
For the example mentioned above following spindle names are valid:
Permissible names | Spindle 1 | Spindle 2 | Spindle 3 |
---|---|---|---|
...after startup | SorS1 | S2 | S3 |
...after #MAIN SPINDLE [S2] | S1 | SorS2 | S3 |
...after #MAIN SPINDLE [S3] | S1 | S2 | SorS3 |
...after #MAIN SPINDLE | SorS1 | S2 | S3 |
As already mentioned, the main spindle can be programmed in the conventional DIN syntax. In this case, all commands in accordance with Tab. 14-1 can be used. The main spindle may, however, also be programmed in the spindle-specific syntax. In this case however, only the restricted command set then is available (see also Tab. 14-1).
Programming example
For the main spindle the following part program blocks are equally permissible:
:
N10 S1=1000 M3 or
N20 S1000 M3 or
N30 S1[REV1000 M3] or
N40 S[REV1000 M3]
: