Horizontal lathe power tool rest thermal error compensation method without temperature sensor
By analyzing the data from the cutting sample inspection and CNC system, a sensorless thermal error model of the power tool post was established. This solved the problems of the unstable thermal error source of the power tool post in horizontal CNC lathes and the difficulty in installing sensors, and achieved stable thermal error compensation.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- DALIAN UNIV OF TECH
- Filing Date
- 2023-12-21
- Publication Date
- 2026-05-01
AI Technical Summary
Existing technologies struggle to effectively address the thermal error problem of power tool postes on horizontal CNC lathes, particularly due to the difficulty in compensation caused by the non-fixed thermal error sources and the inability to install temperature sensors.
Errors in the power tool holder are detected by cutting a sample. A sensorless thermal error model is established by combining the tool number, power head running time and speed in the CNC system. The error compensation value is then written into the X-axis mechanical coordinate origin offset register of the CNC system for compensation.
It achieves effective compensation for thermal deformation of the power tool holder, improves the consistency of part machining accuracy, solves the problem of difficulty in testing and installing sensors using traditional methods, and enhances the accuracy and stability of domestic CNC machine tools.
Smart Images

Figure CN117773164B_ABST
Abstract
Description
Thermal Error Compensation Method for Power Tool Post of Horizontal Lathe without Temperature Sensor Technical Field
[0001] This invention belongs to the field of thermal error compensation for CNC machine tools, and relates to a method for thermal error compensation of a power tool post of a horizontal lathe without a temperature sensor. Background Technology
[0002] Horizontal CNC lathes equipped with powered tool posts can perform multiple machining operations, including turning, milling, drilling, and boring, in a single setup. The powered tool post houses multiple power heads, and the rotational transmission of these heads is primarily gear-driven. During the rotation of the power heads, the frictional heat from the gears causes thermal deformation of the powered tool post, resulting in thermal errors in the horizontal CNC lathe. This directly affects the machining accuracy and stability of the horizontal CNC lathe. Thermal error compensation is an effective means of reducing thermal errors in horizontal CNC lathes.
[0003] Since Switzerland discovered in 1933 that thermal deformation of machine tools is one of the main factors affecting positioning accuracy, extensive research has been conducted on thermal error compensation for horizontal CNC lathes, promoting the improvement of the accuracy and stability of horizontal CNC lathes. A search revealed that the invention patent "A Thermal Error Measurement Device and Modeling Method for CNC Lathe Spindle" (application number: CN202111648768.6) discloses a method for testing the thermal error of the workpiece spindle of a horizontal CNC lathe and a decoupled thermal error multiple linear regression model for the spindle and bed; the invention patent "A Modeling and Compensation Method for Radial Thermal Drift Error of Spindle of a Horizontal CNC Lathe" (application number: CN201711075362.7) discloses a method for measuring the thermal error of the workpiece spindle of a horizontal CNC lathe. A method for modeling and compensating the thermal error of the workpiece spindle in a CNC lathe can be used to determine the thermal deformation posture of the spindle during machining and predict the radial thermal drift error of the spindle based on the thermal deformation mechanism. The invention patent "CNC Lathe Thermal Error Measurement and Compensation System and Compensation Method" (application number: CN201611146489.9) discloses a comprehensive thermal error modeling and compensation method for the workpiece spindle and feed axis of a horizontal CNC lathe, which can solve the problem of thermal error coupling between the spindle and feed axis of a horizontal CNC lathe. From the above search results, it is found that current research on thermal error compensation for CNC horizontal lathes mainly focuses on the workpiece spindle and feed axis, and no research on thermal error compensation methods for the power tool post has been found.
[0004] Furthermore, during operation, the power tool holder with multiple power heads rotates irregularly according to the workpiece's process requirements, with each power head taking turns participating in cutting. The power heads involved in cutting are also affected by chips and cutting fluid. This leads to several thermal error compensation problems: (a) the heat-generating parts and components causing thermal errors in the power tool holder are constantly changing, meaning the thermal error source is not fixed; (b) it is difficult to directly test the thermal error of the power tool holder using conventional error detection instruments such as laser interferometers or machine tool spindle error analyzers; and (c) it is difficult to place temperature sensors in the power tool holder to measure the temperature of the heat source. This poses a significant challenge to thermal error compensation for the power tool holder. Currently, no effective solution for thermal error compensation under this complex operating condition has been found. Summary of the Invention
[0005] This invention addresses the thermal deformation problem of tool turrets in horizontal CNC lathes equipped with powered tool turrets by providing a sensorless method for compensating for thermal errors in powered tool turrets without temperature sensors. It employs a sample cutting method, reflecting the powered tool turret error in the sample error. By detecting the sample error, the powered tool turret error is obtained, overcoming the difficulty of testing the thermal error of the powered tool turret using conventional error detection instruments such as laser interferometers or machine tool spindle error analyzers. Furthermore, it identifies the currently participating powered head by collecting the tool number from the CNC system, addressing the issue of the non-fixed source of the powered tool turret's thermal error. Finally, it collects the powered head's running time and rotational speed in the CNC system, establishing a relationship model between the powered head's running time, rotational speed, and thermal error, thus solving the problem of not being able to install temperature sensors on a moving tool turret. This invention can solve the problem of thermal deformation of the tool turret in horizontal CNC lathes affecting the consistency of part machining accuracy, and is of great significance for improving the accuracy and stability of domestically produced CNC machine tools.
[0006] To achieve the above objectives, the technical solution adopted by the present invention is as follows:
[0007] A sensorless method for compensating the thermal error of a power tool post on a horizontal lathe, characterized by the following steps: First, the thermal error of the power tool post on the CNC lathe is tested by cutting a sample; then, communication is established with the CNC system of the CNC lathe to collect the tool number, power head running time, and power head speed; next, a sensorless thermal error model of the power tool post is established based on the thermal error, power head running time, and power head speed; finally, the thermal error compensation value calculated by the power tool post thermal error model is written into the X-axis mechanical coordinate origin offset register of the CNC system; the specific steps of the method are as follows:
[0008] The first step is to test the thermal error of the CNC lathe's power tool post by cutting a sample part;
[0009] Before testing, ensure that the CNC lathe is stopped and cooled for more than 3 hours; (1) In the initial state, use the adjacent cutting tool on the tool post to turn the outer cylindrical surface of the sample, and use a micrometer to measure the outer diameter of the sample as the reference size; (2) Let the power head on the tool post run idle for a period of time to warm up, and use the same cutting tool adjacent to the power head on the tool post to turn the outer cylindrical surface of the sample, and use a micrometer to measure the outer diameter of the sample; (3) Repeat step (2) until the change in the outer diameter of the sample reaches equilibrium; (4) Let the power head on the tool post stop and cool down for a period of time, and use the adjacent cutting tool on the tool post to turn the outer cylindrical surface of the sample, and use a micrometer to measure the outer diameter of the sample; (5) Repeat step (2) until the change in the outer diameter of the sample reaches equilibrium; (6) Let the power head on the tool post stop and cool down for a period of time, and use the adjacent cutting tool on the tool post to turn the outer cylindrical surface of the sample, and use a micrometer to measure the outer diameter of the sample; (7) Repeat step (2) until the change in the outer diameter of the sample reaches equilibrium; (8) Let the power head on the tool post stop and cool down for a period of time, and use the same cutting tool adjacent to the power head on the tool post to turn the outer cylindrical surface of the sample, and use a micrometer to measure the outer diameter of the sample; (9) Repeat step (2) until the change in the outer diameter of the sample reaches equilibrium; (10) Let the power head on the tool post stop and cool down for a period of time, and use the same cutting tool adjacent to the power head on the tool post to turn the outer cylindrical surface of the sample, and use a micrometer to measure the outer diameter of the sample. (5) Use the same lathe tool to turn the outer cylindrical surface of the sample and measure the outer diameter of the sample with a micrometer; (6) Repeat step (4) until the change in the outer diameter of the sample reaches equilibrium; (7) Subtract the outer diameter of the sample measured in step (1) from the outer diameter of the sample measured in steps (2) to (5) to obtain the thermal error value of the current power head power tool holder; (8) Stop the CNC lathe and cool it for more than 3 hours, switch to the next power head, and repeat steps (1) to (6) to obtain the thermal error of the power tool holder when the new power head moves; (9) Repeat the above steps until the power tool holder caused by the rotation of all power heads has been tested.
[0010] The second step is to establish communication with the CNC system and collect the tool number, power head running time, and power head speed.
[0011] An external computer is connected to the CNC system via a network cable. Based on the dynamic link library functions of the CNC system, the external computer communicates with the CNC system and reads the tool number and the speed of the power motor at the current machining position. The tool number is used to determine the power head tool number at the current machining position, and the speed of the power motor is used to determine whether the power head at the machining position is running. The running time is recorded.
[0012] The third step is to establish a sensorless power tool holder thermal error model.
[0013] When the current machining position is determined to be the power head based on the acquired tool number and motor speed, and the power head is rotating, it is assumed that the power tool holder will generate thermal error. The formula for calculating thermal error is as follows:
[0014]
[0015] In the formula, E heat (n,t) represents the thermal error at time t under rotational speed n, where a, b, and c are constant parameters of the thermal error model during the rotation of the power head. When the power head is in a non-processing position, it cannot rotate, and is therefore considered to be in a cooling state. During this process, the thermal error will decrease. The formula for calculating the thermal error is:
[0016]
[0017] In the formula, E cool (t) represents the thermal error at time t, t0 is the time before the power head stops rotating, n0 is the rotational speed of the power head before it stops rotating, and E heat (n0,t0) represents the thermal error before the power head stops rotating, and d and k are constant parameters of the thermal error model when the power head stops rotating. When there are multiple power heads on the power tool holder, the thermal error calculation formula is as follows:
[0018]
[0019] In the formula, i is the designation of the power head, and E heat_ (n i ,t i ) is the i-th power head at t i Rotational speed n at time i Thermal error under the condition, a i b i c i E is a constant parameter of the thermal error model during the rotation of the i-th power head. cool (t i ) is the i-th power head at t i Thermal error at time t 0i It is the moment before the i-th power head stops rotating, n 0i E is the rotational speed before the i-th power head stops. heat (n 0i ,t 0i ) represents the thermal error before the i-th power head stops, and d i k i These are the constant parameters of the thermal error model when the i-th power head stops rotating;
[0020] The error value when the change in the outer diameter of the sample reaches equilibrium in the first step of the heat engine is taken as the upper limit A of the thermal error compensation value of the power tool holder. The lower limit of the compensation value is set to 0. That is, when the thermal error compensation value calculated by the thermal error model exceeds A, it is compensated according to A; when the thermal error compensation value calculated by the thermal error model is less than 0, it is compensated according to 0.
[0021] The fourth step is to implement thermal error compensation for the power tool post;
[0022] The communication between the external computer and the CNC system is realized by using the dynamic link library functions of the CNC system. The thermal error compensation value calculated by the thermal error model of the power tool post is written into the X-axis mechanical coordinate origin offset register of the CNC system using the function of writing error compensation value in the dynamic link library function library, thereby realizing the thermal error compensation of the power tool post of the horizontal CNC lathe.
[0023] The beneficial effects of this invention are:
[0024] (1) This invention provides a method for thermal error compensation of the power tool post of a horizontal CNC lathe, which can solve the problem of inconsistent machining accuracy of parts due to thermal deformation of the power tool post of a domestic horizontal CNC lathe;
[0025] (2) By adopting the sample cutting method, the error of the power tool holder is reflected in the error of the sample. The error of the power tool holder can be obtained by detecting the error of the sample. This can solve the problem that conventional machine tool error detection instruments such as laser interferometers or spindle error analyzers are difficult to test the thermal error of the power tool holder.
[0026] (3) By collecting the tool number in the CNC system to identify the power head currently participating in cutting, the problem of the unstable thermal error source of the power tool holder can be solved.
[0027] (4) The present invention directly collects the running time and rotation speed of the power head in the CNC system to calculate the thermal error compensation value of the tool holder. No temperature sensor is required, which can solve the problem that the rotation of the tool holder makes it impossible to install the temperature sensor, thus affecting the implementation of thermal error compensation.
[0028] (5) The tool holder thermal error model established by this invention can be integrated with the feed axis thermal error model, and the tool holder thermal error and X-axis thermal error can be superimposed and compensated. Attached Figure Description
[0029] Figure 1 is a schematic diagram of the power head layout of the power tool post of a horizontal CNC lathe;
[0030] Figure 2 is a flowchart of thermal error compensation for the power tool post of a horizontal CNC lathe;
[0031] Figure 3 shows the variation of the outer diameter error of the sample.
[0032] Figure 4 shows the change in the outer diameter error of the sample after compensation.
[0033] In the diagram: 1 Power head one (boring cutter); 2 Turning tool one; 3 Cutting head; 4 Power head two (milling cutter); 5 Power head three (drill); 6 Turning tool two. Detailed Implementation
[0034] The specific embodiments of the present invention will be further described below with reference to the accompanying drawings and technical solutions.
[0035] Taking a certain type of horizontal CNC lathe as an example, the implementation method of the present invention will be described in detail. The CNC system of the horizontal CNC lathe is the FANUC-0i-TF system, equipped with a power tool post and three power heads, which are used for milling, drilling and boring respectively. The layout of the three power heads is shown in Figure 1, and the specific compensation flowchart is shown in Figure 2.
[0036] (1) Testing the thermal error of the CNC lathe's power tool post by cutting sample parts
[0037] Before testing, ensure the CNC lathe is shut down and cooled for at least 3 hours. (a) In the initial state, use the cutting tool 2 next to power head 1 to machine the outer cylindrical surface of the sample, and then use the cutting tool 6 next to power head 3 to machine the outer cylindrical surface of the same sample, so that the outer cylindrical surface of the sample forms a stepped surface. Use a micrometer to measure the outer diameter of the two layers of the sample as the reference dimensions; (b) Let power head 1 switch to the working position and run for 280 seconds to warm up, and then switch power head 4 and power head 3 to the working position in sequence for a total running time of 200 seconds. Then use the cutting tool 2 next to power head 1 and the cutting tool 6 next to power head 3 to machine the outer cylindrical surface of the same sample. (c) Use tool 26 next to tool 5 to turn the outer cylindrical surface of the new sample, forming a stepped surface. Measure the outer diameter of the two layers of the new sample using a micrometer. (d) Repeat step (b) 21 times. (e) Let the power head on the power tool holder stop cooling for 5 minutes. Then, use tool 2 next to power head 1 and tool 26 next to power head 5 to turn the outer cylindrical surface of the new sample, forming a stepped surface. Measure the outer diameter of the two layers of the new sample using a micrometer. (f) Repeat step (d) 14 times. The outer diameter of the sample is shown in Table 1, and the variation of the outer diameter error is shown in Figure 3.
[0038] Table 1 Outer diameter of turned sample
[0039]
[0040]
[0041] (2) Establish communication with the CNC system and collect tool number, power head running time and power head speed;
[0042] The CNC system IP address of this horizontal CNC lathe is "192.168.1.1", and the port number is "8193". Using the MATLAB platform, the "cnc_allclibhndl3" function from the FOCAS2 function library is used to connect the external computer to the CNC system. The program segment is as follows:
[0043] [Conection_Ret,~,CNC_Handle]=calllib('FWLIB32','cnc_allclibhndl3','192.168.1.1','8193',5,CNC_Handle); The "cnc_acts2" function is used to read the speed of the motor. The program segment is as follows:
[0044] [r_ret1,powrunit_speed01]=calllib('FWLIB32','cnc_acts2',CNC_Handle,2,powrunit_speed01);
[0045] The tool number is read using the "cnc_rdmacro" function. The code segment is as follows:
[0046] [r_ret2,powrunit_toolnum] = calllib('FWLIB32','cnc_rdmacro',CNC_Handle,100,10,powrunit_toolnum); When the program returns Conection_Ret equal to 0, it indicates that the external computer and the CNC system are successfully connected; when the program returns r_ret1 equal to 0, it indicates that the speed of the power motor is successfully read, and powrunit_speed01 is the speed of the power motor read. By judging whether the speed of the power motor is 0, the current rotation and stopping time of the power head is recorded; when the program returns r_ret2 equal to 0, it indicates that the tool number is successfully read, and powrunit_toolnum is the tool number read.
[0047] (3) Establish a sensorless power tool holder thermal error model;
[0048] Based on the error data, power head speed, and running time obtained from the test, the thermal error model parameters of the power tool holder are fitted as [a3,b3,c3,d3,k3]=[-0.0004846,0.9406,117.5,-9.882,25.9], [a1,b1,c1,d1,k1]=[-0.00508,10.13,54.22,-9.763,16.77]. Since power head two and power head three are adjacent, their thermal error model parameters are considered to be the same, i.e., [a2,b2,c2,d2,k2]=[a3,b3,c3,d3,k3]. Therefore, the thermal error model of the power tool holder can be written as...
[0049] The growth slope a = 0.00147 μm / s, that is, the formula for calculating the thermal error during the tool holder heating stage is:
[0050]
[0051] Based on the error value when the change in the outer diameter of the sample reaches equilibrium, the upper limit of the thermal error compensation value of the power tool holder is set to A = 29μm, and the lower limit of the compensation value is set to 0μm. That is, when the thermal error compensation value calculated by the thermal error model exceeds 29μm, it is compensated at 29μm; when the thermal error compensation value calculated by the thermal error model is less than 0μm, it is compensated at 0μm.
[0052] (4) Implement thermal error compensation for the power tool post
[0053] The thermal error compensation value calculated by the thermal error model of the power tool post is written into the X-axis mechanical coordinate origin offset register R1070 of the CNC system using the "pmc_wrpmcrng" function in the FOCAS2 function library, thus realizing thermal error compensation of the power tool post of the horizontal CNC lathe. After enabling compensation, a thermal error compensation test of the power tool post is performed. Before the test, ensure that the CNC lathe is stopped and cooled for more than 3 hours. The specific test steps are as follows:
[0054] (a) In the initial state, the outer cylindrical surface of the sample is machined by the cutting tool 2 next to the power head 1, and then the outer cylindrical surface of the same sample is machined by the cutting tool 2 6 next to the power head 3 5, so that the outer cylindrical surface of the sample forms a stepped surface. The outer diameter of the two layers of the sample is measured by micrometer as the reference size.
[0055] (b) Let the power head 1 be switched to the working position and run for 280s. Then, switch the power head 4 and the power head 5 to the working position in sequence for a total running time of 200s. Then, use the turning tool 2 next to the power head 1 and the turning tool 6 next to the power head 5 to turn the outer cylindrical surface of the new sample, so that the outer cylindrical surface of the sample forms a stepped surface. Use a micrometer to measure the outer diameter of the two layers of the new sample.
[0056] (c) Repeat step (b) 13 times.
[0057] The outer diameter of the compensated sample is shown in Table 2, and the change in the outer diameter error is shown in Figure 4.
[0058] Table 2. Outer diameter of the machined sample after compensation
[0059]
[0060] From the error test results in step (1) and the compensation test results in step (4), it can be seen that within the same test time, the error of the outer diameter of the turning tool one next to the power head one decreased from -29μm to 0μm before compensation to -6μm to 3μm after compensation, with an error reduction of 69.0%; the error of the outer diameter of the turning tool two next to the power head three decreased from -25μm to 0μm before compensation to -8μm to 4μm after compensation, with an error reduction of 52.0%.
[0061] The above-described embodiments are merely illustrative of the implementation methods of the present invention, but should not be construed as limiting the scope of the present invention. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of the present invention, and these modifications and improvements all fall within the protection scope of the present invention.
Claims
1. A method for thermal error compensation of a power tool post of a horizontal lathe without a temperature sensor, characterized in that, Includes the following steps: The first step is to test the thermal error of the CNC lathe power tool post by cutting a sample. Before the test, ensure that the CNC lathe is stopped and cooled for more than 3 hours. (1) In the initial state, use a cutting tool adjacent to the power head on the tool post to cut the outer cylindrical surface of the sample. Use a micrometer to measure the outer diameter of the sample as the reference size. (2) Let the power head on the power tool post run idle to warm up. Use the same cutting tool adjacent to the power head on the power tool post to cut the outer cylindrical surface of the sample. Use a micrometer to measure the outer diameter of the sample. (3) Repeat step (2) until the change in the outer diameter of the sample reaches equilibrium. (4) Stop the power head on the power tool post to cool down. Use the same cutting tool adjacent to the power head on the power tool post to cut the outer cylindrical surface of the sample. Use a micrometer to measure the outer diameter of the sample. (5) Repeat step (4) until the change in the outer diameter of the sample reaches equilibrium. (6) Put the power head on the power tool post into the cold machine. (5) Subtract the outer diameter of the sample measured in step (1) from the appearance size of the sample measured in step (5) to obtain the thermal error value of the current power head power tool holder; (7) After the CNC lathe is stopped and cooled for more than 3 hours, switch to the next power head and repeat steps (1) to (6) to obtain the thermal error of the power tool holder when the new power head moves; (8) Repeat the above steps until all power tool holders caused by the rotation of all power heads are tested; Second step, establish communication with the CNC system and collect the tool number, power head running time and power head speed; Connect the external computer to the CNC system through the network cable, realize the communication between the external computer and the CNC system based on the dynamic link library function of the CNC system and read the tool number and the speed of the power motor of the current machining position; Use the tool number to determine the tool number of the power head of the current machining position, use the speed of the power motor to determine whether the power head in the machining position is running, and record the running time; The third step is to establish a sensorless power tool holder thermal error model. When the current machining position is determined to be the power head based on the acquired tool number and motor speed, and the power head is rotating, it is assumed that the power tool holder will generate thermal error. The thermal error calculation formula is: E heat (n,t)=(a+b·n)·(1-e -t / c In equation (1), E heat (n,t) represents the thermal error at time t under rotational speed n, where a, b, and c are constant parameters of the thermal error model during the rotation of the power head. When the power head is in a non-processing position, it cannot rotate, and is therefore considered to be in a cooling state. During this process, the thermal error will decrease. The formula for calculating the thermal error is: In the formula, E cool (t) represents the thermal error at time t, t0 is the time before the power head stops rotating, n0 is the rotational speed of the power head before it stops rotating, and E heat (n0,t0) represents the thermal error before the power head stops rotating, and d and k are constant parameters of the thermal error model when the power head stops rotating. When there are multiple power heads on the power tool holder, the thermal error calculation formula is: In the formula, i is the power head cutter number, E heat_ (n i ,t i ) is the i-th power head at t i Rotational speed n at time i Thermal error under the condition, a i b i c i E is a constant parameter of the thermal error model during the rotation of the i-th power head. cool (t i ) is the i-th power head at t i Thermal error at time t 0i It is the moment before the i-th power head stops rotating, n 0i E is the rotational speed before the i-th power head stops. heat (n 0i ,t 0i ) represents the thermal error before the i-th power head stops, and d i k i These are the constant parameters of the thermal error model when the i-th power head stops rotating; the error value when the change in the outer circle dimension of the sample reaches equilibrium in the first step of the heat engine is taken as the upper limit A of the thermal error compensation value of the power tool holder, and the lower limit of the compensation value is set to 0. That is, when the thermal error compensation value calculated by the thermal error model exceeds A, it is compensated according to A; when the thermal error compensation value calculated by the thermal error model is less than 0, it is compensated according to 0; the fourth step is to implement the thermal error compensation of the power tool holder. The communication between the external computer and the CNC system is realized by using the dynamic link library functions of the CNC system. The thermal error compensation value calculated by the thermal error model of the power tool post is written into the X-axis mechanical coordinate origin offset register of the CNC system using the function of writing error compensation value in the dynamic link library function library, thereby realizing the thermal error compensation of the power tool post of the horizontal CNC lathe.
Citation Information
Patent Citations
Digital controlled lathe thermal error measuring compensation system and method
CN106736848A
A method for modeling and compensating for radial thermal drift error of a horizontal CNC lathe spindle
CN107942934B
A CNC lathe spindle thermal error measurement device and modeling method
CN114296396B
Measuring device, measuring method therefor, work position correcting device for cutting machine, work position correcting method therefor, image capturing device, and cutting machine provided with the image capturing device
CN102414613A
Machine tool complete machine thermal error characteristic test method
CN111618662A