Robot route planning method and device, electronic equipment and storage medium
By inversely solving the pose, path velocity, and acceleration planning of the robot's end effector, the problem of insufficient movement speed of industrial robots in complex environments was solved, achieving efficient and accurate route planning and improving the robot's working efficiency.
Patent Information
- Application Number
- CN202511553668.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-28
- Publication Date
- 2026-02-10
AI Technical Summary
In existing technologies, industrial robots struggle to move at high speeds in complex environments, resulting in low work efficiency. Traditional straight-line or circular route planning methods are poorly applicable in complex route scenarios and cannot meet the requirements of speed, accuracy, and stability.
By inversely solving the pose of the robot's end effector on a specified path, the relationship between angle segments and motion changes is constructed, the maximum path velocity and acceleration are calculated, and combined with the robot's control cycle, the joint angles and joint angular velocities of the robot at each control moment are planned to achieve efficient motion.
Under the given constraints, the robot can move at a higher speed along a specified path, reducing movement time, improving work efficiency, and ensuring the accuracy and smoothness of the path.
Smart Images

Figure CN121498686A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of robot control technology, and in particular to a robot route planning method, apparatus, electronic device and storage medium. Background Technology
[0002] In the field of robot control technology, with the continuous advancement of industrial automation, industrial environments are becoming increasingly complex, and production demands are becoming rapidly changing, placing higher requirements on the motion performance of industrial robots. To meet the demands for speed, accuracy, and stability, research on robot path planning has become increasingly important. In one approach, the robot primarily relies on straight or circular paths, employing fixed path speeds and accelerations to complete the entire route. This limits the robot's ability to move at higher speeds within permissible conditions to shorten movement time, resulting in low robot efficiency. Summary of the Invention
[0003] The purpose of this application is to provide a robot route planning method, apparatus, electronic device, and storage medium, so as to enable the robot to move at a higher speed within permissible conditions, thereby shortening the movement time and improving the robot's work efficiency. The specific technical solution is as follows:
[0004] A first aspect of this application provides a robot route planning method, the method comprising:
[0005] By inverse kinematics of the poses that the robot's end effector needs to achieve when located at discrete points on a specified path, an angle sequence containing angle segments of each discrete point is obtained; wherein, the angle segment of a discrete point contains: the joint angles that each joint of the robot needs to achieve at that discrete point.
[0006] Based on the angle segments of each discrete point, the motion change of each discrete point is calculated to obtain a change sequence; wherein, according to the arrangement order of each discrete point on the specified path, the motion change of each discrete point is: the sum of the motion change of the previous discrete point and the angle difference of the current discrete point; the motion change of the first discrete point in the change sequence is 0, and the angle difference of a discrete point is: the difference between the angle segment of the current discrete point and the angle segment of the previous discrete point in the angle sequence.
[0007] Based on the angle segments and motion changes at each discrete point, a first variation relationship between the angle segments and the motion changes is constructed.
[0008] Based on the change in motion at each discrete point and the first change relationship, constraints are constructed at that discrete point, characterized by path velocity and / or path acceleration; wherein, the path velocity represents the first derivative of the change in motion with respect to time; and the path acceleration represents the second derivative of the change in motion with respect to time.
[0009] Using the sequence of changes, calculate the maximum path velocity and maximum path acceleration required at each discrete point, provided that the constructed constraints are met.
[0010] Based on the maximum path speed, maximum path acceleration, and motion change required at each discrete point, and according to the robot's control cycle, the motion change and required path speed of the robot at each control moment are calculated during the process of controlling the end effector to pass through each discrete point.
[0011] Using the motion changes of the robot at each control moment and the required path velocity, combined with the second variation relationship of the angle segment with respect to the motion changes, the joint angle and joint angular velocity required by the robot at each control moment are calculated; wherein, the second variation relationship is constructed based on the angle segment of each two adjacent discrete points and the maximum required path velocity.
[0012] A second aspect of this application provides a robot route planning device, the device comprising:
[0013] An angle sequence acquisition module is used to perform inverse kinematics on the poses that the robot's end effector needs to achieve when it is located at each discrete point on a specified path, and obtain an angle sequence containing angle segments of each discrete point; wherein, the angle segment of a discrete point contains: the joint angles that each joint of the robot needs to achieve at that discrete point.
[0014] The change quantity sequence acquisition module is used to calculate the motion change of each discrete point based on the angle segments of each discrete point, and obtain the change quantity sequence; wherein, according to the arrangement order of each discrete point on the specified path, the motion change of each discrete point is: the sum of the motion change of the previous discrete point and the angle difference of the current discrete point; the motion change of the first discrete point in the change quantity sequence is 0, and the angle difference of a discrete point is: the difference between the angle segment of the current discrete point and the angle segment of the previous discrete point in the angle sequence.
[0015] The first relational construction module is used to construct the first change relation of the angle segment with respect to the change of motion based on the angle segment and the change of motion of each discrete point;
[0016] The constraint construction module is used to construct constraint conditions at each discrete point, characterized by path velocity and / or path acceleration, based on the motion change at each discrete point and the first change relationship; wherein the path velocity represents the first derivative of the motion change with respect to time; and the path acceleration represents the second derivative of the motion change with respect to time.
[0017] The first calculation module is used to calculate, using the sequence of changes, the maximum path velocity and maximum path acceleration required at each discrete point under the constructed constraints.
[0018] The second calculation module is used to calculate, according to the control cycle of the robot, the motion change and the required path speed of the robot at each control moment during the process of controlling the end effector to pass through each discrete point, based on the maximum path speed, maximum path acceleration and motion change required at each discrete point.
[0019] The third calculation module is used to calculate the joint angle and joint angular velocity that the robot needs to achieve at each control moment by using the motion change amount and the required path velocity of the robot at each control moment, combined with the second change relationship of the angle segment with respect to the motion change amount; wherein, the second change relationship is constructed based on the angle segment of each two adjacent discrete points and the maximum required path velocity.
[0020] A third aspect of this application provides an electronic device, including: a memory for storing a computer program; and a processor for executing the program stored in the memory to implement any of the robot route planning methods described above.
[0021] In another aspect of this application, a computer-readable storage medium is provided, wherein a computer program is stored therein, and when the computer program is executed by a processor, it implements any of the robot route planning methods described above.
[0022] In another aspect of the embodiments of this application, a computer program product containing instructions is provided, which, when run on a computer, causes the computer to execute any of the robot route planning methods described above.
[0023] The beneficial effects of this application's embodiments are as follows: Based on the robot route planning method provided in this application, after obtaining the poses of each discrete point on the specified path to be executed by the robot, the joint angles of each robot joint corresponding to each discrete point can be solved inversely to obtain an angle sequence. Furthermore, the motion change of each discrete point can be calculated based on the angle sequence. Since the motion change of a discrete point represents the accumulation of the differences between angle segments of every two adjacent discrete points before and including that discrete point, the change sequence can reflect the cumulative changes in the robot's motion state at each discrete point on the specified path. Based on the angle segments and motion changes of each discrete point, a first variation relationship of the angle segments with respect to the motion change is constructed. Furthermore, for each discrete point, constraints characterized by path velocity and / or path acceleration can be constructed based on the motion change of that discrete point and the first variation relationship. Correspondingly, under the condition that the constructed constraints are satisfied, the maximum path velocity and maximum path acceleration required at each discrete point are calculated. Furthermore, by combining the robot's control cycle with the maximum path velocity, maximum path acceleration, and motion change required at each discrete point, the required motion change and path velocity of the robot at each control moment can be calculated. Then, by combining the second relationship between the angle segment and the motion change, the required joint angle and joint angular velocity of the robot at each control moment can be calculated. In this way, the robot can be instructed to move according to the required joint angle and joint angular velocity at each control moment, thereby ensuring that the robot can move at a higher speed within permissible conditions when moving along a designated path, thus shortening the movement time and improving the robot's work efficiency. Of course, implementing any product or method of this application does not necessarily require achieving all of the above advantages simultaneously. Attached Figure Description
[0024] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other embodiments can be obtained based on these drawings.
[0025] Figure 1 This is a first flowchart of a robot route planning method provided in an embodiment of this application;
[0026] Figure 2a A schematic diagram of a shoe sole profile provided for this application;
[0027] Figure 2b A schematic projection of a path formed by linear motion, provided for an embodiment of this application;
[0028] Figure 2c A schematic projection of a path formed by spline motion, provided for an embodiment of this application;
[0029] Figure 2d A schematic diagram of the pose of the robot's end effector at seven teaching points, provided in an embodiment of this application;
[0030] Figure 3 A second flowchart of the robot route planning method provided in the embodiments of this application;
[0031] Figure 4 A schematic diagram illustrating the calculation of path speed at each discrete point, provided for an embodiment of this application;
[0032] Figure 5 A schematic diagram illustrating a route planning process using a general robot planner, provided as an embodiment of this application;
[0033] Figure 6 A flowchart illustrating spline motion analysis and path planning is provided for an embodiment of this application.
[0034] Figure 7 A structural diagram of a robot route planning device provided in an embodiment of this application;
[0035] Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Detailed Implementation
[0036] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art based on this application are within the scope of protection of this application.
[0037] In the field of robot control technology, with the continuous advancement of industrial automation, industrial environments are becoming increasingly complex, and production demands are becoming rapidly changing, placing higher demands on the motion performance of industrial robots. To meet the requirements of speed, accuracy, and stability, research on robot path planning has become increasingly important. In one approach, the robot mainly relies on straight or circular paths, using fixed path speeds and accelerations to complete the entire route. This prevents the robot from moving at its maximum speed within permissible conditions to shorten movement time, thus reducing its work efficiency. Traditional straight or circular fitting methods perform poorly when faced with complex routes. Due to their limited fitting accuracy, robots struggle to perform tasks in complex route scenarios requiring high precision, making traditional straight or circular fitting methods less applicable.
[0038] The robot in this application is an industrial robot with multiple joints. This application provides a robot path planning method, which can be applied to an electronic device. This electronic device can be a robot controller (e.g., a general planner), and correspondingly, different robots can implement the robot path planning method provided in this application through their own controllers. Alternatively, the electronic device can also be a control terminal in a robot control system. The robot control system includes at least one robot and a control terminal, and the control terminal can communicate with any robot included in the robot control system. Correspondingly, different robots can implement the robot path planning method provided in this application through the same control terminal in the robot control system. See also... Figure 1 , Figure 1 A first flowchart of a robot route planning method provided in this application embodiment, the method may include the following steps:
[0039] S101: Using the robot's end effector to perform inverse kinematics on the poses required when located at discrete points on the specified path, an angle sequence containing angle segments of each discrete point is obtained.
[0040] Among them, the angle segment of a discrete point includes: the joint angle that each joint of the robot needs to reach at that discrete point.
[0041] S102: Based on the angle segments of each discrete point, calculate the change in motion of each discrete point to obtain the change sequence.
[0042] In this context, according to the order of each discrete point on the specified path, the motion change of each discrete point is the sum of the motion change of the previous discrete point and the angle difference of the current discrete point; the motion change of the first discrete point in the change sequence is 0, and the angle difference of a discrete point is the difference between the angle segment of the current discrete point and the angle segment of the previous discrete point in the angle sequence.
[0043] S103: Based on the angle segments and motion changes of each discrete point, construct the first variation relationship of the angle segments with respect to the motion changes.
[0044] S104: Based on the motion change at each discrete point and the first change relationship, construct the constraint conditions at that discrete point characterized by path velocity and / or path acceleration.
[0045] Here, path velocity represents the first derivative of the change in motion with respect to time; path acceleration represents the second derivative of the change in motion with respect to time.
[0046] S105: Using the sequence of changes, calculate the maximum path velocity and maximum path acceleration required at each discrete point, provided that the constructed constraints are met.
[0047] S106: Based on the maximum path speed, maximum path acceleration, and motion change required at each discrete point, calculate the motion change and required path speed of the robot at each control moment as the end effector passes through each discrete point, according to the robot's control cycle.
[0048] S107: Using the changes in motion of the robot at each control moment and the required path velocity, combined with the second change relationship of the angle segment with respect to the changes in motion, calculate the joint angle and joint angular velocity that the robot needs to achieve at each control moment.
[0049] The second variation formula is constructed based on the angle segments of each pair of adjacent discrete points and the maximum path speed to be achieved.
[0050] Based on the robot path planning method provided in this application, after obtaining the poses of each discrete point on the specified path to be executed by the robot, the joint angles of each robot joint corresponding to each discrete point can be solved inversely to obtain an angle sequence. Then, the motion change of each discrete point can be calculated based on the angle sequence. Since the motion change of a discrete point represents the cumulative difference of angle segments between every two adjacent discrete points preceding and including that discrete point, the change sequence can reflect the cumulative change in the robot's motion state at each discrete point on the specified path. Based on the angle segments and motion changes of each discrete point, a first variation relationship of the angle segments with respect to the motion change is constructed. Furthermore, for each discrete point, constraints characterized by path velocity and / or path acceleration can be constructed based on the motion change and the first variation relationship. Correspondingly, under the condition that the constructed constraints are satisfied, the maximum path velocity and maximum path acceleration required at each discrete point are calculated. Furthermore, by combining the robot's control cycle with the maximum path velocity, maximum path acceleration, and motion change required at each discrete point, the required motion change and path velocity of the robot at each control moment can be calculated. Then, by combining the second relationship between the angle segment and the motion change, the required joint angle and joint angular velocity of the robot at each control moment can be calculated. In this way, the robot can be instructed to move according to the required joint angle and joint angular velocity at each control moment. This ensures that when the robot moves along a designated path, it can move at a higher speed within permissible conditions, thereby shortening the movement time and improving the robot's work efficiency.
[0051] Regarding step S101, the robot's end effector refers to the tool attached to the robot's end joint when the robot performs a specified task. For example, the specified task could be tasks such as applying glue, welding, polishing, and spraying. In a shoe-making scenario, the specified task the robot needs to perform might be applying glue to the four contours of the shoe sole; in this case, the robot's end effector could be a glue-applying tool (such as a glue gun). In a workpiece manufacturing scenario, the specified task the robot needs to perform might be welding different parts of the workpiece together; in this case, the robot's end effector could be a welding tool (such as a welding gun).
[0052] The specified path is the complete path that the robot's end effector must traverse when performing a specified task. Correspondingly, discrete points are points on the specified path. The specified path can be a path conforming to a spline curve. For example, the spline curve can be a NURBS (Non-Uniform Rational B-Spline) curve. Accordingly, the robot path planning method provided in this application can use NURBS curve fitting to discrete points, simplifying path points for complex contours and reducing the amount of engineering editing.
[0053] In one implementation, the electronic device can acquire the poses of the robot's end effector at a preset number of sampling points (i.e., teaching points) along a specified path during the robot teaching process, i.e., during the process of manually guiding the robot to perform a specified task, and use these poses as the teaching points' poses. The specific process for obtaining the teaching points is not limited in this application. For example, the teaching points can be determined manually. That is, multiple positions that the robot needs to traverse during the task are manually specified as teaching points. Alternatively, the teaching points can also be calculated based on computer vision technology. For example, an image acquisition device can be used to acquire images of the objects processed by the robot during the task, and then the acquired images can be detected to obtain teaching points. For example, in the shoe-making scenario mentioned above, the object processed by the robot during the task is the sole; an image of the sole can be acquired to detect the edges of the sole, and then multiple positions can be sampled from the detected edges as teaching points.
[0054] The pose of a teach pendant includes: the position of the teach pendant (i.e., the position of the robot's end effector when it is located at the teach pendant), and the orientation of the teach pendant (i.e., the orientation of the robot's end effector when it is located at the teach pendant). The order in which the robot passes through the teach pendants along a specified path during the execution of a given task can be considered the order of the teach pendants (this can be called the task order between the teach pendants). Accordingly, the teach pendant at the beginning of the specified path is the first teach pendant, and the teach pendant at the end of the specified path is the last teach pendant.
[0055] Taking the shoe-making scenario described above as an example, the robot's designated task is to apply glue to the four contours of the shoe sole, and the robot's end effector is a glue gun. See also... Figure 2a , Figure 2a This is a schematic diagram of a shoe sole profile provided for this application. Accordingly, the robot needs to... Figure 2a The shoe sole outline shown is subjected to a glue-applying motion. Correspondingly, the electronic equipment can acquire the pose of the robot's end effector at 26 teaching points during the robot teaching process, that is, during the process of manually guiding the robot to perform a specified task, and use it as the pose of the teaching point.
[0056] For example, electronic devices can control the robot's end effector to move to each teach point in a linear motion, following the sequence of teach points. See also Figure 2b , Figure 2b This is a schematic projection of a path formed by linear motion, provided as an embodiment of this application. Figure 2bIn this diagram, a black dot represents a teaching point. The path segment between two teaching points represents a straight line in space. Understandably, a path formed by linear motion is not smooth enough and may even exhibit stuttering. If a path formed by linear motion is directly smoothed, the smoothed path may not strictly pass the teaching point, resulting in path deviation.
[0057] Correspondingly, electronic devices can control the robot's end effector to move to each teaching point in sequence via spline motion. See also Figure 2c , Figure 2c This is a schematic projection of a path formed by spline motion, as provided in an embodiment of this application. Figure 2c In the diagram, a black dot represents a teaching point. The path segment between two teaching points represents a curve in space. That is, the specified path is a path conforming to a spline curve. See also... Figure 2d , Figure 2d This is a schematic diagram of the pose of the robot's end effector at seven teaching points, as provided in the embodiments of this application. Figure 2d In the diagram, points a, b, c, d, e, f, and g each represent a teaching point. The electronic device can acquire the pose (position and orientation) of the robot's end effector at each teaching point. S represents a specified path. 201 represents the robot's end effector (glue gun). The arrow direction of the robot's end effector at each teaching point indicates the glue dispensing direction of the glue gun.
[0058] In addition, the robot in this application can also perform tasks such as grinding, spraying, welding, and gluing. The route planning method provided in this application can simplify the robot's motion programming and improve the accuracy of the running route.
[0059] In some embodiments, the electronic device can directly treat each teach point as a discrete point. For example, if the number of teach points is greater than a preset threshold, it indicates that the number of teach points is sufficient. Accordingly, each teach point can be directly treated as a discrete point, that is, the pose of each teach point can be used as the pose that the robot's end effector needs to achieve when it is located at each discrete point on the specified path. The preset threshold can be set by a technician according to the actual task the robot needs to perform. For example, when the robot performs the above-mentioned glue-applying task, the preset threshold can be 2000.
[0060] Understandably, for a given path that the robot needs to run, the more teaching points there are on that path, the smaller the average distance between each teaching point. Correspondingly, the smaller the average distance between teaching points, the smaller the difference between the curve the robot travels between those two teaching points and the given path during subsequent path planning. This ensures the accuracy of the robot's operation.
[0061] In some embodiments, the electronic device can interpolate based on the poses of each taught point to obtain the poses of discrete points along a specified path. See also Figure 3 , Figure 3 This is a second flowchart of a robot route planning method provided in an embodiment of this application. Figure 1 Based on this, before step S101, the method further includes:
[0062] S108: Obtain the poses that the robot's end effector needs to achieve when it is located at each teaching point on the specified path, and use them as the poses of each teaching point.
[0063] S109: Based on the pose of each teaching point, interpolation is performed to obtain the pose that the end effector needs to achieve when it is located at each discrete point on the specified path.
[0064] In this embodiment, the electronic device can interpolate between each taught point to obtain discrete points on a specified path. That is, the electronic device interpolates based on the poses of each taught point to obtain the poses of each discrete point, thus determining the poses that the robot's end effector needs to achieve when located at each discrete point on the specified path. For example, if the number of taught points is not greater than a preset threshold, it indicates that the number of taught points is small. Accordingly, interpolation can be performed based on the poses of each taught point to obtain the poses of each discrete point. The poses that the robot's end effector needs to achieve when located at each discrete point on the specified path can be referred to as the poses of each discrete point. Correspondingly, the pose of a discrete point includes: the position of the discrete point (i.e., the position of the robot's end effector when located at that discrete point), and the orientation of the discrete point (i.e., the orientation of the robot's end effector when located at that discrete point).
[0065] In one implementation, the acquired pose of the teaching point includes: position and orientation represented in Cartesian space coordinates. Step S109 includes: converting the orientation of each teaching point, represented in Cartesian space coordinates, into an orientation represented in quaternion form; interpolating the position and orientation represented in quaternion form of each teaching point to obtain the position and orientation represented in quaternion form of each discrete point; converting the orientation represented in quaternion form of each discrete point into an orientation represented in Cartesian space coordinates, and combining the position of each discrete point to obtain the pose that the end effector needs to achieve when located at each discrete point on the specified path.
[0066] In this embodiment, the pose of the teaching point is represented in Cartesian coordinates. The position represented in Cartesian coordinates can be expressed as: An orientation expressed in Cartesian coordinates can be represented as: In Cartesian coordinate system, the origin can represent a specific location in real space. For example, the origin of Cartesian coordinate system can represent the center point of the robot's base, or any point in the space where the robot is located. This represents the coordinate value of the teaching point on the X-axis in Cartesian space. This represents the Y-coordinate of the teaching point on the Cartesian space. This represents the coordinate value of the teaching point on the Z-axis in Cartesian space; This indicates the rotation angle of the end effector about the X-axis at the position of the taught point. This indicates the rotation angle of the end effector about the Y-axis at the position of the taught point. This represents the rotation angle of the end effector around the Z-axis at the position of the taught point. Correspondingly, for each taught point, the attitude represented in Cartesian coordinates can be converted to an attitude represented in quaternion form, thereby eliminating abrupt changes in attitude interpolation and the gimbal lock problem of Euler angles. The attitude represented in quaternion form can be expressed as: .in, Indicates the real part, , and This represents the imaginary part vector.
[0067] In one implementation, after transforming the pose of each teaching point in Cartesian coordinates, the angular difference between the poses of any two adjacent teaching points is determined according to the task order between them. If the angular difference between the poses of two adjacent teaching points exceeds 180 degrees, the transformed pose of the latter teaching point can be inverted, i.e., the negative values of the real and imaginary parts of the transformed pose are calculated respectively. The inverted result can then be used as the pose of the latter teaching point in quaternion form. This enables quaternion-based pose flipping optimization, avoiding the problem of pose flipping between adjacent teaching points. This also avoids the problem of the end effector being unable to plan a path according to the poses of adjacent teaching points, and the robot being unable to move along the specified path due to pose flipping.
[0068] After obtaining the pose of each taught point in quaternion form, the electronic device can interpolate using the poses of every two adjacent taught points to obtain the pose of at least one discrete point located between those two taught points. For example, the number of interpolated discrete points is not less than a preset threshold. The discrete points can be points in the pose representation space between every two adjacent taught points obtained through interpolation. Alternatively, the discrete points can include both taught points and points in the pose representation space between every two adjacent taught points obtained through interpolation.
[0069] In one implementation, the electronic device can use a linear interpolation algorithm to interpolate the positions and orientations of every two adjacent teaching points, calculating the position and orientation of at least one discrete point located between those two teaching points. Since the orientation of the interpolated discrete point is obtained based on a linear interpolation algorithm, it is not represented in standard quaternion form. Therefore, the orientation of the interpolated discrete point needs to be normalized to obtain its orientation represented in standard quaternion form. Correspondingly, the orientation of a discrete point represented in standard quaternion form (denoted as ) is... ) can be represented as:
[0070] ;
[0071] in, This represents the normalized pose of a discrete point. This indicates the orientation of the discrete point obtained through interpolation; This represents the magnitude of the attitude of the discrete point obtained through interpolation.
[0072] Accordingly, the electronic device can interpolate using the positions of every two adjacent teaching points to obtain the position of at least one discrete point located between those two teaching points. The position of each discrete point and the attitude represented in quaternion form can be expressed as: Furthermore, the electronic device can convert the pose of each discrete point, represented in quaternion form, into a pose represented in Cartesian coordinates. Combining this with the positions of each discrete point, it can obtain the pose that the end effector needs to achieve when located at each discrete point on the specified path. Accordingly, the pose of each discrete point in Cartesian coordinates can be represented as: .
[0073] Based on the above processing, after acquiring the teaching points on the specified path, the electronic device can increase the number of discrete points on the specified path through interpolation, that is, acquire the poses that the end effector needs to achieve when located at each discrete point on the specified path. Furthermore, when performing route planning based on the poses of each discrete point, the accuracy of route planning can be improved. In addition, by using a spatial position and attitude synchronous interpolation method, it can be ensured that the robot's position and attitude can synchronously reach the pose of the teaching points during the actual execution of the specified task.
[0074] Furthermore, compared to directly using the position and orientation of each taught point in Cartesian coordinates to calculate the pose of each discrete point, the embodiments of this application can utilize the orientation represented by quaternions to eliminate the uncertainty inherent in the description of Euler angles (i.e., the orientation represented in Cartesian coordinates). That is, it avoids the problem of orientation flipping between adjacent taught points. This also avoids the problem that the end effector cannot perform path planning according to the orientations of adjacent taught points due to orientation flipping, and the robot cannot move along the specified path.
[0075] Based on the NURBS interpolation method, this approach overcomes the limitations of robots traversing non-linear circular arc scenarios, enabling effective execution across all spatial shapes, such as ellipses and parabolas. After obtaining the required poses of the robot's end effector at discrete points along a specified path, the electronic device can utilize inverse kinematics algorithms (e.g., analytical and numerical methods) to perform inverse kinematics calculations for the pose at each discrete point, obtaining angle segments to those points, and thus, an angle sequence containing these angle segments. Each angle segment at a discrete point contains the required joint angles for each joint of the robot at that point.
[0076] The order of discrete points (or task order) can be defined as the sequence of discrete points the robot must traverse along a specified path during the execution of a single task. The number of discrete points can be denoted as N. The angle sequence can be represented as: . This represents the angle segment at the i-th discrete point. For example, if N is 2000, the angle sequence contains 2000 angle segments. The i-th angle segment in the angle sequence represents the joint angles that the robot's end effector needs to achieve when it is located at the i-th discrete point during the subsequent execution of the specified task. When the robot has 6 joints (i.e., it is a six-axis robot), the angle segment of a discrete point can be represented by a 6-dimensional vector. The value in the j-th dimension of the 6-dimensional vector of a discrete point represents the joint angle that the robot's end effector needs to achieve at that discrete point during the subsequent execution of the specified task.
[0077] Regarding step S102, after obtaining the angle segments of each discrete point, the change in motion of each discrete point can be calculated based on these angle segments, resulting in a sequence of changes. This sequence of changes can be represented as: . This represents the change in motion at the i-th discrete point. For example, It can be calculated using the following formula:
[0078] ;
[0079] This represents the angle segment of the i-th discrete point. This represents the difference between the angle segment of the i-th discrete point and the angle segment of the (i-1)-th discrete point. For example, when representing the angle segment of a discrete point as a 6-dimensional vector, Let be the distance between the six-dimensional vector representing the angle segment of the i-th discrete point and the six-dimensional vector representing the angle segment of the (i-1)-th discrete point. The distance between the two vectors can be expressed as: . Representing vectors The value of the i-th element in the array. Representing vectors The value of the i-th element. The change in motion of a discrete point can be called the change in motion corresponding to the angular segment of that discrete point.
[0080] Regarding step S103, after obtaining the angle segments and motion changes at each discrete point, a first variation formula for the angle segments with respect to the motion changes can be constructed. Accordingly, this first variation formula can describe the relationship between the angle segment (J) and the motion changes (s). When the robot is a six-axis robot, the angle segment can be represented as a six-dimensional vector. This first variation formula can describe the relationship between the six-dimensional angle segment and the one-dimensional motion changes. Accordingly, the electronic device can calculate a six-dimensional angle segment corresponding to a given motion change based on this first variation formula.
[0081] In some embodiments, S103 includes: constructing a univariate multivariate function of the angle segment with respect to the motion change based on the motion change and angle segment of each adjacent first specified number of discrete points, as the first sub-relationship corresponding to the first specified number of discrete points. Wherein, the first specified number is greater than 2.
[0082] In this embodiment, the exponent of the highest-order term in each first sub-relation is: a first specified number minus 1. For example, if the first specified number is 3, then the exponent of the highest-order term in each first sub-relation is 2, and the number of first sub-relations obtained is: the number of discrete points minus 2. If the first specified number is 4, then the exponent of the highest-order term in each first sub-relation is 3, and the number of first sub-relations obtained is: the number of discrete points minus 3.
[0083] In some embodiments, the first specified number is 3. Accordingly, based on the motion changes and angular segments of the first specified number of discrete points, the first sub-relation corresponding to the first specified number of discrete points is expressed as:
[0084] ;
[0085] This represents the change in motion of the first discrete point out of the first specified number of discrete points; This represents the first sub-relation corresponding to the first discrete point among the first specified number of discrete points; This represents the constant term in the first sub-relation. This represents the coefficient of the linear term in the first sub-relation. This represents the coefficient of the quadratic term in the first sub-relation; Indicates the change in motion; Indicates an angle segment.
[0086] In this embodiment of the application, the first specified number is 3. The electronic device can construct the first sub-relationship corresponding to the 3 discrete points based on the motion change and angle segment of each of the 3 adjacent discrete points. That is, for three adjacent discrete points, a quadratic function of motion change (s) can be used to fit the first sub-relationship corresponding to the 3 discrete points.
[0087] In one implementation, for a discrete point, according to the task order among the discrete points, if the discrete point is the first among a first specified number of adjacent discrete points, then the first sub-relation constructed based on the first specified number of discrete points can be used as the first sub-relation corresponding to that discrete point. When the first specified number is 3, for the last two discrete points among all discrete points, the first sub-relation corresponding to the third-to-last discrete point can be determined as the first sub-relation corresponding to those two last two discrete points. For example, for the above angle sequence: , sequence of changes: When constructing the first sub-relation corresponding to the first discrete point, the electronic device can fit the corresponding first sub-relation based on the motion changes and angle segments of the first, second, and third discrete points. That is, it can... and , and , and Substitute them into the following formulas respectively:
[0088] ;
[0089] Furthermore, the first sub-relation corresponding to the first discrete point can be solved to obtain the following: , and This allows us to construct the first sub-relation corresponding to the first discrete point. Similarly, for N discrete points, we can construct the first sub-relation corresponding to each of the first N-2 discrete points.
[0090] Based on the above processing, for each path interval on a specified path (i.e., the path interval between a first specified number of adjacent discrete points), the coefficients of each term in the first sub-relationship corresponding to the first specified number of discrete points can be calculated using the motion changes and angle segments of those first specified number of discrete points, thus obtaining the first sub-relationship corresponding to those first specified number of discrete points. In other words, the electronic device can construct the first sub-relationship using the motion changes and angle segments of multiple consecutive discrete points through a globally parameterized model.
[0091] Regarding step S104, since the first variation equation can describe the relationship between the angle segment (J) and the change in motion (s), the first derivative of the first variation equation with respect to the change in motion reflects the rate of change of the angle segment relative to the change in motion; the second derivative of the first variation equation with respect to the change in motion reflects the rate of change of the rate of change of the angle segment relative to the rate of change in motion. Accordingly, the electronic device can construct constraints characterized by path velocity and / or path acceleration at each discrete point based on the change in motion at each discrete point and the first variation equation, considering multiple dimensions such as robot joints, Cartesian space, and the lifespan of dynamic structural components.
[0092] In one implementation, step S104 includes: for each discrete point, constructing constraints characterized by path velocity and / or path acceleration at that discrete point based on the motion change of that discrete point and the first sub-relationship corresponding to that discrete point. After constructing the first sub-relationship corresponding to each discrete point, the electronic device can construct constraints characterized by path velocity and / or path acceleration at that discrete point based on the motion change of that discrete point and the first sub-relationship corresponding to that discrete point.
[0093] In some embodiments, the constraints include at least one of the following: joint angular velocity constraints, joint angular acceleration constraints, torque constraints, Cartesian space velocity constraints, and Cartesian space acceleration constraints.
[0094] In a complete route planning process, the joint angular velocity constraints, joint angular acceleration constraints, torque constraints, Cartesian space velocity constraints, and Cartesian space acceleration constraints can all be constructed using the methods described later. Alternatively, in a complete route planning process, for some of the joint angular velocity constraints, joint angular acceleration constraints, torque constraints, Cartesian space velocity constraints, and Cartesian space acceleration constraints, the construction methods described later can be used, while the other constraints can be constructed using other methods.
[0095] The joint angular velocity constraints are constructed through the following steps:
[0096] For each discrete point, based on the change in motion at that discrete point and the corresponding first sub-relation, a joint angular velocity constraint condition, characterized by path velocity, is constructed at that discrete point; wherein, the constructed joint angular velocity constraint condition is expressed as:
[0097]
[0098] ;
[0099] The expression representing the relationship between the angle segment and time; This represents the joint angular velocity of each joint of the robot; This represents the first sub-relation corresponding to the discrete point; This represents the first derivative of the change in motion with respect to time. Indicates about The function; Indicates the change in motion; This indicates the maximum joint angular velocity supported by each joint of the robot.
[0100] In this embodiment of the application, the constraint conditions include joint angular velocity constraints. Wherein, The function representing the relationship between an angle segment and time can be understood as follows: the first derivative of the angle segment with respect to time represents the joint angular velocity. That is, This represents angular velocity. Furthermore, according to mathematical relationships (the chain rule), we know that: ,in, Let represent the first derivative of the first sub-relation (i.e., the angle segment with respect to the change in motion). It can be written as , It represents the derivative of the change in motion with respect to time. This represents the constraint condition. Correspondingly, it applies to a discrete point (e.g., the i-th discrete point). This indicates that the first sub-relation corresponding to the discrete point is for... The derivative of (the change in motion) can be expressed as:
[0101] ;
[0102] This represents the change in motion at that discrete point (i.e., the i-th discrete point). It can be seen that... For a function of s, correspondingly, It can be represented as That is, for a discrete point, when the robot's end effector is located at that discrete point, the angular velocities of each joint of the robot can be expressed as: Correspondingly, the constructed joint angular velocity constraints indicate: Less than the maximum joint angular velocity supported by each joint of the robot.
[0103] Understandably, when the robot is a six-axis robot, the dimension of an angle segment is six. For example, an angle segment of a discrete point can be represented by a six-dimensional vector. In this case, and The dimension is also 6; express The value of each dimension is less than or equal to The value of the corresponding dimension; One dimension represents the maximum joint angular velocity supported by one of the robot's joints. The maximum joint angular velocities supported by different joints of the robot can be the same or different. Thus, by characterizing the rate of change of motion (i.e., angular velocity) with respect to the function of angular segments and the change in motion, it is possible to construct the path velocity at that discrete point. The constraints are characterized by converting unknowns in the joint angular velocity constraints into knowns, thus constructing the constraints for joint angular velocity.
[0104] Joint angular acceleration constraints are constructed through the following steps:
[0105] Based on the motion change at this discrete point and the corresponding first sub-relation, a joint angular acceleration constraint condition, characterized by path velocity and path acceleration, is constructed at this discrete point; wherein, the constructed joint angular acceleration constraint condition is expressed as:
[0106]
[0107]
[0108] The expression representing the change of an angle segment with respect to time. This represents the joint angular velocity of each joint of the robot. This represents the angular acceleration of each joint of the robot. This represents the first sub-relation corresponding to the discrete point; This represents the first derivative of the change in motion with respect to time. This represents the second derivative of the change in motion with respect to time. and Indicates about The function; This represents the minimum joint angular acceleration supported by each joint of the robot. This represents the maximum joint angular acceleration supported by each joint of the robot.
[0109] In this embodiment of the application, the constraint conditions include joint angular acceleration constraints. Wherein, The function representing the relationship between an angle segment and time can be understood as follows: the second derivative of the angle segment with respect to time represents the joint angular acceleration. That is, This represents angular acceleration. Furthermore, according to mathematical relationships (the chain rule), we know that: ,in, This represents the derivative of the change in motion with respect to time. Correspondingly, it represents the derivative with respect to a discrete point (e.g., the i-th discrete point). This indicates that the first sub-relation corresponding to the discrete point is for... The second derivative of (the change in motion) can be expressed as:
[0110]
[0111] That is, for a discrete point, when the robot's end effector is located at that discrete point, the angular acceleration of each joint of the robot can be expressed as: Correspondingly, the constructed joint angular acceleration constraints indicate: It is less than the maximum joint angular acceleration supported by each joint of the robot, and greater than the minimum joint angular acceleration supported by each joint of the robot. This means that when the robot is a six-axis robot, the dimension of the angle segment is six-dimensional. For example, the angle segment of a discrete point can be represented by a six-dimensional vector. In this case, , and The dimension is also 6. The maximum joint angular acceleration supported by different joints of the robot can be the same or different. Thus, by using the functional relationship between angular segments and the change in motion, the rate of change of motion with respect to time (i.e., angular acceleration) can be characterized, and the path velocity at that discrete point can be constructed. ) and path speed ( The constraints are characterized by converting the unknowns in the joint angular acceleration constraints into knowns, thus constructing the joint angular velocity constraints.
[0112] Moment constraints are constructed through the following steps:
[0113] Based on the change in motion at this discrete point and the corresponding first sub-relation, a torque constraint condition characterized by path velocity and path acceleration is constructed at this discrete point; wherein, the constructed torque constraint condition is expressed as:
[0114]
[0115]
[0116] The expression representing the relationship between the torque of each joint of the robot and time; The expression representing the change of an angle segment with respect to time. This represents the joint angular velocity of each joint of the robot. This represents the angular acceleration of each joint of the robot. Represents the inertia matrix; Represents the matrix of Coriolis force and centrifugal force; Represents the gravity matrix; To be It is obtained by converting it into a function of the change in motion; , and Indicates about The function; This represents the first sub-relation corresponding to the discrete point; This represents the minimum torque that each joint of the robot can support; This indicates the maximum torque supported by each joint of the robot; Indicates the change in motion; This represents the first derivative of the change in motion with respect to time. This represents the second derivative of the change in motion with respect to time. This indicates transpose.
[0117] In this embodiment of the application, the constraint conditions include torque constraint conditions. Wherein, This represents the first derivative of the angle segment with respect to time, i.e. This indicates the joint angular velocity. Let represent the second derivative of the angle segment with respect to time, i.e., This represents angular acceleration. Thus, by using the functional relationship between angular segments and the change in motion, the torque of each joint of the robot can be characterized, and the path velocity at that discrete point can be constructed. ) and path speed ( The constraints are characterized by converting unknowns in the torque constraints into known quantities, thus constructing the torque constraints. Furthermore, the torque constraints can calculate not only the output limits of the joint motors but also the force limits of the gearbox, including but not limited to bending moment constraints and gearbox constraints. This ensures that the robot's output does not exceed the motor's capacity during operation, guaranteeing structural safety during operation.
[0118] Compared to methods that do not include torque constraints, the embodiments of this application take into account the actual performance capability of the motor and introduce dynamic constraints. In this way, the motor's capacity can be effectively utilized while avoiding excessive excess capacity during operation or damage caused by exceeding the motor's tolerance range.
[0119] Cartesian space velocity constraints are constructed through the following steps:
[0120] Based on the change in motion at this discrete point and the corresponding first sub-relation, a Cartesian space velocity constraint condition, characterized by path velocity, is constructed at this discrete point; wherein, the constructed Cartesian space velocity constraint condition is expressed as:
[0121]
[0122]
[0123] Represents the Cartesian space velocity of the end effector. , and These represent the path velocities of the end effector in the x-axis, y-axis, and z-axis directions in Cartesian space, respectively. , and These represent the rotational speeds of the end effector around the x-axis, y-axis, and z-axis of Cartesian space, respectively. Let: represent the angle segments that the joint angles of each joint of the robot satisfy. The Jacobian matrix representing the conversion relationship between the joint angular velocities of the robot's joints and the Cartesian space velocity of the end effector. This represents the rate of change of the Jacobian matrix; The expression representing the change of an angle segment with respect to time. This represents the joint angular velocity of each joint of the robot; This represents the first sub-relation corresponding to the discrete point; Indicates about The function; This indicates the maximum Cartesian path speed and maximum Cartesian rotation speed supported by the end effector; It represents the change in motion. It represents the first derivative of the change in motion with respect to time.
[0124] In this embodiment, Cartesian space velocity includes: Cartesian space path velocity and Cartesian space rotational velocity. For example, in the case of a six-axis robot, Cartesian space velocity can be expressed as:
[0125] .
[0126] in, This represents the joint angular velocity that the robot's i-th joint needs to achieve at this discrete point.
[0127] Accordingly, the electronic device can constrain at least one of the Cartesian space path velocity and the Cartesian space rotational velocity. The constraint on the Cartesian space path velocity can be expressed as:
[0128]
[0129] The constraint on the attitude velocity in Cartesian space can be expressed as:
[0130] .
[0131] Thus, it is possible to use the Jacobian matrix to measure the path velocity ( The velocity in Cartesian space is represented by (s) and the change in motion (s), and then the velocity constraints in Cartesian space are constructed.
[0132] Cartesian space acceleration constraints are constructed through the following steps:
[0133] Based on the change in motion at this discrete point and the corresponding first sub-relation, a Cartesian space acceleration constraint condition, characterized by path velocity, is constructed at this discrete point; wherein, the constructed Cartesian space acceleration constraint condition is expressed as:
[0134]
[0135]
[0136] Represents the Cartesian acceleration of each joint of the robot; Let: represent the angle segments that the joint angles of each joint of the robot satisfy. The Jacobian matrix representing the conversion relationship between the joint angular velocities of the robot's joints and the Cartesian space velocity of the end effector. This represents the rate of change of the Jacobian matrix; This represents the first sub-relation corresponding to the discrete point; , Indicates about The function; This represents the maximum Cartesian acceleration supported by each joint of the robot. This represents the minimum Cartesian acceleration supported by each joint of the robot. It represents the change in motion. This represents the first derivative of the change in motion with respect to time. This represents the second derivative of the change in motion with respect to time.
[0137] In this embodiment, the constraints include Cartesian space acceleration constraints. Thus, the robot's Cartesian space acceleration constraints can be expressed as path velocity using the Jacobian matrix. ), path acceleration ( The unknowns of the joint line acceleration constraints ( ) and the change in motion (s) are represented. The unknowns of the joint line acceleration constraints are converted into knowns, and Cartesian space acceleration constraints are constructed. Correspondingly, when the constraints include: joint angular velocity constraints, joint angular acceleration constraints, torque constraints, Cartesian space velocity constraints, and Cartesian space acceleration constraints, the constraints at a discrete point can be expressed as: .
[0138] In this way, constraints can be imposed from multiple dimensions such as joints, space, and motors to ensure the smoothness and rationality of the robot's planned route.
[0139] Regarding step S105, the electronic device can, based on the motion changes (i.e., the sequence of changes) at each discrete point, and using a reverse search algorithm, starting from the last discrete point, calculate the maximum path velocity and corresponding path acceleration supported at the previous discrete point, provided that the constructed constraints are met. Furthermore, based on the reverse search algorithm, starting from the first discrete point, it calculates the maximum path velocity and corresponding path acceleration supported at the next discrete point, provided that the constructed constraints are met, and considering the maximum path velocity and corresponding path acceleration achievable at each discrete point obtained from the reverse search algorithm, thus obtaining the maximum path velocity and maximum path acceleration required at each discrete point.
[0140] In some embodiments, step S105 includes: Step S1051: Starting from the discrete point corresponding to the last motion change in the change sequence, and with the path velocity of the last discrete point being 0, based on the reverse search algorithm, in reverse order of the arrangement, for each discrete point, sequentially calculate the first maximum path velocity supported by the previous discrete point and the path acceleration and first minimum path velocity corresponding to the first maximum path velocity, under the condition of satisfying the constraint conditions and the first preset formula at the previous discrete point, until the first maximum path velocity supported by each discrete point and the path acceleration and first minimum path velocity corresponding to the first maximum path velocity are obtained. The first preset formula is:
[0141] ;
[0142]
[0143] Represents the path velocity at a discrete point. This represents the amount of motion change at the discrete point; This represents the path velocity of the previous discrete point. This represents the change in motion of the previous discrete point. This represents the difference between the amount of motion change at this discrete point and the previous discrete point. This represents the path acceleration between the current discrete point and the previous discrete point.
[0144] Step S1052: Starting from the discrete point corresponding to the first change in motion in the change sequence, and with the path velocity of the first discrete point being 0, based on the forward search algorithm, and in the order of arrangement, calculate the second maximum path velocity and the path acceleration corresponding to the second maximum path velocity of the next discrete point, provided that the constraints, the second preset formula, and the first maximum path velocity supported by the next discrete point are satisfied, until the second maximum path velocity and the path acceleration corresponding to the second maximum path velocity of each discrete point are obtained; wherein, the second preset formula is:
[0145] ;
[0146]
[0147] Represents the path velocity at a discrete point. This represents the amount of motion change at the discrete point; This represents the path velocity to the next discrete point after the given discrete point. It represents the change in motion of the next discrete point after the current discrete point. This represents the difference between the amount of motion change at the current discrete point and the next discrete point. This represents the path acceleration between the current discrete point and the next discrete point.
[0148] Step S1053: Based on the second maximum path velocity supported by each discrete point and the path acceleration corresponding to the second maximum path velocity, obtain the maximum path velocity and maximum path acceleration required at each discrete point.
[0149] In this embodiment, the electronic device takes the last discrete point (i.e., the discrete point corresponding to the last change in motion in the sequence of changes) as its starting point. The path velocity at the last discrete point is 0. That is, the first maximum path velocity and the first minimum path velocity supported by the last discrete point (starting point) are both 0. For a discrete point, given the first maximum and first minimum path velocities supported by that discrete point, a linear solver can be used to calculate the first maximum path velocity supported by the previous discrete point, the path acceleration corresponding to the first maximum path velocity, and the first minimum path velocity, under the constraint conditions and the first preset formula, satisfied by the previous discrete point. The first maximum path velocity supported by each discrete point can be denoted as: .
[0150] In a pair of adjacent discrete points, the left discrete point represents the discrete point passed by the end effector later when moving along the specified path; the right discrete point represents the discrete point passed by the end effector earlier when moving along the specified path. A first preset formula represents the path velocity relationship between two adjacent discrete points, and is expressed as:
[0151]
[0152] Represents the path velocity at a discrete point; This represents the path velocity of the previous discrete point. This represents the difference between the amount of motion change at this discrete point and the previous discrete point. This represents the path acceleration between the current discrete point and the previous discrete point. Correspondingly, among two adjacent discrete points, the constraint condition at the left discrete point can be represented by at least one of the following:
[0153]
[0154] in, This represents the angular or linear acceleration of the discrete point on the left. This represents the minimum angular acceleration or minimum linear acceleration of the discrete point on the left. This indicates the maximum angular acceleration or maximum linear acceleration of the discrete point on the left. This represents the angular velocity or linear velocity of the discrete point on the left. This indicates the maximum angular velocity or maximum linear velocity of the discrete point on the left.
[0155] Thus, the electronic device can use a reverse search algorithm to sequentially calculate the velocity range of the discrete points on the left (i.e., the velocity range formed by the first maximum path velocity and the first minimum path velocity) using the known maximum and minimum path velocities of the discrete points on the right. After completing the reverse search, i.e., obtaining the first maximum path velocity supported by each discrete point and the corresponding path acceleration and first minimum path velocity, the electronic device starts a forward search from the first discrete point (i.e., the discrete point corresponding to the first change in motion in the change sequence). The path velocity at the first discrete point is 0. That is, the first maximum path velocity and the first minimum path velocity supported by the first discrete point (the starting point) are the same, both being 0.
[0156] Similarly, for a discrete point, given the first maximum path velocity and the first minimum path velocity supported by that discrete point, a linear solver can be used to calculate the second maximum path velocity supported by the next discrete point and the corresponding path acceleration, provided that the constraints, the second preset formula, and the first maximum path velocity supported by the next discrete point are satisfied. For a discrete point, the second maximum path velocity is no greater than its first maximum path velocity. The second preset formula represents the path velocity relationship between two adjacent discrete points, and is expressed as:
[0157]
[0158] Represents the path velocity at a discrete point; This represents the path velocity to the next discrete point after the current discrete point. This represents the difference between the amount of motion change at the current discrete point and the next discrete point. This represents the path acceleration between the current discrete point and the next discrete point. Correspondingly, among two adjacent discrete points, the constraint condition at the rightmost discrete point can be represented by at least one of the following:
[0159]
[0160] in, This represents the angular or linear acceleration of the discrete point on the right. This represents the minimum angular acceleration or minimum linear acceleration of the discrete point on the right. This indicates the maximum angular acceleration or maximum linear acceleration of the discrete point on the right. This represents the angular velocity or linear velocity of the discrete point on the right. This indicates the maximum angular velocity or maximum linear velocity of the discrete point on the right.
[0161] In this way, the electronic device can recalculate the maximum path speed (i.e., the second maximum path speed) and the path acceleration corresponding to the second maximum path speed by using a forward search algorithm and all constraints, provided that the maximum path speed supported by each discrete point does not exceed the first maximum path speed supported by each discrete point.
[0162] In one implementation, the electronic device can directly use the second maximum path speed supported by each discrete point and the path acceleration corresponding to the second maximum path speed as the maximum path speed and maximum path acceleration required at each discrete point. In some embodiments, step S1053 includes: Step 1: Smoothing the second maximum path speed supported by each discrete point to obtain the maximum path speed required at each discrete point. Step 2: Calculating the maximum path acceleration required at each discrete point based on the maximum path speed required at every two adjacent discrete points.
[0163] In this embodiment, to reduce robot jitter caused by acceleration switching during the movement of the robot's end effector along a specified path, the electronic device can smooth the second maximum path velocity supported by each discrete point, and use the smoothing result as the maximum path velocity required at each discrete point. For example, the second maximum path velocity supported by each discrete point can be smoothed by adding third-order Jerk constraints, Bezier smoothing, phase plane filtering, etc. Correspondingly, the electronic device can recalculate the maximum path acceleration required at each discrete point based on the path velocity relationship between two adjacent discrete points (i.e., a first preset formula or a second preset formula).
[0164] See Figure 4 , Figure 4 This is a schematic diagram illustrating the calculation of path speed at each discrete point, provided in an embodiment of this application. Figure 4 In the diagram, the dotted solid lines represent velocity constraint lines, indicating the maximum path velocity characterized by the constraint conditions at each discrete point. Solid lines represent the first maximum path velocity supported by each discrete point obtained from the reverse search. Dotted-dash lines represent the second maximum path velocity supported by each discrete point obtained from the forward search. Dashed lines represent smoothing the second maximum path velocity supported by each discrete point; for example, smoothing can be achieved by adding third-order Jerk constraints (which can be simply called third-order smoothing), thus obtaining the maximum path velocity required at each discrete point. Based on the above processing, continuous acceleration during motion can be achieved through smoothing, avoiding robot jitter caused by acceleration switching and ensuring the smoothness of robot motion.
[0165] Regarding step S106, the robot's control cycle represents the period during which the robot switches between motion states. For example, the robot's control cycle can be 4 ms (milliseconds). Correspondingly, during the process of controlling the robot's end effector to move along a specified path, the electronic device can send control commands to the robot at each control moment to control the robot's motion state. Correspondingly, the time interval between any two adjacent control moments is the control cycle. Correspondingly, the electronic device can calculate the motion change and required path speed of the robot at each control moment during the process of controlling the end effector to pass through each discrete point, based on the maximum path speed, maximum path acceleration, and motion change required at each discrete point.
[0166] In some embodiments, step S106 includes: Step S1061: For each pair of adjacent discrete points, calculate the time required for the end effector to pass through the two discrete points based on the maximum path speed, maximum path acceleration, and motion change required at the two discrete points. Step S1062: Determine the time represented by each discrete point based on the calculated time, as the discrete time corresponding to each discrete point. Step S1063: Determine each control time when controlling the end effector according to the robot's control cycle, and the previous discrete time adjacent to each control time. Step S1064: For each control time, calculate the required motion change and path speed for that control time based on the maximum path speed, maximum path acceleration, and motion change required at the previous discrete time adjacent to that control time.
[0167] In this embodiment, the maximum path velocity, maximum path acceleration, and motion change at each discrete point are known. Furthermore, for each pair of adjacent discrete points, the electronic device can calculate the time required for the end effector to traverse those two discrete points using kinematic formulas, based on the maximum path velocity, maximum path acceleration, and motion change at those two discrete points.
[0168] In one implementation, the time required for the end effector to traverse every two adjacent discrete points is expressed as:
[0169]
[0170] Indicates that the end effector has passed the first The discrete point and the first The time required for each discrete point; Indicates the first The change in motion of a discrete point Indicates the first The change in motion at a discrete point; Indicates the first The maximum path speed required at each discrete point. Indicates the first The maximum path speed required at each discrete point; Indicates the first The maximum path acceleration required at each discrete point.
[0171] Among them, if This indicates that the end effector starts from the specified path at the first... The discrete point runs to the... The device moves at a constant velocity between discrete points. Correspondingly, the electronic device can calculate the motion of the end effector from the first discrete point based on the kinematic formula of uniform motion. The discrete point runs to the... The time required for each discrete point. If This indicates that the end effector is performing the action at the first stage. The discrete point and the first The discrete points undergo non-uniform motion. Correspondingly, the electronic device can calculate the end effector's velocity from the first discrete point based on the kinematic formula for uniformly accelerated motion. The discrete point runs to the... The time required for each discrete point.
[0172] Thus, the electronic device can calculate the duration between every two adjacent discrete points. Furthermore, the electronic device can determine the time represented by each discrete point based on the calculated durations, as the discrete time corresponding to each discrete point. The discrete time corresponding to the first discrete point can be called the starting time, denoted as: . No. The discrete time corresponding to each discrete point can be denoted as: . No. The discrete point and the first The relationship between discrete times corresponding to discrete points can be expressed as: Accordingly, the electronic device can determine the preceding discrete time interval adjacent to each control time interval based on each control time interval and each discrete time interval. Similarly, the electronic device can determine the following discrete time interval adjacent to each control time interval based on each control time interval and each discrete time interval.
[0173] For each control moment, the required change in motion and path velocity at that control moment can be calculated based on the maximum path velocity, maximum path acceleration, and change in motion required at the previous discrete moment adjacent to that control moment.
[0174] In one implementation, step S1064 includes: for each control moment, based on the maximum path velocity, maximum path acceleration, and motion change required to be achieved in the preceding discrete moment adjacent to that control moment, calculating the required motion change to be achieved at that control moment according to a third preset formula. The third preset formula is:
[0175] ;
[0176] ;
[0177] ;
[0178]
[0179] Indicates the control moment. Indicates the first The discrete time corresponding to each discrete point Indicates the first The discrete time corresponding to each discrete point; This indicates that the control time t is related to the first... The time difference between discrete moments corresponding to discrete points; This represents the path velocity required to be reached at control time t. Indicates the first The maximum path speed required at each discrete point. Indicates the first The maximum path acceleration required at each discrete point; This represents the change in motion at control time t. Indicates the first The change in motion at a discrete point.
[0180] In this embodiment of the application, for each control time (denoted as t). If This indicates that the control time is at: the first The discrete time corresponding to the i-th discrete point and the i-th discrete point Between discrete points corresponding to discrete times. Accordingly, after determining the preceding discrete time (referred to as the calibration discrete time for ease of description) adjacent to the control time, the electronic device can calculate the time difference between the control time and the calibration discrete time, which can be expressed as:
[0181]
[0182] in, It is the previous discrete time adjacent to the control time (i.e., the calibration discrete time of the control time).
[0183] Furthermore, after calculating the time difference between the control moment and the calibration discrete moment, the path velocity at the control moment can be calculated based on the maximum path velocity and maximum path acceleration required at the calibration discrete moment. The path velocity at the control moment (denoted as...) ) can be represented as: .in, This represents the path velocity at control time t. Indicates the first The maximum path speed required at each discrete point. Indicates the first The maximum path acceleration required at each discrete point.
[0184] After calculating the path velocity at the control moment, the motion change at the control moment can be calculated based on the maximum path velocity and maximum path acceleration required at the calibration discrete moment, and the motion change at the calibration discrete moment. The motion change at the control moment (denoted as...) ) can be represented as: .
[0185] Regarding step S107, after obtaining the motion changes and required path speeds of the robot at each control moment, the electronic device can calculate the joint angles and joint angular velocities required by the robot at each control moment by combining the second relationship between the angle segments and the motion changes. Accordingly, during the process of controlling the robot to perform the specified task, each joint of the robot can be controlled to run according to the required joint angular velocity at each control moment, so that each joint of the robot reaches the required joint angle at that control moment. In this way, the robot can be controlled to complete the specified path and fulfill the specified task.
[0186] In some embodiments, the second variation formula includes a second sub-formula corresponding to each discrete point. Accordingly, step S107 includes: Step S1071: For each control moment, determine from the discrete points that the corresponding discrete moment is prior to and adjacent to the control moment, and use these as calibration discrete points for that control moment. Step S1072: Using the motion change and path velocity required by the end effector at that control moment, and the second sub-formula corresponding to the calibration discrete point in the second variation formula, calculate the joint angle and joint angular velocity required by the robot at that control moment.
[0187] In this embodiment, after obtaining the angle segments and motion changes at each discrete point, a second variation formula of the angle segments with respect to the motion changes can be constructed. Accordingly, this second variation formula can describe the variation relationship of the angle segment (J) with respect to the motion changes (s). When the robot is a six-axis robot, this second variation formula can describe the variation relationship between the six-dimensional angle segments and the one-dimensional motion changes. Accordingly, the electronic device can calculate a six-dimensional angle segment corresponding to a given motion change (such as the motion changes at each control moment) based on this second variation formula.
[0188] The second variation relation includes a second sub-relation corresponding to each discrete point. In one implementation, to ensure the continuity of the calculated angular velocity at each control moment, a second sub-relation with a highest-order term of cubic can be constructed using the angle segments of each pair of adjacent discrete points and the maximum path velocity to be achieved. That is, the electronic device can construct the second sub-relation using the motion states (angle segments and the maximum path velocity to be achieved) of each pair of adjacent discrete points. Specifically, by using the motion states of each pair of adjacent discrete points, a second sub-relation is constructed that conforms to the angle segments and motion changes within a local region of the robot along a specified path. In other words, the electronic device can construct the second sub-relation using a local difference model. Furthermore, as can be seen from the process of constructing the first sub-relation, the construction method of the second sub-relation differs from that of the first sub-relation. In the process of constructing the second sub-relation, the path velocity (i.e., the maximum path velocity to be achieved at each discrete point) is additionally introduced, ensuring the continuity of the robot's velocity during movement.
[0189] For each control moment, the electronic device can determine from the discrete points that are adjacent to and precede the control moment (i.e., the calibration discrete points of the control moment), and the discrete points that are adjacent to and follow the control moment. That is, the relationship between the control moment and the discrete moments corresponding to the two determined discrete points can be expressed as: For a given control moment, based on the angle segments between the calibration discrete point and the subsequent discrete point, and the required maximum path velocity, the second sub-relation corresponding to that calibration discrete point is expressed as follows:
[0190] ;
[0191] ;
[0192] ;
[0193] ;
[0194] ;
[0195]
[0196] This represents the change in motion at the calibrated discrete point; This represents the second sub-relation corresponding to the calibrated discrete point; Indicates the change in motion; This represents the angle segment of the calibrated discrete point; This represents the angle segment of the next discrete point after the current calibration discrete point. This indicates the path speed required to reach the specified discrete point. This indicates the path velocity required to reach the next discrete point after the current calibration discrete point. It represents the difference between the amount of motion change at the current calibrated discrete point and the next discrete point.
[0197] In some embodiments, S1072 includes: Step 1: Based on the second sub-relation corresponding to the calibration discrete point, construct a third sub-relation for the angle segment with respect to the motion change during the time interval between the calibration discrete point and the next discrete point, and a fourth sub-relation for the joint angular velocity with respect to the path velocity. Step 2: Substitute the motion change and path velocity required by the end effector at the control moment into the third sub-relation to obtain the joint angle required by the robot at the control moment, and substitute them into the fourth sub-relation to obtain the joint angular velocity required by the robot at the control moment.
[0198] In this embodiment of the application, the first derivative of the second sub-relation can be obtained based on the second sub-relation corresponding to a discrete point (i.e., ) and second derivative (i.e. ).in, It can be represented as: ; It can be represented as: Furthermore, the electronic device can utilize the constant term, linear coefficient, and quadratic coefficient of the second sub-relation corresponding to the calibrated discrete point to construct the third and fourth sub-relations for any time between the discrete times corresponding to the two determined discrete points. Within the time interval between the calibrated discrete point and the next discrete point, the third sub-relation of the angle segment with respect to the change in motion is expressed as:
[0199]
[0200] ;
[0201] t represents any time within the time interval between the current discrete point and the discrete time corresponding to the next discrete point. This represents the change in motion at the calibrated discrete point; This represents the change in motion at the next discrete point after the calibrated discrete point; Indicates time The change in motion; This indicates that the i-th joint of the robot is at time i. The required joint angle; This represents the joint angle that the robot's i-th joint needs to reach at this calibrated discrete point. This represents the joint angle that the robot's i-th joint needs to reach at the next discrete point after the calibration discrete point. This represents the joint angular velocity that the robot's i-th joint needs to achieve at the calibrated discrete point. This represents the joint angular velocity that the robot's i-th joint needs to achieve at a discrete point after the calibration discrete point. It represents the difference between the amount of motion change at the current calibrated discrete point and the next discrete point.
[0202] During the time interval between the discrete moments corresponding to the current calibrated discrete point and the next discrete point, the fourth sub-relation of the joint angular velocity with respect to the path velocity is expressed as:
[0203]
[0204] ;
[0205] in, This represents the joint angular velocity that the i-th joint of the robot needs to reach at time t; This represents the path velocity at time t. Based on the above processing, the conversion between time, motion changes, and angle segments can be achieved. For each control moment, the required motion change and path velocity of the robot at that control moment can be calculated. In this way, the robot can strictly traverse every point on the specified path, ensuring the accuracy of the running route.
[0206] See Figure 5 , Figure 5 This is a schematic diagram illustrating a route planning process using a general robot planner, as provided in an embodiment of this application. Figure 5In this context, user input indicates that the electronic device can acquire the user's input of the desired robot action (i.e., task). The electronic device supports spline motion analysis. Based on the robot route planning method provided in this application, spline motion analysis can be used to obtain the robot joint sequence (i.e., angle sequence) and motion constraint information (i.e., constraints at discrete points). Furthermore, the general route planner can obtain the robot motion control sequence output (i.e., the joint angles and angular velocities the robot needs to achieve at each control moment). Additionally, the electronic device also supports existing joint motion analysis, linear motion analysis, and circular motion analysis. Accordingly, the robot can plan its route based on the results of any of these types of motion analysis to execute the specified task.
[0207] See Figure 6 , Figure 6 This is a flowchart illustrating spline motion analysis and path planning as provided in an embodiment of this application. It includes the following steps:
[0208] S601: Cartesian attitude to quaternion, that is, the electronic device acquires the position and attitude of each discrete point in the form of Cartesian space coordinates.
[0209] S602: Quaternion orientation correction, that is, converting the pose of each teaching point, represented in Cartesian space coordinates, into the pose represented in quaternion form, and performing quaternion flip optimization.
[0210] S603: Pose and Quaternion Synchronous NURBS Interpolation, that is, using the position of each teaching point and the pose represented in quaternion form to perform interpolation to obtain the interpolation results of each discrete point.
[0211] S604: Quaternion standardization correction of interpolation results, that is, normalizing the interpolation results of each discrete point to obtain the position of each discrete point and its orientation in quaternion form.
[0212] S605: Correct the result to Cartesian pose, that is, convert the pose of each discrete point in quaternion form to the pose in Cartesian space coordinates, and combine the position of each discrete point to obtain the pose that the end effector needs to achieve when it is located at each discrete point on the specified path.
[0213] S606: Inverse kinematics sequence, that is, after obtaining the poses that the robot's end effector needs to achieve when it is located at each discrete point on the specified path, the electronic device can use inverse kinematics solving algorithms (e.g., analytical and numerical methods) to perform inverse kinematics solving for the pose of each discrete point to obtain the angle segments of that discrete point, and then obtain the angle sequence containing the angle segments of each discrete point.
[0214] S607: Joint angle sequence parameterization, that is, after obtaining the angle segments of each discrete point, the motion change of each discrete point can be calculated based on the angle segments of each discrete point to obtain the change sequence. And based on the angle segments and motion changes of each discrete point, the first change relationship of the angle segments with respect to the motion changes can be constructed.
[0215] S608: Construct joint dimension constraints and spatial dimension constraints, that is, the electronic device can construct constraints characterized by path velocity and / or path acceleration at each discrete point based on the motion change amount and the first change relationship at each discrete point. Among them, the constraints include at least one of the following: joint angular velocity constraints, joint angular acceleration constraints, torque constraints, Cartesian space velocity constraints, and Cartesian space acceleration constraints.
[0216] S609: Reverse search for maximum speed, that is, taking the discrete point corresponding to the last motion change in the change sequence as the starting point, for each discrete point, based on the reverse search algorithm, calculate the first maximum path speed supported by the previous discrete point and the path acceleration and first minimum path speed corresponding to the first maximum path speed, under the condition of satisfying the constraint conditions and the first preset formula at the previous discrete point, until the first maximum path speed supported by each discrete point and the path acceleration and first minimum path speed corresponding to the first maximum path speed are obtained.
[0217] S610: Forward search for maximum speed, that is, starting from the discrete point corresponding to the first change in motion in the change sequence, for each discrete point, based on the forward search algorithm, calculate the second maximum path speed supported by the next discrete point and the path acceleration corresponding to the second maximum path speed, under the condition that the constraint conditions, the second preset formula, and the first maximum path speed supported by the next discrete point are satisfied, until the second maximum path speed supported by each discrete point and the path acceleration corresponding to the second maximum path speed are obtained.
[0218] S611: Third-order smoothing programming, that is, smoothing the second maximum path speed supported by each discrete point to obtain the maximum path speed that needs to be achieved at each discrete point.
[0219] S612: Solve for each sequence time point, that is, based on the maximum path speed, maximum path acceleration and motion change required at each discrete point, calculate the motion change and required path speed of the robot at each control time point as the control end effector passes through each discrete point according to the robot's control cycle.
[0220] S613: Based on the sequence time, generate a time path at a fixed period. That is, by using the changes in the robot's motion at each control moment and the required path speed, combined with the second change relationship of the angle segment with respect to the changes in motion, calculate the joint angle and joint angular velocity that the robot needs to achieve at each control moment.
[0221] Based on the same inventive concept, embodiments of this application provide a robot route planning device. See also Figure 7 , Figure 7 This application provides a structural diagram of a robot route planning device, the device comprising:
[0222] Angle sequence acquisition module 701 is used to perform inverse kinematics on the poses that the robot's end effector needs to achieve when it is located at each discrete point on a specified path, and obtain an angle sequence containing angle segments of each discrete point; wherein, the angle segment of a discrete point includes: the joint angles that each joint of the robot needs to achieve at that discrete point.
[0223] The change quantity sequence acquisition module 702 is used to calculate the motion change of each discrete point based on the angle segments of each discrete point to obtain a change quantity sequence; wherein, according to the arrangement order of each discrete point on the specified path, the motion change of each discrete point is: the sum of the motion change of the previous discrete point and the angle difference of the discrete point; the motion change of the first discrete point in the change quantity sequence is 0, and the angle difference of a discrete point is: the difference between the angle segment of the discrete point and the angle segment of the previous discrete point in the angle sequence.
[0224] The first relational construction module 703 is used to construct the first change relational expression of the angle segment with respect to the change in motion based on the angle segment and the change in motion of each discrete point;
[0225] The constraint construction module 704 is used to construct constraint conditions at each discrete point, characterized by path velocity and / or path acceleration, based on the motion change at each discrete point and the first change relationship; wherein the path velocity represents the first derivative of the motion change with respect to time; and the path acceleration represents the second derivative of the motion change with respect to time.
[0226] The first calculation module 705 is used to calculate, using the sequence of changes, the maximum path velocity and maximum path acceleration required at each discrete point under the condition of satisfying the constructed constraints.
[0227] The second calculation module 706 is used to calculate, according to the control cycle of the robot, the motion change and the required path speed of the robot at each control moment during the process of controlling the end effector to pass through each discrete point, based on the maximum path speed, maximum path acceleration and motion change required at each discrete point.
[0228] The third calculation module 707 is used to calculate the joint angle and joint angular velocity that the robot needs to achieve at each control moment by using the motion change amount and the required path velocity of the robot at each control moment, combined with the second change relationship of the angle segment with respect to the motion change amount; wherein, the second change relationship is constructed based on the angle segment of each two adjacent discrete points and the maximum required path velocity.
[0229] In some embodiments, the apparatus further includes: a teach point acquisition module, configured to acquire, before performing inverse kinematics on the poses required by the robot's end effector at each discrete point on the specified path to obtain an angle sequence containing angle segments of each discrete point, the poses required by the robot's end effector at each teach point on the specified path, as the poses of each teach point; and a first interpolation module, configured to perform interpolation based on the poses of each teach point to obtain the poses required by the end effector at each discrete point on the specified path.
[0230] In some embodiments, the acquired pose of the teaching point includes: position and orientation represented in Cartesian space coordinates; the first interpolation module is specifically used to: convert the orientation of each teaching point represented in Cartesian space coordinates into an orientation represented in quaternion form; perform interpolation using the position of each teaching point and the orientation represented in quaternion form to obtain the position of each discrete point and the orientation represented in quaternion form; convert the orientation of each discrete point represented in quaternion form into an orientation represented in Cartesian space coordinates, and combine the position of each discrete point to obtain the pose that the end effector needs to achieve when it is located at each discrete point on the specified path.
[0231] In some embodiments, the first relational construction module 703 is specifically used to: construct a univariate multivariate function of the angle segment with respect to the motion change based on the motion change and angle segment of each adjacent first specified number of discrete points, as the first sub-relational expression corresponding to the first specified number of discrete points; wherein, the first specified number is greater than 2;
[0232] The constraint construction module 704 includes a constraint construction submodule, which is used to construct, for each discrete point, a constraint condition characterized by path velocity and / or path acceleration at the discrete point, based on the motion change of the discrete point and the first sub-relation corresponding to the discrete point.
[0233] In some embodiments, the first specified number is 3; based on the motion changes and angle segments of the first specified number of discrete points, the first sub-relation corresponding to the first specified number of discrete points is expressed as:
[0234]
[0235] This represents the change in motion of the first discrete point out of the first specified number of discrete points; This represents the first sub-relation corresponding to the first discrete point among the first specified number of discrete points; This represents the constant term in the first sub-relation. This represents the coefficient of the linear term in the first sub-relation. This represents the coefficient of the quadratic term in the first sub-relation; Indicates the change in motion; Indicates an angle segment.
[0236] In some embodiments, the constraint conditions include at least one of the following: joint angular velocity constraint conditions, joint angular acceleration constraint conditions, torque constraint conditions, Cartesian space velocity constraint conditions, and Cartesian space acceleration constraint conditions.
[0237] The joint angular velocity constraint conditions are constructed through the following steps:
[0238] For each discrete point, based on the change in motion at that discrete point and the corresponding first sub-relation, a joint angular velocity constraint condition, characterized by path velocity, is constructed at that discrete point; wherein, the constructed joint angular velocity constraint condition is expressed as:
[0239]
[0240]
[0241] The expression representing the relationship between the angle segment and time; This represents the joint angular velocity of each joint of the robot; This represents the first sub-relation corresponding to the discrete point; This represents the first derivative of the change in motion with respect to time. Indicates about The function; Indicates the change in motion; This indicates the maximum joint angular velocity supported by each joint of the robot;
[0242] And / or, the joint angular acceleration constraint conditions are constructed through the following steps:
[0243] Based on the motion change at this discrete point and the corresponding first sub-relation, a joint angular acceleration constraint condition, characterized by path velocity and path acceleration, is constructed at this discrete point; wherein, the constructed joint angular acceleration constraint condition is expressed as:
[0244]
[0245]
[0246] The expression representing the change of an angle segment with respect to time. This represents the joint angular velocity of each joint of the robot. This represents the joint angular acceleration of each joint of the robot; This represents the first sub-relation corresponding to the discrete point; This represents the first derivative of the change in motion with respect to time. This represents the second derivative of the change in motion with respect to time. and Indicates about The function; This represents the minimum joint angular acceleration supported by each joint of the robot. This represents the maximum joint angular acceleration supported by each joint of the robot;
[0247] And / or, the torque constraint conditions are constructed through the following steps:
[0248] Based on the change in motion at this discrete point and the corresponding first sub-relation, a torque constraint condition characterized by path velocity and path acceleration is constructed at this discrete point; wherein, the constructed torque constraint condition is expressed as:
[0249]
[0250]
[0251] The expression representing the relationship between the torque of each joint of the robot and time; The expression representing the change of an angle segment with respect to time. This represents the joint angular velocity of each joint of the robot. This represents the joint angular acceleration of each joint of the robot; Represents the inertia matrix; Represents the matrix of Coriolis force and centrifugal force; Represents the gravity matrix; To be It is obtained by converting it into a function of the change in motion; , and Indicates about The function; This represents the first sub-relation corresponding to the discrete point; This represents the minimum torque supported by each joint of the robot; This indicates the maximum torque supported by each joint of the robot; Indicates the change in motion; This represents the first derivative of the change in motion with respect to time. This represents the second derivative of the change in motion with respect to time. Indicates transpose;
[0252] And / or, the Cartesian space velocity constraints are constructed through the following steps:
[0253] Based on the change in motion at this discrete point and the corresponding first sub-relation, a Cartesian space velocity constraint condition, characterized by path velocity, is constructed at this discrete point; wherein, the constructed Cartesian space velocity constraint condition is expressed as:
[0254]
[0255]
[0256] This represents the Cartesian space velocity of the end effector. , and These represent the path velocities of the end effector in the x-axis, y-axis, and z-axis directions in Cartesian space, respectively. , and These represent the rotational speeds of the end effector about the x-axis, y-axis, and z-axis of Cartesian space, respectively. Let be the Jacobian matrix representing the conversion relationship between the joint angular velocities of each joint of the robot at time t and the Cartesian space velocity of the end effector; The expression representing the change of an angle segment with respect to time. This represents the joint angular velocity of each joint of the robot; This represents the first sub-relation corresponding to the discrete point; Indicates about The function; This indicates the maximum Cartesian path speed and maximum Cartesian rotation speed supported by the end effector; It represents the change in motion. This represents the first derivative of the change in motion with respect to time.
[0257] And / or, the Cartesian space acceleration constraints are constructed through the following steps:
[0258] Based on the change in motion at this discrete point and the corresponding first sub-relation, a Cartesian space acceleration constraint condition, characterized by path velocity, is constructed at this discrete point; wherein, the constructed Cartesian space acceleration constraint condition is expressed as:
[0259]
[0260]
[0261] This represents the Cartesian space acceleration of each joint of the robot; Let: represent the joint angles of the robot's joints satisfying an angle segment. At that time, the Jacobian matrix representing the conversion relationship between the joint angular velocities of each joint of the robot and the Cartesian space velocity of the end effector. This represents the rate of change of the Jacobian matrix; This represents the first sub-relation corresponding to the discrete point; , Indicates about The function; This represents the maximum Cartesian acceleration supported by each joint of the robot. This represents the minimum Cartesian acceleration supported by each joint of the robot. It represents the change in motion. This represents the first derivative of the change in motion with respect to time. This represents the second derivative of the change in motion with respect to time.
[0262] In some embodiments, the first calculation module 705 includes: a reverse search submodule, configured to, starting from the discrete point corresponding to the last motion change in the change sequence and with the path velocity of the last discrete point being 0, calculate, based on a reverse search algorithm, in reverse order of the arrangement order, for each discrete point, the first maximum path velocity supported by the previous discrete point and the path acceleration and first minimum path velocity corresponding to the first maximum path velocity, given that the constraints and the first preset formula at the previous discrete point are satisfied, until the first maximum path velocity supported by each discrete point and the path acceleration and first minimum path velocity corresponding to the first maximum path velocity are obtained; wherein, the first preset formula is:
[0263] ;
[0264]
[0265] Represents the path velocity at a discrete point. This represents the amount of motion change at the discrete point; This represents the path velocity of the previous discrete point. This represents the change in motion of the previous discrete point. This represents the difference between the amount of motion change at this discrete point and the previous discrete point. This represents the path acceleration between the current discrete point and the previous discrete point;
[0266] The forward search submodule is used to start from the discrete point corresponding to the first change in motion in the change sequence, and with the path velocity of the first discrete point being 0. Based on the forward search algorithm, and according to the arrangement order, it calculates the second maximum path velocity and the path acceleration corresponding to the second maximum path velocity of the next discrete point, given that the constraints, the second preset formula, and the first maximum path velocity supported by the next discrete point are satisfied, until the second maximum path velocity and the path acceleration corresponding to the second maximum path velocity of each discrete point are obtained; wherein, the second preset formula is:
[0267] ;
[0268]
[0269] Represents the path velocity at a discrete point. This represents the amount of motion change at the discrete point; This represents the path velocity to the next discrete point after the given discrete point. It represents the change in motion of the next discrete point after the current discrete point. This represents the difference between the amount of motion change at the current discrete point and the next discrete point. This represents the path acceleration between the current discrete point and the next discrete point.
[0270] The first calculation submodule is used to obtain the maximum path speed and maximum path acceleration required at each discrete point based on the second maximum path speed supported by each discrete point and the path acceleration corresponding to the second maximum path speed.
[0271] In some embodiments, the first calculation submodule is specifically used to: smooth the second maximum path velocity supported by each discrete point to obtain the maximum path velocity required at each discrete point; and calculate the maximum path acceleration required at each discrete point based on the maximum path velocity required at each pair of adjacent discrete points.
[0272] In some embodiments, the second calculation module 706 includes: a duration calculation submodule, used to calculate, for each pair of adjacent discrete points, the duration required for the end effector to pass through the two discrete points based on the maximum path speed, maximum path acceleration, and motion change required at the two discrete points; a discrete time determination submodule, used to determine the time represented by each discrete point based on the calculated duration, as the discrete time corresponding to each discrete point; a first positioning submodule, used to determine each control time when controlling the end effector according to the robot's control cycle, and the previous discrete time adjacent to each control time; and a second calculation submodule, used to calculate, for each control time, the motion change and path speed required at that control time based on the maximum path speed, maximum path acceleration, and motion change required at the previous discrete time adjacent to that control time.
[0273] In some embodiments, the time required for the end effector to traverse every two adjacent discrete points is expressed as:
[0274] ;
[0275] Indicates that the end effector has passed the first The discrete point and the first The time required for each discrete point; Indicates the first The change in motion of a discrete point Indicates the first The change in motion at a discrete point; Indicates the first The maximum path speed required at each discrete point. Indicates the first The maximum path speed required at each discrete point; Indicates the first The maximum path acceleration required at each discrete point;
[0276] The second calculation submodule is specifically used for: for each control moment, based on the maximum path velocity, maximum path acceleration, and change in motion required to be achieved in the preceding discrete moment adjacent to that control moment, calculating the change in motion required to be achieved at that control moment according to a third preset formula; wherein, the third preset formula is:
[0277] ;
[0278] ;
[0279] ;
[0280]
[0281] Indicates the control time. Indicates the first The discrete time corresponding to each discrete point Indicates the first The discrete time corresponding to each discrete point; This indicates that the control time t is related to the first... The time difference between discrete moments corresponding to discrete points; This represents the path velocity required to be reached at control time t. Indicates the first The maximum path speed required at each discrete point. Indicates the first The maximum path acceleration required at each discrete point; This represents the change in motion at control time t. Indicates the first The change in motion at a discrete point.
[0282] In some embodiments, the second variation relation includes a second sub-relation corresponding to each discrete point; the third calculation module 707 includes: a second positioning sub-module, configured to, for each control moment, determine from each discrete point a discrete point whose corresponding discrete moment is before and adjacent to the control moment, as a calibration discrete point for the control moment; and a third calculation sub-module, configured to, using the motion change and path velocity required by the end effector at the control moment, and the second sub-relation corresponding to the calibration discrete point in the second variation relation, calculate the joint angle and joint angular velocity required by the robot at the control moment.
[0283] In some embodiments, the third calculation submodule is specifically used to: construct, based on the second sub-relation corresponding to the calibration discrete point, a third sub-relation of the angle segment with respect to the motion change, and a fourth sub-relation of the joint angular velocity with respect to the path velocity within the time interval between the calibration discrete point and the next discrete point; substitute the motion change and path velocity that the end effector needs to achieve at the control moment into the third sub-relation to obtain the joint angle that the robot needs to achieve at the control moment, and substitute them into the fourth sub-relation to obtain the joint angular velocity that the robot needs to achieve at the control moment.
[0284] In some embodiments, the second sub-relation corresponding to the calibration discrete point is expressed as:
[0285] ;
[0286] ;
[0287] ;
[0288] ;
[0289] ;
[0290]
[0291] This represents the change in motion at the calibrated discrete point; This represents the second sub-relation corresponding to the calibrated discrete point; Indicates the change in motion; This represents an angle segment representing the calibrated discrete point; This represents the angle segment of the next discrete point after the current calibration discrete point. This indicates the path speed required to reach the specified discrete point. This indicates the path velocity required to reach the next discrete point after the current calibration discrete point. This represents the difference between the amount of motion change at the current discrete point and the next discrete point.
[0292] The third sub-relation of the angle segment with respect to the change in motion during the time interval between the discrete time corresponding to the calibrated discrete point and the next discrete point is expressed as:
[0293]
[0294] ;
[0295] t represents any time within the time interval between the current discrete point and the discrete time corresponding to the next discrete point. This represents the change in motion at the calibrated discrete point; This represents the change in motion at the next discrete point after the calibrated discrete point; Indicates time The change in motion; This indicates that the i-th joint of the robot is at time [time]. The required joint angle; This represents the joint angle that the i-th joint of the robot needs to reach at the calibrated discrete point. This represents the joint angle that the robot's i-th joint needs to reach at a discrete point after the calibration discrete point. This represents the joint angular velocity that the i-th joint of the robot needs to achieve at the calibrated discrete point. This represents the joint angular velocity that the robot's i-th joint needs to achieve at a discrete point after the calibration discrete point. This represents the difference between the amount of motion change at the current discrete point and the next discrete point.
[0296] During the time interval between the discrete moments corresponding to the current calibrated discrete point and the next discrete point, the fourth sub-relation of the joint angular velocity with respect to the path velocity is expressed as:
[0297]
[0298] ;
[0299] in, This represents the joint angular velocity that the i-th joint of the robot needs to achieve at time t; This represents the path velocity at time t.
[0300] This application also provides an electronic device, such as... Figure 8 As shown, it includes:
[0301] Memory 801 is used to store computer programs;
[0302] The processor 802, when executing the program stored in the memory 801, implements the steps of any of the above-described robot route planning methods.
[0303] Furthermore, the aforementioned electronic devices may also include a communication bus and / or a communication interface. The processor 802, the communication interface, and the memory 801 communicate with each other via the communication bus. The communication bus mentioned in the aforementioned electronic devices may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus can be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one thick line is used to represent it in the figure, but this does not indicate that there is only one bus or one type of bus.
[0304] The communication interface is used for communication between the aforementioned electronic device and other devices. The memory may include random access memory (RAM) or non-volatile memory (NVM), such as at least one disk storage device. Optionally, the memory may also be at least one storage device located remotely from the aforementioned processor. The aforementioned processor may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it may also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.
[0305] In another embodiment provided in this application, a computer-readable storage medium is also provided, which stores a computer program that, when executed by a processor, implements the steps of any of the robot route planning methods described above.
[0306] In another embodiment provided in this application, a computer program product containing instructions is also provided, which, when run on a computer, causes the computer to execute any of the robot route planning methods described above.
[0307] In the above embodiments, implementation can be achieved entirely or partially through software, hardware, firmware, or any combination thereof. When implemented using software, it can be implemented entirely or partially in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another. For example, the computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that integrates one or more available media. The available medium can be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a solid-state drive (SSD), etc.
[0308] It should be noted that, in this document, relational terms such as "first" and "second" are used only to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0309] The various embodiments in this specification are described in a related manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, the embodiments of apparatus, electronic devices, computer-readable storage media, and program products are basically similar to the method embodiments, so the descriptions are relatively simple; relevant parts can be referred to the descriptions of the method embodiments.
[0310] The above description is merely a preferred embodiment of this application and is not intended to limit the scope of protection of this application. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this application are included within the scope of protection of this application.
Claims
1. A robot route planning method, characterized in that, The method includes: By inverse kinematics of the poses that the robot's end effector needs to achieve when located at discrete points on a specified path, an angle sequence containing angle segments of each discrete point is obtained; wherein, the angle segment of a discrete point contains: the joint angles that each joint of the robot needs to achieve at that discrete point. Based on the angle segments of each discrete point, the motion change of each discrete point is calculated to obtain a change sequence; wherein, according to the arrangement order of each discrete point on the specified path, the motion change of each discrete point is: the sum of the motion change of the previous discrete point and the angle difference of the current discrete point; the motion change of the first discrete point in the change sequence is 0, and the angle difference of a discrete point is: the difference between the angle segment of the current discrete point and the angle segment of the previous discrete point in the angle sequence. Based on the angle segments and motion changes at each discrete point, a first variation relationship between the angle segments and the motion changes is constructed. Based on the change in motion at each discrete point and the first change relationship, constraints are constructed at that discrete point, characterized by path velocity and / or path acceleration; wherein, the path velocity represents the first derivative of the change in motion with respect to time; and the path acceleration represents the second derivative of the change in motion with respect to time. Using the sequence of changes, calculate the maximum path velocity and maximum path acceleration required at each discrete point, provided that the constructed constraints are met. Based on the maximum path speed, maximum path acceleration, and motion change required at each discrete point, and according to the robot's control cycle, the motion change and required path speed of the robot at each control moment are calculated during the process of controlling the end effector to pass through each discrete point. Using the motion changes of the robot at each control moment and the required path velocity, combined with the second variation relationship of the angle segment with respect to the motion changes, the joint angle and joint angular velocity required by the robot at each control moment are calculated; wherein, the second variation relationship is constructed based on the angle segment of each two adjacent discrete points and the maximum required path velocity.
2. The method according to claim 1, characterized in that, Before performing inverse kinematics on the poses required by the robot's end effector at discrete points along a specified path to obtain an angle sequence containing angle segments of each discrete point, the method further includes: Obtain the poses that the robot's end effector needs to achieve when it is located at each teaching point on the specified path, and use them as the poses of each teaching point; By interpolating the poses of each teaching point, the poses that the end effector needs to achieve when located at each discrete point on the specified path are obtained.
3. The method according to claim 2, characterized in that, The acquired pose of the teaching point includes: position and orientation represented in Cartesian space coordinates; The interpolation based on the poses of each taught point to obtain the poses that the end effector needs to achieve when located at discrete points on a specified path includes: The pose of each teaching point, represented in Cartesian space coordinates, is converted into a pose represented in quaternion form. By interpolating the positions of each teaching point and their attitudes represented in quaternion form, the positions of each discrete point and their attitudes represented in quaternion form can be obtained. The pose of each discrete point, represented in quaternion form, is converted into a pose represented in Cartesian coordinates. Combined with the position of each discrete point, the pose that the end effector needs to achieve when it is located at each discrete point on the specified path is obtained.
4. The method according to claim 1, characterized in that, The first variation relationship of the angle segment with respect to the motion change amount is constructed based on the angle segment and motion change amount of each discrete point, including: Based on the motion change and angle segments of each adjacent first specified number of discrete points, a univariate multivariate function of the angle segment with respect to the motion change is constructed as the first sub-relation corresponding to the first specified number of discrete points; wherein, the first specified number is greater than 2. The constraint conditions, characterized by path velocity and / or path acceleration, are constructed at each discrete point based on the change in motion at each discrete point and the first change relationship, including: For each discrete point, based on the change in motion at that discrete point and the first sub-relation corresponding to that discrete point, constraints characterized by path velocity and / or path acceleration are constructed at that discrete point.
5. The method according to claim 4, characterized in that, The first specified number is 3; Based on the motion changes and angle segments of a first specified number of adjacent discrete points, the first sub-relation corresponding to the first specified number of discrete points is expressed as follows: ; This represents the change in motion of the first discrete point out of the first specified number of discrete points; This represents the first sub-relation corresponding to the first discrete point among the first specified number of discrete points; This represents the constant term in the first sub-relation. This represents the coefficient of the linear term in the first sub-relation. This represents the coefficient of the quadratic term in the first sub-relation; Indicates the change in motion; Indicates an angle segment.
6. The method according to claim 4, characterized in that, The constraints include at least one of the following: joint angular velocity constraints, joint angular acceleration constraints, torque constraints, Cartesian space velocity constraints, and Cartesian space acceleration constraints. The joint angular velocity constraint conditions are constructed through the following steps: For each discrete point, based on the motion change at that discrete point and the corresponding first sub-relation, the joint angular velocity constraint condition characterized by path velocity at that discrete point is constructed. The constructed joint angular velocity constraint is expressed as follows: ; ; The expression representing the relationship between the angle segment and time; This represents the joint angular velocity of each joint of the robot; This represents the first sub-relation corresponding to the discrete point; This represents the first derivative of the change in motion with respect to time. Indicates about The function; Indicates the change in motion; This indicates the maximum joint angular velocity supported by each joint of the robot; And / or, The joint angular acceleration constraint conditions are constructed through the following steps: Based on the motion change at the discrete point and the corresponding first sub-relation, the joint angular acceleration constraint condition at the discrete point, characterized by path velocity and path acceleration, is constructed. The constructed joint angular acceleration constraint is expressed as follows: ; ; The expression representing the change of an angle segment with respect to time. This represents the joint angular velocity of each joint of the robot. This represents the joint angular acceleration of each joint of the robot; This represents the first sub-relation corresponding to the discrete point; This represents the first derivative of the change in motion with respect to time. This represents the second derivative of the change in motion with respect to time. and Indicates about The function; This represents the minimum joint angular acceleration supported by each joint of the robot. This represents the maximum joint angular acceleration supported by each joint of the robot; And / or, The torque constraint condition is constructed through the following steps: Based on the change in motion at the discrete point and the corresponding first sub-relation, a torque constraint condition characterized by path velocity and path acceleration is constructed at the discrete point. The constructed torque constraint condition is expressed as follows: ; ; The expression representing the relationship between the torque of each joint of the robot and time; The expression representing the change of an angle segment with respect to time. This represents the joint angular velocity of each joint of the robot. This represents the joint angular acceleration of each joint of the robot; Represents the inertia matrix; Represents the matrix of Coriolis force and centrifugal force; Represents the gravity matrix; To be It is obtained by converting it into a function of the change in motion; , and Indicates about The function; This represents the first sub-relation corresponding to the discrete point; This represents the minimum torque supported by each joint of the robot; This indicates the maximum torque supported by each joint of the robot; Indicates the change in motion; This represents the first derivative of the change in motion with respect to time. This represents the second derivative of the change in motion with respect to time. Indicates transpose; And / or, The Cartesian space velocity constraint is constructed through the following steps: Based on the change in motion at the discrete point and the corresponding first sub-relation, a Cartesian space velocity constraint condition characterized by path velocity is constructed at the discrete point. The constructed Cartesian space velocity constraint is expressed as follows: ; ; This represents the Cartesian space velocity of the end effector. , and These represent the path velocities of the end effector in the x-axis, y-axis, and z-axis directions in Cartesian space, respectively. , and These represent the rotational speeds of the end effector about the x-axis, y-axis, and z-axis of Cartesian space, respectively. Let be the Jacobian matrix representing the conversion relationship between the joint angular velocities of each joint of the robot at time t and the Cartesian space velocity of the end effector; The expression representing the change of an angle segment with respect to time. This represents the joint angular velocity of each joint of the robot; This represents the first sub-relation corresponding to the discrete point; Indicates about The function; This indicates the maximum Cartesian path speed and maximum Cartesian rotation speed supported by the end effector; It represents the change in motion. This represents the first derivative of the change in motion with respect to time. And / or, The Cartesian space acceleration constraint is constructed through the following steps: Based on the change in motion at the discrete point and the corresponding first sub-relation, a Cartesian space acceleration constraint condition characterized by path velocity is constructed at the discrete point. The constructed Cartesian space acceleration constraint condition is expressed as follows: : ; ; This represents the Cartesian space acceleration of each joint of the robot; Let: represent the joint angles of the robot's joints satisfying an angle segment. At that time, the Jacobian matrix representing the conversion relationship between the joint angular velocities of each joint of the robot and the Cartesian space velocity of the end effector. This represents the rate of change of the Jacobian matrix; This represents the first sub-relation corresponding to the discrete point; , Indicates about The function; This represents the maximum Cartesian acceleration supported by each joint of the robot. This represents the minimum Cartesian acceleration supported by each joint of the robot. It represents the change in motion. This represents the first derivative of the change in motion with respect to time. This represents the second derivative of the change in motion with respect to time.
7. The method according to claim 1, characterized in that, The step of using the sequence of changes to calculate the maximum path velocity and maximum path acceleration required at each discrete point, under the constructed constraints, includes: Starting from the discrete point corresponding to the last motion change in the sequence of changes, and with the path speed of the last discrete point being 0, based on the reverse search algorithm, in reverse order of the arrangement, for each discrete point, the first maximum path speed supported by the previous discrete point and the path acceleration and first minimum path speed corresponding to the first maximum path speed are calculated sequentially, under the condition that the constraint conditions and the first preset formula at the previous discrete point are satisfied, until the first maximum path speed supported by each discrete point and the path acceleration and first minimum path speed corresponding to the first maximum path speed are obtained; The first preset formula is: ; ; Represents the path velocity at a discrete point. This represents the amount of motion change at the discrete point; This represents the path velocity of the previous discrete point. This represents the change in motion of the previous discrete point. This represents the difference between the amount of motion change at this discrete point and the previous discrete point. This represents the path acceleration between the current discrete point and the previous discrete point; Starting from the discrete point corresponding to the first change in motion in the sequence of changes, and with the path velocity of the first discrete point being 0, based on the forward search algorithm, and in accordance with the arrangement order, the second maximum path velocity and the path acceleration corresponding to the second maximum path velocity are calculated sequentially at the next discrete point after the discrete point, provided that the constraint conditions, the second preset formula, and the first maximum path velocity supported by the next discrete point are satisfied, until the second maximum path velocity and the path acceleration corresponding to the second maximum path velocity are obtained for each discrete point. The second preset formula is: ; ; Represents the path velocity at a discrete point. This represents the amount of motion change at the discrete point; This represents the path velocity to the next discrete point after the given discrete point. It represents the change in motion of the next discrete point after the current discrete point. This represents the difference between the amount of motion change at the current discrete point and the next discrete point. This represents the path acceleration between the current discrete point and the next discrete point. Based on the second maximum path velocity supported by each discrete point and the path acceleration corresponding to the second maximum path velocity, the maximum path velocity and maximum path acceleration required at each discrete point are obtained.
8. The method according to claim 7, characterized in that, The process of obtaining the maximum path speed and maximum path acceleration required at each discrete point based on the second maximum path speed supported by each discrete point and the path acceleration corresponding to the second maximum path speed includes: The second maximum path speed supported by each discrete point is smoothed to obtain the maximum path speed that needs to be achieved at each discrete point. Calculate the maximum path acceleration required at each discrete point based on the maximum path velocity required at each pair of adjacent discrete points.
9. The method according to claim 1, characterized in that, Based on the maximum path speed, maximum path acceleration, and motion change required at each discrete point, and according to the robot's control cycle, the calculation of the motion change and required path speed of the robot at each control moment during the process of controlling the end effector to pass through each discrete point includes: For each pair of adjacent discrete points, the time required for the end effector to pass through the two discrete points is calculated based on the maximum path velocity, maximum path acceleration, and change in motion required at those two discrete points. Based on the calculated duration, the time represented by each discrete point is determined, which is then used as the discrete time corresponding to each discrete point. Determine each control moment when controlling the end effector according to the control cycle of the robot, and the preceding discrete moment adjacent to each control moment; For each control moment, the required change in motion and path velocity at that control moment are calculated based on the maximum path velocity, maximum path acceleration, and change in motion required to be achieved in the preceding discrete moment adjacent to that control moment.
10. The method according to claim 9, characterized in that, The time required for the end effector to pass through each pair of adjacent discrete points is expressed as: ; Indicates that the end effector has passed the first The discrete point and the first The time required for each discrete point; Indicates the first The change in motion of a discrete point Indicates the first The change in motion of a discrete point; Indicates the first The maximum path speed required at each discrete point. Indicates the first The maximum path speed required at each discrete point; Indicates the first The maximum path acceleration required at each discrete point; For each control moment, based on the maximum path velocity, maximum path acceleration, and change in motion required in the preceding discrete moment, the calculation of the required change in motion and path velocity for that control moment includes: For each control moment, based on the maximum path velocity, maximum path acceleration, and change in motion required to be achieved in the preceding discrete moment, the change in motion required to be achieved at that control moment is calculated according to a third preset formula; wherein, the third preset formula is: ; ; ; ; Indicates the control moment. Indicates the first The discrete time corresponding to each discrete point Indicates the first The discrete time corresponding to each discrete point; This indicates that the control time t is related to the first... The time difference between discrete moments corresponding to discrete points; This represents the path velocity required to be reached at control time t. Indicates the first The maximum path speed required at each discrete point. Indicates the first The maximum path acceleration required at each discrete point; This represents the change in motion at the control time t. Indicates the first The change in motion at a discrete point.
11. The method according to claim 9, characterized in that, The second variation relation includes a second sub-relation corresponding to each discrete point; Using the changes in motion of the robot at each control moment and the required path velocity, combined with the second relationship between the angle segment and the changes in motion, the required joint angles and joint angular velocities of the robot at each control moment are calculated, including: For each control moment, the discrete points whose corresponding discrete moments are before and adjacent to the control moment are determined from each discrete point and are used as the calibration discrete points for that control moment. Using the motion change and path velocity required by the end effector at the control moment, and the second sub-relationship corresponding to the calibrated discrete point in the second change relationship, the joint angle and joint angular velocity required by the robot at the control moment are calculated.
12. The method according to claim 11, characterized in that, The step of calculating the joint angle and joint angular velocity required by the robot at the control moment using the motion change and path velocity required by the end effector at that control moment, and the second sub-relationship corresponding to the calibration discrete point at that control moment in the second change relationship, includes: Based on the second sub-relation corresponding to the calibration discrete point, a third sub-relation of the angle segment with respect to the motion change amount is constructed within the time interval between the calibration discrete point and the next discrete point, and a fourth sub-relation of the joint angular velocity with respect to the path velocity. Substituting the motion change and path velocity required by the end effector at the control moment into the third sub-relationship yields the joint angle required by the robot at the control moment, and substituting them into the fourth sub-relationship yields the joint angular velocity required by the robot at the control moment.
13. The method according to claim 12, characterized in that, The second sub-relation corresponding to the calibration discrete point is expressed as: ; ; ; ; ; ; This represents the change in motion at the calibrated discrete point; This represents the second sub-relation corresponding to the calibrated discrete point; Indicates the change in motion; This represents the angle segment of the calibrated discrete point; This represents the angle segment of the next discrete point after the current calibration discrete point. This indicates the path speed required to reach the specified discrete point. This indicates the path velocity required to reach the next discrete point after the current calibration discrete point. This represents the difference between the amount of motion change at the current discrete point and the next discrete point. The third sub-relation of the angle segment with respect to the change in motion during the time interval between the discrete time corresponding to the calibrated discrete point and the next discrete point is expressed as: ; ; t represents any time within the time interval between the current discrete point and the discrete time corresponding to the next discrete point. This represents the change in motion at the calibrated discrete point; This represents the change in motion at the next discrete point after the calibrated discrete point; Indicates time The change in motion; This indicates that the i-th joint of the robot is at time [time]. The required joint angle; This represents the joint angle that the i-th joint of the robot needs to reach at the calibrated discrete point. This represents the joint angle that the robot's i-th joint needs to reach at a discrete point after the calibration discrete point. This represents the joint angular velocity that the i-th joint of the robot needs to achieve at the calibrated discrete point. This represents the joint angular velocity that the robot's i-th joint needs to achieve at a discrete point after the calibration discrete point. This represents the difference between the amount of motion change at the current discrete point and the next discrete point. During the time interval between the discrete moments corresponding to the current calibrated discrete point and the next discrete point, the fourth sub-relation of the joint angular velocity with respect to the path velocity is expressed as: ; ; in, This represents the joint angular velocity that the i-th joint of the robot needs to achieve at time t; This represents the path velocity at time t.
14. A robot route planning device, characterized in that, The device includes: An angle sequence acquisition module is used to perform inverse kinematics on the poses that the robot's end effector needs to achieve when it is located at each discrete point on a specified path, and obtain an angle sequence containing angle segments of each discrete point; wherein, the angle segment of a discrete point contains: the joint angles that each joint of the robot needs to achieve at that discrete point. The change quantity sequence acquisition module is used to calculate the motion change of each discrete point based on the angle segments of each discrete point, and obtain the change quantity sequence; wherein, according to the arrangement order of each discrete point on the specified path, the motion change of each discrete point is: the sum of the motion change of the previous discrete point and the angle difference of the current discrete point; the motion change of the first discrete point in the change quantity sequence is 0, and the angle difference of a discrete point is: the difference between the angle segment of the current discrete point and the angle segment of the previous discrete point in the angle sequence. The first relational construction module is used to construct the first change relation of the angle segment with respect to the change of motion based on the angle segment and the change of motion of each discrete point; The constraint construction module is used to construct constraint conditions at each discrete point, characterized by path velocity and / or path acceleration, based on the motion change at each discrete point and the first change relationship; wherein the path velocity represents the first derivative of the motion change with respect to time; and the path acceleration represents the second derivative of the motion change with respect to time. The first calculation module is used to calculate, using the sequence of changes, the maximum path velocity and maximum path acceleration required at each discrete point under the constructed constraints. The second calculation module is used to calculate, according to the control cycle of the robot, the motion change and the required path speed of the robot at each control moment during the process of controlling the end effector to pass through each discrete point, based on the maximum path speed, maximum path acceleration and motion change required at each discrete point. The third calculation module is used to calculate the joint angle and joint angular velocity that the robot needs to achieve at each control moment by using the motion change amount and the required path velocity of the robot at each control moment, combined with the second change relationship of the angle segment with respect to the motion change amount; wherein, the second change relationship is constructed based on the angle segment of each two adjacent discrete points and the maximum required path velocity.
15. An electronic device, characterized in that, include: Memory, used to store computer programs; A processor, when executing a program stored in memory, implements the method described in any one of claims 1-13.
16. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the method described in any one of claims 1-13.
17. A computer program product, characterized in that, When the computer program product is run on a computer, it causes the computer to perform the method according to any one of claims 1-13.