Share this

Implementation of a PLC-based precision cutting CNC lathe

2026-04-06 03:30:45 · · #1

Abstract: This paper proposes a design scheme for a CNC lathe suitable for precision cutting. The scheme employs a mechanically triggered sensor, which is activated by controlling the movement of the cutting tool . The PLC transmits the signal from the sensor to the CNC system, which then performs the corresponding data processing. The connection between the mechanically triggered sensor and the PLC 's input expansion terminal is simple and easy to maintain, reducing costs compared to using other sensors.

Keywords: PLC; CNC machine tool; precision; NUM; sensor

Abstract: This paper proposes one kind of CNC machine tool design proposal which is suitable precisely cuts. This plan uses the machinery to touch the sensor, triggers the sensor through the control lathe tool movement, and the PLC put the sensor signal to the CNC system, at last, carries on the corresponding data processing by the system. The connected wired between machinery sensor and the PLC is simple, moreover is easy to maintain, compared to other sensors has reduced the cost.

Keyword: PLC;CNC machine tool; precisely ;NUM;sensor

1. Introduction

With the development of science and technology and the advancement of manufacturing technology, society's demand for product diversification is becoming increasingly strong, product replacement cycles are becoming shorter, and the proportion of small and medium-batch production is significantly increasing, thus placing higher demands on manufacturing equipment. To meet market needs, manufacturing equipment is required to possess high efficiency, high quality, high flexibility, and low cost. CNC machine tools , as a type of automated processing equipment, are widely adopted. Simultaneously, as modern machinery manufacturing develops to higher levels, CNC machine tools will inevitably become the foundational equipment for Flexible Manufacturing Cells (FMC), Flexible Manufacturing Systems (FMS), and Computer Integrated Manufacturing Systems (CIMS). Computer Numerical Control (CNC) systems, as essential basic equipment for manufacturing complex-shaped, high-quality, and high-precision products, have become an important component of today's advanced manufacturing technology.

A Programmable Logic Controller (PLC) is a new type of industrial control device based on computer technology that gradually developed in the late 1960s. As a novel product applying computer technology to industrial control, the PLC is an indispensable and important component of open numerical control systems. It plays a crucial role in handling the control of switching quantities. Modern advanced CNC machine tools generally consist of three parts: the machine tool body (MT), the NC (NC controller), and the PLC. In a CNC machine tool, the NC and PLC work together to control the machine tool. The NC mainly performs "digital control" tasks such as management, scheduling, and trajectory control, while the PLC mainly performs logic-related actions, such as tool changing, workpiece clamping, and the operation of coolant and lubricant. PLC technology is widely used in various industrial process controls and automated production line controls, becoming a very important application technology in the field of industrial automation.

There are two types of control information on CNC machine tools: one type controls the position information of the machine tool's feed motion axes, such as the forward, backward, left, and right movement of the CNC machine tool's worktable; the up and down movement of the spindle head; and the rotational displacement around a certain linear axis. This control is achieved by using the difference between the theoretical position calculated through interpolation and the actual feedback position to control the servo feed motor. The core function of this control is to ensure the realization of the contour trajectory of the machined part. Except for point-to-point machining, the movements of each axis must maintain a strict proportional relationship at all times. This type of digital information is processed by the CNC system (a dedicated computer), i.e., "digital control." The other type is the control of the CNC machine tool's operation during operation. This is based on the state of the switching signals from various limit switches, sensors, buttons, relays, etc., within the CNC system and on the machine tool, and follows a pre-defined logical sequence to control functions such as spindle starting/stopping, reversing, tool changing, workpiece clamping/unclamping, and the operation of the hydraulic, cooling, and lubrication systems. This type of control information mainly involves the sequential control of switching signals and is generally accomplished by a PLC.

2. Functional Analysis of Precision Cutting CNC Machine Tools

Precision CNC cutting machine tools use a CNC system to digitally control the movement of the cutting tool to achieve workpiece cutting. When writing CNC turning programs, the cutting tool is not considered. Before machining, the user must input four compensation parameters into the CNC system: X-axis compensation, Z-axis compensation, tool tip radius, and tool tip shape. The CNC system then performs compensation calculations based on the program. Of these four parameters, the tool tip shape is confirmed according to the CNC system's specifications, and the tool tip radius can be measured using a radius gauge. However, measuring the X and Z-axis compensation is relatively difficult. Automatic tool setters can effectively solve this problem. Therefore, most CNC machine tools and machining centers are equipped with various types of tool setting devices, such as external tool setters, in-machine optical tool setters, and contact-type automatic tool setters. Because turning centers do not have a high degree of standardization in clamping general CNC lathe tools, the tool setting accuracy using external tool setters is relatively low. Furthermore, dedicated external tool setters are expensive, complex to operate, and require dedicated operating space, thus limiting their practicality. Using an in-machine contact automatic tool setting device is undoubtedly a simple and quick method for tool setting. It can conveniently and automatically measure the fixed tool compensation value, greatly reducing tool setting time and improving the machining efficiency of the machine tool. Therefore, this paper aims to design an in-machine contact CNC lathe to achieve precise tool setting before CNC turning, thereby improving productivity and reducing machining costs. The main problems to be solved are as follows: The automatic tool setter needs a high-precision electronic probe (sensor) that can accurately trigger at the trigger point and has a fast response time; the probe of the tool setter is in rigid contact with the tool tip, so a buffer device is needed to protect the probe surface, and the pressure needs to be controlled at around 1-10 MPa to avoid damaging the sensor probe and causing pitting; the system can use the machine tool's own position measuring device for measurement. By recording the coordinates (X, Z) of different tool tip trigger points, a set of coordinate values ​​can be easily obtained, and the tool compensation value can be determined after analysis and calculation; the device (connecting arm) for installing and fixing the tool setter should meet the corresponding accuracy requirements, satisfy the parallelism and perpendicularity requirements, and have good rigidity and ease of operation.

3 Overall Design of Precision Cutting CNC Machine Tool

For precision cutting, the primary requirement is to ensure the cutting accuracy of the tool. Therefore, the accuracy of the sensors—a key component of the CNC machine tool—must be guaranteed. The function of the sensor is to sense and detect information in one form and convert it into another, transforming the measured quantity (the physical quantity of the tool tip position) into a physical quantity that can be represented by an output signal (current, voltage) according to a certain rule. The sensors for precision cutting CNC machine tools consist of the following parts:

Figure 1: Sensor Composition of CNC Machine Tools

In this paper, the selected sensor should have considerable accuracy and perform the following functions:

1) To achieve sensing in both the X and Z axes, the tool setter needs to obtain the coordinate values ​​of the X and Z axes. This requires different tools to trigger the sensor at the same point. Then, the machine tool's CNC system functions, combined with programming, to acquire the coordinate values ​​at that point. In essence, the sensor's function is simply to provide a switching signal; different tools triggering the signal at the same point is sufficient.

2) Due to the different tool deflection angles, the sensors cannot be made into two pairs of sensors that are perpendicular to each other along the X and Z axes. As a result, when measuring the Z-axis coordinates, the obtained tool tip coordinates may not be the true tool tip coordinates.

This paper employs a mechanical switch sensor, which uses mechanical triggering to obtain a switching output. When the tool tip and sensor advance to a preset position in parallel, the circuit is activated, generating a trigger signal. While mechanical sensors generally have lower accuracy, with proper design, the error can be controlled within a reasonable range. Furthermore, the sensor can be custom-designed to accommodate varying tool deflection angles, sensor size, and connection methods. This type of sensor is simple, practical, and low-cost, making it highly valuable for market promotion.

4. PLC and CNC System Programming

The NUM1020/1040 CNC system, developed by NUM in 1995, is a compact and fully functional 32-axis CNC system, fully compatible with the NUM1060 series. It is particularly suitable for 1- to 6-axis CNC machine tools. Its hardware features include: a GSP motherboard using CISC (Very Large Scale Integration) technology; pluggable (detachable) small modules connected to the motherboard; and, considering the connection between the CNC system and external systems, NUM has manufactured the functional modules for external communication as pluggable small modules for easy future maintenance. Specifically, these include axis modules, display modules, and communication modules. The NUM1020/1040 uses +24VDC as its power input. Since the CNC system is a low-voltage circuit, using +24VDC as the power input significantly reduces the impact of heat sources and instability factors. Users can place the +24VDC regulated power supply inside the electrical cabinet, greatly improving the reliability of the entire CNC system. Internal integration of PLC functions enhances the internal communication capabilities between the PLC and CNC, strengthening the logic control of the CNC machine tool. The 32-input and 24-output modules of the PLC and NUM can be connected to external circuits. These modules connect to the NUM CNC system via cables provided by NUM, improving the overall reliability of the machine tool. (If a problem occurs, only this module will be damaged, not the CNC system). Fiber optic communication expands the PLC input/output points, simplifying wiring connections. Axis adapter modules allow the machine tool's encoder and servo wiring to be directly connected to these modules, and then connected to the CNC system's axis board, further improving the CNC system's reliability. Furthermore, NUM's axis connections differ from other CNC systems; the NUM axis module connects all information for that axis (such as encoder, speed signal, and homing switch). If there is a problem with the machine tool's axis, you can quickly find the problem (internal or external) by simply swapping the plugs on the axis module; it features a lightweight and practical compact control panel. Its display is compatible with computer CRTs, and it has 47 function keys compatible with NC, 6 user-defined keys, and a serial communication interface, allowing connection to a PC keyboard (direct plug-and-play).

According to the design requirements, when the sensor detects a signal, the CNC system program does not monitor it, and the tool tip coordinate value cannot be recorded for data processing at this time. The feed motor must first be stopped, waiting for the operator's command before proceeding to the next step. Therefore, this function should be implemented through PLC control, connecting the Q001.0 and Q001.1 terminals to two feed motors respectively for individual control. Secondly, the sensor has four probes, but the control of the feed motors is the same for all of them: any sensor receiving a signal must simultaneously stop the corresponding motor before data processing can begin.

After receiving signals from the CNC machine tool's sensors, the signals are transmitted to the PLC via an interface circuit. The PLC then transmits the received signals to the CNC via an exchange area. The CNC processes the information and then sends it back to the PLC, which controls the X-axis and Z-axis motors. The interface circuit between the CNC system and the sensors is shown in Figure 2.

The diagram shows the PLC wiring. The four input ports %I001.0, %I001.1, %I001.2, and %I001.3 are connected to the four sensors respectively, and then connected to the COM port. When a sensor receives a signal, it acts like a closed switch, switching the voltage from +24VDC to zero, thus sending a signal to the corresponding input port of the PLC. Output port %Q001.0 enables the X-axis feed motor, and %Q001.1 enables the Y-axis feed motor.

Figure 2: CNC machine tool interface circuit

The NUM1060CNC is a multi-functional, multi-processor system that provides various automatic control functions for connection to CNC machine tools. The automatic control functions, programmed in ladder logic, include sensors and actuators mounted on the machine tool and data exchange with the CNC. These automatic control functions are housed in the central processing unit, which includes one or more function cards through which the CNC performs graphical display, automatic control, and information storage. Data exchange between the CPU and the system can be categorized into two types: communication via the exchange area and communication via protocols.

The automatic control functions are managed by a supervisory program, which includes basic tasks such as initialization, assigning input/output points to different frames, and managing input/output interfaces and monitors. The supervisory program, together with the user program, provides overall supervision and management of the system. The user program runs cyclically under the control of the supervisory program and is governed by a real-time clock (RTC) with a 20ms cycle.

The memory space arrangement of the machine tool processor is as follows:

(1) 32K static RAM with backup function (power loss retention).

(2) 32K dynamic RAM that is reset (cleared) when the power is turned on.

(3) 180KB of dynamic RAM used by the user program of the machine tool processor (1MB V1).

(4) 2.5MB of dynamic RAM used by the user program of the machine tool processor (4MB V1).

(5) 3.5MB of dynamic RAM used by the user program of the machine tool processor (4MB V2).

(6) 64KB of dynamic RAM used by the user program on the UCSII module.

The automatic control functions are as follows:

(1) Direct access to DACs (12 bits).

(2) Indirect read and write access to ADCs and input/output points is achieved through virtual memory space (refreshed every 20ms).

5. Summary of Innovation Points

The innovation of this paper lies in addressing the problem of long tool setting time and poor accuracy in precise cutting on CNC lathes. A precision cutting CNC lathe was designed, which uses the NUM CNC system's own measuring device to accurately capture the tool tip position and obtain the tool tip coordinates. The positional deviation of different tools relative to a standard tool is calculated and stored in the CNC system, achieving automatic tool setting. This effectively improves the efficiency and accuracy of tool setting and is widely applicable. It can play a positive role in improving production efficiency and reducing manufacturing costs.

References:

1 Liu Liu, Simple Tool Setting Instrument for CNC Lathes [J], Combined Machining and Automated Machining Technology, 2002, 2: 56-57

2 Gai Shujun, Wang Chaoming. Automatic tool setter used on a simple CNC lathe [J], Manufacturing Technology and Machine Tool, 1997, 7: 38-40

3 Chen Guangming, Wu Hongbin. Tool setting principle and method of CNC lathe [J], Machine Tool & Hydraulics, 2002, 3: 179-181

4 Wang Chunhai, Zhang Zengliang. Pitch Error Detection and Compensation of CNC Machine Tools [J]. Microcomputer Information, 2006, 1-1:p228-229

Read next

CATDOLL 128CM Hedi

Height: 128cm Weight: 19kg Shoulder Width: 30cm Bust/Waist/Hip: 57/52/63cm Oral Depth: 3-5cm Vaginal Depth: 3-15cm Anal...

Articles 2026-02-22
CATDOLL 108CM Q Torso Doll

CATDOLL 108CM Q Torso Doll

Articles
2026-02-22
CATDOLL 146CM Vivian TPE

CATDOLL 146CM Vivian TPE

Articles
2026-02-22