Automatic generation of NC code based on data drive

In CAPP and CAM systems, human-computer interaction to achieve the generation of NC code is the most common method. Usually CAPP does not provide CAM with the required machine tool equipment, machining tools, cutting speed, feed rate and other parameter information. CAM must obtain these information and enter it through human-computer interaction one by one. Finally, the NC code is obtained. This method is not only inefficient, but also prone to errors, becoming an obstacle to CIMS. In the course of researching CAD/CAPP/CAM information integration using Pro/Engineer platform, we have explored a data-driven method to automatically transfer information between CAPP and CAM, and realized automatic configuration of processing model parameters to obtain NC code. . First, the concept of data-driven files The principle of data-driven approach to a certain rule, the processing characteristics of the process described in a neutral description, the formation of a model of the characteristics of the processing process, and as a basis for the composition of data files. When the system reads this file, it will drive the system to automatically execute the feature processing described in the data file. When the file is read in, it completes the transmission of information between systems. Such a way to describe the human-computer interaction operation by data description and to realize the information transmission between systems by automatic reading of data files, the author calls it the data driving method. This method is characterized by the use of data to express human-computer interaction operations. The process of reading files is the process of information transmission and processing. This use of data files to achieve the transfer of information between systems is currently the focus of CAD/CAPP/CAM integration. Implementing Data-Driven Preconditions Feature Modeling Process Modeling The so-called patterning of feature processing refers to every feature that needs to be processed, whether it is a planar feature or a hole feature, they all have similar processing processes. In fact, when we use Pro/Engineer to process features, the process is very similar. The patterning process is as follows: Start an NC SEQUENCE, ie start processing of a machining feature. Select the type of machining feature and determine whether the machining feature is a planar, hole, or other type. The selection of the machining tool selects the appropriate tool from the standard library according to the material of the part, the type of feature, the accuracy requirement of the feature, and the rough finishing state. The choice of machining parameters, based on the existing equipment, selected tools and other factors comprehensive determination of machining parameters, and select from the machining parameter library. Selection of machining objects and relief surfaces: In Pro/Engineer, every feature or geometric element of a part can be selected from the menu. The relief surface can be obtained by setting a reasonable value in the Z-axis direction of the machining coordinate system. Tool path generation and material cutting dynamic demonstration: After completing the above work, tool path files can be generated and the tool cutting process can be dynamically demonstrated to determine whether the generated tool path is reasonable. The generated NC SEQUENCE is saved, and the complete processing of a feature is completed. The standardized tool parameters and machining parameters of the tool parameters and machining parameters are stored in the standard library in the form of data files. When needed, they can be realized by calling the file name. In order to expand the scope of application, the standard library is open-ended, and users can arbitrarily add, modify, and delete these parameters as needed, which can reduce duplicate settings, save time, and increase efficiency. Menu selection of part features In the processing of feature processing using human-computer interaction, the selection of processing features is often achieved by clicking on the feature on the screen with the mouse. When the data processing method is used to process the feature processing, it is necessary to select the features through the menu because the coordinate range of the selectable points is not easily determined. In Pro/Engineer software, each feature and every geometric element can be obtained by selecting the menu. Neutral expression rules for the processing of processing characteristics In order to make the processing of processing characteristics reasonable and sufficient, it is necessary to specify the description of the processing of processing characteristics. Combining with the features of the system software, the operation expressions of the processing process are defined as follows: Note information To express the annotation information, you can add “!” to the information you want to express. For example: ! trail file version No. ### User input user input information occupies a single row, there is no other information in this row. For example, to enter the part name Example 1, can be expressed as: Example 1 The system menu selection adds "#" to the desired menu. For example, to select the menu DONE, it is expressed as: #DONE The selection point of the mouse selection mouse is represented by the x, y coordinates, and the pressed key is added after the coordinates. The mouse has three keys, represented by L (left), M (middle), and R (right). For example, if you click the left mouse button to take a point (2.00, 3.00, it means: 2.00 3.00 L. The default system setting is to accept the system default value by making the following a blank line with the system default prompt. The 2D object is selected with @sel2d At the beginning, followed by the name of the object and its key attributes and the mouse point selection method, taking the circle dimension as an example, select the circle whose center is (0, 4), and the dimension point is (1, 1), which means: @ Sel2d CIRCLE 0 4 1 1 M Three-dimensional object selection takes @ sel view 0 as the first row, followed by the data structure information of the three-dimensional object For example, for the plane, the data structure is: typedef struct p_plane { double e1 [3] : / * U to the unit vector * / double e2 [3] : / * v to the unit vector * / double e3 [3] : / * Pointer to the plane * / double origin[3]: /* Plane's original point * / }: Assume that e1[3]={1,0,0}:e2[3]={0,1,0}:e3[3]={0,0,1}:origin[3]={0,0, 0} is expressed as: @ sel view 0 1 0 0 0 1 0 0 0 1 0 0 0 The establishment of the modeled machining process Based on the above analysis, the processing of the machining features is modeled. The man-machine interaction process of parts processed by Pro/Engineer software summed up the processing modes of common machining methods for box-type parts, which are mainly hole machining and surface machining, and drilling machining modes and bore holes in hole machining modes. Machining mode, thread hole machining mode, reaming machining mode, etc.: In the plane machining mode, there are mainly milling machining modes, grinding machining modes, etc. To specifically illustrate the establishment of a model machining process, the following takes a threaded hole machining mode as an example. Description: # NC SEQUENCE / * Start a feature processing * / #New Sequence # HOLEMAKING / * Determine the machining feature type * / # DONE # TAP / * Determine the hole feature type * / # DONE # DONE # RETRIE_E # T5 / * Determine the tool Parameters * / # DONE # RETRIE_E # T0001 / * Determine machining parameters * / # DONE # BY TIP / * Determine hole properties * / #DONE #SEL BY MENU #FIRST.PRT #SURFACE #TOPFACE #ENTER 6 /* Hole Deep input * / #SEL BY MENU #AXISI / * Hole axis selection * / #DONE SEL #DONE / RETURN #DONE #DONE/RETURN #PLAY PATH / *Tool path generation * / #DONE CL #DONE #NC CHECK / * Material Cutting Dynamic Presentation * / #RUN #DONE / RE TURN #CONFIRM #DONE / RETURN #DONE SEQ / * End Process Definition * / #CL DATA #NC SEQUENCE #16: Holemaking,Operation:POP 150 #FILE TT0001 / *Save Toolpath Files * / #DONE OUTPUT #DBMS # Determination of SAVE feature processing methods In certain manufacturing environments, certain feature processing methods are limited. Taking the characteristics of through-holes as an example, this feature can be achieved through the arrangement and combination of drilling, expanding, thick hinges, precision hinges, rough boring, and fine boring. We can define the processing method suitable for a given feature according to the requirements of the system according to the actual manufacturing environment. In the process of process decision-making, the system selects specific machining methods by reasoning on the process constraints parameters of feature types and features. As with the establishment of the feature processing method library, we have established a standard tool library and a machining parameter library. In the specific application, the content of the database can be added, modified, and deleted according to actual conditions to meet the needs of different situations.

2
Figure 1 Data Driven File Generation Diagram

Second, the data drive file generation The data drive file is produced by the process decision module (CAPP module) in the process of making a decision with the process route. When CAPP makes process decisions, each process and machining method of a machining object is determined. At the same time, the tools, machine tools, feeds, machine speeds, etc. for machining this feature are selected, and they are all input into a file. The file is a data-driven file. . It can be identified and executed by Pro/Engineer. The data-driven file generation process is shown in Figure 1. When the file is read in, the required parameters for generating the NC code are automatically transmitted to the predetermined machining model: After the file is read, the system can perform tool path demonstration and generate the NC code. After the NC code is post-processed, it can be used for machining.

2
Figure 2 shows the structure of the data driver file

Since the content of the data-driven file is structured as a single feature pattern process, neutral files are feature-based. A pattern machining of a feature in Pro/Engineer is called an NC Sequence. Several NC sequences based on the same machining coordinate system are called an Operation. A data-driven file can contain multiple Operations, and each Operation may contain multiple NC Sequences. Its content framework is shown in Figure 2. Third, the automatic reading of the data driver file and the generation of the NC code With the data driver file, you can use it to achieve the NC code generation. Reading a data driver file is accomplished by using a menu developed by Pro/Develop's file reading function. This menu is a submenu MISIL of MISC under the MAIN menu. When you enter the Pro/Engineer interface, press the TRAIL menu key, and then enter the data driver file name according to the system requirements. The file will be read automatically. The file is read in as follows: #include"prodevelop.h" #include"profiles.h" int pro_read_file_to_pro (wchar_t file_name, / *(in)The file name * / Prohandle object_ptr, / *(in) The object * / Int File_type, / * (in) The file type * /) The interface diagram for reading data driver files (omitted). After reading the file, the tool path file *.ncl containing the tool path can be obtained directly. After the tool location file is obtained, it can be converted into the recognizable NC code of the corresponding device by the post processor. IV. Conclusions This paper discusses the use of data-driven methods to achieve the automatic generation of NC code, which solves the problem of inputting information in NC programming. This method avoids the repeated input of information, maximizes the use of system information resources, ensures the smooth flow of parts information flow, and initially realizes the integration of CAD/CAPP/CAM information. Practice shows that compared with the traditional NC code generation method, this method is convenient and quick, and it can reduce errors that occur due to human-computer interaction. The generated NC code can be applied to actual processing.

VFS Powder Packing Machine

Spice Packing Machine,Seasoning Packing Machine,Detergent Packing Machine,Vfs Powder Packing Machine

DURZERD PACKAGING MACHINERY CO., LTD. , https://www.durzerdmachine.com