Multi-joint welding robot digital twinning control method based on body Petri net

Through the multi-joint welding robot digital twin control method based on the ontology Petri network, the complexity and versatility of the robot digital twin control technology are solved, and high-precision and intelligent control effects are achieved, adapting to production scheduling and monitoring under complex working conditions.

CN120347443APending Publication Date: 2025-07-22HARBIN INST OF TECH +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510565504.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-30
Publication Date
2025-07-22

AI Technical Summary

Technical Problem

The existing robot digital twin control technology has problems such as complex establishment process, inability to integrate geometric models, unclear semantics and poor universality, which is difficult to meet the needs of high-precision and intelligent control.

Method used

The digital twin control method of multi-joint welding robot based on the ontology Petri network is adopted, including simulation task establishment, virtual robot import, Petri network model modeling, data communication and status update, and the combination of Kalman filtering and Petri network is used to update the filter state in real time, simplify the model establishment process, and improve the universality and scalability of the model.

Benefits of technology

It realizes the geometric model integration function of robot digital twins, with clear semantics, improves the application value and versatility of the control model, and adapts to the production scheduling and monitoring needs under complex working conditions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120347443A_ABST
    Figure CN120347443A_ABST
Patent Text Reader

Abstract

The invention aims to overcome the defects that a geometric model cannot integrate functions, is indefinite in semantics, is poor in universality and the like in a digital twinning technology and intelligent robot establishment process, and discloses a multi-joint robot digital twinning control method based on a body Petri net, which integrates five parts: simulation task establishment, virtual robot import and Petri net model modeling. Data communication and state updating, and model evaluation; specifically, the motion simulation control part is used for simulating the operation process and matters needing attention of equipment; in a digital twinning control stage, establishing an ontology coloring Petri net model; in the entity robot communication link, Kalman filtering is combined with a Petri network, and the filtering state is updated in real time; according to the method, the model building process can be simplified, traditional digital twinning function modules are inherited, the universality and expansibility of the built model are achieved in combination with the ontology Petri net, and the application value of the control model is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of digital twin, and specifically relates to a digital twin control method for a multi-joint welding robot based on an ontology Petri net. Background Art

[0002] Robots are an important part of the industrial field. With the deepening of people's understanding of robot technology, robot technology has been applied in various fields. Robots can replace a large number of repetitive and complex industrial steps, not only improving work efficiency and reducing production costs, but also handling work tasks involving toxic substances, extreme temperatures or dangerous machinery, eliminating the risk of harm to human workers caused by these work tasks.

[0003] In traditional robot control, the motion state and motion information of the robot are often closed and not open, making it difficult for operators to obtain the motion information of the robot in real time, resulting in non-intuitive and lagging evaluation results. To overcome these limitations, digital twin technology has emerged.

[0004] However, with the improvement of automation and intelligence levels, the work of robots has evolved from simple repetition to precise and intelligent operation, which poses higher requirements for robot control methods. Currently, for the digital twin control technology of robots, there are still disadvantages such as complex establishment processes, inability to integrate functions in geometric models, unclear semantics, and poor generality. Summary of the Invention

[0005] In view of this, in order to solve the problems existing in the current digital twin control technology of robots, the purpose of the present invention is to provide a digital twin control method for a multi-joint welding robot based on an ontology Petri net.

[0006] To achieve the above object, the present invention provides the following technical solutions:

[0007] A digital twin control method for a multi-joint welding robot based on an ontology Petri net, comprising the following steps:

[0008] Step 1: Establishment of a simulation task: Construct a virtual control environment including a teaching module, a single-axis / multi-axis simulation motion module, and a motion trajectory simulation module;

[0009] The teaching module realizes the bidirectional mapping of the pose parameters of the virtual and real robots through an inverse solution function;

[0010] The single-axis / multi-axis simulation motion module performs single motion axis parameter setting and multi-axis linkage relationship calculation, and integrates an emergency stop protection mechanism and a motion range limit module;

[0011] The motion trajectory simulation module sets up a user-defined coordinate system and key path points to achieve trajectory planning under multiple coordinate systems;

[0012] Step 2: Virtual robot import: Create a high-precision virtual model based on the actual robot measurement data, import the initial data, motion data, environmental parameters, and fault data of the robot to build a digital twin system of the multi-joint welding robot;

[0013] Step 3: Petri net model building: Establish a Petri net model containing places, transitions, arcs, and tokens, and distinguish the task priorities, robot states, and environmental parameters of the tokens through a color function;

[0014] Step 4: Data communication and state update: Embed a Kalman filter in the Petri net transition node. When the transition is triggered, perform state prediction, calculate the predicted state and covariance matrix through the state transition matrix, and update the system state when the observed data arrives;

[0015] Step 5: Model evaluation: Implement multi-dimensional verification including accuracy evaluation, stability evaluation, robustness evaluation, and real-time evaluation. Among them, the accuracy evaluation compares the consistency of the motion trajectories of the physical and virtual robots, and the real-time evaluation measures the response delay of the measurement system.

[0016] Furthermore, in the above Step 1, the single-axis / multi-axis simulation motion module includes:

[0017] Single-axis motion parameter setting unit: Set and adjust the parameters of the motion axis as needed, and collect and analyze the motion data of the motion axis;

[0018] Multi-axis linkage calculation unit: Analyze the relative pose relationship between the motion axes and execute the interference detection algorithm;

[0019] Safety protection unit: Integrate the emergency stop button signal processing module and the motion range boundary detection algorithm.

[0020] Furthermore, in the above Step 1, the motion trajectory simulation module includes:

[0021] Coordinate system definition unit: Support setting a user coordinate system with adjustable X / Y / Z axis directions at any position in the mechanical system;

[0022] Path planning unit: Insert key trajectory points in the simulation environment and generate a continuous path for the end effector to pass through;

[0023] Multi-coordinate system conversion unit: Realize the real-time conversion between the user coordinate system and the world coordinate system.

[0024] Furthermore, in the above Step 2:

[0025] The initial data is the factory data of the robot, including basic physical attributes and structural parameters;

[0026] The motion data includes motion parameters and attitude parameters. The motion parameters include joint position, speed, and acceleration. The attitude parameters include joint rotation angle, yaw angle, and pitch angle;

[0027] The environmental parameters include the characteristics of the virtual environment where the robot is located, including the physical space range of the simulation model and mechanical environment parameters. The mechanical environment parameters include external forces such as gravity, friction, and external impact force;

[0028] The fault data includes direct characteristic parameters and indirect characteristic parameters. The direct characteristic parameters include output parameters and damage amounts of equipment or components. The indirect characteristic parameters include vibration, noise, temperature, and electricity.

[0029] Furthermore, in step 3, the method steps for creating a Petri net model are as follows:

[0030] 31) According to the engineering content of the production line, establish a working process diagram of the multi-joint welding robot;

[0031] 32) According to the working process diagram and transformation rules, parse and generate a specific Petri net model. The method steps are as follows:

[0032] 321) Determine each link of the production line and their mutual relationships, and clarify the meaning of the basic elements of the Petri net in the production line;

[0033] 322) According to each link of the production line and their mutual relationships, and the basic elements of the Petri net, draw the Petri net diagram of the production line to obtain the Petri net model of the production line.

[0034] Furthermore, it also includes step 33), introducing a color function to distinguish different types of tokens and transitions, establishing the Petri net model as a colored motion Petri net model of the robot, and representing the priority of tasks through the colors of the tokens.

[0035] Furthermore, in step 4, data communication and status update include:

[0036] Data import: Collect the entity action data of the multi-joint robot and transmit it to the virtual robot; after receiving the instructions sent by the virtual robot, implement the actions of the entity.

[0037] Data communication: Connect the entity robot and the virtual robot for data transmission. The digital twin system uses instructions to control the movement of the entity robot unit. The entity robot unit sends the actual motion data to the digital twin system to drive the twin system for visual rendering, realizing approximate synchronization between the two.

[0038] Status update: The filtering status is updated in real time by combining Kalman filtering and Petri nets.

[0039] Furthermore, data import includes data loading, data saving, data playback, and data cleaning;

[0040] Data loading refers to reading the data previously saved in the storage medium and loading it into the digital twin system for further use; the loaded data is used to update the status of the digital twin model, perform real-time monitoring, or historical data analysis;

[0041] Data saving refers to storing various types of data in the digital twin system to provide data support for subsequent data analysis, model training, and decision-making;

[0042] Data playback allows users to view the data changes within a certain past time period in the digital twin system, helping users understand the system's operating status and identify potential problems;

[0043] Data cleaning refers to deleting or correcting redundant, outdated, or incorrect data in the digital twin system to improve data quality and ensure the accuracy of subsequent analysis and modeling.

[0044] Furthermore, in step 42), the method steps for status update are as follows:

[0045] 421) Design a Kalman filter. Determine the state variable x according to the characteristics of the system state variables; determine the parameters of the filter including the state transition matrix F, the observation matrix H, and the noise covariance matrix Q; initialize the Kalman filter and the Petri net model;

[0046] 422) Embed the Kalman filter in the Petri net transition node and wait for the Petri net model transition to be triggered;

[0047] 423) Determine whether a transition is triggered in the Petri net model: If yes, execute step 424); if not, execute step 422);

[0048] 424) Determine whether there is new observation data: If yes, execute step 425); if not, execute step 422);

[0049] 425) Perform Kalman filter status update, use the state transition matrix F and the previous state estimate x k-1∣k-1 , calculate the predicted state x at the current moment k∣k-1 ; at the same time, update the state estimation error covariance matrix P k∣k-1 ;

[0050] 426) Use the Kalman gain and the observation data zk Update the state estimate x k∣k and the state estimate error covariance matrix P k∣k ;

[0051] 427) Determine whether the state update of the Kalman filter is consistent with the state change of the Petri net model: If so, the state update ends; if not, execute step 422).

[0052] Furthermore, the state transition matrix F is used to describe how the system state changes over time and is expressed as:

[0053] x k|k―1 = Fx k―1|k―1

[0054] where: x k|k―1 is the predicted state at time k; x k―1|k―1 is the estimated state at time k-1;

[0055] The observation matrix H is used to map the system state to the observation space and describes how to obtain the observation value from the system state, and is expressed as:

[0056] z k = Hx k + v k

[0057] where: z k is the observation value; v k is the observation noise.

[0058] The beneficial effects of the present invention are as follows:

[0059] The present invention aims to solve the shortcomings of the geometric model in the process of establishing the digital twin technology and intelligent robots, such as inability to integrate functions, unclear semantics, and poor generality. A digital twin control method for multi-joint robots based on ontology Petri net is proposed, which is integrated into five parts: simulation task establishment, virtual robot import, Petri net model modeling, data communication and state update, and model evaluation; specifically: the motion simulation control part is used to simulate the operation process and precautions of the device; in the digital twin control stage, an ontology-colored Petri net model is established; in the communication link of the physical robot, the Kalman filter and the Petri net are combined to update the filtering state in real time; the present invention can simplify the model establishment process, inherit the functional modules of the traditional digital twin, combine the ontology Petri net, realize the generality and expandability of the established model, and improve the application value of the control model. Description of the Drawings

[0060] In order to make the objectives, technical solutions, and beneficial effects of the present invention clearer, the present invention provides the following drawings for description:

[0061] Figure 1 This is the flowchart of the digital twin control method for a multi-joint robot based on an ontology Petri net of the present invention;

[0062] Figure 2 It is the motion simulation control diagram;

[0063] Figure 3 It is the schematic diagram of the point and pose insertion interface;

[0064] Figure 4 It is the schematic diagram of the user coordinate system setting;

[0065] Figure 5 It is the digital twin system diagram of the robot;

[0066] Figure 6 It is the Petri net model diagram;

[0067] Figure 7 It is the state update flowchart. Specific embodiments

[0068] The present invention will be further described below in conjunction with the accompanying drawings and specific embodiments, so that those skilled in the art can better understand the present invention and be able to implement it, but the embodiments given are not intended to limit the present invention.

[0069] As Figure 1 shown, the digital twin control method for a multi-joint welding robot based on an ontology Petri net in this embodiment includes the following steps.

[0070] Step 1: Establish a simulation task: Construct a virtual control environment including a teaching module, a single-axis / multi-axis simulation motion module, and a motion trajectory simulation module.

[0071] In the design interface, the interface includes a teaching button, single-axis / multi-axis simulation motion, an execution simulation logic button, a trajectory list, and a 3DViewer model observation area, as Figure 2 shown. The teaching button uses the function mousePressEvent() to determine whether the teaching ball is clicked, and the function mouseMoveEvent() calculates the mouse movement displacement. The teaching module transmits the virtual robot position to the multi-joint robot entity through the inverse kinematics function and provides a reset function.

[0072] That is, the teaching module of this embodiment realizes the bidirectional mapping of the pose parameters of the virtual and real robots through the inverse kinematics function. Specifically, the teaching part is used to set the actions of the virtual robot model in the simulation system, simulate the actual working state of the robot, realize the virtual-real interaction, and provide data support for the subsequent point insertion.

[0073] The single-axis / multi-axis simulation motion module performs single motion axis parameter setting and multi-axis linkage relationship calculation, and integrates an emergency stop protection mechanism and a motion range limit module; the motion trajectory simulation module sets user-defined coordinate systems and key path points to achieve trajectory planning under multiple coordinate systems. In this embodiment, the single-axis / multi-axis simulation motion module includes a single-axis motion parameter setting unit, a multi-axis linkage calculation unit, and a safety protection unit.

[0074] The single-axis motion parameter setting unit sets and adjusts the parameters of the motion axis as needed, and collects and analyzes the motion data of the motion axis. Specifically, the single-axis motion parameter setting unit can simulate the motion trajectory of a single motion axis, such as linear motion or rotational motion, set and adjust the parameters of the motion axis as needed, and collect and analyze the motion data of the motion axis, such as displacement, velocity, acceleration, etc.

[0075] The multi-axis linkage calculation unit analyzes the relative pose relationship between motion axes and executes an interference detection algorithm. Specifically, the multi-axis linkage calculation unit can simulate the linkage relationship between multiple motion axes, calculate the relative positions and postures between the motion axes, ensure the accuracy of the simulation, and perform more complex motion trajectory simulations to meet complex machining requirements.

[0076] The safety protection unit integrates an emergency stop button signal processing module and a motion range boundary detection algorithm. Such as interference detection to avoid interference between motion axes or collisions with surrounding objects during motion. Such as introducing a limit position protection mechanism to prevent the axis from moving beyond the set safety range. Such as setting an emergency stop button to immediately stop the axis movement in case of an emergency.

[0077] In this embodiment, the motion trajectory simulation module includes a coordinate system definition unit, a path planning unit, and a multi-coordinate system conversion unit. The motion trajectory simulation module is responsible for simulating the actual operation process of the mechanical system according to the model, parameters, and boundary conditions set by the user. The system will gradually calculate parameters such as the motion trajectory, velocity, acceleration, and attitude change of the machine according to the preset algorithm and process, update the mechanical model in the simulation environment in real time, and output the simulation results.

[0078] The coordinate system definition unit supports setting a user coordinate system with adjustable X / Y / Z axis directions at any position in the mechanical system. The user coordinate system can be defined at any position in the mechanical system, and the X, Y, and Z axis directions of the coordinate system should be arbitrarily set according to user needs to adapt to different simulation scenarios. The coordinate system definition unit supports setting multiple user coordinate systems for multi-angle and multi-level simulation analysis in complex systems.

[0079] The path planning unit inserts key points of the trajectory in the simulation environment to generate a continuous path for the end effector to pass through. The path planning unit in this embodiment allows users to accurately define and insert various points in the simulation environment, which usually represent the key positions and stop points during the movement of the machine, facilitating the simulation of the path of the robot end passing through the points and inserting the points into the path at the same time.

[0080] The multi - coordinate system conversion unit realizes the real - time conversion between the user coordinate system and the world coordinate system.

[0081] The execution simulation logic button can define the initial position, initial speed, overall path, step size, and current time of the virtual robot, set the initial parameters for starting the simulation and the conditions for ending the simulation, define the coordinates of XYZ, and allow users to modify the coordinate values and working coordinate systems of the defined points through the point editing function. When inserting or editing points, verification and conflict detection are performed to ensure the effectiveness and safety of the points. Users can add, modify, or delete points at any time according to actual needs, as Figure 3 shown. Define the information of the XYZ working coordinate system and insert the defined axes into a pre - prepared list for storage. This list is used to store and manage multiple points and their related working coordinate systems, as well as the conversion relationship between the working coordinate system and the world coordinate system, as Figure 4 shown.

[0082] Step 2: Virtual robot import: Create a high - precision virtual model based on the actual robot measurement data, import the initial data, motion data, environmental parameters, and fault data of the robot, and construct a digital twin system of the multi - joint welding robot, as Figure 5 shown. When importing the virtual robot, import the size, shape, motion range of the robot, and the interaction method with other devices, etc. Specifically, first, a detailed measurement and analysis of the actual robot are required to create a digital model of the virtual robot. When creating the model, it is necessary to ensure the accuracy and precision of the model so as to perform accurate simulation and emulation in the digital twin environment.

[0083] Specifically, the initial data is the factory data of the robot, including basic physical properties and structural parameters. The motion data includes motion parameters and attitude parameters. The motion parameters include joint positions, speeds, and accelerations, and the attitude parameters include joint rotation angles, yaw angles, and pitch angles. The environmental parameters include the characteristics of the virtual environment where the robot is located, including the physical space range and mechanical environment parameters of the simulation model. The mechanical environment parameters include external forces such as gravity, friction, and external impact forces. The fault data includes direct characteristic parameters and indirect characteristic parameters. The direct characteristic parameters include the output parameters and damage amounts of devices or components, and the indirect characteristic parameters include vibration, noise, temperature, and power.

[0084] Step 3: Petri net model construction: Construct a Petri net model that includes places, transitions, arcs, and tokens. Distinguish the task priorities, robot states, and environmental parameters of the tokens through a color function, such as Figure 6 as shown.

[0085] A classic Petri net model mainly consists of four elements: places, transitions, and directed arcs (arcs) between places and transitions, and tokens.

[0086] The participation of the Petri net model provides a unified graphical representation method to describe the various characteristics of the system, can intuitively reflect phenomena such as parallelism, synchronization, conflict, and sharing, and has strong expressive power. The Petri net model has an exact meaning, can be analyzed and verified from the perspectives of semantics and matrix theory, and also has flexible scalability. Therefore, in the two-dimensional plane environment of a workstation, a robot motion Petri net model can be constructed according to the motion of a multi-joint robot.

[0087] To increase the generalization of the model, the concept of colored Petri nets is introduced, and an additional element, the color function, is added to distinguish different types of tokens and transitions. Establish a colored robot motion Petri net model. According to different mechanical working scenarios, different types of tokens are issued by places to achieve different types of work. On the basis of the existing color function, expand the color dimension: (1) Set task priorities: red (urgent), yellow (routine), green (low priority); (2) Robot states: blue (idle), orange (running), purple (fault); (3) Environmental parameters: temperature (mapped to a gradient color from 0 - 100 °C), humidity (represented by grayscale values). Dynamically update the token colors according to real-time data to enhance the adaptability of the model to complex working conditions.

[0088] When creating a Petri net model, first establish the corresponding work process diagram according to the specific engineering content. Establish the transformation rules for converting the work flow diagram into a Petri net model, including: (1) Create a place for the start activity; (2) Create a place for the end activity; (3) Create a place for the selection node; (4) Create a place for the merge node; (5) Create a place for the fork node; (6) Create a place for the join node; (7) Create a transition to fuse places for the signal emission activity; (8) Create a transition to fuse places for the signal reception activity.

[0089] According to the specific work process diagram and transformation rules, parse and generate the specific Petri net model. Determine the places, transitions, arcs, tokens, and color function.

[0090] Specifically, in the Petri net model, places represent the states or conditions of the system, transitions represent the events or operations in the system, which are the reasons for triggering state changes. Directed arcs represent the relationships between places and transitions, describing the flow of resources or the satisfaction of conditions. Tokens are dynamic objects between places (in this article, it is a robot completing an action unit), which can move from one place to another and represent the state of the system. The color function is used to classify and identify tokens, enabling more refined description and analysis of the system. Specifically, the places and transitions of the Petri net model are shown in Table 1.

[0091] Table 1 Places and Transitions of the Petri Net Model

[0092]

[0093]

[0094] In the existing colored Petri net model, by expanding the color dimension and encoding various information, it can better meet the production scheduling and monitoring requirements under complex working conditions. The specific improvement contents are as follows:

[0095] (1) The color of the token represents the priority of the task, and different colors are used to distinguish the urgency of the task. For example: Red: indicates an urgent task that must be processed first. Yellow: indicates a regular task with medium priority. Green: indicates a low-priority task with the lowest processing priority.

[0096] Use colors to represent different states of the robot during production. For example: Blue: indicates that the robot is in an idle state and can execute tasks. Orange: indicates that the robot is executing tasks. Purple: indicates that the robot has a fault or is in a shutdown state and cannot execute tasks.

[0097] Use color gradients and grayscale values to represent relevant parameters of the environment. For example, within the temperature range of 0°C to 100°C, set a color gradient, such as from blue at low temperature to red at high temperature, to more intuitively reflect temperature changes. Humidity is represented by grayscale values, from black at low humidity to white at high humidity, to assist in monitoring environmental humidity changes.

[0098] (2) By introducing sensors and real-time data input, the color of the token is dynamically updated according to the current working environment state. For example: According to the change in environmental temperature, the color of the token is adjusted in real time to visually identify whether the cooling system needs to be started. When the robot fails, the color of the token is automatically changed to prompt the operator to perform fault troubleshooting. According to the real-time priority change of the task, the color of the task token is automatically changed, making the urgency of the task visible.

[0099] Specifically, in this embodiment, the method steps for creating a Petri net model are as follows:

[0100] 31) Establish a working process diagram of the multi-joint welding robot according to the engineering content of the production line, as Figure 6 shown.

[0101] 32) Parse and generate a specific Petri net model according to the working process diagram and transformation rules. The method steps are as follows.

[0102] 321) Determine each link of the production line and their mutual relationships, and clarify the meanings of the basic elements of the Petri net in the production line.

[0103] 322) Draw the Petri net diagram of the production line according to each link of the production line, their mutual relationships, and the basic elements of the Petri net to obtain the Petri net model of the production line.

[0104] 33) Introduce a color function to distinguish different types of tokens and transitions, establish the Petri net model as a robot-colored motion Petri net model, and represent the priority of tasks through the colors of tokens.

[0105] Step 4: Data communication and status update: Embed a Kalman filter in the Petri net transition node. When the transition is triggered, perform state prediction, calculate the predicted state and covariance matrix through the state transition matrix, and update the system state when the observed data arrives.

[0106] In the twin operation window in the main interface operation area, input the IP address and port of the physical robot. After clicking the connection button, if the connection button becomes "Disconnect" and "Connected to the server successfully" is displayed in "Data (Send / Receive)", then the connection to the physical robot is successful. Through this connection, the digital twin system can obtain the state information of the robot in real time (such as position, speed, load, etc.), and use this data for model update, simulation analysis, and optimization decision-making. At the same time, the system can also send control instructions to the robot to achieve remote monitoring and automatic control.

[0107] In this embodiment, data communication and status update include data import, data communication, and status update.

[0108] (1) Data import: Collect the entity action data of the multi-joint robot entity and transmit it to the virtual robot; after receiving the instructions sent by the virtual robot, implement the actions of the entity. This includes data reception, storage, analysis, and visualization, etc.

[0109] In this embodiment, data import includes data loading, data saving, data playback, and data cleaning;

[0110] Data loading refers to reading the data previously saved in the storage medium and loading it into the digital twin system for further use; the loaded data is used to update the state of the digital twin model, perform real-time monitoring, or conduct historical data analysis.

[0111] Data saving refers to storing various types of data in the digital twin system to provide data guarantee for subsequent data analysis, model training, and decision support.

[0112] Data playback allows users to view the data changes within a certain period in the past in the digital twin system, helping users understand the operating state of the system and identify potential problems.

[0113] Data cleaning refers to deleting or correcting redundant, outdated, or incorrect data in the digital twin system, such as missing values, outliers, duplicate data, etc. This is to improve data quality, ensure the accuracy of subsequent analysis and modeling, and also release storage space and improve system performance.

[0114] (2) Data communication: Connect the physical robot and the virtual robot for data transmission. The digital twin system uses instructions to control the movement of the physical robot unit. The physical robot unit sends the actual movement data to the digital twin system to drive the twin system for visual rendering, achieving approximate synchronization between the two.

[0115] Specifically, the communication system between the physical robot and the virtual-real robot includes: the upper computer control system, the robot controller, and the interaction interface. The robot generates a planned motion path instruction according to the established Petri net instruction format, sets the client as the upper computer software, and the server as the robot controller. The communication process between the upper and lower computers is as follows: The upper computer control system generates a control file and sends it to the robot controller, then sends the motionstart controller instruction to start the motion program, and actively sends the getcurpos controller instruction to the physical robot to request to obtain the angles of each current joint of the physical robot. After receiving the data, it renders and updates the virtual model layer, and then continues to send the getcurpos instruction to the robot. The interaction interface is as Figure 4 shown, and the specific interaction steps are as follows:

[0116] The digital twin system establishes a communication connection with the server software (simulating the actual robot controller), simulating the establishment of network communication between the upper and lower computers.

[0117] The digital twin system sends data to the robot controller, simulating the control of the lower computer.

[0118] The communication module of the digital twin system sends the motion path instruction of the welding unit to the server-side software and sends the motionstart instruction to start the motion program. The server-side software successfully receives the control instruction sent by the digital twin system.

[0119] The server - side software sends actual motion data to simulate the control of the digital - twin system by an actual robot. As Figure 5 shown, the server - side software sends the angle values of each axis of the robot. After the twin system successfully receives the data, it draws the motion curve.

[0120] (3) State update: Combine Kalman filtering and Petri nets to update the filtering state in real - time.

[0121] As Figure 7 shown, in this embodiment, the method steps of state update are as follows:

[0122] 421) Design a Kalman filter. According to the characteristics of the system state variables, determine the state variable x; determine the parameters of the filter including the state - transition matrix F, the observation matrix H, and the noise - covariance matrix Q; initialize the Kalman filter and the Petri - net model;

[0123] The state - transition matrix F is used to describe how the system state changes over time and is expressed as:

[0124] x k|k―1 = Fx k―1|k―1

[0125] where: x k|k―1 is the predicted state at time k; x k―1|k―1 is the estimated state at time k - 1;

[0126] The observation matrix H is used to map the system state to the observation space and describes how to obtain the observation value from the system state, expressed as:

[0127] z k = Hx k + v k

[0128] where: z k is the observation value; v k is the observation noise.

[0129] The process - noise covariance matrix Q describes the uncertainty in the change of the system state.

[0130] 422) Embed the Kalman filter in the Petri - net transition node and wait for the Petri - net model transition to be triggered.

[0131] 423) Determine whether a transition is triggered in the Petri - net model: If yes, execute step 424); if no, execute step 422).

[0132] 424) Determine whether there is new observation data: If yes, execute step 425); if no, execute step 422).

[0133] 425) Perform the state update of the Kalman filter, using the state transition matrix F and the state estimate x at the previous moment k-1∣k-1 , and calculate the predicted state x at the current moment k∣k-1 ; meanwhile, update the state estimation error covariance matrix P k∣k-1 .

[0134] 426) Use the Kalman gain and the observed data z k to update the state estimate x k∣k and the state estimation error covariance matrix P k∣k .

[0135] 427) Determine whether the state update of the Kalman filter is consistent with the state change of the Petri net model: if so, the state update ends; if not, execute supplement 422).

[0136] Step Five: Model Evaluation: Implement multi-dimensional verification including accuracy evaluation, stability evaluation, robustness evaluation, and real-time evaluation. Among them, the accuracy evaluation compares the consistency of the motion trajectories of the physical and virtual robots, and the real-time evaluation measures the system response delay.

[0137] In the accuracy evaluation, the data set is divided into a training set, a validation set, and a test set. Set appropriate evaluation metrics, such as accuracy, precision, and recall.

[0138] In the stability evaluation, the data set is divided into multiple subsets. Each time, one of the subsets is used as the test set, and the remaining subsets are used as the training set. At the same time, perform multiple repeated training and validation processes, and take the average performance for evaluation to reduce the deviation of the evaluation results.

[0139] In the robustness evaluation, add random errors or outliers to the data set to evaluate the performance of the model on these data. At the same time, make small and targeted modifications to the input data (adversarial samples) to evaluate the performance of the model when under adversarial attacks.

[0140] In the real-time evaluation, when the model processes data, record the response time of each request. By analyzing the response time data, evaluate the real-time response ability of the model.

[0141] The above-described embodiments are only preferred embodiments given to fully illustrate the present invention, and the protection scope of the present invention is not limited thereto. Equivalent substitutions or transformations made by those skilled in the art on the basis of the present invention are all within the protection scope of the present invention. The protection scope of the present invention shall be subject to the claims.

Claims

1. A digital twin control method for a multi-joint welding robot based on ontology Petri net, characterized in that: It includes the following steps: Step 1: Establishment of simulation task: Construct a virtual control environment including a teaching module, a single-axis / multi-axis simulation motion module, and a motion trajectory simulation module; The teaching module realizes the bidirectional mapping of virtual and real robot pose parameters through an inverse solution function; The single-axis / multi-axis simulation motion module performs single motion axis parameter setting and multi-axis linkage relationship calculation, and integrates an emergency stop protection mechanism and a motion range limit module; The motion trajectory simulation module sets user-defined coordinate systems and key path points to achieve trajectory planning under multiple coordinate systems; Step 2: Import of virtual robot: Create a high-precision virtual model based on the measured data of the actual robot, import the initial data, motion data, environmental parameters, and fault data of the robot to construct a digital twin system of a multi-joint welding robot; Step 3: Modeling of Petri net model: Establish a Petri net model including places, transitions, arcs, and tokens, and distinguish the task priorities, robot states, and environmental parameters of the tokens through a color function; Step 4: Data communication and state update: Embed a Kalman filter in the Petri net transition node. When the transition is triggered, perform state prediction, calculate the predicted state and covariance matrix through the state transition matrix, and update the system state when the observed data arrives; Step 5: Model evaluation: Implement multi-dimensional verification including accuracy evaluation, stability evaluation, robustness evaluation, and real-time evaluation. Among them, the accuracy evaluation compares the consistency of the motion trajectories of the physical and virtual robots, and the real-time evaluation measures the response delay of the system.

2. The digital twin control method for a multi-joint welding robot based on an ontology Petri net according to claim 1, characterized in that: In the said Step 1, the single-axis / multi-axis simulation motion module includes: Single-axis motion parameter setting unit: Set and adjust the parameters of the motion axis as needed, and collect and analyze the motion data of the motion axis; Multi-axis linkage calculation unit: Analyze the relative pose relationship between motion axes and execute an interference detection algorithm; Safety protection unit: Integrate an emergency stop button signal processing module and a motion range boundary detection algorithm.

3. The digital twin control method of the multi-joint welding robot based on the ontology Petri net according to claim 1, characterized in that: In the said Step 1, the motion trajectory simulation module includes: Coordinate system definition unit: Support setting user coordinate systems with adjustable X / Y / Z axis directions at any position in the mechanical system; Path planning unit: Insert key trajectory points in the simulation environment to generate a continuous path of the end effector passing through the points; Multi-coordinate system conversion unit: Realize the real-time conversion between the user coordinate system and the world coordinate system.

4. The digital twin control method of a multi-joint welding robot based on an ontology Petri net according to claim 1, characterized in that: In the said Step 2: The initial data is the factory data of the robot, including basic physical attributes and structural parameters; The motion data includes motion parameters and attitude parameters. The motion parameters include joint position, speed, and acceleration, and the attitude parameters include joint rotation angle, yaw angle, and pitch angle; The environmental parameters include the characteristics of the virtual environment where the robot is located, including the physical space range and mechanical environment parameters of the simulation model. The mechanical environment parameters include external forces including gravity, friction, and external impact forces; The fault data includes direct characteristic parameters and indirect characteristic parameters. The direct characteristic parameters include the output parameters and damage amounts of equipment or components, and the indirect characteristic parameters include vibration, noise, temperature, and electric quantity.

5. The digital twin control method of the multi-joint welding robot based on the ontology Petri net according to claim 1, characterized in that: In step 3), the method steps for creating a Petri net model are as follows: 31) Establish a working process diagram of the multi-joint welding robot according to the engineering content of the production line; 32) Parse and generate a specific Petri net model according to the working process diagram and transformation rules. The method steps are as follows: 321) Determine each link of the production line and their mutual relationships, and clarify the meaning of the basic elements of the Petri net in the production line; 322) Draw a Petri net diagram of the production line based on each link of the production line and their mutual relationships and the basic elements of the Petri net to obtain the Petri net model of the production line.

6. The digital twin control method for a multi-joint welding robot based on an ontology Petri net according to claim 5, characterized in that: It also includes step 33), introducing a color function to distinguish different types of tokens and transitions, establishing the Petri net model as a robot colored motion Petri net model, and representing the priority of tasks through the colors of tokens.

7. The digital twin control method for a multi-joint welding robot based on an ontology Petri net according to claim 1, characterized in that: In step 4), data communication and status update include: Data import: Collect the entity action data of the multi-joint robot and transmit it to the virtual robot; after receiving the instructions sent by the virtual robot, implement the actions of the entity. Data communication: Connect the entity robot and the virtual robot for data transmission. The digital twin system uses instructions to control the movement of the entity robot unit. The entity robot unit sends the actual motion data to the digital twin system to drive the twin system for visual rendering, realizing approximate synchronization between the two. Status update: Combine Kalman filtering and Petri net to update the filtering status in real time.

8. The digital twin control method for a multi-joint welding robot based on an ontology Petri net according to claim 7, characterized in that: Data import includes data loading, data saving, data playback, and data cleaning; Data loading refers to reading the data previously saved in the storage medium and loading it into the digital twin system for further use; the loaded data is used to update the status of the digital twin model, conduct real-time monitoring, or perform historical data analysis; Data saving refers to storing various types of data in the digital twin system to provide data guarantee for subsequent data analysis, model training, and decision support; Data playback allows users to view the data changes within a certain period in the past in the digital twin system to help users understand the operating status of the system and identify potential problems; Data cleaning refers to deleting or correcting redundant, outdated, or incorrect data in the digital twin system to improve data quality and ensure the accuracy of subsequent analysis and modeling.

9. The digital twin control method for a multi-joint welding robot based on an ontology Petri net according to claim 7, characterized in that: In step 42), the method steps for status update are as follows: 421) Design a Kalman filter. According to the characteristics of the system state variables, determine the state variable x; determine the parameters of the filter including the state transition matrix F, the observation matrix H, and the noise covariance matrix Q; initialize the Kalman filter and the Petri net model; 422) Embed the Kalman filter in the Petri net transition node and wait for the Petri net model transition to be triggered; 423) Determine whether a transition is triggered in the Petri net model: If so, execute step 424); if not, execute step 422); 424) Determine whether there is new observation data: If so, execute step 425); if not, execute step 422); 425) Perform the Kalman filter state update, using the state transition matrix F and the state estimate x at the previous moment, k-1∣k-1 to calculate the predicted state x at the current moment k∣k-1 ; meanwhile, update the state estimate error covariance matrix P k∣k-1 ; 426) Use the Kalman gain and the observed data z k Update the state estimate x k∣k and the state estimation error covariance matrix P k∣k ; 427) Determine whether the state update of the Kalman filter is consistent with the state change of the Petri net model: If so, the state update ends; if not, execute step 422).

10. The digital twin control method of the multi-joint welding robot based on the ontology Petri net according to claim 9, characterized in that: The state transition matrix F is used to describe how the system state changes over time and is expressed as: x k|k―1 = Fx k―1|k―1 where: x k|k―1 is the predicted state at time k; x k―1|k―1 is the estimated state at time k-1; The observation matrix H is used to map the system state to the observation space and describes how to obtain the observed values from the system state, expressed as: z k = Hx k + v k where: z k is the observed value; v k is the observation noise.