Automatic measurement and correction method for engraving and milling machine tool based on Mastercam software

By developing post-processing programs and configuration measurement logic codes, the measurement programming compatibility problem of the domestic Jingdiao JD50 CNC system and Mastercam software is solved, and the automatic measurement and correction of domestic Jingdiao machine tools is realized, and the production efficiency and product quality are improved.

CN120085609APending Publication Date: 2025-06-03CHENGDU SIWI HIGH TECH IND GARDEN
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510240458.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-03
Publication Date
2025-06-03

AI Technical Summary

Technical Problem

The compatibility problem of measurement programming adaptation between the domestic Jingdiao JD50 CNC system and Mastercam software has resulted in the inability to directly compatible with the measurement program framework designed based on 33 local variables, forcing the operator to return to manual measurement mode.

Method used

Develop post-processing programs for Mastercam software, and are adapted to the Jingdiao JD50 CNC system, and configure measurement logic code and a second-class user macro program interface, so that the Jingdiao JD50 CNC system can realize automatic measurement and correction functions based on Mastercam software.

Benefits of technology

It realizes automatic measurement and correction of domestic fine engraving machine tools, simplifies the operation process, significantly improves operation reliability, and improves production efficiency and product quality.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120085609A_ABST
    Figure CN120085609A_ABST
Patent Text Reader

Abstract

The invention provides an automatic measurement and correction method for an engraving and milling machine tool based on Mastercam software, relates to the technical field of numerical control of the engraving and milling machine tool, and solves the problem of measurement programming adaptation compatibility between a domestic engraving and milling JD50 numerical control system and the Mastercam software. The method comprises the following steps: developing a post-processing program of Mastercam software, and enabling the post-processing program to be adaptive to a fine carving JD50 numerical control system; configuring a measurement logic code of the fine carving JD50 numerical control system; the method comprises the following steps: generating a processing main program by using Mastercam software, and configuring a second-class user macro program interface in the processing main program; and the engraving and milling JD50 numerical control system drives the engraving and milling machine tool to execute measuring head calibration, online measurement and tool correction operation in a variable mapping mode. According to the invention, the accurate carving JD50 numerical control system can realize automatic measurement and correction functions of the accurate carving machine tool based on Mastercam software, and the method has the advantages of simple operation and high reliability.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of numerical control technology for precision engraving machines, and particularly to an automatic measurement and correction method for precision engraving machines based on Mastercam software. Background Art

[0002] With the rapid development of intelligent manufacturing technology, the demand for automated measurement and correction technology in the numerical control machining industry is increasing day by day. In mass production and flexible manufacturing scenarios, the traditional measurement methods relying on manual intervention are difficult to meet the high-efficiency and high-precision production requirements. The automatic measurement and correction technology can effectively eliminate the influence of factors such as workpiece clamping error and tool wear on machining accuracy by collecting machining deviation data in real time and feeding it back to the control system, significantly shortening the process adjustment time and improving product consistency, and has become an important direction for the intelligent upgrade of modern CNC machine tools.

[0003] Currently, the international mainstream CNC system manufacturers have gradually improved the technical ecosystem of automated measurement functions. Taking the FANUC CNC system as an example, through in-depth cooperation with CAD / CAM software developers and measurement equipment suppliers, it has formed a mature measurement programming solution. A typical application is the measurement module jointly developed by Mastercam software and Renishaw probes. This module designs a dedicated post-processing program for the FANUC CNC system, which can automatically generate measurement codes including main programs and fixed subroutines. Under this architecture, users only need to edit the main program according to the measurement type, and then directly call the standardized subroutine to complete parameter transfer and measurement action execution. This mode greatly reduces the difficulty of developing measurement programs, but its implementation depends on the unique macro program variable system of the FANUC CNC system - especially the use of the second-class user macro program with 33 local variables for cross-program parameter transfer, forming a technical closed-loop of software and hardware collaboration.

[0004] However, in the process of popularizing and applying domestic CNC systems, such technology adaptation faces significant challenges. Taking the Jingdiao JD50 CNC system as an example, as a domestic CNC platform with independent intellectual property rights, although it complies with ISO standards and has good machining performance, its macro program architecture is essentially different from foreign systems. Specifically, the Jingdiao JD50 CNC system adopts a first-class user macro program architecture, which only supports 26 local variables for parameter transfer between the main program and subroutines, and cannot directly be compatible with the measurement program framework designed based on 33 local variables. This structural difference causes the FANUC-specific code generated by the Mastercam measurement module to be unable to run on the Jingdiao JD50 CNC system, forcing operators to fall back to the manual measurement mode: inputting measurement instructions line by line through the MDI interface, manually recording data and calculating compensation values. This process is not only inefficient and prone to introducing human errors, but also difficult to achieve process standardization due to the inability to save measurement programs, seriously restricting the deployment ability of Jingdiao machines in automated production lines.

[0005] In the prior art, there is still a blank in the measurement programming adaptation solution for domestic CNC systems. Directly transplanting the measurement code architecture of the FANUC CNC system faces compatibility problems such as insufficient macro program variables and mismatched function instructions, while completely redeveloping the measurement module requires a large amount of R & D resources. How to achieve seamless docking of the Mastercam measurement function with the domestic CNC platform without changing the underlying logic of the Jingdiao JD50 CNC system has become a technical problem that urgently needs to be solved to improve the intelligent level of domestic Jingdiao machine tools. Summary of the Invention

[0006] The purpose of the present invention is to solve the measurement programming adaptation compatibility problem between the domestic Jingdiao JD50 CNC system and the Mastercam software. Therefore, an automatic measurement and correction method for Jingdiao machine tools based on the Mastercam software is proposed. The present invention has made adaptation improvements in aspects such as post-processing program development, macro program and logic code configuration, enabling the Jingdiao JD50 CNC system to also achieve the automatic measurement and correction function of the Jingdiao machine tool based on the Mastercam software, and having the advantages of simple operation and high reliability.

[0007] The present invention adopts the following technical solutions to achieve the purpose:

[0008] An automatic measurement and correction method for Jingdiao machine tools based on the Mastercam software, comprising the following steps:

[0009] S1. Develop the post-processing program of the Mastercam software and make the post-processing program adapt to the Jingdiao JD50 CNC system;

[0010] S2. After completion of the adaptation, further configure the measurement logic code of the Jingdiao JD50 CNC system;

[0011] S3. Based on the configured measurement logic code, use the Mastercam software to generate a machining main program, and configure a secondary user macro program interface in the machining main program; the Jingdiao JD50 CNC system drives the Jingdiao machine tool to perform probe calibration, on-line measurement and tool compensation operations through variable mapping.

[0012] Further, in step S1, the development and adaptation of the post-processing program specifically include:

[0013] S11. Define a common variable range, which is used to store temporary data during the measurement and correction process;

[0014] S12. Allocate a subprogram number range, which is used to call the measurement macro program;

[0015] S13. Set the probe calibration information and store it in the user variable range;

[0016] S14. Match the probe tool change code, spindle orientation code, and reference point return code of the Jingdiao machine tool to the Jingdiao JD50 numerical control system.

[0017] Specifically, in step S11, the common variable range is defined as numbers 100 to 147. Among them, numbers 100 to 120 are used to store the probe trigger coordinate data, and numbers 121 to 147 are used to store the tool compensation value data;

[0018] In step S12, the subroutine number range is from 6001 to 6207. Among them, numbers 6001 to 6100 are used for the probe calibration macro program, and numbers 6101 to 6207 are used for the tool measurement and compensation macro program;

[0019] In step S13, the user variable range is from 656 to 675. Among them, numbers 656 to 665 store the probe length calibration data, and numbers 666 to 675 store the probe radius calibration data.

[0020] Furthermore, in step S2, configure the measurement logic code of the Jingdiao JD50 numerical control system, specifically including:

[0021] S21. Modify the system print code to the DPRNT line format;

[0022] S22. Set the system alarm parameter to the first preset number, and at the same time mask the parameter corresponding to the second preset number;

[0023] S23. Add a pause pre-reading code M12 and a close pre-reading code M13;

[0024] S24. Bind the probe trigger signal and the jump signal channel to form a closed-loop measurement logic.

[0025] Specifically, in step S22, set the system alarm parameter to number 2402, and at the same time mask parameter 3004; the system alarm parameter 2402 is associated with the probe overtravel alarm signal, and an alarm is triggered when the probe measurement value exceeds the threshold set in the user variable range;

[0026] In step S23, the pause pre-reading code M12 is used to pause the system pre-reading buffer before the probe is triggered, and the close pre-reading code M13 is used to restore the pre-reading logic after the measurement is completed;

[0027] In step S24, the jump signal channel includes the input port X10.1 and the output port Y10.5, which are used to receive the probe trigger signal and send the measurement completion signal respectively.

[0028] Further, in step S3, a secondary user macro program interface is configured in the machining main program, specifically: modifying the macro parameter passing rule of the preset machining main program, and mapping multiple preset primary macro program variables to corresponding secondary macro program variables respectively.

[0029] Specifically, the preset machining main programs include main programs O6101, O6009, and O6107; the primary macro program variables No. 10, No. 12, No. 14, No. 15, and No. 16 are mapped to the secondary macro program variables No. 26, No. 25, No. 24, No. 23, and No. 22 respectively; after the mapping is completed, the machining main program is generated using Mastercam software for driving the Jingdiao machine tool to operate by the Jingdiao JD50 numerical control system.

[0030] Specifically, the primary macro program variable No. 10 is mapped to the secondary macro program variable No. 26 for transmitting the X-axis measurement coordinate; the primary macro program variable No. 12 is mapped to the secondary macro program variable No. 25 for transmitting the Y-axis measurement coordinate.

[0031] Specifically, the primary macro program variable No. 14 is mapped to the secondary macro program variable No. 24 for transmitting the Z-axis measurement coordinate; the primary macro program variable No. 15 is mapped to the secondary macro program variable No. 23 for transmitting the tool radius compensation value.

[0032] Specifically, the primary macro program variable No. 16 is mapped to the secondary macro program variable No. 22 for transmitting the tool length compensation value and comparing it with the calibration data in the user variable to generate a correction amount.

[0033] In summary, due to the adoption of this technical solution, the beneficial effects of the present invention are as follows:

[0034] By developing the post-processing program of Mastercam automatic measurement programming, configuring the measurement macro program and logic code of the Jingdiao machine tool control system, and configuring the secondary user macro program, the present invention realizes the automatic measurement and correction of domestic Jingdiao machine tools. This method not only simplifies the operation process but also significantly improves the reliability of the operation.

[0035] The method of the present invention simplifies the operation difficulty of automatic measurement and correction of workpieces. Due to adaptation and compatibility problems, the traditional method can only adopt complex manual adjustment methods; while the new method of the present invention can achieve efficient and accurate automatic operation, enabling the measurement and correction process to be quickly completed even for complex workpiece machining. This makes it possible for rapid tool change, enabling the production line to more flexibly meet the production requirements of different products.

[0036] The application of the method of the present invention will greatly improve production efficiency and product quality. Due to the accuracy of automatic measurement and correction, the errors caused by human factors are reduced, ensuring that each workpiece conforms to the design standards as much as possible. This is particularly important for batch production, as it guarantees the stability and consistency of large-scale production. In addition, in a flexible automated production line, this method also demonstrates its unique advantages and can achieve efficient processing without affecting the production rhythm. Brief Description of the Drawings

[0037] Figure 1 It is a schematic diagram briefly showing the overall process of the method of the present invention. Detailed Embodiment

[0038] To make the objectives, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are some, but not all, of the embodiments of the present invention. Generally, the components of the embodiments of the present invention described and illustrated herein can be arranged and designed in various different configurations.

[0039] Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the claimed invention, but merely represents selected embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without creative efforts shall fall within the scope of protection of the present invention.

[0040] An automatic measurement and correction method for a precision engraving machine based on Mastercam software Figure 1 It shows a brief overview of the overall process of this method. For synchronous reference, the various steps of this method can be summarized as follows:

[0041] S1. Develop a post-processing program for Mastercam software and make the post-processing program adapt to the precision engraving JD50 numerical control system;

[0042] S2. After completion of adaptation, further configure the measurement logic code of the precision engraving JD50 numerical control system;

[0043] S3. Based on the configured measurement logic code, use Mastercam software to generate a machining main program, and configure a type-two user macro program interface in the machining main program; the precision engraving JD50 numerical control system drives the precision engraving machine to perform probe calibration, on-line measurement and tool compensation operations through variable mapping.

[0044] After the above steps are executed, the domesticated precision engraving machine tool, under the control of the domestic Jingdiao JD50 numerical control system, can achieve automatic closed-loop control of probe calibration, on-line measurement, and tool compensation based on the Mastercam software, thereby significantly improving machining accuracy and efficiency and reducing manual intervention.

[0045] Example 1

[0046] This example introduces the development and adaptation of the post-processing program in step S1.

[0047] Step S1: Develop and adapt a post-processing program for the Jingdiao JD50 numerical control system.

[0048] Define variable storage intervals, including:

[0049] Common variable interval: Allocate variables numbered 100 - 147. Among them, variables numbered 100 - 120 are used to store the X / Y / Z coordinate data when the probe is triggered (for example, the X coordinate is stored in #100, the Y coordinate is stored in #101, and the Z coordinate is stored in #102); variables numbered 121 - 147 are used to store tool length / radius compensation values (for example, the length compensation value is stored in #121, and the radius compensation value is stored in #122).

[0050] User variable interval: Allocate variables numbered 656 - 675, which are used to store probe calibration parameters. Among them, variables numbered 656 - 665 are used to store probe length calibration data (for example, the reference length is stored in #656); variables numbered 666 - 675 are used to store radius calibration data (for example, the reference radius is stored in #666).

[0051] Allocate subroutine call intervals, including subroutines numbered 6001 - 6207, which can correspond to the main machining programs generated by the Mastercam software. Among them, subroutines numbered 6001 - 6100 are probe calibration macro programs (for example, O6001 is for X / Y plane calibration); subroutines numbered 6101 - 6207 are tool measurement and compensation macro programs (for example, O6101 is for tool length measurement).

[0052] Configure the control codes related to the Jingdiao machine tool: Match the probe tool change code M06 Txx, spindle orientation code M19, and reference point return code G28 of the Jingdiao machine tool with the instruction set of the Jingdiao JD50 numerical control system to ensure synchronous action timing.

[0053] Example 2

[0054] Based on Example 1, this example introduces the relevant configuration of the measurement logic code of the Jingdiao JD50 numerical control system in step S2.

[0055] First, modify the print code of the Jingdiao JD50 numerical control system to the DPRNT line format.

[0056] Subsequently, modify the alarm parameters: Set parameter No. 2402 to be associated with the probe overtravel alarm (for example, the alarm is triggered when the probe coordinates exceed the threshold stored in #656).

[0057] Mask parameter No. 3004: Cancel the default emergency stop signal association to avoid false triggering.

[0058] Add pre-reading control codes, where: M12 is used as a pause for pre-reading, pausing the system pre-reading buffer before the probe is triggered to ensure that measurement instructions are executed line by line; M13 is used as a resume for pre-reading, resuming the pre-reading function of the buffer after the measurement is completed to improve the subsequent processing efficiency.

[0059] Bind signal channels, where the input port X10.1: Receives the probe trigger signal (set to 1 when triggered); the output port Y10.5: Sends the measurement completion signal (resets the probe status after being set to 1). Thus, the corresponding closed-loop logic is formed: X10.1 trigger → execute measurement → Y10.5 feedback → continue processing.

[0060] Embodiment 3

[0061] Based on the above embodiments, this embodiment introduces the relevant construction of macro program variable mapping in step S3. In the main programs O6101, O6009, and O6107, the macro interface configurations corresponding to the mapping of relevant variables are as follows:

[0062] #10 → #26: Transmit the X-axis measurement coordinate to the second-class macro program variable;

[0063] #12 → #25: Transmit the Y-axis measurement coordinate to the second-class macro program variable;

[0064] #14 → #24: Transmit the Z-axis measurement coordinate to the second-class macro program variable;

[0065] #15 → #23: Transmit the tool radius compensation value to the second-class macro program variable;

[0066] #16 → #22: Transmit the tool length compensation value to the second-class macro program variable.

[0067] In the measurement calibration stage, by calling the main program O6101, the probe reference data can be written into the user variable range #656 - #675; after entering the online measurement stage, execute O6009 / O6107 to trigger the probe to collect coordinates and store them in the common variable range #100 - #120.

[0068] The compensation calculation method is: Compare the calibration value with the measured value through the mapped variables, generate the compensation amount and write it into the common variable range #121 - #147.

[0069] The dynamic correction method is as follows: The Jingdiao JD50 numerical control system calls the corresponding variables in the common variable range #121 - #147 in real time to correct the tool path.

[0070] Through the adaptability improvement carried out by the above method process, the present invention enables the Jingdiao JD50 numerical control system to directly perform measurement correction control on the Jingdiao machine tool based on the Mastercam software; it not only solves the problems of low efficiency and unstable quality existing in the traditional processing method, but also further promotes the development of the automated processing technology of the domestic equipment system. Especially in the aspects of batch production processing and the application of flexible automated production lines, the effect is particularly remarkable, showing a broad application prospect.

Claims

1. An automatic measurement and correction method for precision engraving machine tools based on Mastercam software, characterized in that: The steps include: S1. Develop the post-processing program of Mastercam software and make it suitable for Jingdiao JD50 CNC system; S2. After completing the adaptation, further configure the measurement logic code of the Jingdiao JD50 CNC system; S3. Based on the configured measurement logic code, use Mastercam software to generate the main machining program, and configure the second-class user macro program interface in the main machining program; the Jingdiao JD50 CNC system drives the Jingdiao machine tool to perform probe calibration, online measurement and tool compensation operations through variable mapping.

2. The automatic measurement and correction method for precision engraving machine tools according to claim 1 is characterized in that: In step S1, the development and adaptation of the post-processing program specifically includes: S11, defining a common variable interval, where the common variable interval is used to store temporary data during the measurement correction process; S12, allocating a subroutine number interval, the subroutine number interval is used to call the measurement macro program; S13, setting probe calibration information and storing it in the user variable interval; S14. Match the probe tool change code, spindle orientation code and reference point return code of the Jingdiao machine tool to the Jingdiao JD50 CNC system.

3. The automatic measurement and correction method for precision engraving machine tools according to claim 2 is characterized in that: In step S11, the common variable interval is defined as No. 100 to No. 147, wherein No. 100 to No. 120 are used to store probe trigger coordinate data, and No. 121 to No. 147 are used to store tool compensation value data; In step S12, the subroutine number range is from 6001 to 6207, of which 6001 to 6100 are used for probe calibration macro programs, and 6101 to 6207 are used for tool measurement and correction macro programs; In step S13, the user variable interval is from No. 656 to No. 675, wherein No. 656 to No. 665 store the probe length calibration data, and No. 666 to No. 675 store the probe radius calibration data.

4. The automatic measurement and correction method for precision engraving machine tools according to claim 1 is characterized in that: In step S2, the measurement logic code of the Jingdiao JD50 CNC system is configured, which specifically includes: S21, modify the system print code to DPRNT line format; S22, setting the system alarm parameter to the first preset number, and shielding the parameter corresponding to the second preset number; S23, add the pause pre-reading code M12 and the close pre-reading code M13; S24, bind the probe trigger signal and the jump signal channel to form a closed-loop measurement logic.

5. The automatic measurement and correction method for precision engraving machine tools according to claim 4 is characterized in that: In step S22, the system alarm parameter is set to 2402, and parameter 3004 is shielded at the same time; the system alarm parameter 2402 is associated with the probe overtravel alarm signal, and an alarm is triggered when the probe measurement value exceeds the threshold set in the user variable interval; In step S23, the pause pre-reading code M12 is used to pause the system pre-reading buffer before the probe is triggered, and the close pre-reading code M13 is used to restore the pre-reading logic after the measurement is completed; In step S24, the jump signal channel includes an input port X10.1 and an output port Y10.5, which are used to receive a probe trigger signal and send a measurement completion signal respectively.

6. The automatic measurement and correction method for precision engraving machine tools according to claim 1 is characterized in that: In step S3, a second-class user macro program interface is configured in the main processing program, specifically: modifying the preset macro parameter transfer rules of the main processing program, and mapping multiple preset first-class macro program variables to corresponding multiple second-class macro program variables.

7. The automatic measurement and correction method for precision engraving machine tools according to claim 6 is characterized in that: The preset machining main programs include main programs O6101, O6009 and O6107; the first-class macro program variables No. 10, No. 12, No. 14, No. 15 and No. 16 are mapped to the second-class macro program variables No. 26, No. 25, No. 24, No. 23 and No. 22 respectively; After the mapping is completed, Mastercam software is used to generate the main processing program for the Jingdiao JD50 CNC system to drive the Jingdiao machine tool to move.

8. The automatic measurement and correction method for precision engraving machine tools according to claim 7 is characterized in that: The first-class macro program variable No. 10 is mapped to the second-class macro program variable No. 26 for transmitting the X-axis measurement coordinates; the first-class macro program variable No. 12 is mapped to the second-class macro program variable No. 25 for transmitting the Y-axis measurement coordinates.

9. The automatic measurement and correction method for precision engraving machine tools according to claim 7 is characterized in that: The first-class macro program variable No. 14 is mapped to the second-class macro program variable No. 24 for transmitting the Z-axis measurement coordinates; the first-class macro program variable No. 15 is mapped to the second-class macro program variable No. 23 for transmitting the tool radius compensation value.

10. The automatic measurement and correction method for precision engraving machine tools according to claim 7, characterized in that: The first-class macro program variable No. 16 is mapped to the second-class macro program variable No. 22, which is used to transfer the tool length compensation value and compare it with the calibration data in the user variable to generate the correction amount.

Citation Information

Cited By

  • Length measuring device for numerical control machine tool

    CN224575243U