A motion magnification adjustment method, device, computer equipment and storage medium
By obtaining the historical execution magnification and magnification derivatives in industrial robots or machine tools, and combining the instruction magnification for real-time calculation and Hermite interpolation conversion, the problems of motion acceleration discontinuity and jitter are solved, and smooth and reliable motion magnification adjustment is achieved.
Patent Information
- Application Number
- CN202110793945.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-07-14
- Publication Date
- 2025-08-08
- Estimated Expiration
- 2041-07-14
AI Technical Summary
When the prior art performs motion magnification adjustment in industrial robots or machine tools, there are problems of motion acceleration discontinuity and velocity or acceleration jitter, resulting in motion non-smoothing.
By obtaining the historical execution magnification and magnification derivatives, combining the instruction magnification for real-time calculation, and interpolation of motion instructions using Hermite interpolation conversion to ensure the continuity of motion acceleration and velocity.
The smoothness and flexibility of the movement are achieved, the overshoot of the motion acceleration is avoided, and the reliability and efficiency of magnification adjustment are improved.
Smart Images

Figure CN115609343B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of rate control technology, and in particular to a motion rate adjustment method, device, computer equipment and storage medium. Background Art
[0002] In industrial robot or machine tool applications, it is often necessary to change the motion magnification through a teach pendant or machine panel, and adjust the machine's motion speed through the changed motion magnification. Normally, the machine runs at a magnification of 100%. At this time, it is equivalent to sending the planned motion instructions directly to the servo drive. The servo drive controls the machine to perform the relevant motion according to the received motion instructions. When the magnification is not 100%, it is necessary to interpolate the planned motion instructions and then send the interpolated motion instructions to the servo drive. At present, traditional magnification adjustment is generally achieved through linear interpolation. Although this method can effectively adjust the motion magnification, it will also have an adverse effect on the motion speed and acceleration, such as speed or acceleration jitter, and there is a problem of not being able to guarantee the continuity of motion acceleration. Summary of the Invention
[0003] Based on this, it is necessary to provide a motion rate adjustment method, device, computer equipment and storage medium that can ensure the continuity of motion acceleration to address the above technical problems.
[0004] A motion magnification adjustment method, the method comprising:
[0005] Obtaining a historical execution magnification calculated at a previous sampling moment, a historical magnification derivative corresponding to the historical execution magnification, and a magnification instruction transmitted via a control device, wherein the magnification instruction carries a command magnification;
[0006] Calculating the execution rate required for the machine device to be executed during the current sampling process and the rate derivative corresponding to the execution rate based on the historical execution rate, the historical rate derivative, and the instruction rate to obtain the real-time execution rate and the real-time rate derivative;
[0007] Obtaining a motion instruction transmitted via a motion planner, and performing interpolation conversion on the motion instruction according to the real-time execution magnification and the real-time magnification derivative to obtain a corresponding interpolated motion instruction;
[0008] Transmitting the interpolation motion instruction to a servo driver, so that the servo server adjusts the motion speed of the machine device according to the received interpolation motion instruction;
[0009] When entering the next sampling moment, the real-time execution rate is used as the historical execution rate calculated at the previous sampling moment, the real-time rate derivative is used as the historical rate derivative, and the step of obtaining the historical execution rate, historical rate derivative and rate instruction calculated at the previous sampling moment is returned to continue execution until the real-time execution rate obtained at the corresponding sampling moment is equal to the obtained instruction rate, and the rate adjustment is ended.
[0010] A motion magnification adjustment device, comprising:
[0011] an acquisition module, configured to acquire a historical execution magnification calculated at a previous sampling moment, a historical magnification derivative corresponding to the historical execution magnification, and a magnification instruction transmitted via a control device, wherein the magnification instruction carries an instruction magnification;
[0012] a calculation module, configured to calculate the execution magnification required to be executed by the machine device during the current sampling process and the magnification derivative corresponding to the execution magnification based on the historical execution magnification, the historical magnification derivative, and the instruction magnification, to obtain the real-time execution magnification and the real-time magnification derivative;
[0013] a conversion module, configured to obtain a motion instruction transmitted via the motion planner, and perform interpolation conversion on the motion instruction according to the real-time execution magnification and the real-time magnification derivative to obtain a corresponding interpolated motion instruction;
[0014] an output module, configured to transmit the interpolation motion instruction to a servo driver, so that the servo server adjusts the motion speed of the machine device according to the received interpolation motion instruction;
[0015] An iterative module is used to, when entering the next sampling moment, use the real-time execution rate as the historical execution rate calculated at the previous sampling moment, use the real-time rate derivative as the historical rate derivative, and return to the step of obtaining the historical execution rate, historical rate derivative and rate instruction calculated at the previous sampling moment to continue execution until the real-time execution rate obtained at the corresponding sampling moment is equal to the obtained instruction rate, and then end the rate adjustment.
[0016] A computer device includes a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:
[0017] Obtaining a historical execution magnification calculated at a previous sampling moment, a historical magnification derivative corresponding to the historical execution magnification, and a magnification instruction transmitted via a control device, wherein the magnification instruction carries a command magnification;
[0018] Calculating the execution rate required for the machine device to be executed during the current sampling process and the rate derivative corresponding to the execution rate based on the historical execution rate, the historical rate derivative, and the instruction rate to obtain the real-time execution rate and the real-time rate derivative;
[0019] Obtaining a motion instruction transmitted via a motion planner, and performing interpolation conversion on the motion instruction according to the real-time execution magnification and the real-time magnification derivative to obtain a corresponding interpolated motion instruction;
[0020] Transmitting the interpolation motion instruction to a servo driver, so that the servo server adjusts the motion speed of the machine device according to the received interpolation motion instruction;
[0021] When entering the next sampling moment, the real-time execution rate is used as the historical execution rate calculated at the previous sampling moment, the real-time rate derivative is used as the historical rate derivative, and the step of obtaining the historical execution rate, historical rate derivative and rate instruction calculated at the previous sampling moment is returned to continue execution until the real-time execution rate obtained at the corresponding sampling moment is equal to the obtained instruction rate, and the rate adjustment is ended.
[0022] A computer-readable storage medium stores a computer program, which, when executed by a processor, implements the following steps:
[0023] Obtaining a historical execution magnification calculated at a previous sampling moment, a historical magnification derivative corresponding to the historical execution magnification, and a magnification instruction transmitted via a control device, wherein the magnification instruction carries a command magnification;
[0024] Calculating the execution rate required for the machine device to be executed during the current sampling process and the rate derivative corresponding to the execution rate based on the historical execution rate, the historical rate derivative, and the instruction rate to obtain the real-time execution rate and the real-time rate derivative;
[0025] Obtaining a motion instruction transmitted via a motion planner, and performing interpolation conversion on the motion instruction according to the real-time execution magnification and the real-time magnification derivative to obtain a corresponding interpolated motion instruction;
[0026] Transmitting the interpolation motion instruction to a servo driver, so that the servo server adjusts the motion speed of the machine device according to the received interpolation motion instruction;
[0027] When entering the next sampling moment, the real-time execution rate is used as the historical execution rate calculated at the previous sampling moment, the real-time rate derivative is used as the historical rate derivative, and the step of obtaining the historical execution rate, historical rate derivative and rate instruction calculated at the previous sampling moment is returned to continue execution until the real-time execution rate obtained at the corresponding sampling moment is equal to the obtained instruction rate, and the rate adjustment is ended.
[0028] The above-mentioned motion rate adjustment method, device, computer equipment and storage medium calculate the real-time execution rate and real-time rate derivative based on the historical execution rate calculated at the previous sampling moment, the historical rate derivative corresponding to the historical execution rate, and the rate instruction transmitted by the control device; wherein the real-time execution rate can be understood as the actual step size of interpolation. Currently, the motion instructions transmitted via the motion planner are interpolated and converted based on the real-time execution rate and the real-time rate derivative, which can ensure the continuity of the acceleration and speed of the interpolated motion instructions, avoid the overshoot caused by filtering (that is, the instantaneous rate may be greater than the set value), improve the reliability of the rate adjustment, and thereby ensure the flexibility and smoothness of the machine movement. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] Figure 1 A diagram showing an application environment of a motion magnification adjustment method in one embodiment;
[0030] Figure 2 Schematic diagram of a flow chart of a motion magnification adjustment method in one embodiment;
[0031] Figure 3 1 is a flow chart of the steps of calculating interpolation motion instructions in one embodiment;
[0032] Figure 4 is a system structure block diagram of a processing system when the motion magnification adjustment method is applied to a corresponding processing system in one embodiment;
[0033] Figure 5 FIG1 is a general operation flow chart of a motion magnification adjustment method in one embodiment;
[0034] Figure 6 A diagram of a command rate and an operation rate signal in one embodiment;
[0035] Figure 7 is a timing diagram of motion instructions and interpolation motion instructions in one embodiment;
[0036] Figure 8 is a structural block diagram of a motion magnification adjustment device in one embodiment;
[0037] Figure 9FIG. 1 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0038] In order to make the purpose, technical solutions and advantages of this application more clear, the following further describes this application in detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.
[0039] The motion magnification adjustment method provided in this application can be applied to Figure 1 In the application environment shown in FIG. , the control device 102, the motion planner 104, and the servo driver 106 all communicate with the computer device 108 via a network, and the servo driver 106 is also connected to the machine device 110. At any sampling moment, the computer device 108 first obtains the historical execution rate calculated at the previous sampling moment, the historical rate derivative corresponding to the historical execution rate, and the rate instruction transmitted via the control device 102, the rate instruction carrying the instruction rate. Next, the computer device 108 calculates the execution rate required to be executed by the machine device during the current sampling process and the rate derivative corresponding to the execution rate based on the historical execution rate, the historical rate derivative, and the instruction rate, to obtain the real-time execution rate and the real-time rate derivative. Next, the computer device 108 obtains the motion instruction transmitted via the motion planner 104, and interpolates the motion instruction based on the real-time execution rate and the real-time rate derivative to obtain the corresponding interpolated motion instruction. Finally, the computer device 108 transmits the interpolated motion command to the servo driver 106, which then adjusts the motion speed of the machine device 110 based on the received interpolated motion command. At the next sampling moment, the computer device 108 uses the real-time execution rate as the historical execution rate calculated at the previous sampling moment, the real-time rate derivative as the historical rate derivative, and returns to the step of obtaining the historical execution rate, historical rate derivative, and rate command calculated at the previous sampling moment. The computer device 108 terminates rate adjustment until the real-time execution rate calculated at the corresponding sampling moment equals the obtained command rate.
[0040] It should be noted that the control device 102 can be, but is not limited to, a teaching pendant and a machine tool panel. The motion planner 104 is a device used to achieve precise position control, speed control, acceleration control, torque or force control of mechanical motion; the motion planner 104 can be classified into a single-chip microcomputer controller, a stand-alone motion controller, a PC-based motion control card and a network controller according to its structure. The servo driver 106 is a controller used to control a servo motor. Its function is similar to that of a frequency converter acting on an ordinary AC motor. It is part of a servo system and is mainly used in high-precision positioning systems. It generally controls the servo motor in three ways: position, speed and torque to achieve high-precision transmission system positioning. The computer device 108 can be a terminal or a server, wherein the terminal can be, but is not limited to, various personal computers, laptops, smart phones, tablet computers and portable wearable devices, and the server can be implemented as an independent server or a server cluster consisting of multiple servers.
[0041] In one embodiment, Figure 2 As shown, a motion magnification adjustment method is provided, which is applied to Figure 1 The computer device in the example is used to illustrate the process, including the following steps:
[0042] Step S202 , obtaining the historical execution magnification calculated at the previous sampling moment, the historical magnification derivative corresponding to the historical execution magnification, and the magnification instruction transmitted via the control device, wherein the magnification instruction carries the instruction magnification.
[0043] The control device includes a magnification adjustment module. A magnification instruction is a command generated when a user operates the magnification adjustment module to adjust the magnification. The instruction magnification refers to the magnification data contained in the instruction magnification. For example, if the control device sets the magnification to 50%, the instruction magnification is 0.5, and the control device will maintain this value until it is next changed.
[0044] Specifically, the multiplier instruction is usually transmitted by the control device. When the computer device determines that the communication connection with the control device is normal, the computer device will receive the multiplier instruction transmitted via the control device and parse the instruction multiplier from the multiplier instruction.
[0045] In one embodiment, the control device can be at least one of a teach pendant and a machine panel. It should be noted that the teach pendant, also known as a programming pendant, is a core component of a robotic control system. It is a device used to register and store mechanical motion or process memory, and is executed by an electronic system or computer system. The machine panel is a key component of a CNC machine tool and serves as a tool for operators to interact with the CNC machine tool (system). It primarily consists of a display device, keyboard, status light, and handheld unit.
[0046] In step S204, based on the historical execution rate, historical rate derivative and instruction rate, the execution rate that the machine device needs to execute during the current sampling process and the rate derivative corresponding to the execution rate are calculated to obtain the real-time execution rate and real-time rate derivative.
[0047] Specifically, the real-time execution rate is calculated by the following steps: Based on the historical execution rate, the historical rate derivative, and the preset sampling time, the execution rate required by the machine device during the current sampling process is calculated using the following formula to obtain the real-time execution rate:
[0048]
[0049] Among them, r s + To execute the magnification in real time, r s - is the historical execution rate, is the historical rate derivative, T s is the sampling time.
[0050] In one embodiment, the computer device uses a preset tracking differentiator, takes the historical execution rate, the historical rate derivative (with respect to time) and the preset sampling time as input data of the tracking differentiator, and the tracking differentiator processes the input data based on the above formula (1) to obtain the corresponding real-time execution rate.
[0051] In the above embodiment, the real-time execution rate can be understood as the actual interpolation step size. For example, the real-time execution rate at the previous sampling moment is 0.2, and a rate instruction with a rate of 0.5 is received at the current sampling moment. In order to ensure the continuity of movement, the computer device will control the real-time execution rate of the machine device through the tracking differentiator to continuously change from 0.2 to 0.5, rather than directly jumping from 0.2 to 0.5. In this way, the flexibility and smoothness of the movement are guaranteed, and overshoot of the rate adjustment is avoided.
[0052] Specifically, the real-time rate derivative is calculated by the following steps: Based on the historical execution rate, the historical rate derivative, the instruction rate, and the preset sampling time, the second-order rate derivative is calculated using the following formula:
[0053]
[0054] Among them, r s - is the historical execution rate, is the historical rate derivative, T s is the sampling time, r in A is the command multiplier. maxis the preset upper bound of the second-order derivative of the magnification, f is the second-order derivative of the magnification, and fhan(·) is a nonlinear function;
[0055] According to the second-order derivative of the magnification f and the preset upper bound of the magnification derivative V max , the real-time rate derivative corresponding to the real-time execution rate is calculated using the following formula:
[0056]
[0057] in, is the real-time rate derivative, and sat(·) is the saturation function.
[0058] In one embodiment, fhan(x, v, a, h) is a nonlinear function, which is mainly used to calculate the second-order derivative of the magnification and is defined as follows:
[0059]
[0060] Among them, x, v, a, h are the first input parameters that need to be processed by the nonlinear function, and sign(·) is the sign function, which can separate the sign of the function.
[0061] In one embodiment, sat(x,u,l) is a saturation function defined as follows:
[0062]
[0063] Among them, x, u, l are the second input parameters that need to be processed by the saturation function.
[0064] In the above embodiment, the step change magnification is adjusted by tracking the differentiator, which ensures the smoothness and overshoot of the magnification adjustment, improves the adjustment efficiency, and has great application value in robot collision detection and safety response functions.
[0065] Step S206 , obtaining the motion instructions transmitted via the motion planner, and performing interpolation conversion on the motion instructions according to the real-time execution rate and the real-time rate derivative to obtain corresponding interpolated motion instructions.
[0066] Specifically, the method also includes: at the corresponding sampling moment, taking out two target objects from a preset circular buffer in chronological order; taking the first target object that is earlier in time as the first node, taking the second target object that is later in time as the second node, and taking the motion time as the interpolation variable; according to the node interval formed between the first node and the second node, when it is determined that the calculated real-time execution ratio is greater than zero and the interpolation variable exceeds the node interval, the first node currently removed is stored through a preset motion data bidirectional stack; and when it is determined that the interpolation variable exceeds the node range interval, the motion instruction currently transmitted through the motion planner is stored through a preset circular buffer; the second node is taken as the new first node, the third target object that is re-taken out of the circular buffer and is later in time is taken as the new second node, and the interpolation variable is re-determined; returning to the step of determining the value of the real-time execution ratio and judging whether the interpolation variable exceeds the corresponding node interval and continuing to execute until the corresponding iteration end condition is triggered, and then stopping the iteration.
[0067] In one embodiment, a computer device first determines node information based on forward or reverse data retrieved from a bidirectional motion data stack, or determines node information based on currently acquired motion instructions. The computer device then uses the node information, the real-time execution factor, and the real-time factor derivative as input data for an interpolator controller, which performs Hermite interpolation on the input data to generate corresponding interpolated motion instructions.
[0068] In the above embodiment, when the magnification changes in a step, the motion data is fitted using Hermite interpolation conversion, which can ensure the continuity of the acceleration and speed of the motion instructions after interpolation, avoid the overshoot caused by filtering (that is, the instantaneous magnification may be greater than the set value), and improve the reliability of the magnification adjustment.
[0069] In step S208 , the interpolation motion instruction is transmitted to the servo driver, so that the servo server adjusts the motion speed of the machine device according to the received interpolation motion instruction.
[0070] A motion command refers to the motion planned by the motion planner. When the multiplier is 1, the actual speed of the machine will remain consistent with the speed planned by the motion planner. When the multiplier is greater than 1, the actual speed will be greater than the planned speed. When the multiplier is less than 1 but greater than 0, the actual speed will be less than the planned speed. When the multiplier is less than zero, the machine will move backward. Based on the interpolated motion command received, the servo driver will control the machine to adjust its speed according to the interpolated target position information, target velocity information, and target acceleration information to ensure that the machine's speed remains consistent with the planned speed.
[0071] Step S210, when entering the next sampling moment, the real-time execution magnification is used as the historical execution magnification calculated at the previous sampling moment, the real-time magnification derivative is used as the historical magnification derivative, and the step of returning to obtain the historical execution magnification, historical magnification derivative and magnification instruction calculated at the previous sampling moment is continued to execute until the real-time execution magnification obtained at the corresponding sampling moment is equal to the obtained instruction magnification, and the magnification adjustment is ended.
[0072] In the above-mentioned motion rate adjustment method, the real-time execution rate and the real-time rate derivative are calculated based on the historical execution rate calculated at the previous sampling moment, the historical rate derivative corresponding to the historical execution rate, and the rate instruction transmitted by the control device; wherein, the real-time execution rate can be understood as the actual step size of interpolation. Currently, the motion instructions transmitted through the motion planner are interpolated and converted based on the real-time execution rate and the real-time rate derivative, which can ensure the continuity of the acceleration and speed of the interpolated motion instructions, avoid the overshoot caused by filtering (that is, the instantaneous rate may be greater than the set value), improve the reliability of the rate adjustment, and thereby ensure the flexibility and smoothness of the machine movement.
[0073] In one embodiment, please refer to Figure 3 , according to the real-time execution rate and the real-time rate derivative, the motion instructions are interpolated and converted to obtain the corresponding interpolated motion instructions, including:
[0074] Step S302, when it is determined that the circular buffer is not full and the real-time execution ratio is greater than zero, reverse data is obtained from the motion data bidirectional stack, and node information is determined based on the obtained reverse data; the reverse data includes the first motion instruction interpolated when it is determined that the real-time execution ratio is less than zero.
[0075] Among them, the motion data bidirectional stack refers to two stacks that share a stack top pointer. When the top of the motion data bidirectional stack coincides with the bottom of the forward data stack, there is only reverse data. When the top of the motion data bidirectional stack coincides with the bottom of the reverse data stack, there is only forward data. If the top of the motion data bidirectional stack is in the middle of the two stack bottoms, it can be considered that the motion data bidirectional stack contains both reverse data and forward data. Forward data refers to the motion instruction (data) interpolated when the actual magnification is greater than zero. At this time, the actual motion direction of the machine equipment is the same as the planned motion direction. Reverse data refers to the motion instruction (data) interpolated when the actual magnification is less than zero. At this time, the actual motion direction of the machine equipment is opposite to the planned motion direction (moving backwards).
[0076] Specifically, the computer device determines whether there is reverse data in the motion data bidirectional stack based on the relative position relationship between the top of the stack and the two bottoms of the stack in the motion data bidirectional stack, based on the remaining storage space size of the determined circular buffer. When it is determined that the circular buffer is not full and the real-time execution ratio is greater than zero, the computer device determines whether there is reverse data in the motion data bidirectional stack. When it is determined that there is reverse data, the computer device acquires the reverse data and determines the node information based on the acquired reverse data.
[0077] In one embodiment, if the circular buffer size is five motion instructions, and the computer device indicates a caching failure during instruction caching, indicating that the circular buffer is full, the computer device will interpolate the currently acquired motion instructions based on the acquired node information and the real-time execution magnification ratio and its derivative calculated in step S204. If the caching is successful, the computer device will determine the value of the real-time execution magnification ratio. If the real-time execution magnification ratio is greater than zero, the computer device will obtain reverse data from the motion data bidirectional stack and determine the node information based on the obtained reverse data.
[0078] In the above embodiments, for applications such as machine equipment collision detection, the machine equipment is often required to perform a back-off operation after detecting a collision, which requires that the motion magnification can be set to a negative value. The above-mentioned reverse data is determined based on the relative position relationship between the top of the stack and the two bottoms of the stack in the bidirectional stack of motion data, which improves the efficiency of reverse data recognition, fits the application scenario of robot collision detection, and has great application value.
[0079] Step S304: When the reverse data acquisition fails, node information is determined based on the currently acquired motion instruction.
[0080] It should be noted that in the current embodiment, the computer device will determine whether there is reverse data in the motion data bidirectional stack based on the relative position relationship between the top of the stack and the two bottoms of the stack. When it is confirmed that the top of the motion data bidirectional stack does not overlap with the bottom of the forward data stack, it can be considered that the current reverse data acquisition has failed, and the node information needs to be determined based on the acquired motion instructions.
[0081] Step S306, when it is determined that the circular buffer is not full and the real-time execution ratio is less than zero, forward data is obtained from the motion data bidirectional stack, and node information is determined based on the obtained forward data; the forward data includes the second motion instruction interpolated when it is determined that the real-time execution ratio is greater than zero.
[0082] Specifically, when it is determined that the circular buffer is not full and the real-time execution multiplier is less than zero, the computer device acquires forward data based on the relative position relationship between the top of the stack and the two bottoms of the stack in the motion data bidirectional stack, and when it is determined that the top of the motion data bidirectional stack coincides with the bottom of the reverse data stack, and determines the node information based on the acquired forward data.
[0083] In one embodiment, when forward data acquisition fails, i.e., when it is determined that the top of the bidirectional motion data stack does not overlap with the bottom of the reverse data stack, a corresponding error message is output. In one embodiment, the error message output by the computer device can be displayed on a display screen provided by the computer device, or on a display terminal connected to the computer device, and the error message can be displayed on the display screen and / or display terminal to prompt an operator to perform equipment maintenance and fault detection.
[0084] In step S308 , a preset interpolator controller performs Hermite interpolation conversion according to the node information, the real-time execution magnification and the real-time magnification derivative to obtain a corresponding interpolation motion instruction.
[0085] Specifically, the node information includes interpolation position information, speed information and acceleration information; a preset interpolator controller performs Hermite interpolation conversion according to the node information, real-time execution magnification and real-time magnification derivative to obtain corresponding interpolation motion instructions, including: calculating the interpolation polynomial coefficients according to the preset sampling time and node information; determining the interpolation time, and calculating the target interpolation position information, target speed information and target acceleration information after interpolation according to the calculated interpolation polynomial coefficients, interpolation time, real-time execution magnification and real-time magnification derivative; generating instructions based on the target interpolation position information, target speed information and target acceleration information to obtain corresponding interpolation motion instructions.
[0086] In one embodiment, the interpolation polynomial coefficients are calculated according to the preset sampling time and node information, including: calculating and determining the corresponding interpolation polynomial coefficients using the following formula:
[0087]
[0088] Where x0 is the position information of the first node, v0 is the velocity information of the first node, and a0 is the acceleration information of the first node; x1 is the position information of the second node, v1 is the velocity information of the second node, and a1 is the acceleration information of the second node; T s is the preset sampling time; p0~p5 are the corresponding interpolation polynomial coefficients.
[0089] In one embodiment, calculating the target interpolation position information, target velocity information, and target acceleration information after interpolation based on the calculated interpolation polynomial coefficients, interpolation time, real-time execution rate, and real-time rate derivative includes: calculating the target interpolation position information, target velocity information, and target acceleration information after interpolation using the following formula:
[0090]
[0091] Among them, t is the interpolation time, and its value range is [0,T s ]; r s + To perform the multiplication in real time, is the real-time rate derivative; q is the target interpolation position information, q v is the target speed information, q a is the target acceleration information.
[0092] In the above embodiment, when the magnification changes in a step, the motion data is fitted using Hermite interpolation conversion, which can ensure the continuity of the acceleration and speed of the motion instructions after interpolation, avoid the overshoot caused by filtering (that is, the instantaneous magnification may be greater than the set value), and improve the reliability of the magnification adjustment.
[0093] When the motion magnification adjustment method disclosed in any of the above embodiments is applied to a corresponding processing system, the system structure block diagram of the processing system is as follows: Figure 4 As shown, it includes a teach pendant, a second-order tracking differentiator, a quintic Hermite interpolator, a servo drive, a motion planner and a circular buffer, wherein:
[0094] (1) Teaching pendant, used to transmit the magnification instruction to the second-order tracking differentiator.
[0095] (2) The second-order tracking differentiator is used to receive the rate command and obtain the historical execution rate and the historical rate derivative corresponding to the historical execution rate calculated at the previous sampling moment. On the other hand, it is also used to calculate the real-time execution rate and the real-time rate derivative based on the historical execution rate, the historical rate derivative, and the command rate, and transmit the obtained real-time execution rate and real-time rate derivative to the quintic Hermite interpolator.
[0096] (3) Motion planner, used to transmit planned motion instructions.
[0097] (4) A circular buffer for receiving and storing motion instructions transmitted via the motion planner.
[0098] (5) The quintic Hermite interpolator is used to receive the real-time execution rate and the real-time rate derivative, and to obtain the reverse motion data from the motion data bidirectional stack. If the acquisition fails, the quintic Hermite interpolator retrieves the planned motion instruction from the circular buffer and performs a quintic Hermite interpolation conversion on the currently retrieved planned motion instruction based on the real-time execution rate and the real-time rate derivative to obtain the corresponding interpolated motion instruction. The quintic Hermite interpolator is also used to transmit the calculated interpolated motion instruction to the servo drive.
[0099] (6) A servo drive, which is used to adjust the movement speed of the machine equipment according to the received interpolation movement instruction so that the movement speed of the machine equipment is consistent with the planned movement speed.
[0100] In the above-mentioned embodiments, a tracking differentiator is proposed to adjust the rate of step changes, thereby preventing overshoot in the rate adjustment. Furthermore, quintic Hermite interpolation is proposed to fit the planned motion instructions, thereby preventing jitter in motion speed and acceleration. Furthermore, the above-mentioned processing system supports setting the speed and acceleration of the rate change, and supports negative rates (i.e., reverse motion), which is well-suited for robot collision detection applications and has great application value in safety response functions.
[0101] Please refer to Figure 5 , combined with Figure 4 The overall operation process of the above-mentioned motion magnification adjustment method includes the following steps:
[0102] (1) Obtain the instruction rate and use it as the input of the tracking differentiator. The output of the tracking differentiator is the execution rate (actual rate). The tracking differentiator can be further determined by the above formulas (1) to (3). This embodiment of the present application will not be described in detail.
[0103] (2) Determine whether the circular buffer is full. If so, jump to step (3). Otherwise, determine whether the actual magnification is greater than zero. If so, further determine whether there is reverse data in the motion data bidirectional stack. If so, take the reverse data as the node information of the quintic Hermite interpolator. Otherwise, take the planned motion instruction as the node information of the quintic Hermite interpolator. If the running magnification is less than zero, determine whether there is forward data in the motion data bidirectional stack. If so, take the forward data as the node information of the quintic Hermite interpolator. Otherwise, perform error processing.
[0104] (3) Based on the acquired node information and the execution magnification (actual magnification) and its derivative calculated based on step (1), a quintic Hermite interpolator is used to calculate the motion instruction output to the servo drive. This process can be further described by the above formulas (6) to (7), which are not described in detail in the embodiments of the present application.
[0105] The embodiment of the present invention runs on the Linux platform. In this embodiment, the sampling period T s Set to 1 millisecond to track the upper speed limit V of the differentiator max Set to 5, A max The upper limit of acceleration is set to 50. Figure 6 As shown, the black solid line is the instruction magnification, which is Figure 6 It can be seen that at the 3rd second, the command rate will change from 1 to 0.15, and at the 7th second, the command rate will change from 1 to 0.15. The black dotted line is the execution rate (actual rate) achieved by the second-order tracking differentiator. It can be seen that the execution rate will change from 1 to 0.15 smoothly without overshoot at the 3rd second, and from 0.15 to 1 smoothly without overshoot at the 7th second. Taking the 3001st cycle as an example, if the command rate r is input at this time, in 0.15, the historical execution rate of the previous cycle =1, the historical rate derivative of the previous period is 0. After substituting these data into the above formulas (1) to (3), the real-time execution rate r of the current cycle can be calculated. s + 1, the real-time rate derivative of the current cycle is -0.05.
[0106] It should be noted that due to the real-time execution rate r s + Is positive, and there is no reverse data in the bidirectional stack of motion data (because the magnification is always positive and no reverse data is generated), according to Figure 5It can be seen that if the circular buffer is not full, it is necessary to take out the corresponding motion instructions from the motion planner and store the taken motion instructions in the circular buffer. Figure 4 The black solid line in the middle shows that the solid line lasts for 10 seconds and has 60,000 data points. Taking the 3001th cycle as an example, the circular buffer is not full at this time and the real-time execution rate is r s + It is positive, and there is no reverse data in the bidirectional stack of motion data. Therefore, it is necessary to take out the 3001st motion instruction from the motion planner and store it in the circular buffer.
[0107] like Figure 7 As shown, Figure 7 The black dashed line in the middle represents the executed motion command. In the first three seconds, due to the multiplier being 1, the interpolated motion command generated by the five-step Hermite interpolator is almost identical to the planned motion command, resulting in a nearly overlapping curve. However, between the third and seventh seconds, due to the execution multiplier not being 1, the interpolated motion command differs significantly from the planned motion command, but the interpolated motion command remains continuous. For example, in cycle 3001, the previous node of the five-step Hermite interpolator is the 3000th planned motion command, whose position x0, velocity v0, and acceleration a0 are -0.4605, -0.3962, and 1.071, respectively. The next node is the 3001th planned motion command, whose position x1, velocity v1, and acceleration a1 are -0.4609, -0.3951, and 1.073, respectively. Since the preset sampling time is 1 millisecond, after substituting the above known data into formula (6), the obtained quintic polynomial coefficients p0~p5 are: -0.4605, -0.3962, 0.5353, -4.3936, 7323.5 and -292953.6 respectively. Since the interpolation time t is 0.001 at this time, the real-time execution magnification r s + =1, real-time rate derivative = -0.05, based on formula (7), the target interpolation position q and target speed q after interpolation can be calculated. v , target acceleration q a They are -0.4609, -0.3951 and 1.019 respectively.
[0108] The above embodiments fully demonstrate that the motion magnification adjustment method of the present application can change the magnification smoothly without overshoot, and in this process the continuity of motion acceleration and speed will be guaranteed; in addition, the motion magnification adjustment method of the present application can conveniently set the speed and acceleration of the magnification change, effectively improving the efficiency of the magnification adjustment.
[0109] It should be understood that although Figure 2-3 and Figure 5 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. In addition, Figure 2-3 and Figure 5 At least part of the steps may include multiple steps or multiple stages. These steps or stages are not necessarily performed at the same time, but can be performed at different times. The order of execution of these steps or stages is not necessarily one by one, but can be performed in turn or alternately with other steps or at least part of the steps or stages in other steps.
[0110] In one embodiment, Figure 8 As shown, a motion magnification adjustment device 800 is provided, comprising: an acquisition module 801, a calculation module 802, a conversion module 803, an output module 804 and an iteration module 805, wherein:
[0111] The acquisition module 801 is used to obtain the historical execution rate calculated at the previous sampling moment, the historical rate derivative corresponding to the historical execution rate, and the rate instruction transmitted via the control device, where the rate instruction carries the instruction rate.
[0112] The calculation module 802 is used to calculate the execution rate that the machine equipment needs to execute in the current sampling process, as well as the rate derivative corresponding to the execution rate based on the historical execution rate, the historical rate derivative and the instruction rate, to obtain the real-time execution rate and the real-time rate derivative.
[0113] The conversion module 803 is used to obtain the motion instructions transmitted via the motion planner, and perform interpolation conversion on the motion instructions according to the real-time execution rate and the real-time rate derivative to obtain corresponding interpolated motion instructions.
[0114] The output module 804 is used to transmit the interpolation motion instruction to the servo driver, so that the servo server adjusts the motion speed of the machine device according to the received interpolation motion instruction.
[0115] Iterative module 805 is used to use the real-time execution rate as the historical execution rate calculated at the previous sampling moment, use the real-time rate derivative as the historical rate derivative when entering the next sampling moment, and return to the step of obtaining the historical execution rate, historical rate derivative and rate instruction calculated at the previous sampling moment to continue execution until the real-time execution rate obtained at the corresponding sampling moment is equal to the obtained instruction rate, and then end the rate adjustment.
[0116] In one embodiment, the calculation module 802 is further configured to calculate the execution rate that the machine device needs to execute during the current sampling process based on the historical execution rate, the historical rate derivative, and the preset sampling time, using the following formula to obtain the real-time execution rate:
[0117]
[0118] Among them, r s + To execute the magnification in real time, r s - is the historical execution rate, is the historical rate derivative, T s is the sampling time.
[0119] In one embodiment, the calculation module 802 is further configured to calculate the second-order derivative of the rate according to the historical execution rate, the historical rate derivative, the instruction rate, and the preset sampling time using the following formula:
[0120]
[0121] Among them, r s - is the historical execution rate, is the historical rate derivative, T s is the sampling time, r in A is the command multiplier. max is the preset upper bound of the second-order derivative of the magnification, f is the second-order derivative of the magnification, and fhan(·) is a nonlinear function;
[0122] According to the second-order derivative of the magnification f and the preset upper bound of the magnification derivative V max , the real-time rate derivative corresponding to the real-time execution rate is calculated using the following formula:
[0123]
[0124] in, is the real-time rate derivative, and sat(·) is the saturation function.
[0125] In one embodiment, the apparatus 800 further includes a cache module, wherein:
[0126] The cache module is used to take out two target objects from a preset circular buffer in time sequence at the corresponding sampling moment; take the first target object with an earlier time as the first node, take the second target object with a later time as the second node, and take the motion time as the interpolation variable; based on the node interval formed between the first node and the second node, when it is determined that the calculated real-time execution rate is greater than zero and the interpolation variable exceeds the node interval, store the first node currently removed through a preset motion data bidirectional stack; and when it is determined that the interpolation variable exceeds the node range interval, store the motion instruction currently transmitted through the motion planner through a preset circular buffer; take the second node as the new first node, take the third target object that is re-taken from the circular buffer and has a later time as the new second node, and redetermine the interpolation variable; return to the step of determining the value of the real-time execution rate and judging whether the interpolation variable exceeds the corresponding node interval and continue to execute until the corresponding iteration end condition is triggered, then stop the iteration.
[0127] In one embodiment, the conversion module 803 is also used to obtain reverse data from the motion data bidirectional stack when it is determined that the circular buffer is not full and the real-time execution ratio is greater than zero, and determine the node information based on the obtained reverse data; the reverse data includes the first motion instruction interpolated when it is determined that the real-time execution ratio is less than zero; when the reverse data acquisition fails, the node information is determined based on the currently acquired motion instruction; when it is determined that the circular buffer is not full and the real-time execution ratio is less than zero, the forward data is obtained from the motion data bidirectional stack, and the node information is determined based on the obtained forward data; the forward data includes the second motion instruction interpolated when it is determined that the real-time execution ratio is greater than zero; a preset interpolator controller performs Hermite interpolation conversion according to the node information, the real-time execution ratio and the real-time ratio derivative to obtain the corresponding interpolated motion instruction.
[0128] In one embodiment, the node information includes interpolation position information, velocity information and acceleration information; the conversion module 803 is further used to calculate the interpolation polynomial coefficients according to the preset sampling time and node information; determine the interpolation time, and calculate the target interpolation position information, target velocity information and target acceleration information after interpolation based on the calculated interpolation polynomial coefficients, interpolation time, real-time execution magnification and real-time magnification derivative; generate instructions based on the target interpolation position information, target velocity information and target acceleration information to obtain corresponding interpolation motion instructions.
[0129] In one embodiment, the conversion module 803 is further configured to calculate and determine corresponding interpolation polynomial coefficients using the following formula:
[0130]
[0131] Where x0 is the position information of the first node, v0 is the velocity information of the first node, and a0 is the acceleration information of the first node; x1 is the position information of the second node, v1 is the velocity information of the second node, and a1 is the acceleration information of the second node; T s is the preset sampling time; p0~p5 are the corresponding interpolation polynomial coefficients.
[0132] In one embodiment, the conversion module 803 is further configured to calculate the interpolated target interpolation position information, target velocity information, and target acceleration information using the following formula:
[0133]
[0134] Among them, t is the interpolation time, and its value range is [0,T s ]; r s + To perform the multiplication in real time, is the real-time rate derivative; q is the target interpolation position information, q v is the target speed information, q a is the target acceleration information.
[0135] The above-mentioned motion rate adjustment device calculates the real-time execution rate and the real-time rate derivative based on the historical execution rate calculated at the previous sampling moment, the historical rate derivative corresponding to the historical execution rate, and the rate instruction transmitted by the control device; wherein the real-time execution rate can be understood as the actual step size of interpolation. Currently, the motion instruction transmitted via the motion planner is interpolated and converted based on the real-time execution rate and the real-time rate derivative, which can ensure the continuity of the acceleration and speed of the interpolated motion instruction, avoid the overshoot caused by filtering (that is, the instantaneous rate may be greater than the set value), improve the reliability of the rate adjustment, and thereby ensure the flexibility and smoothness of the machine movement.
[0136] For the specific definition of the motion magnification adjustment device, please refer to the definition of the motion magnification adjustment method above, and will not be repeated here. The various modules in the above-mentioned motion magnification adjustment device can be implemented in whole or in part by software, hardware, or a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
[0137] In one embodiment, a computer device is provided. The computer device may be a terminal or a server, and its internal structure diagram may be as follows: Figure 9As shown. The computer device includes a processor, a memory and a communication interface connected via a system bus. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be achieved through WIFI, an operator network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a motion magnification adjustment method is implemented.
[0138] Those skilled in the art will understand that Figure 9 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than shown in the figure, or combine certain components, or have a different component arrangement.
[0139] In one embodiment, a computer device is further provided, including a memory and a processor. The memory stores a computer program, and the processor implements the steps in the above method embodiments when executing the computer program.
[0140] The above-mentioned computer device calculates the real-time execution rate and the real-time rate derivative based on the historical execution rate calculated at the previous sampling moment, the historical rate derivative corresponding to the historical execution rate, and the rate instruction transmitted by the control device; wherein the real-time execution rate can be understood as the actual step size of interpolation. Currently, the motion instructions transmitted via the motion planner are interpolated and converted based on the real-time execution rate and the real-time rate derivative, which can ensure the continuity of the acceleration and speed of the interpolated motion instructions, avoid the overshoot caused by filtering (that is, the instantaneous rate may be greater than the set value), improve the reliability of the rate adjustment, and thereby ensure the flexibility and smoothness of the machine movement.
[0141] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.
[0142] The above-mentioned storage medium calculates the real-time execution rate and the real-time rate derivative based on the historical execution rate calculated at the previous sampling moment, the historical rate derivative corresponding to the historical execution rate, and the rate instruction transmitted by the control device; wherein the real-time execution rate can be understood as the actual step size of interpolation. Currently, the motion instruction transmitted via the motion planner is interpolated and converted based on the real-time execution rate and the real-time rate derivative, which can ensure the continuity of the acceleration and speed of the interpolated motion instruction, avoid the overshoot caused by filtering (that is, the instantaneous rate may be greater than the set value), improve the reliability of the rate adjustment, and thereby ensure the flexibility and smoothness of the machine movement.
[0143] Those skilled in the art will appreciate that all or part of the processes in the above-mentioned embodiment methods can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application may include at least one of non-volatile and volatile memory. Non-volatile memory may include read-only memory (ROM), magnetic tape, floppy disk, flash memory or optical memory, etc. Volatile memory may include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).
[0144] The technical features of the above embodiments can be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0145] The above-described embodiments merely represent several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present invention. It should be noted that a person skilled in the art could make various modifications and improvements without departing from the spirit of the present application, all of which fall within the scope of protection of the present application. Therefore, the scope of protection of the present patent application shall be determined by the appended claims.
Claims
1. A motion magnification adjustment method, characterized in that: The method comprises: Obtaining a historical execution magnification calculated at a previous sampling moment, a historical magnification derivative corresponding to the historical execution magnification, and a magnification instruction transmitted via a control device, wherein the magnification instruction carries a command magnification; Calculating the execution rate required for the machine device to be executed during the current sampling process and the rate derivative corresponding to the execution rate based on the historical execution rate, the historical rate derivative, and the instruction rate to obtain the real-time execution rate and the real-time rate derivative; Obtaining a motion instruction transmitted via a motion planner, and performing interpolation conversion on the motion instruction according to the real-time execution magnification and the real-time magnification derivative to obtain a corresponding interpolated motion instruction; Transmitting the interpolation motion instruction to a servo driver, so that the servo driver adjusts the motion speed of the machine device according to the received interpolation motion instruction; When entering the next sampling moment, the real-time execution rate is used as the historical execution rate calculated at the previous sampling moment, the real-time rate derivative is used as the historical rate derivative, and the step of obtaining the historical execution rate, historical rate derivative and rate instruction calculated at the previous sampling moment is returned to continue execution until the real-time execution rate obtained at the corresponding sampling moment is equal to the obtained instruction rate, and the rate adjustment is ended.
2. The method according to claim 1, characterized in that The real-time execution rate is calculated by the following steps: Based on the historical execution rate, the historical execution rate derivative, and the preset sampling time, the execution rate that the machine device needs to execute during the current sampling process is calculated using the following formula to obtain the real-time execution rate: ; in, To perform the multiplication in real time, is the historical execution rate, is the historical rate derivative, is the sampling time.
3. The method according to claim 1, characterized in that The real-time rate derivative is calculated by the following steps: According to the historical execution rate, the historical rate derivative, the instruction rate and the preset sampling time, the second-order derivative of the rate is calculated by the following formula: ; in, is the historical execution rate, is the historical rate derivative, is the sampling time, is the instruction multiplier, is the preset upper bound of the second-order derivative of the magnification, is the second-order derivative of the rate, is a nonlinear function; According to the second derivative of the magnification and the preset upper bound of the rate derivative , the real-time rate derivative corresponding to the real-time execution rate is calculated by the following formula: ; in, is the real-time rate derivative, is a saturation function.
4. The method according to claim 1, wherein The method further comprises: At the corresponding sampling moment, two target objects are taken out from the preset circular buffer in time sequence; The first target object that is ahead in time is used as the first node, the second target object that is behind in time is used as the second node, and the movement time is used as the interpolation variable; Based on a node interval formed between the first node and the second node, when it is determined that the calculated real-time execution magnification is greater than zero and the interpolation variable exceeds the node interval, storing the first node currently moved out via a preset motion data bidirectional stack; and when it is determined that the interpolation variable exceeds the node interval, storing the motion instruction currently transmitted via the motion planner via a preset circular buffer; The second node is used as a new first node, the third target object which is retrieved from the circular buffer and has a later time as a new second node, and the interpolation variable is re-determined; The process returns to the step of determining the value of the real-time execution multiplier and determining whether the interpolation variable exceeds the corresponding node interval, and continues to execute until the corresponding iteration end condition is triggered, and then stops the iteration.
5. The method according to claim 4, characterized in that The interpolation conversion of the motion instruction according to the real-time execution rate and the real-time rate derivative to obtain the corresponding interpolation motion instruction includes: When it is determined that the circular buffer is not full and the real-time execution magnification is greater than zero, reverse data is acquired from the motion data bidirectional stack, and node information is determined based on the acquired reverse data; the reverse data includes the first motion instruction interpolated when it is determined that the real-time execution magnification is less than zero; When reverse data acquisition fails, node information is determined based on the currently acquired motion instructions; When it is determined that the circular buffer is not full and the real-time execution magnification is less than zero, forward data is acquired from the motion data bidirectional stack, and node information is determined based on the acquired forward data; the forward data includes the second motion instruction interpolated when it is determined that the real-time execution magnification is greater than zero; A preset interpolator controller performs Hermite interpolation conversion according to the node information, the real-time execution magnification and the real-time magnification derivative to obtain a corresponding interpolation motion instruction.
6. The method according to claim 5, characterized in that The node information includes interpolated position information, velocity information, and acceleration information; the preset interpolator controller performs Hermite interpolation conversion based on the node information, the real-time execution magnification, and the real-time magnification derivative to obtain corresponding interpolated motion instructions, including: Calculating the interpolation polynomial coefficients according to the preset sampling time and the node information; Determine the interpolation time, and calculate the target interpolation position information, target velocity information, and target acceleration information after interpolation based on the calculated interpolation polynomial coefficients, interpolation time, real-time execution magnification, and real-time magnification derivative; Instructions are generated based on the target interpolation position information, target velocity information, and target acceleration information to obtain corresponding interpolation motion instructions.
7. The method according to claim 6, characterized in that The calculation of the interpolation polynomial coefficients according to the preset sampling time and the node information includes: The corresponding interpolation polynomial coefficients are calculated using the following formula: ; in, is the location information of the first node, is the speed information of the first node, is the acceleration information of the first node; is the location information of the second node, is the speed information of the second node, is the acceleration information of the second node; is the preset sampling time; are the corresponding interpolation polynomial coefficients; The method of calculating the target interpolation position information, target velocity information, and target acceleration information after interpolation based on the calculated interpolation polynomial coefficients, interpolation time, real-time execution rate, and real-time rate derivative includes: The interpolated target position information, target velocity information, and target acceleration information are calculated using the following formula: ; in, is the interpolation time, and its value range is ; To perform the multiplication in real time, is the real-time rate derivative; Interpolate the target position information, is the target speed information, is the target acceleration information.
8. A motion magnification adjustment device, characterized in that: The device comprises: an acquisition module, configured to acquire a historical execution magnification calculated at a previous sampling moment, a historical magnification derivative corresponding to the historical execution magnification, and a magnification instruction transmitted via a control device, wherein the magnification instruction carries an instruction magnification; a calculation module, configured to calculate the execution magnification required to be executed by the machine device during the current sampling process and the magnification derivative corresponding to the execution magnification based on the historical execution magnification, the historical magnification derivative, and the instruction magnification, to obtain the real-time execution magnification and the real-time magnification derivative; a conversion module, configured to obtain a motion instruction transmitted via the motion planner, and perform interpolation conversion on the motion instruction according to the real-time execution magnification and the real-time magnification derivative to obtain a corresponding interpolated motion instruction; an output module, configured to transmit the interpolation motion instruction to a servo driver, so that the servo driver adjusts the motion speed of the machine device according to the received interpolation motion instruction; An iterative module is used to, when entering the next sampling moment, use the real-time execution rate as the historical execution rate calculated at the previous sampling moment, use the real-time rate derivative as the historical rate derivative, and return to the step of obtaining the historical execution rate, historical rate derivative and rate instruction calculated at the previous sampling moment to continue execution until the real-time execution rate obtained at the corresponding sampling moment is equal to the obtained instruction rate, and then end the rate adjustment.
9. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Collaborative movement control method of industrial robot
CN110497411A
Method for controlling motion of device, device, and storage apparatus
CN111727411A