Installation manual
CNC 8035
13.
PLC PROGRAMMING EXAMPLE
Main module.
(SOFT M: V15.3X)
(S
OFT T: V16.3X)
·416·
----- Spindle turning control -----
The spindle enable output O-S-ENAB will be activated when selecting function M03 or M04.
M-03 OR M-04 = O-S-ENAB
----- Treatment of spindle gear change -----
The spindle in this example has two gears (high and low). To perform a gear change, proceed as
follows:
• Deactivate the general CNC input AUXEND.
• Remove the control of the spindle back to the CNC Controlled by PLC.
• Output an oscillating velocity command to change gears.
• Move the gears.
• Verify that the gear change has been completed.
• Remove the oscillating velocity command.
• Return the control of the spindle back to the CNC.
• Activate the general CNC input AUXEND.
Deactivate the general CNC input AUXEND
While changing gears (ranges), general CNC input AUXEND should be canceled in order
to interrupt the execution of the CNC. "Treatment of the general CNC input AUXEND".
Remove the control of the spindle back to the CNC Controlled by PLC.
Output an oscillating velocity command to change gears.
DFU M-41 OR DFU M-42
When a range (gear) change is requested...
= MOV 2000 SANALOG
... A 0.610V analog command for the spindle is prepared and...
= SET PLCCNTL
... the PLC grabs the control of the spindle loop.
PLCCNTL AND M2011
While the PLC has the spindle control...
= SPDLEREV
... the spindle turning direction is changed every 400 milliseconds.
Move the gears.
The corresponding gear output (O-GEAR) is kept active until the range selection is completed
(I-GEAR).
M-41 AND NOT I-GEAR1 = O-GEAR1
M-42 AND NOT I-GEAR2 = O-GEAR2
Verify that the gear change has been completed.
Remove the oscillating velocity command.
Return the control of the spindle back to the CNC.