P3: Basic PLC Program for SINUMERIK 840D sl
13.13 Block descriptions
Basic Functions
1028
Function Manual, 09/2011, 6FC5397-0BP40-2BA0
Call example
13.13.22 FC 18: SpinCtrl spindle control
Function
FC SpinCtrl can be used to control spindles and axes from the PLC.
References
/FB1/Function Manual, Basic Functions; Spindles (S1)
Function Manual, Extended Functions; Positioning Axes (P2)
Function Manual, Extended Functions; Indexing Axes (T1)
This block supports the following functions:
• Position spindle
• Rotate spindle
• Oscillate spindle
• Indexing axes
• Positioning axes
Each function is activated by the positive edge of the appropriate initiation signal (start, stop). This signal must
remain in the logic "1" state until the function has been acknowledged positively or negatively by InPos="1" or
Error = "1". The output parameters are deleted when the relevant trigger signal is reset and the function
terminated.
To be able to control an axis or spindle via the PLC, it must be activated for the PLC. This can, for example, be
achieved by calling the FC "SpinCtrl" with activation of the "Start" or "Stop" parameter. In this case, the FC
"SpinCtrl" requests control over the spindle/axis from the NC.
TimerNo
I
INT
10 ...
Timer for programming the wait
time
Y
O
BOOL
Energizing of star contactor
Delta
O
BOOL
Energizing of delta contactor
Ref
I/O
WORD
Instance for status information
Internal use
CALL FC 17 (
YDelta :=
I 45.7,
//Star delta
SpindleIFNo :=
4,
TimeVal :=
S5T#150ms,
TimerNo :=
10,
//Timer 10
Y :=
Q 52.3,
//Star contactor
Delta :=
Q 52.4,
//Delta contactor
Ref :=
mw 50);
//Instance
Signal
Typ
e
Type
Value range
Comment