CN115268370B - Method for automatically drilling and riveting numerical control code to restore simulation process - Google Patents
Method for automatically drilling and riveting numerical control code to restore simulation process Download PDFInfo
- Publication number
- CN115268370B CN115268370B CN202210848523.6A CN202210848523A CN115268370B CN 115268370 B CN115268370 B CN 115268370B CN 202210848523 A CN202210848523 A CN 202210848523A CN 115268370 B CN115268370 B CN 115268370B
- Authority
- CN
- China
- Prior art keywords
- motion
- database
- data
- value
- axis
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 60
- 238000004088 simulation Methods 0.000 title claims abstract description 41
- 238000005553 drilling Methods 0.000 title claims abstract description 18
- 238000004519 manufacturing process Methods 0.000 abstract description 2
- 238000012545 processing Methods 0.000 description 4
- 238000012795 verification Methods 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000003754 machining Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000005457 optimization Methods 0.000 description 1
- 238000011084 recovery Methods 0.000 description 1
- 230000000007 visual effect Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05B—CONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
- G05B19/00—Programme-control systems
- G05B19/02—Programme-control systems electric
- G05B19/18—Numerical control [NC], i.e. automatically operating machines, in particular machine tools, e.g. in a manufacturing environment, so as to execute positioning, movement or co-ordinated operations by means of programme data in numerical form
- G05B19/4093—Numerical control [NC], i.e. automatically operating machines, in particular machine tools, e.g. in a manufacturing environment, so as to execute positioning, movement or co-ordinated operations by means of programme data in numerical form characterised by part programming, e.g. entry of geometrical information as taken from a technical drawing, combining this with machining and material information to obtain control information, named part programme, for the NC machine
- G05B19/40937—Numerical control [NC], i.e. automatically operating machines, in particular machine tools, e.g. in a manufacturing environment, so as to execute positioning, movement or co-ordinated operations by means of programme data in numerical form characterised by part programming, e.g. entry of geometrical information as taken from a technical drawing, combining this with machining and material information to obtain control information, named part programme, for the NC machine concerning programming of machining or material parameters, pocket machining
-
- G—PHYSICS
- G05—CONTROLLING; REGULATING
- G05B—CONTROL OR REGULATING SYSTEMS IN GENERAL; FUNCTIONAL ELEMENTS OF SUCH SYSTEMS; MONITORING OR TESTING ARRANGEMENTS FOR SUCH SYSTEMS OR ELEMENTS
- G05B2219/00—Program-control systems
- G05B2219/30—Nc systems
- G05B2219/32—Operator till task planning
- G05B2219/32161—Object oriented control, programming
Landscapes
- Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Geometry (AREA)
- Human Computer Interaction (AREA)
- Manufacturing & Machinery (AREA)
- General Physics & Mathematics (AREA)
- Automation & Control Theory (AREA)
- Numerical Control (AREA)
Abstract
A method for automatically drilling and riveting a simulation process by using a numerical control code includes the steps of firstly, establishing motion items of each shaft of automatic drilling and riveting in DELMIA, setting initial values, reading text information in a program file, and establishing a database containing motion types and coordinate values. Secondly, establishing simulation events in a copying mode one by one according to a database, setting coordinate values of all axes, and connecting all the simulation events to realize continuous motion. Finally, simulation is carried out in DELMIA, and the simulation process is restored. The method for restoring the simulation process by using the numerical control code can get rid of the dependence of the offline programming software special for automatic drilling and riveting: 1) The numerical control codes can be restored to the simulation process, and checked and verified again before being put into production, so that feasibility and accuracy are ensured; 2) The simulation module of the special off-line programming software is separated, and the working efficiency of off-line programming is improved.
Description
Technical Field
The invention belongs to the field of numerical control design, and provides a method for automatically drilling and riveting to restore a simulation process by numerical control codes.
Background
The automatic drilling and riveting equipment is huge, the movement mechanism is complex, the dimension is more, collision interference is easy to occur in the automatic drilling and riveting processing engineering, and serious consequences are caused. Before the automatic drilling and riveting numerical control program is applied to product processing, the feasibility and reliability of the product processing flow must be verified through strict visual simulation. The simulation results can guide optimization of the machining gesture. The simulation verification of the automatic drilling and riveting numerical control codes requires a simulation module of the special offline programming software for automatic drilling and riveting, so that the conditions of the special offline programming software limit the numerical control code simulation verification work of a large number of processing tasks and limit the offline programming work efficiency of automatic drilling and riveting.
Disclosure of Invention
In order to overcome the defects of the prior art, the invention provides a method for automatically drilling and riveting to restore a simulation process by using numerical control codes.
In order to achieve the above purpose, the invention adopts the following technical scheme:
A method for automatically drilling and riveting to restore a simulation process by a numerical control code comprises the following steps:
First, using the MoveJointsAct method in DELMIA, an initial 5-axis carriage motion term M0, a 6-axis actuator motion term N0 are established, and all axis coordinates are set to initial values.
And secondly, reading text information in the program file by using a Textreader method in the C# language, and further reading the text information into the string object S.
Thirdly, reading and judging the text information, and establishing a database R containing motion types and coordinate values, wherein the method comprises the following steps of:
① Newly creating a data value V1, a motion type value 'M' and 5-axis data which are all '0' in a database R;
② Newly creating a data value V2, a motion type value 'N' and 6-axis data which are all '0' in a database R;
③ Selecting a first piece of code content P within the text object S;
④ Judging whether the P comprises a motion value by using a Contains method of C#, deleting the P in S if the P does not comprise the motion value, otherwise, distinguishing the bracket motion from the actuator motion by using the Contains method of C#, executing step ⑤ if the bracket motion is the bracket motion, and executing step ⑥ if the actuator motion is the actuator motion;
⑤ Selecting final motion data V1 of a bracket class in a database R, reading 5-axis data in the V1, reading 5-axis data in P by using a Split method, calculating a difference value, deleting P in S if no difference value exists, creating a data value V2 in the database R if the difference value exists, recording the 5-axis data in P to V2, and deleting P in S;
⑥ Selecting final motion data V1 of an actuator class in a database R, reading 6-axis data in the V1, reading 6-axis data in P by using a Split method, calculating a difference value, deleting P in S if no difference value exists, creating a data value V2 in the database R if the difference value exists, recording 5-axis data in P to V2, and deleting P in S;
⑦ And repeatedly executing the steps ③ - ⑥ until no data exists in the text object S, and finishing the recording of the database R.
Fourthly, establishing a simulation event A by using a DELMIA software MoveJointsAct method, copying M0 and N0 motion items to A one by one according to a database R, and setting data of each axis, wherein the specific method C is as follows:
① Reading a first data value V1 in a database R;
② Reading the motion type value in V1, executing step ③ if the motion type value is M, and executing step ④ if the motion type value is N;
③ Copying M0 to the final position of A by using a COPY method, setting a 5-axis data value in V1 into M0, and deleting V1 in a database R;
④ Copying N0 to the final position of A, setting the 6-axis data value in V1 to N0, and deleting V1 in a database R;
⑤ And repeatedly executing the steps ① - ④ until no data exists in the database R, and finishing the setting of the simulation event.
Fifth, all simulation events A are linked using the DELMIA software CREATELINK method to achieve motion continuation.
And sixthly, simulating the A by using a DELMIA software ProcessSimulation method, and completing the reduction simulation process.
The key technical points of the invention are as follows:
1) Using a DELMIA software MoveJointsAct method to establish automatic drilling and riveting each shaft motion item and setting an initial value;
2) Reading text information in the program file by using a Textreader method in C# language;
3) Reading and judging the text information, and establishing a database containing motion types and coordinate values;
4) Establishing simulation events in a copying mode one by one according to a database, and setting coordinate values of all axes;
5) All simulation events are linked using the DELMIA software CREATELINK method to achieve motion continuation;
6) The simulation will be performed using the DELMIA software ProcessSimulation method, restoring the simulation process.
The method for restoring the simulation process by the numerical control code gets rid of the dependence of the offline programming software special for automatic drilling and riveting, and has the beneficial effects that:
(1) The numerical control codes can be restored to the simulation process, and the numerical control codes are checked and verified again before being put into production, so that the feasibility and the accuracy of the program codes are ensured;
(2) The simulation module separated from the special offline programming software can process the programming work and the simulation work simultaneously, so that the working efficiency of offline programming is improved.
Drawings
FIG. 1 is a flow chart of the present invention.
Detailed Description
The following describes the embodiments of the present invention further with reference to the drawings and technical schemes.
As shown in fig. 1, in this embodiment, the method for automatically drilling and riveting to restore the simulation process by using the numerical control code includes the following implementation steps:
1) Using the DELMIA software MoveJointsAct method, an initial 5-axis carriage motion term M0, a 6-axis actuator motion term N0 are established, and all axis coordinates are set to initial values.
2) The text information in the program file is read by using a method Textreader in the c# language, and then the text information is read into the string object S (method a).
3) The text information is read and judged (method B), and a database R containing the motion type and the coordinate value is established, wherein the method comprises the following steps:
① Newly creating a data value V1, a motion type value 'M' and 5-axis data which are all '0' in a database R;
② Newly creating a data value V2, a motion type value 'N' and 6-axis data which are all '0' in a database R;
③ Selecting a first piece of code content P within the text object S;
④ Judging whether the P comprises a motion value by using a Contains method of C#, deleting the P in S if the P does not comprise the motion value, otherwise, distinguishing the bracket motion from the actuator motion by using the Contains method of C#, executing step ⑤ if the bracket motion is the bracket motion, and executing step ⑥ if the actuator motion is the actuator motion;
⑤ Selecting final motion data V1 of a bracket class in a database R, reading 5-axis data in the V1, reading 5-axis data in P by using a Split method, calculating a difference value, deleting P in S if no difference value exists, creating a data value V2 in the database R if the difference value exists, recording the 5-axis data in P to V2, and deleting P in S;
⑥ Selecting final motion data V1 of an actuator class in a database R, reading 6-axis data in the V1, reading 6-axis data in P by using a Split method, calculating a difference value, deleting P in S if no difference value exists, creating a data value V2 in the database R if the difference value exists, recording 5-axis data in P to V2, and deleting P in S;
⑦ And repeatedly executing the steps ③ - ⑥ until no data exists in the text object S, and finishing the recording of the database R.
4) The simulation event A is established by using a DELMIA software MoveJointsAct method, M0 and N0 motion items are copied to A piece by piece according to a database R, and data of each axis are set, and the specific method C is as follows:
① Reading a first data value V1 in a database R;
② Reading the motion type value in V1, executing step ③ if the motion type value is M, and executing step ④ if the motion type value is N;
③ Copying M0 to the final position of A by using a COPY method, setting a 5-axis data value in V1 into M0, and deleting V1 in a database R;
④ Copying N0 to the final position of A, setting the 6-axis data value in V1 to N0, and deleting V1 in a database R;
⑤ And repeatedly executing the steps ① - ④ until no data exists in the database R, and finishing the setting of the simulation event.
5) All simulation events a were connected using DELMIA software CREATELINK method to achieve motion continuation.
6) The simulation of A is performed by using the DELMIA software ProcessSimulation method, and the recovery simulation process is completed.
The examples described above represent only embodiments of the invention and are not to be understood as limiting the scope of the patent of the invention, it being pointed out that several variants and modifications may be made by those skilled in the art without departing from the concept of the invention, which fall within the scope of protection of the invention.
Claims (1)
1. The method for automatically drilling and riveting to restore the simulation process by using the numerical control code is characterized by comprising the following steps:
The first step, an initial 5-axis bracket motion item M0 and a 6-axis actuator motion item N0 are established in DELMIA, and all axis coordinates are set as initial values;
secondly, reading text information in the program file, and further reading the text information into a string object S;
thirdly, reading and judging the text information, and establishing a database R containing motion types and coordinate values, wherein the method comprises the following steps of:
① Newly creating a data value V1, a motion type value 'M' and 5-axis data which are all '0' in a database R;
② Newly creating a data value V2, a motion type value 'N' and 6-axis data which are all '0' in a database R;
③ Selecting a first piece of code content P within the text object S;
④ Judging whether the P comprises a motion value, if the P does not comprise the motion value, deleting the P in the S, otherwise further distinguishing whether the bracket moves or the actuator moves, if the bracket moves, executing the step ⑤, and if the actuator moves, executing the step ⑥;
⑤ Selecting final motion data V1 of a bracket class in a database R, reading 5-axis data in the V1, reading 5-axis data in P, then calculating a difference value, deleting P in S if no difference value exists, creating a data value V2 in the database R if the difference value exists, recording the 5-axis data in P to V2 when the motion type is M, and deleting P in S;
⑥ Selecting final motion data V1 of an actuator class in a database R, reading 6-axis data in the V1, reading 6-axis data in P, then calculating a difference value, deleting P in S if no difference value exists, creating a data value V2 in the database R if the difference value exists, wherein the motion type is N, recording 5-axis data in P to V2, and deleting P in S;
⑦ Repeatedly executing the steps ③ - ⑥ until no data exists in the text object S, and finishing the recording of the database R;
fourth, establishing a simulation event A, copying M0 and N0 motion items to A one by one according to a database R, and setting data of each axis, wherein the specific method C is as follows:
① Reading a first data value V1 in a database R;
② Reading the motion type value in V1, executing step ③ if the motion type value is M, and executing step ④ if the motion type value is N;
③ Copying M0 to the final position of A, setting the 5-axis data value in V1 to M0, and deleting V1 in a database R;
④ Copying N0 to the final position of A, setting the 6-axis data value in V1 to N0, and deleting V1 in a database R;
⑤ Repeatedly executing the steps ① - ④ until no data exists in the database R, and finishing setting the simulation event;
Fifthly, connecting all simulation events A to realize motion continuity;
and step six, simulating the A to finish the reduction simulation process.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210848523.6A CN115268370B (en) | 2022-07-19 | 2022-07-19 | Method for automatically drilling and riveting numerical control code to restore simulation process |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202210848523.6A CN115268370B (en) | 2022-07-19 | 2022-07-19 | Method for automatically drilling and riveting numerical control code to restore simulation process |
Publications (2)
Publication Number | Publication Date |
---|---|
CN115268370A CN115268370A (en) | 2022-11-01 |
CN115268370B true CN115268370B (en) | 2024-06-18 |
Family
ID=83767666
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202210848523.6A Active CN115268370B (en) | 2022-07-19 | 2022-07-19 | Method for automatically drilling and riveting numerical control code to restore simulation process |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115268370B (en) |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103454972A (en) * | 2013-06-26 | 2013-12-18 | 厦门钨业股份有限公司 | Tool five-axis numerical control grinding automatic programming method based on UG NX API |
CN103587719A (en) * | 2013-11-11 | 2014-02-19 | 中航沈飞民用飞机有限责任公司 | Full-automatic drilling and riveting positioning method of flat workpiece |
Family Cites Families (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JP2811338B2 (en) * | 1989-12-07 | 1998-10-15 | マツダ株式会社 | NC processing data creation method and apparatus |
ATE392656T1 (en) * | 2004-06-15 | 2008-05-15 | Abb Ab | METHOD AND SYSTEM FOR OFF-LINE PROGRAMMING OF SEVERAL INTERACTING ROBOTS |
CN1588257A (en) * | 2004-09-29 | 2005-03-02 | 沈阳理工大学 | Automatic programing system and method for grenade digital control machine tool processing |
CN100343770C (en) * | 2005-09-14 | 2007-10-17 | 山东大学 | Intelligent control system for digital control machine tool and control method thereof |
CN103955168B (en) * | 2014-04-22 | 2016-10-05 | 浙江大学 | Robot hole processing off-line programing method based on DELMIA emulation |
CN110488756B (en) * | 2019-09-05 | 2022-10-18 | 武汉久同智能科技有限公司 | Method and system for automatically calculating numerical control multi-row drill processing parameters of woodworking plate |
CN113467369B (en) * | 2021-07-19 | 2022-05-13 | 中航沈飞民用飞机有限责任公司 | Automatic drilling and riveting numerical control code visual interactive correction method |
-
2022
- 2022-07-19 CN CN202210848523.6A patent/CN115268370B/en active Active
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103454972A (en) * | 2013-06-26 | 2013-12-18 | 厦门钨业股份有限公司 | Tool five-axis numerical control grinding automatic programming method based on UG NX API |
CN103587719A (en) * | 2013-11-11 | 2014-02-19 | 中航沈飞民用飞机有限责任公司 | Full-automatic drilling and riveting positioning method of flat workpiece |
Also Published As
Publication number | Publication date |
---|---|
CN115268370A (en) | 2022-11-01 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US20090326892A1 (en) | System and method for constructing virtual nc controllers for machine tool simulation | |
EP0606649A2 (en) | Numerically controlled machine tool and method to re-execute a machining program after it has been stopped | |
CN102637016A (en) | A machine tool control process and apparatus therefor | |
CN104942808A (en) | Robot motion path off-line programming method and system | |
CN104875204A (en) | Offline programming module and application method of plasma space cutting robot | |
EP2417498B1 (en) | Method for automatically partitioning a part program into fundamental operations | |
US11322147B2 (en) | Voice control system for operating machinery | |
CN111993419B (en) | PDPS-based robot offline manufacturing method and device and computer terminal equipment | |
US7346478B2 (en) | Method of embedding tooling control data within mechanical fixture design to enable programmable logic control verification simulation | |
CN115268370B (en) | Method for automatically drilling and riveting numerical control code to restore simulation process | |
CN105204430B (en) | The five axis postpositive disposal methods based on lathe physical model | |
Bourne | CML: a meta-interpreter for manufacturing | |
CN102275392A (en) | Method for setting and controlling spray marking machine for continuously hot-rolled steel coils | |
Mohamed et al. | Integrated interface system for tool path generation of STEP file | |
CN111142476A (en) | Application of general control system reconstructed in common numerical control machine tool | |
CN109656151A (en) | Shield machine intelligence tool changing analogue system and implementation method based on UNITY | |
Sulaiman et al. | Integrated Interface Development Environment using STEP Universal Data Structure | |
CN101592920A (en) | A kind of method of five-axle number control machine tool virtual machine real electric machining simulation | |
JP2852986B2 (en) | Processing system | |
CN110675724A (en) | Design method of robot gluing teaching system | |
CN115718670B (en) | Automatic substitution operating system and method for semiconductor dust-free room | |
CN111522287B (en) | PLC safety signal processing method, system and storage medium | |
Chen | Research on the design of mechanical robot control system for industrial PC in the context of big data | |
CN115562165A (en) | Seven-axis robot numerical control machining system with machining position positioning and jumping functions | |
CN118131675A (en) | Method for realizing civil fly-by-wire control direct mode control law |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |