Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples do not represent all implementations consistent with the invention. Rather, they are merely examples of apparatus and methods consistent with aspects of the invention as detailed in the accompanying claims.
The terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. As used in this specification and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any or all possible combinations of one or more of the associated listed items.
It should be understood that although the terms first, second, third, etc. may be used herein to describe various information, these information should not be limited by these terms. These terms are only used to distinguish one type of information from another. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of the invention. The term "if" as used herein may be interpreted as "at..once" or "when..once" or "in response to a determination", depending on the context.
Referring to fig. 1, fig. 1 is an automatic assembly method according to an embodiment of the present application, where the automatic assembly method includes the following steps:
Step 101, acquiring an assembly part model for assembling a body to be assembled, an assembly resource model for assembling assembly resources used in assembling the body to be assembled and an automatic assembly process file for realizing automatic assembly for the body to be assembled.
In this embodiment, the automated assembly process file is a process file constructed according to a standard template of a specified process file.
The part model to be assembled, the assembly resource model, or the automated assembly process file may be locally derived, or may be derived from other electronic devices, which is not limited in this embodiment.
An assembly resource model may be understood as a collection of all involved assembly resources during the assembly process. Typically including a stationary table, an assembly fixture, an assembly transport tool, an assembly inspection tool, and the like.
After the automatic assembly process file is obtained, the information recorded by the automatic assembly process file can be stored in an automatic assembly process standard database according to a specified format so as to be read from the automatic assembly process standard database when the automatic assembly process file is used later.
Taking automatic spot welding of pin pins as an example, the automatic assembly process file contains the following necessary process information:
And 102, analyzing the automatic assembly process file to generate an automatic assembly timing sequence information file for the to-be-assembled body.
The automatic assembly process file is recorded with automatic assembly timing information, and in the step, the automatic assembly timing information aiming at the body to be assembled is obtained from the automatic assembly process file, and a corresponding file is generated.
And step 103, filling the key attributes in the automatic assembly timing information file into the key attributes corresponding to the keys according to the keys which are indicated to classify the key attributes in the constructed timing information database.
In the present embodiment, an automated assembly timing information database is constructed in advance and keys of the automated assembly timing information database are determined. Based on the above example, the keys of the automated assembly timing information database may be an execution tool, an execution category, a clamping object, a target position, a target gesture, a view angle switch, an end effector rotation, an end effector state, an assembly character, a mating object, a start time, and an end time.
And 104, constructing a simulation environment in an assembly scene according to the acquired assembly resource model and the assembly part model, and initializing the constructed simulation environment.
In the present embodiment, the assembly simulation of the assembly resource model and the assembly part model of the present embodiment is a simulation environment applied in an assembly scene.
The simulation environment under the assembly scene is built in advance according to the assembly resource model and the assembly part model, and when the simulation environment is built, a model standard input format for simulating an automatic assembly process is specified, a coordinate system is built, calibration rules are built, and a simulation environment initialization standard is built. Based on the above example, a simulation environment that can be driven by a motion function is initialized according to a simulation environment initialization standard and an input three-dimensional model of the pin and an automatic spot welding station three-dimensional model of the pin.
And 105, determining the pose of the assembly part model and the assembly resource model under the global coordinates according to the conversion relation between the coordinate systems corresponding to the constructed assembly part model and the assembly resource model and the global coordinate system in the simulation environment.
In this embodiment, the coordinate systems corresponding to the fitting part model and the fitting resource model are both unified into a global coordinate system so as to perform fitting under the same coordinate system.
And 106, controlling the assembly resource model to call a motion function of the constructed motion simulation function library under the global coordinate system according to the time sequence information corresponding to each key in the time sequence information database so as to automatically assemble the parts to be assembled in the assembly part model by utilizing the motion function and complete assembly of the body to be assembled.
In this embodiment, according to the assembly sequence of the to-be-assembled body recorded by the time sequence information, the assembly resources used when the to-be-assembled body is assembled in the assembly resource model are controlled to automatically assemble the assembly part model by using the motion function correspondingly used under the global coordinate system, so that the assembly process can be automatically and visually realized without manipulation by a professional, and the method is also convenient for guiding workers without professional background to simulate assembly on site in an actual assembly scene.
It can be seen that in the technical scheme provided by the embodiment, the acquired automatic assembly process file is analyzed to generate an automatic assembly time sequence information file for an assembly to be assembled, keys which are classified for key attributes are expressed in a constructed time sequence information database, key attributes in the automatic assembly time sequence information file are filled into key attributes corresponding to the keys, a simulation environment under an assembly scene is constructed according to the acquired assembly resource model and the assembly part model, the constructed simulation environment is initialized, the positions and the postures of the assembly part model and the assembly resource model under the global coordinates are determined according to the conversion relation between the coordinate systems corresponding to the assembly part model and the assembly resource model and the global coordinate system in the simulation environment, and according to the time sequence information corresponding to the keys in the time sequence information database, the motion function of the assembly resource model in the global coordinate system is controlled to be called, so that the assembly to be assembled in the assembly part model is automatically assembled by the motion function, and the assembly to be assembled is completed. Compared with the prior art, the embodiment of the application considers the universality under different automatic assembly and detection processes from the viewpoint of simplifying the simulation operation difficulty, and builds the motion functions of the motion simulation function library of various automatic assemblies and devices based on the importance, so that the assembly process simulation covers various common automatic assembly and detection processes, and for different process types, users only need to fill necessary process information in an automatic assembly process file according to a standard template, thus greatly reducing the operation difficulty of the users, and automatically and quickly completing the assembly of parts without excessive operations of professionals.
In one embodiment of the present application, the motion simulation function library is constructed as follows:
And A1, establishing track planning functions of various motion settings aiming at the set kinematic pairs, the assembly mechanism and the assembly equipment.
The set kinematic pair can be a typical kinematic pair or a specific kinematic pair, the track planning functions of various kinematic settings can be general track planning functions or specific track planning kinematic functions, the set kinematic pair is related to an assembly body to be assembled, and if the set kinematic pair is general, various general kinematic functions, namely track planning functions, can be established for typical kinematic pairs, mechanisms and assembly equipment.
And step A2, setting the collision attribute of the entity, and associating the related collision detection function with the entity with the set collision attribute.
To avoid interference problems, the present embodiment associates a relevant collision detection function to a given entity in order to avoid collisions by calling the collision detection function at assembly time.
And A3, constructing kinematic and dynamic properties corresponding to each kinematic pair, each assembly mechanism and each assembly device, and establishing corresponding automatic assembly device driving functions aiming at the kinematic pair, the assembly mechanism and the assembly device with the constructed kinematic and dynamic properties.
And step A4, declaring a motion function calling interface and determining motion function calling parameters required by each motion function calling interface when calling the motion function.
Therefore, the technical scheme provided by the embodiment can construct a modularized and adaptive general motion simulation function library.
In some embodiments, the implementation of step 106 may include:
and B1, based on the time sequence information corresponding to each key in the time sequence information database, calling a collision detection function, an automatic assembly equipment driving function and a set track planning function used for assembling the body to be assembled from the motion function library, and generating an automatic track plan for realizing automatic assembly of the body to be assembled.
And B2, controlling the assembly resource model to automatically assemble the parts to be assembled in the assembly part model according to automatic track planning.
The embodiment can directly control the assembly resource model to automatically assemble the assembly part model according to the automatic track planning.
In some embodiments, after step 106, the method may further include performing animation rendering on automatic assembly of the parts in the assembly part model in real time in a simulation environment during assembly of the parts in the assembly part model, acquiring an animation rendering information stream, performing video information processing on the animation rendering information stream, and outputting simulation video of the automatic assembly process in a designated window. The embodiment can watch the automatic assembly process of the assembly to be assembled on line, and can be recorded broadcast or live broadcast, but the embodiment is not limited to this.
In some embodiments, the assembly tool model includes at least an AGV (automated guided vehicle, automatic guided vehicle), a rectangular robot, and a robot, and the implementation of step B1 may include the following steps:
And step B11, when a starting instruction indicating the start of assembly simulation is received, if the assembly tool model is detected to be the AGV, executing step B12. If it is detected that the assembly tool model is a rectangular robot, step B15 is performed. If the assembly tool is a designated robot, step B18 is performed.
And step B12, calling a track planning function in a motion simulation function library to carry out track planning on the AGV based on the time sequence information corresponding to each key in the time sequence information database, generating a new path point aiming at the AGV, taking the new path point as a current path point, calling a collision detection function in the motion simulation function library to determine whether collision exists on the current path point aiming at the AGV, and executing the step B13 if the collision exists. If no collision exists, step B14 is performed.
And step B13, deleting the current path point, and returning to the step of performing track planning on the AGV based on the time sequence information corresponding to each key in the time sequence information database.
This step deletes the path points where there is a collision so that the generated trajectory path has no collision problem.
And step B14, reserving the current path point, and returning to the step B12 until the AGV reaches the end point of the track planning, and generating a path for the AGV according to the smoothness of the generated path point by the reserved path point.
In this step, no collision occurs when the AGV completes automatic assembly according to the final generated path.
And step B15, performing track planning on the direct coordinate robot based on the time sequence information corresponding to each key in the time sequence information database, generating a track planning path, acquiring bounding boxes from a starting point to an end point from the track planning path, determining whether an obstacle exists in the bounding boxes, and executing step B16 if the obstacle exists.
And step B16, decomposing the movement direction of the track planning path in a mode of avoiding obstacles, and determining the movement sequence of the rectangular robot according to the track planning path so as to generate a path of the rectangular robot.
The path generated in the step enables the rectangular robot not to encounter an obstacle during automatic assembly.
And B17, performing track planning on the appointed robot based on the time sequence information corresponding to each key in the time sequence information database, generating a new path point aiming at the appointed robot, taking the new path point as a current path point, performing inverse kinematics and dynamics calculation when the appointed robot is subjected to task execution based on the current path point, executing the step B18 if the calculated path planning aiming at the appointed robot is determined to have collision through a collision detection function of a call motion simulation function library, and executing the step B19 if the calculated path planning aiming at the appointed robot is determined to have no collision through the collision detection function of the call motion simulation function library.
And step B18, deleting the current path point, and returning to execute the step of planning the track of the appointed robot based on the time sequence information corresponding to each key in the time sequence information database.
And step B19, reserving the current path point, returning to the step of planning the track of the appointed robot based on the time sequence information corresponding to each key in the time sequence information database until the appointed robot reaches the end point of the track planning, and generating the path aiming at the appointed robot according to the smoothness of generating the path point by the reserved path point.
The path generated by the step enables the appointed robot not to collide when automatic assembly is carried out.
Compared with the existing automatic assembly process simulation, the method considers the universality under different automatic assembly and detection processes from the aspect of simplifying the simulation operation difficulty, and builds a motion function library and a self-driven simulation general instruction stream of various automatic assembly and detection equipment based on the emphasis, so that the assembly process simulation covers various common automatic assembly and detection processes, and for different process types, a user only needs to fill necessary process information in an automatic assembly process standard database, thereby greatly reducing the operation difficulty of the user.
In a second aspect, an embodiment of the present application further provides a schematic structural diagram of an automatic assembling apparatus 200, where the automatic assembling apparatus 200 includes:
The model information obtaining unit 201 is configured to obtain an assembly part model for assembling a body to be assembled, an assembly resource model for assembling an assembly resource used when assembling the body to be assembled, and an automatic assembly process file for implementing automatic assembly for the body to be assembled, where the automatic assembly process file is a process file constructed according to a specified process file standard template.
The timing information file generating unit 202 is configured to analyze the automated assembly process file and generate an automated assembly timing information file for the assembly to be assembled.
And the key attribute filling unit 203 is configured to fill the key attribute in the automated sequence information file into the key attribute corresponding to the key according to the key that indicates the classification of the key attribute in the constructed sequence information database.
And a simulation environment initializing unit 204, configured to construct a simulation environment in the assembly scene according to the acquired assembly resource model and assembly part model, and initialize the constructed simulation environment.
And the coordinate conversion unit 205 is configured to determine the pose of the assembled part model and the assembled resource model under the global coordinates according to the conversion relationship between the coordinate system corresponding to the assembled part model and the assembled resource model and the global coordinate system in the simulation environment.
And the automatic assembly unit 206 is configured to control the assembly resource model to call a motion function of the constructed motion simulation function library under the global coordinate system according to the time sequence information corresponding to each key in the time sequence information database, so as to automatically assemble the part to be assembled in the assembly part model by using the motion function, and complete assembly of the assembly body to be assembled.
As an embodiment, the motion simulation function library is constructed as follows:
establishing a track planning function of various motion settings aiming at the set kinematic pairs, the assembly mechanism and the assembly equipment;
setting collision attribute of the entity, and associating related collision detection functions with the entity with the set collision attribute;
constructing kinematic and dynamic properties corresponding to each kinematic pair, each assembly mechanism and each assembly device, and establishing corresponding automatic assembly device driving functions aiming at the kinematic pairs, the assembly mechanisms and the assembly devices with the constructed kinematic and dynamic properties;
And declaring a motion function call interface and determining motion function call parameters required by each motion function call interface when calling the motion function.
As an embodiment, the automatic assembly unit is configured to:
Based on the time sequence information corresponding to each key in the time sequence information database, generating an automatic track planning for realizing automatic assembly of the body to be assembled from a collision detection function, an automatic assembly equipment driving function and a set track planning function which are used when the body to be assembled is assembled in the motion function library;
and controlling the assembly resource model to automatically assemble the parts to be assembled in the assembly part model according to the automatic track planning.
As an embodiment, the automatic assembling device further includes:
the on-line simulation unit is used for performing animation rendering on the automatic assembly of the parts in the assembly part model in real time in a simulation environment in the assembly process of the parts, acquiring an animation rendering information stream, performing video information processing on the animation rendering information stream, and outputting simulation videos of the automatic assembly process in a designated window.
As an embodiment, the assembly tool model at least includes an automatic guided vehicle AGV, a rectangular robot, and a robot, and the generating an automatic trajectory plan for implementing automatic assembly of the body to be assembled based on the time sequence information corresponding to each key in the time sequence information database, by calling a collision detection function, an automatic assembly equipment driving function, and a set trajectory planning function used when the body to be assembled is assembled from the motion function library, includes:
When a starting instruction for indicating the start of assembly simulation is received, if the assembly tool model is detected to be the AGV, a track planning function in a motion simulation function library is called based on the time sequence information corresponding to each key in a time sequence information database to carry out track planning on the AGV, a new path point aiming at the AGV is generated, the new path point is used as a current path point, a collision detection function in the motion simulation function library is called to determine whether collision exists on the current path point aiming at the AGV, if collision exists, the current path point is deleted, the step of carrying out track planning on the AGV based on the time sequence information corresponding to each key in the time sequence information database is carried out, if collision does not exist, the current path point is reserved, the step of carrying out track planning on the AGV based on the time sequence information corresponding to each key in the time sequence information database is carried out, until the AGV reaches the end point of track planning, and the reserved path point is generated aiming at the AGV according to the smoothness of generating the path point;
If the assembling tool model is detected to be a rectangular robot, track planning is carried out on the direct coordinate robot based on the time sequence information corresponding to each key in the time sequence information database, a track planning path is generated, bounding boxes from a starting point to an end point are obtained from the track planning path, whether an obstacle exists in the bounding boxes is determined, if the obstacle exists, the movement direction of the track planning path is decomposed in a mode of avoiding the obstacle, and the movement sequence of the rectangular robot executed according to the track planning path is determined, so that a path of the rectangular robot is generated;
If the assembly tool is a designated robot, track planning is carried out on the designated robot based on the time sequence information corresponding to each key in the time sequence information database, a new path point aiming at the designated robot is generated, the new path point is used as a current path point, inverse kinematics and dynamics calculation are carried out when tasks are carried out on the designated robot based on the current path point, if the calculated path planning aiming at the designated robot is determined to have collision through a collision detection function of a call motion simulation function library, the current path point is deleted, the step of carrying out track planning on the designated robot based on the time sequence information corresponding to each key in the time sequence information database is carried out is returned, if the calculated path planning aiming at the designated robot is not collided through a collision detection function of a call motion simulation function library, the current path point is reserved, the step of carrying out track planning on the designated robot based on the time sequence information corresponding to each key in the time sequence information database is returned until the designated robot reaches the end point of the track planning, and the path aiming at the designated robot is generated smoothly according to the generated path point.
According to the technical scheme, the automatic assembly device analyzes the acquired automatic assembly process file to generate an automatic assembly time sequence information file for an assembly body, keys for classifying key attributes are shown in a constructed time sequence information database, key attributes in the automatic assembly time sequence information file are filled into key attributes corresponding to the keys, a simulation environment under an assembly scene is constructed according to the acquired assembly resource model and the assembly part model, the constructed simulation environment is initialized, the positions of the assembly part model and the assembly resource model under global coordinates are determined according to the conversion relation between the coordinate systems corresponding to the constructed assembly part model and the assembly resource model and the global coordinate system in the simulation environment, and according to the time sequence information corresponding to the keys in the time sequence information database, the assembly resource model is controlled to call a motion function of a constructed motion simulation function library under the global coordinate system so as to automatically assemble the assembly body to be assembled by utilizing the motion function. Compared with the prior art, the embodiment of the application considers the universality under different automatic assembly and detection processes from the aspect of simplifying the simulation operation difficulty, constructs the motion functions of the motion simulation function library of various automatic assembly and equipment based on the importance, so that the assembly process simulation covers various common automatic assembly and detection processes, and for different process types, a user only needs to fill necessary process information in an automatic assembly process file according to a standard template, thus greatly reducing the operation difficulty of the user, and automatically and quickly completing the assembly of parts without excessive operations of professionals
The implementation process of the functions and roles of each unit in the above device is specifically shown in the implementation process of the corresponding steps in the above method, and will not be described herein again.
The embodiment of the application also provides the electronic equipment, and the schematic diagram of the hardware architecture can be shown in fig. 3 from the hardware level. Comprising a machine-readable storage medium having stored thereon machine-executable instructions executable by a processor for performing machine-executable instructions to implement the automated assembly operations disclosed in the examples above.
A machine-readable storage medium according to an embodiment of the present application stores machine-executable instructions that, when invoked and executed by a processor, cause the processor to implement the automated assembly operations disclosed in the above examples.
Here, a machine-readable storage medium may be any electronic, magnetic, optical, or other physical storage device that may contain or store information, such as executable instructions, data, or the like. For example, the machine-readable storage medium may be RAM (Radom Access Memory, random access memory), volatile memory, non-volatile memory, flash memory, a storage drive (e.g., hard drive), a solid state disk, any type of storage disk (e.g., optical disk, dvd, etc.), or a similar storage medium, or a combination thereof.
The system, apparatus, module or unit set forth in the above embodiments may be implemented in particular by a computer chip or entity, or by a product having a certain function. A typical implementation device is a computer, which may be in the form of a personal computer, laptop computer, cellular telephone, camera phone, smart phone, personal digital assistant, media player, navigation device, email device, game console, tablet computer, wearable device, or a combination of any of these devices.
For convenience of description, the above devices are described as being functionally divided into various units, respectively. Of course, the functions of each element may be implemented in the same piece or pieces of software and/or hardware when implementing the present application.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, embodiments of the application may take the form of a computer program product on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
Moreover, these computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
For the device embodiments, reference is made to the description of the method embodiments for the relevant points, since they essentially correspond to the method embodiments. The apparatus embodiments described above are merely illustrative, wherein the elements illustrated as separate elements may or may not be physically separate, and the elements shown as elements may or may not be physical elements, may be located in one place, or may be distributed over a plurality of network elements. Some or all of the units may be selected according to actual needs to achieve the purposes of the present application. Those of ordinary skill in the art will understand and implement the present application without undue burden.
The foregoing description of the preferred embodiments of the application is not intended to be limiting, but rather to enable any modification, equivalent replacement, improvement or the like to be made within the spirit and principles of the application.