At the beginning of this year, we successfully completed the technical transformation of a five-axis CNC gantry milling machine. Its spindle adopts gearbox to change speed, the control system is Siemens SINUMERIK 840C numerical control system, and the coordinates and spindle drive are Siemens SIMO Driver 611A. According to the characteristics of machine tool spindle displacement structure and control system, the spindle displacement is automatically controlled by the built-in PLC control program.
1 spindle speed change mechanism
The spindle speed change mechanism of this machine tool is controlled by two bidirectional electromagnetic valves (SOL 1 ~ SOL4), which drive two gear sets to move up and down respectively. Each gear set has two positions, and changing the gear ratio produces four-speed rotation. Four gear detection switches (SW 1 ~ SW4) are installed in the headstock. The pressure relay (PS 1) detects the shift hydraulic pressure. See figure 1 for its gear structure.
Signal and data interface of control system
The control system consists of NCK and PLC modules, which transmit information through data blocks. The input and output points of the machine tool are connected to the input and output modules of PLC. The numerical control system sends the speed command voltage to the spindle. The spindle data block of the system stores the relevant data of spindle displacement, which can be operated in real time through PLC program. The system can have 8-speed control. The machine tool adopts four gears, and there can be speed crossing between adjacent gears.
In order to realize the automatic shift of the spindle, four shift speed ranges of the spindle are preset in the machine tool data. The NC control system sends different command voltages to the spindle drive device according to different gears, corresponding to different rotational speeds of the spindle motor.
Input signals: gear detection signal SW 1 ~ SW4, shift hydraulic pressure PS 1, spindle motor stop Nmin, actual spindle motor speed Nact;;
Output signal: shift solenoid valve SOL 1 ~ SOL4, motor drive command voltage Vist.
The spindle data block of the system includes swing speed, swing frequency, built-in shift range, current gear, shift command, target gear, shift end sign, spindle motor running state, spindle prohibition, spindle PLC control and other data. The signal flow of the control system is shown in Figure 2.
The system can use the state combination code of SW 1 ~ SW4 detection switch as the symbol of the current spindle gear. See table 1 for the status of solenoid valve and detection switch.
Table 1 spindle displacement state displacement number sol1sol2sol3sol4sw1sw2sw3sw4
1st gear101010/00.
Second gear 011000110.
Third gear10011001
Fourth gear 01111.
PLC Realization of Automatic Shift of No.3 Spindle
The control process of spindle speed change is realized in PLC. After receiving the shift command from NCK, PLC first checks whether the spindle motor is in a stopped state. If it is not stopped, PLC will send a "Spindle Prohibition" command to the spindle to stop the spindle. PLC sets a specific timer and sends an output command to the corresponding shift hydraulic cylinder (SOL 1 ~ SOL4) according to the target gear to drive the corresponding gear to move. At the same time, start the spindle swing mode, set the swing frequency, and make the gears mesh during the movement. After the timer expires, PLC detects whether the corresponding gear switch is effective. If it is valid, it means that the shift gear is engaged in place, report the shift to NCK and fill in "current gear" in the data block. At this point, the spindle automatically enters the next speed. Otherwise, PLC carries out error alarm processing. The control flow of spindle speed change is shown in Figure 3.
In the design of PLC, we must pay attention to:
In order to avoid the confusion of spindle displacement, in the initialization module of PLC program, the gear detection switch of the machine tool is scanned as soon as the system is powered on, and the "current gear" is set in the data block to initialize the system state.
Before moving the running spindle, the rotating speed of the spindle must be reduced to zero, otherwise the gear will be damaged.
Before the spindle rotates to the next speed, the corresponding shift cylinder must move to the correct position to engage the corresponding gear.
In order to better mesh, the oil cylinder controls the spindle to swing back and forth slightly during the movement, which can shorten the shift time and avoid the impact and precision damage caused by gear hard top.
4 conclusion
At present, the large-scale transformation of domestic machine tools will involve the problem of spindle displacement. Proper control of spindle offset can not only improve the machining accuracy of machine tools, but also prolong the service life of spindles.
According to the characteristics of Siemens 840C control data interface and gear shifting mechanism of machine tools, adopting mechatronics, through the design of PLC program, the CNC system will automatically shift gears as long as the spindle speed is written in the CNC programming. The reformed spindle can shift gears freely and run reliably. Timely alarm prompt and error handling for the cylinder stroke is not in place and the shift pressure is not enough during the shift. The self-protection function of machine tool spindle is a problem that designers must pay attention to. There may be hydraulic problems in gear shifting, such as insufficient gear shifting pressure and hydraulic solenoid valve failure, resulting in the cylinder not being in place. When the shift is overtime, the system should give a clear alarm and prohibit the spindle from shifting to protect the spindle. In the process of gear shifting, flexible gear shifting can be realized by skillfully using the swing mode of the spindle. At the same time, a timer should be used to check the response of the output command periodically.