Machining program conversion system, controller, machining center, method and storage medium

By processing program conversion systems, analyzing and converting instructions from different CNC systems, the problem of incompatibility of different CNC systems is solved, the system is universal, and the user can seamlessly migrate programming languages.

CN119310926APending Publication Date: 2025-01-14GENESIS EQUIP (XIAN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411429473.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-10-14
Publication Date
2025-01-14

AI Technical Summary

Technical Problem

The instruction systems of different CNC systems are incompatible, which causes users to spend time releasing and programming when using CNC machine tools of different CNC systems, reducing the universality of the system.

Method used

Provide a processing program conversion system, including a parsing module, a code rule library, a conversion algorithm library, and a program management and output module, which can receive the initial processing program, parse and convert it into a program adapted to the target programming language, and analyze the module's The submodule processes G code, tool compensation, interpolation code and macro processing, and combines the code rule library and the conversion algorithm library to achieve cross-system conversion.

Benefits of technology

It realizes the conversion of the initial processing program input by the user into a target program adapted to the current CNC system, improving the universality of the CNC system, so that users can run normally even if they use an unfit programming language.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119310926A_ABST
    Figure CN119310926A_ABST
Patent Text Reader

Abstract

The invention provides a machining program conversion system, a controller, a machining center, a method and a storage medium. The machining program conversion system comprises an analysis module used for receiving an initial machining program and a code rule base with instruction code feature sets of at least two numerical control systems. The conversion algorithm library is used for storing at least two conversion rules for converting one machining program into another machining program; the program management and output module is used for converting the initial machining program received by the analysis module into a target machining program; wherein the conversion algorithm library is respectively coupled with the analysis module and the code rule library, and the program management and output module is respectively coupled with the code rule library and the conversion algorithm library. By adopting the processing program conversion system in the embodiment of the invention, the processing program can be normally operated even if a user compiles the processing program by adopting a programming language which is not matched with the current numerical control system, so that the universality of the numerical control system is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the field of machine tool technology, and in particular to a machining program conversion system, a controller, a machining center, a method and a storage medium. Background Art

[0002] CNC machine tools use CNC systems to control the spindle to process workpieces. There are many different CNC systems used in CNC machine tools on the market, such as FANUC CNC system, Mitsubishi CNC system, SIEMENS CNC system or Huazhong CNC system.

[0003] Although more and more CNC systems are working towards the direction of open CNC systems, there is still the problem of incompatibility between the instruction systems of different CNC systems. After long-term use, users may only be accustomed to the programming operation of a certain CNC system, but in some cases they need to operate a CNC machine tool equipped with an unfamiliar CNC system. Therefore, how to improve the versatility of the CNC system equipped on the CNC machine tool has become a technical problem that needs to be solved urgently. Summary of the invention

[0004] The embodiments of the present application are intended to solve at least one of the existing technical problems. To this end, the embodiments of the present application provide a machining program conversion system, a controller, a machining center, a method and a storage medium to improve the versatility of a numerical control system.

[0005] To this end, the present application provides the following technical solutions:

[0006] A first aspect of an embodiment of the present application provides a processing program conversion system, comprising:

[0007] A parsing module, used for receiving an initial processing program;

[0008] A code rule base, including at least two instruction code feature sets of numerical control systems;

[0009] a conversion algorithm library, coupled to the analysis module and the code rule library respectively, wherein the conversion algorithm library stores at least two conversion rules for converting one processing program into another processing program; and

[0010] The program management and output module is coupled to the code rule library and the conversion algorithm library respectively, and is used to convert the initial processing program received by the analysis module into a target processing program.

[0011] Furthermore, the parsing module includes:

[0012] The G code interpretation submodule is used for interpreting the processing instructions of the received initial processing program, extracting features, and integrating and generating a data table;

[0013] A tool compensation processing submodule, for integrating and analyzing the tool compensation information in the received initial machining program;

[0014] An interpolation code processing submodule, used to screen interpolation algorithms with the same meaning and encapsulate them; and

[0015] The macro processing submodule is used for extracting features of the macro program in the received initial processing program and classifying the data.

[0016] Furthermore, the analysis module also includes:

[0017] The program structure checking submodule is used to check the structure errors of the received initial processing program, and to check the syntax errors, lexical errors and semantic errors of the received initial processing program.

[0018] Furthermore, the conversion algorithm library includes a data preprocessing algorithm sub-library, a feature extraction algorithm sub-library and a feature allocation algorithm sub-library;

[0019] The data preprocessing algorithm sub-library is at least used for preprocessing of absolute coordinates and incremental coordinates, conversion between workpiece coordinate system and machine tool coordinate system, preprocessing of interpolation operation or preprocessing of tool compensation;

[0020] The feature extraction algorithm sub-library is used to extract feature information of program statements of the initial machining program, and search the code rule library for an instruction code feature set matching the feature information, and search the conversion algorithm library for a conversion rule matching the feature information;

[0021] The feature allocation algorithm sub-library is used to generate a mapping relationship between program statements before and after conversion according to the conversion rules, and replace or change statements in the initial processing program based on the mapping relationship.

[0022] Furthermore, the program management and output module also includes:

[0023] a program management submodule, coupled to the conversion algorithm library, for adding or deleting conversion algorithms to the conversion algorithm library by programming or script files; and

[0024] The program output submodule is coupled to the code rule library and is used to convert the initial processing program received by the analysis module into the target processing program.

[0025] A second aspect of an embodiment of the present application provides a controller applied to a machining center, the controller having a machining program input interface and storing a machining program conversion system as described in any of the preceding embodiments, the machining program conversion system receiving the initial machining program to be converted through the machining program input interface.

[0026] Furthermore, the controller also has a display panel, and the display panel is used to display the real-time progress of the processing program conversion system converting the initial processing program into the target processing program.

[0027] A third aspect of the embodiments of the present application provides a machining center, which comprises a machining device and a controller as described in any of the aforementioned embodiments, wherein the controller is used to control the operation of the machining device.

[0028] A fourth aspect of the embodiments of the present application provides a machining program conversion method, wherein the machining program conversion method uses the machining program conversion system in any of the aforementioned embodiments, and the machining program conversion method includes:

[0029] receiving the initial processing program to be converted, interpreting processing instructions and extracting features of the initial processing program, and integrating and generating a data table; and

[0030] The data table is read, and the instruction code feature set in the code rule library and the conversion rules in the conversion algorithm library are called to convert the initial processing program into the target processing program.

[0031] The fifth aspect of the embodiments of the present application provides a computer-readable storage medium, in which a computer program is stored, and the computer program includes program instructions, which are suitable for loading by a processor to execute the steps of the machining program conversion method in any of the corresponding embodiments described above.

[0032] A sixth aspect of the embodiments of the present application provides a computer program product, which includes program instructions, and the program instructions are suitable for loading by a processor to execute the steps of the processing program conversion method in any of the corresponding embodiments described above.

[0033] The processing program conversion system in the embodiment of the present application has at least the following technical effects: the processing program conversion system runs the program instructions in the parsing module, the code rule library, the conversion algorithm library, and the program management and output module, and converts the initial processing program input by the user into a target processing program compatible with the programming language used by the current numerical control system, so that even if the user uses a programming language that is not compatible with the current numerical control system to compile the processing program, it can still run normally, thereby improving the versatility of the numerical control system. The above-mentioned other aspects in the embodiment of the present application also have at least the technical effects of the processing program conversion system, which will not be repeated here.

[0034] Additional aspects and advantages of the present application will be partially given in the following description. Thus, in part, they will become apparent from the following description or will be understood through the practice of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 A schematic diagram of the architecture of a processing program conversion system provided in some embodiments of the present application;

[0036] Figure 2 A flowchart of a processing program conversion method provided for some embodiments of the present application. DETAILED DESCRIPTION

[0037] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments of the present application or the description of the prior art will be briefly introduced below.

[0038] Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, without paying creative work, drawings of other embodiments can also be obtained according to the technical solutions shown in these drawings.

[0039] It should be understood that the "plurality" mentioned herein refers to two or more than two. In the description of this application, unless otherwise specified, " / " means or, for example, "A / B" means A or B; "and / or" in this article is only a description of the association relationship of the associated objects, which means that there can be three kinds of relationships, for example, "A and / or B" can mean: A exists alone, A and B exist at the same time, B exists alone, etc.

[0040] In addition, in order to clearly describe the technical solutions of the embodiments of the present application, in the embodiments of the present application, expressions such as "first" or "second" are used to distinguish the same items or similar items with substantially the same functions and effects. Those skilled in the art can understand that expressions such as "first" and "second" do not limit the quantity and execution order, and expressions such as "first" and "second" do not necessarily mean that they are different.

[0041] Before explaining the embodiments of the present application in detail, the application scenarios of the embodiments of the present application are introduced.

[0042] In the current CNC machine tool industry, different CNC machine tool manufacturers may use different CNC systems. However, the command systems and operating interfaces of different CNC systems usually differ to a certain extent, making it difficult for users to skillfully use the command systems of various CNC systems for programming. For example, in the Mitsubishi CNC system, "SQR" means square root. However, in CNC systems such as FANUC, "SQRT" is used to represent square root, so that after users have mastered the programming of a certain CNC system, they need to spend time relearning when facing a new CNC system. The technical solution provided in the embodiments of the present application is intended to solve the above problems to a certain extent.

[0043] In the embodiments of the present application, the coupling between program modules includes the situation where one program module calls another program module, the situation where the input data of one program module depends on the output result of another program module, and the situation where the relationship between two program modules is an inheritance relationship, a composition relationship, or an implementation relationship.

[0044] Please see Figure 1 Some embodiments of the first aspect of the present application provide a processing program conversion system, which is used to convert an initial processing program input by a user into a target processing program, for example, converting the program code of the initial processing program compiled in the programming language of the Mitsubishi numerical control system into the program code of the target processing program compiled in the programming language of the SIEMENS numerical control system. Figure 1 As shown, the machining program conversion system includes a parsing module 10 , a code rule library 20 , a conversion algorithm library 30 and a program management and output module 40 .

[0045] The analysis module 10 is used to receive an initial machining program, which is input by a user and is compiled in a programming language different from that of the target machining program, which is the same as the programming language used by the numerical control system of the numerical control machine tool.

[0046] The code rule base 20 includes instruction code feature sets of at least two numerical control systems, for example, instruction code feature sets of multiple numerical control systems including Mitsubishi numerical control system and SIEMENS numerical control system.

[0047] The conversion algorithm library 30 is coupled with the analysis module 10 and the code rule library 20 respectively, and the conversion algorithm library 30 stores at least two conversion rules for converting one machining program into another machining program. The conversion algorithm library 30 also stores at least two conversion rules for converting one machining program into another machining program. For example, the conversion algorithm library 30 may store a first conversion rule for converting a machining program code compiled in the programming language of the A numerical control system into a machining program code compiled in the programming language of the B numerical control system and a third conversion rule for converting a machining program code compiled in the programming language of the C numerical control system into a machining program code compiled in the programming language of the D numerical control system. It may also store a first conversion rule for converting a machining program code compiled in the programming language of the A numerical control system into a machining program code compiled in the programming language of the B numerical control system and a second conversion rule for converting a machining program code compiled in the programming language of the B numerical control system into a machining program code compiled in the programming language of the A numerical control system.

[0048] The program management and output module 40 is coupled to the code rule library 20 and the conversion algorithm library 30 respectively, and is used to convert the initial processing program received by the analysis module 10 into a target processing program. The program management and output module 40 calls the relevant instruction code feature set of the code rule library 20 and the corresponding conversion rules of the conversion algorithm library 30 to convert the initial processing program code input by the user into the target processing program code.

[0049] The machining program conversion system in the embodiment of the present application can be applied to CNC machine tools such as machining centers. The machining program conversion system runs the program instructions in the parsing module 10, the code rule library 20, the conversion algorithm library 30, and the program management and output module 40 to convert the initial machining program input by the user into a target machining program compatible with the programming language used by the current CNC system, so that even if the user uses a programming language that is not compatible with the current CNC system to compile the machining program, it can still run normally.

[0050] For further information, see Figure 1 In some embodiments, the parsing module 10 includes a G-code interpretation submodule 11 , a tool compensation processing submodule 12 , an interpolation code processing submodule 13 and a macro processing submodule 14 .

[0051] The G code interpretation submodule 11 is used for processing instruction interpretation and feature extraction of the received initial processing program, and integrates and generates a data table. The same G code in different CNC systems may have different meanings. For example, "G70" in the FANUC CNC system represents a finishing cycle, while "G70" in the SIEMENS CNC system represents an imperial size; the instruction codes representing the same meaning in different CNC systems may also be different. For example, "G00" in the FANUC CNC system represents rapid movement, while "G0" in the SIEMENS CNC system represents rapid movement. After receiving the initial processing program input by the user, the G code interpretation submodule 11 in the parsing module 10 identifies the CNC system to which it belongs and interprets the instructions. For example, after comprehensively judging that it belongs to the FANUC CNC system based on multiple instruction statements, the G code interpretation submodule 11 interprets "G70" in the initial processing program as a "finishing cycle". The G code interpretation submodule 11 extracts keyword features in the initial machining program, such as "G70" in "G70P100 Q160", the starting segment number "100" and the ending segment number "160". The G code interpretation submodule 11 also integrates the keyword features and associated statements that need to be converted into a data table, for example, the keyword features and associated statements, i.e., the program statements in the program segment number 100 to the program segment number 160, into a data table, and the data table also includes the meaning of the ISO G code. After the program management and output module 40 calls or reads the above-mentioned feature statement data table, the conversion algorithm library 30 and the code rule library 20, it converts them into a target machining program compiled according to the programming language of the target numerical control system.

[0052] The tool compensation processing submodule 12 is used to integrate and analyze the tool compensation information in the received initial machining program. The tool compensation function in the machining program is very necessary and widely used, so the analysis module 10 is specially set up with the tool compensation processing submodule 12 for the analysis of the program statements involved in the tool compensation function. Tool compensation is usually divided into two categories: tool length compensation and tool radius compensation. Therefore, the tool compensation processing submodule 12 integrates and analyzes the tool compensation information in the received initial machining program and also divides it into two categories: tool length compensation information and tool radius compensation information. For example, when the tool compensation processing submodule 12 recognizes that the program statement of the received initial machining program contains "G43" or "G44", it is classified as tool length compensation information and its meaning is explained; and when it is recognized that the program statement of the received initial machining program contains "G41" or "G42", it is classified as tool radius compensation information and its meaning is explained. The integrated analysis of the tool compensation processing submodule 12 at least includes the classification of tool compensation, and the interpretation of the meaning of the program statement after comparing the ISO tool compensation form.

[0053] The interpolation code processing submodule 13 is used to screen interpolation algorithms with the same meaning and encapsulate them. Specifically, the interpolation code processing submodule 13 compares the meaning of the ISO interpolation code and encapsulates multiple interpolation algorithms with the same meaning for calling. The interpolation code processing submodule 13 classifies and encapsulates according to the type of interpolation algorithm, such as the straight line function method, the extended digital integration method, the double digital integration interpolation method, the angle approximation arc interpolation method, the point-by-point comparison method or the comparison integration method.

[0054] The macro processing submodule 14 is used to extract the features of the macro program in the received initial processing program and classify the data. For example, if the macro processing submodule 14 recognizes that the program statement contains the variable identifier "#+(number)" or "R+(number)", and there is only one assignment identifier "=" in the statement (the case where two equal signs are used together "==" does not belong to assignment), it can be determined as a macro program statement. Based on this, the macro processing submodule 14 extracts features such as variable type, variable name, and assigned parameter value, and classifies the extracted features according to the variable type.

[0055] For common and important program contents in CNC machining programs, submodules such as G-code interpretation submodule 11, tool compensation processing submodule 12, interpolation code processing submodule 13 and macro processing submodule 14 are specially set up to handle tasks such as feature extraction, classification, integration and packaging before program conversion, so as to make the program conversion of the entire machining program conversion system more efficient.

[0056] For further information, see Figure 1 In some embodiments, the parsing module 10 also includes a program structure checking submodule 15, which is used to check for structural errors in the received initial processing program, as well as to check for grammatical errors, lexical errors and semantic errors in the received initial processing program.

[0057] Structural errors include mutually exclusive errors between function codes in the entire program or a program segment: at least two G codes of the same group appear in the same program segment; contradictory dimension codes appear in the same program segment; and M codes appear in excess in the same program segment. A statement in the initial machining program input by the user that only contains the program number but lacks the program content can also be considered a structural error. For example, a program statement is "N070", which lacks program content. Syntactic errors include situations where the program segment format is not standardized, such as using address R programming when the machining trajectory is a full circle, or not specifying either the arc coordinates or the radius in the circular interpolation state. Lexical errors include situations where instructions that cannot be recognized by the code rule library 20 appear, such as the "GM" instruction that is neither a G code instruction nor an M code instruction. Semantic errors include situations where the spindle has not stopped before the tool change, tool compensation has not been canceled before the tool change, and the tool change instruction is after the new tool is used for machining.

[0058] Checking the relevant errors of the initial processing program before the processing program conversion can reduce unnecessary conversion work. The processing program conversion system in some embodiments of the present application not only checks program structure errors, but also checks syntax errors, lexical errors, and semantic errors, making the checking of relevant errors of the initial processing program more comprehensive.

[0059] Furthermore, in some embodiments, the conversion algorithm library 30 includes a data preprocessing algorithm sub-library 31 , a feature extraction algorithm sub-library 32 , and a feature allocation algorithm sub-library 33 .

[0060] The data preprocessing algorithm sub-library 31 is at least used for preprocessing absolute coordinates and incremental coordinates, converting workpiece coordinate system and machine tool coordinate system, preprocessing interpolation operation or preprocessing tool compensation. Specifically, the data preprocessing algorithm sub-library 31 can be used for preprocessing absolute coordinates and incremental coordinates to convert them into coordinate information that can be recognized by the current numerical control system; the data preprocessing algorithm sub-library 31 can also use programmable zero offset instructions to convert between the workpiece coordinate system and the machine tool coordinate system; the data preprocessing algorithm sub-library 31 can also be used to preprocess interpolation operations to obtain data required for interpolation calculations; and the data preprocessing algorithm sub-library 31 can also be used to preprocess tool compensation to obtain data required for tool compensation calculations.

[0061] The feature extraction algorithm sub-library 32 is used to extract the feature information of the program statements of the initial processing program, and search the code rule library 20 for the instruction code feature set that matches the feature information, and search the conversion algorithm library 30 for the conversion rules that match the feature information, waiting for the subsequent replacement or change of the program statements.

[0062] The feature allocation algorithm sub-library 33 is used to generate a mapping relationship between program statements before and after conversion according to the conversion rules, and replace or change certain statements in the initial processing program based on the mapping relationship.

[0063] Through the synergistic effect of the three sub-libraries, namely the data preprocessing algorithm sub-library 31, the feature extraction algorithm sub-library 32 and the feature allocation algorithm sub-library 33, the initial machining program is relatively efficiently and accurately converted into a target machining program adapted to the current numerical control system.

[0064] Furthermore, in some embodiments, the program management and output module 40 includes a program management submodule 41 and a program output submodule 42. The program management submodule 41 is coupled to the conversion algorithm library 30 and is used to add or delete conversion algorithms to the conversion algorithm library 30 by programming or script files; the program output submodule 42 is coupled to the code rule library 20 and is used to convert the initial processing program received by the parsing module 10 into a target processing program.

[0065] The conversion algorithm in the conversion algorithm library 30 in the machining program conversion system is difficult to cover or cope with the conversion requirements of the program codes of any two numerical control systems, so it is necessary to add a new conversion algorithm to meet the new machining program conversion requirements. In some cases, it may be necessary to delete the conversion algorithm. The program management submodule 41 in the embodiment of the present application can add or delete conversion algorithms to the conversion algorithm library 30 by programming or script files to meet such requirements. Programming languages ​​are roughly divided into two categories: compiled languages ​​and interpreted languages. The former can add or delete conversion algorithms in the conversion algorithm library 30 by programming, and the latter can add or delete conversion algorithms in the conversion algorithm library 30 by script files.

[0066] It is understandable that, in some embodiments, the program output submodule 42 is coupled not only to the code rule library 20, but also to the conversion algorithm library 30. The program output submodule 42 can not only convert the initial processing program received by the analysis module 10 into a target processing program, but also further compile or interpret the target processing program into a data form that can be recognized by the current machine tool and store it in the corresponding decoding result buffer storage unit. For example, the program output submodule 42 can not only convert the processing program code compiled in the programming language of the A numerical control system into the processing program code compiled in the programming language of the B numerical control system, but also further convert the processing program code compiled in the programming language of the B numerical control system into a data form that can be recognized by the current machine tool. The program output submodule 42 integrates the compilation unit or interpretation unit in the traditional numerical control system, and directly outputs the data form that can be recognized by the current machine tool.

[0067] In some embodiments, the processing program conversion system further includes a user interface module, which is used to display an operation interface of a numerical control system adapted to the initial processing program. For example, the user inputs an initial processing program compiled in the programming language of numerical control system A, and the user interface module also displays a common operation interface of numerical control system A, but the program management and output module 40 outputs a target processing program compiled in the programming language of numerical control system B. The user can still face the operation interface of the numerical control system to which he is accustomed, but the machine tool operates normally with the processing program of another numerical control system. It is understandable that the operation interface can also display the real-time progress of the conversion from the initial processing program to the target processing program.

[0068] Some embodiments of the second aspect of the present application provide a controller for a machining center, wherein the controller has a machining program input interface and stores a machining program conversion system according to any of the above embodiments, wherein the machining program conversion system receives the initial machining program to be converted through the machining program input interface.

[0069] Furthermore, in some embodiments, the controller also has a display panel, and the display panel is used to display the real-time progress of the processing program conversion system converting the initial processing program into the target processing program.

[0070] Some embodiments of the third aspect of the present application provide a machining center, wherein the machining center comprises a machining device and a controller as described in any of the above embodiments, wherein the controller is used to control the action of the machining device.

[0071] Some embodiments of the fourth aspect of the present application provide a method for converting a machining program. The method for converting a machining program uses the machining program conversion system in any of the aforementioned embodiments. Figure 2 As shown, the machining program conversion method includes steps S110 to S120:

[0072] Step S110: receiving the initial processing program to be converted, interpreting the processing instructions and extracting the features of the initial processing program, and integrating and generating a data table. It is understandable that the initial processing program to be converted comes from the user input, wherein the user inputs the initial processing program to be converted in the following ways: manual program input (including on-site programming input), storage medium input, and network input. Manual program input is to manually input the CNC processing program into the operation panel or handheld programmer of the CNC machine tool, storage medium input includes inputting the CNC processing program stored in a storage medium such as a disk or a U disk into the CNC machine tool control system through a card reader or a USB interface, and network input includes inputting the CNC processing program into the CNC machine tool control system through a computer network such as a local area network or a wide area network.

[0073] Step S120: reading the data table, and calling the instruction code feature set in the code rule library 20 and the conversion rules in the conversion algorithm library 30 to convert the initial processing program into the target processing program.

[0074] The processing program conversion method in the embodiment of the present application converts the initial processing program input by the user into a target processing program compatible with the programming language used by the current numerical control system, so that even if the user uses a programming language that is not compatible with the current numerical control system to compile the processing program, it can still run normally.

[0075] Furthermore, in some embodiments, step S110 further includes step S112, step S114 and step S116:

[0076] Step S112: Identify each statement in the initial processing program.

[0077] Step S114: Determine the category of the program statement based on the information of the program statement that is read. It is not difficult to understand that determining the category of the program statement does not require all the information of the program statement, but only requires extracting key information that reflects the characteristics of the program statement.

[0078] Step S116: If it is determined that the program statement belongs to a macro program, then the program statement is subjected to macro feature extraction and data classification. Specifically, the extracted macro features include features such as variable type, variable name, and assigned parameter value, and the extracted macro features are classified according to the variable type;

[0079] If it is determined that the program statement involves tool compensation information, the tool compensation information is integrated and analyzed. Specifically, the integrated analysis includes the classification of tool compensation, and the interpretation of the meaning of the program statement after comparing the ISO tool compensation format;

[0080] If it is determined that the program statement involves interpolation information, the interpolation code processing submodule is called for processing, wherein the interpolation code processing submodule can compare the meaning of the ISO interpolation code and classify and package multiple interpolation algorithms with the same meaning for calling.

[0081] Before converting the machining program, determine whether there is tool compensation information, interpolation information, and program statements of parametric programming macro programs, and perform targeted feature extraction, classification, or integration tasks to make the conversion of the entire machining program more efficient.

[0082] In some embodiments, step S112 is preceded by step S111:

[0083] Step S111: Check the structural errors of the received initial processing program, and check the grammatical errors, lexical errors and semantic errors in the received initial processing program. Checking the relevant errors of the initial processing program before the processing program conversion helps to reduce unnecessary conversion work. It is understandable that step S111 may also include: if there are structural errors, grammatical errors, lexical errors or semantic errors in the initial processing program, outputting prompt information of the relevant errors.

[0084] In some embodiments, step S120 includes step S122, step S124, and step S126:

[0085] Step S122: Preprocess the absolute coordinates and incremental coordinates to convert them into coordinate information that can be recognized by the current CNC system; convert the workpiece coordinate system into the machine tool coordinate system; preprocess the interpolation operation to obtain the data required for the interpolation calculation; and preprocess the tool compensation to obtain the data required for the tool compensation calculation.

[0086] Step S124: extracting feature information of program statements of the initial machining program, searching the code rule library 20 for an instruction code feature set matching the feature information, and searching the conversion algorithm library 30 for a conversion rule matching the feature information.

[0087] Step S126: Generate a mapping relationship between program statements before and after conversion according to the conversion rule, and replace or change certain statements in the initial processing program based on the mapping relationship.

[0088] In some embodiments, step S120 further includes step S128:

[0089] Step S128: converting the received initial machining program into a target machining program and outputting the program. Further, step S128 also includes: compiling or interpreting the target machining program into a data format that can be recognized by the machine tool, thereby integrating the decoding link in the numerical control system.

[0090] In some embodiments, the processing program conversion method further includes: adding or deleting code rules in the conversion algorithm library 30 according to the received program or script file, thereby allowing the user to add or delete conversion algorithms to meet the needs of updating the code rules for processing program conversion.

[0091] In some embodiments, the machining program conversion method further includes: providing a numerical control system operation interface adapted to the program language of the initial machining program, and displaying the real-time progress of the conversion from the initial machining program to the target machining program.

[0092] Some embodiments of the fifth aspect of the present application provide a computer-readable storage medium, in which a computer program is stored, and the computer program includes program instructions, which are suitable for loading by a processor to execute the steps of the processing program conversion method in any of the corresponding embodiments described above.

[0093] For technical details not disclosed in the computer-readable storage medium embodiment involved in this application, please refer to the description of any embodiment of the processing program conversion method in the second aspect of the embodiment of this application. As an example, the program instructions can be deployed on a computer device, or executed on multiple computer devices located in one location, or, executed on multiple computer devices distributed in multiple locations and interconnected by a communication network.

[0094] Some embodiments of the sixth aspect of the present application provide a computer program product, which includes program instructions, and the program instructions are suitable for loading by a processor to execute the steps of the processing program conversion method in any corresponding embodiment of the foregoing text.

[0095] In any of the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loading and executing computer program instructions on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network or other programmable device. The computer instruction can be stored in a computer-readable storage medium or transmitted by a computer-readable storage medium. The computer instruction can be transmitted from a website site, a computer, a server or a data center to another website site, a computer, a server or a data center by wired (for example, coaxial cable, optical fiber, digital line (DSL)) or wireless (for example, infrared, wireless, microwave, etc.) mode. The computer-readable storage medium can be any available medium that a computer can access or a data processing device such as a server, a data center, etc. that contains one or more available media integrated. Available media can be magnetic media (for example, floppy disk, hard disk, tape), optical media (for example, DVD), or semiconductor media (for example, solid-state drive (Solid State Disk, SSD)) and the like.

[0096] The above examples are only preferred embodiments of the present application, and certainly cannot be used to limit the scope of rights of the present application. Therefore, equivalent changes made according to the claims of the present application still fall within the scope covered by the present application.

Claims

1. A processing program conversion system, characterized in that: include: A parsing module, used for receiving an initial processing program; A code rule base, including at least two instruction code feature sets of numerical control systems; a conversion algorithm library, coupled to the analysis module and the code rule library respectively, wherein the conversion algorithm library stores at least two conversion rules for converting one processing program into another processing program; and The program management and output module is coupled to the code rule library and the conversion algorithm library respectively, and is used to convert the initial processing program received by the analysis module into a target processing program.

2. The processing program conversion system according to claim 1, characterized in that: The parsing module comprises: The G code interpretation submodule is used for interpreting the processing instructions of the received initial processing program, extracting features, and integrating and generating a data table; A tool compensation processing submodule, for integrating and analyzing the tool compensation information in the received initial machining program; An interpolation code processing submodule, used to screen interpolation algorithms with the same meaning and encapsulate them; and The macro processing submodule is used for extracting features of the macro program in the received initial processing program and classifying the data.

3. The processing program conversion system according to claim 2, characterized in that: The parsing module also includes: The program structure checking submodule is used to check the structure errors of the received initial processing program, and to check the syntax errors, lexical errors and semantic errors of the received initial processing program.

4. The machining program conversion system according to any one of claims 1 to 3, characterized in that: The conversion algorithm library includes a data preprocessing algorithm sub-library, a feature extraction algorithm sub-library and a feature allocation algorithm sub-library; The data preprocessing algorithm sub-library is at least used for preprocessing of absolute coordinates and incremental coordinates, conversion between workpiece coordinate system and machine tool coordinate system, preprocessing of interpolation operation or preprocessing of tool compensation; The feature extraction algorithm sub-library is used to extract feature information of program statements of the initial machining program, and search the code rule library for an instruction code feature set matching the feature information, and search the conversion algorithm library for a conversion rule matching the feature information; The feature allocation algorithm sub-library is used to generate a mapping relationship between program statements before and after conversion according to the conversion rules, and replace or change statements in the initial processing program based on the mapping relationship.

5. The machining program conversion system according to any one of claims 1 to 3, characterized in that: The program management and output module also includes: a program management submodule, coupled to the conversion algorithm library, for adding or deleting conversion algorithms to the conversion algorithm library by programming or script files; and The program output submodule is coupled to the code rule library and is used to convert the initial processing program received by the analysis module into the target processing program.

6. A controller for a machining center, characterized in that: The controller has a machining program input interface and stores a machining program conversion system according to any one of claims 1 to 5, wherein the machining program conversion system receives the initial machining program to be converted through the machining program input interface.

7. The controller for a machining center according to claim 6, characterized in that: The controller further comprises a display panel, and the display panel is used to display the real-time progress of the processing program conversion system converting the initial processing program into the target processing program.

8. A machining center, characterized in that: A processing device and a controller applied to a processing center as claimed in claim 6 or 7 are provided, wherein the controller is used to control the action of the processing device.

9. A processing program conversion method, characterized in that: Using the machining program conversion system as claimed in any one of claims 1 to 5, the machining program conversion method comprises: receiving the initial processing program to be converted, interpreting processing instructions and extracting features of the initial processing program, and integrating and generating a data table; and The data table is read, and the instruction code feature set in the code rule library and the conversion rules in the conversion algorithm library are called to convert the initial processing program into the target processing program.

10. A computer-readable storage medium, characterized in that A computer program is stored, and the computer program includes program instructions, and the program instructions are suitable for being loaded by a processor to execute the steps in the machining program conversion method as claimed in claim 9.