Robot control method and device, robot, computer readable storage medium and computer program product

By determining the relationship between the energy conversion state of the motor and the target torque current mapping relationship in the robot, and combining real-time speed and torque commands for current conversion and compensation, the problem of low accuracy of the robot's movement is solved, and high-precision torque control is achieved.

CN119675500APending Publication Date: 2025-03-21UBTECH ROBOTICS CORP LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202411673205.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-20
Publication Date
2025-03-21

AI Technical Summary

Technical Problem

In the prior art, the robot's operation accuracy is low, mainly due to the low torque control accuracy of the joint servo, which is affected by nonlinear factors, which leads to a deviation from the required torque.

Method used

By determining the energy conversion state of the motor based on the rotation direction and current direction of the motor in the joint servo, the target torque current mapping relationship is determined from multiple torque current mapping relationships based on this state, and combining the real-time rotation speed and torque command of the motor, the current is converted and compensated to eliminate harmonics, obtain accurate current commands, and control the motor to generate the target torque.

Benefits of technology

It realizes the robot's diversified torque control mode without installing torque sensors, eliminates the influence of harmonics, accurately controls the motor output torque, improves the torque control accuracy, and improves the accuracy of the robot's movements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119675500A_ABST
    Figure CN119675500A_ABST
Patent Text Reader

Abstract

The invention provides a robot control method and device, a robot, a computer program product and a computer readable storage medium. The method comprises the steps that the energy conversion state of a motor is determined according to the rotation direction and the current direction of the motor in the joint steering engine; determining a target torque current mapping relation from a plurality of torque current mapping relations based on the energy conversion state; according to the real-time rotating speed of the motor and a torque instruction received by the joint steering engine, determining conversion current from the target torque current mapping relation; determining a first compensation current used for eliminating harmonic waves brought by the conversion current, and compensating the conversion current by using the first compensation current to obtain a current instruction; and based on the current instruction, a motor in the joint steering engine is controlled to generate target torque. According to the invention, the precision degree of the action of the robot can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to robotics technology, and in particular to a robot control method, a robot, a computer-readable storage medium, and a computer program product. Background Art

[0002] In order to realize the motion control capability of the humanoid robot, the robot's joint servo needs to have the ability of high-precision torque control. The torque control of the joint servo can be achieved through a torque sensor. However, due to the influence of some nonlinear factors, there will be a deviation between the torque output by the motor and the required torque, resulting in low accuracy of torque control. It can be seen that in the related art, when controlling the movement of the robot, there is a problem of low accuracy of the robot's movements. Summary of the invention

[0003] The embodiments of the present application provide a robot control method, device, robot, computer-readable storage medium and computer program product, which can improve the accuracy of robot movements.

[0004] The technical solution of the embodiment of the present application is implemented as follows:

[0005] The present application provides a robot control method, the method comprising:

[0006] Determining the energy conversion state of the motor according to the rotation direction and current direction of the motor in the joint servo;

[0007] Based on the energy conversion state, determining a target torque-current mapping relationship from a plurality of torque-current mapping relationships;

[0008] According to the real-time speed of the motor and the torque command received by the joint servo, the conversion current is determined from the target torque-current mapping relationship; wherein the torque command is sent by the upper processing system;

[0009] Determine a first compensation current for eliminating harmonics caused by the conversion current, and use the first compensation current to compensate the conversion current to obtain a current instruction;

[0010] Based on the current command, the motor in the joint steering gear is controlled to generate a target torque, where the target torque is the torque corresponding to the torque command.

[0011] The present application provides a robot control device, comprising:

[0012] A torque current converter, used for determining the energy conversion state of the motor according to the rotation direction and current direction of the motor in the joint servo; determining a target torque current mapping relationship from a plurality of torque current mapping relationships based on the energy conversion state; determining a conversion current from the target torque current mapping relationship according to the real-time rotation speed of the motor and the torque command received by the joint servo; wherein the torque command is sent by an upper processing system; determining a first compensation current for eliminating harmonics caused by the conversion current, and using the first compensation current to compensate the conversion current to obtain a current command;

[0013] The motor control circuit is used to control the motor in the joint servo to generate a target torque based on the current command, and the target torque is the torque corresponding to the torque command.

[0014] In the above scheme, the torque current converter is also used to calculate the proportional relationship between the conversion current and the harmonic analysis current; wherein the harmonic analysis current is the current used in harmonic analysis; and the first compensation current is determined based on the proportional relationship and the second compensation current corresponding to the harmonic analysis current.

[0015] In the above solution, the control device of the robot may further include: a harmonic analysis circuit, which is used to determine the second compensation current based on the harmonic analysis current.

[0016] In the above scheme, the harmonic analysis circuit is also used to perform N-th torque test on the joint servo when the joint servo uses the harmonic analysis current as the current command, so as to obtain N groups of torque data; wherein N is an integer, and N≥2; perform harmonic analysis on the N groups of the torque data to obtain the phase, amplitude and direction of the M-th harmonic; wherein M is a positive integer; determine the second compensation current based on the phase, amplitude and direction of the M-th harmonic; wherein the phase of the second compensation current is complementary to the phase of the M-th harmonic, the amplitude is the same as the amplitude of the M-th harmonic, and the direction is opposite to the direction of the M-th harmonic.

[0017] In the above scheme, the torque-to-current converter is also used to determine the energy conversion state as a discharge state when the rotation direction and the current direction of the motor in the articulated servo meet the discharge condition; and to determine the energy conversion state as a power generation state when the rotation direction and the current direction of the motor meet the power generation condition.

[0018] In the above scheme, the discharge condition includes: the rotation direction is positive and the current direction is positive, or the rotation direction is negative and the current direction is negative; the power generation condition includes: the rotation direction is positive and the current direction is negative, or the rotation direction is negative and the current direction is positive.

[0019] In the above scheme, the torque current converter is also used to determine the discharge torque current mapping relationship among the multiple torque current mapping relationships as the target torque current mapping relationship when the energy conversion state includes a discharge state; and to determine the generation torque current mapping relationship among the multiple torque current mapping relationships as the target torque current mapping relationship when the energy conversion state includes a generation state.

[0020] The present application provides a robot, comprising:

[0021] A memory for storing computer executable instructions or computer programs;

[0022] The processor is used to implement the robot control method provided in the embodiment of the present application when executing the computer executable instructions or computer programs stored in the memory.

[0023] An embodiment of the present application provides a computer-readable storage medium storing a computer program or computer-executable instructions for implementing the robot control method provided in the embodiment of the present application when executed by a processor.

[0024] An embodiment of the present application provides a computer program product, including a computer program or computer executable instructions. When the computer program or computer executable instructions are executed by a processor, the robot control method provided by the embodiment of the present application is implemented.

[0025] The embodiment of the present application has the following beneficial effects: first, according to the rotation direction and current direction of the motor in the joint servo, the energy conversion state of the motor is determined, then according to the energy conversion state of the motor, the most suitable target torque current mapping relationship is determined for the motor, according to the determined target torque current mapping relationship and the real-time speed of the motor, the torque command sent by the upper processing system is converted to obtain the conversion current, and the first compensation current is determined, and the conversion current is compensated by the first compensation current to eliminate the harmonics caused by the conversion current to obtain the current command, and finally the torque generation of the motor is controlled based on the obtained current command. In this way, the torque current conversion can be realized according to the mapping relationship between the torque and the current, and the torque sensor does not need to be installed on the robot, so that the robot can realize the diversified torque control mode, and at the same time, the influence of harmonics can be eliminated to obtain the current command that can accurately control the output torque of the motor, ensure the consistency of the torque output, improve the accuracy of the torque control, and finally improve the accuracy of the robot's action. BRIEF DESCRIPTION OF THE DRAWINGS

[0026] Figure 1 It is a schematic diagram of a torque control system based on a torque sensor;

[0027] Figure 2 This is a schematic diagram of the process of the robot control method provided in the embodiment of the present application. Figure 1 ;

[0028] Figure 3 is a schematic diagram of the relationship between the torque command and the current command provided in the embodiment of the present application;

[0029] Figure 4 This is a schematic diagram of the process of the robot control method provided in the embodiment of the present application. Figure 2 ;

[0030] Figure 5 The system framework of the torque control of the joint servo provided in the embodiment of the present application Figure 1 ;

[0031] Figure 6 It is a schematic diagram of the process of torque current conversion provided by an embodiment of the present application;

[0032] Figure 7 The system framework of the torque control of the joint servo provided in the embodiment of the present application Figure 2 ;

[0033] Figure 8 is a schematic diagram of the structure of a control device of a robot provided in an embodiment of the present application;

[0034] Fig. 9 It is a schematic diagram of the structure of the robot provided in the embodiment of the present application. DETAILED DESCRIPTION

[0035] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings. The described embodiments should not be regarded as limiting the present application. All other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of this application.

[0036] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it can be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0037] In the following description, the terms "first\second" involved are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that "first\second" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.

[0038] In the embodiments of the present application, the term "module" or "unit" refers to a computer program or a part of a computer program with a predetermined function, and works together with other related parts to achieve a predetermined goal, and can be implemented in whole or in part by using software, hardware (such as processing circuits or memories) or a combination thereof. Similarly, a processor (or multiple processors or memories) can be used to implement one or more modules or units. In addition, each module or unit can be part of an overall module or unit that includes the function of the module or unit.

[0039] Unless otherwise defined, all technical and scientific terms used in the embodiments of the present application have the same meanings as those commonly understood by those skilled in the art. The terms used in the embodiments of the present application are only for the purpose of describing the embodiments of the present application and are not intended to limit the present application.

[0040] The relevant data collection and processing in the embodiments of this application should be strictly in accordance with the requirements of relevant laws and regulations when applied in examples, obtain the informed consent or separate consent of the personal information subject, and carry out subsequent data use and processing within the scope of authorization of laws and regulations and the personal information subject.

[0041] Before further describing the embodiments of the present application in detail, the nouns and terms involved in the embodiments of the present application are explained. The nouns and terms involved in the embodiments of the present application are subject to the following interpretations.

[0042] Different forms of robots have different motion control requirements. Generally speaking, humanoid robots need to have higher performance motion control capabilities. In order to achieve the motion control capabilities of humanoid robots, the robot's joint servos need to have torque control capabilities.

[0043] The torque control of the joint servo can be achieved through a torque sensor. Figure 1 This is a schematic diagram of a torque control system based on a torque sensor. Figure 1 In the torque control system, the torque closed-loop controller 1-2 is based on the torque command 1-1 and the permanent magnet synchronous motor fed back by the torque sensor 1-3, referred to as motor 1

[0044] -4's actual torque, output current command 1-5, and then input the error between current command 1-5 and the actual current value of motor 1-4 fed back by current sensor 1-6 into current closed-loop controller 1-7; current closed-loop controller 1-7 generates a signal for controlling motor current according to the obtained error, and the signal is input into space vector pulse width modulator (Space Vector Pulse Width Modulation, SVPWM) 1-8 to generate a PWM signal for controlling the inverter in the motor driver (not shown in the figure), and the inverter in the motor driver generates current according to the PWM signal, and inputs it into permanent magnet synchronous motor 1-4 to generate the torque specified by the torque command.

[0045] However, due to the limitations of the overall structure of some robots and reliability considerations, some robots' joints may not be suitable for installing torque sensors, which limits the robot's need to achieve diversified torque control modes; and due to the influence of some nonlinear factors, such as the inconsistency of the three-phase winding of the motor, the magnetization of the motor magnet, and the nonlinear factors caused by the installation of the motor-end encoder, the torque output by the motor deviates from the torque required by the host computer, resulting in low torque control accuracy. In summary, in the related art, when controlling the movement of the robot, there is a problem of low accuracy of the robot's movements.

[0046] In this regard, an embodiment of the present application provides a robot control method, which can be applied to the joint control scenario of the robot. When controlling the robot, the energy conversion state of the motor itself can be determined according to the rotation direction and current direction of the motor in the joint servo, and then based on the determined energy conversion state, the most appropriate target torque-current mapping relationship is determined for the motor. According to the real-time speed of the motor and the torque command received by the joint servo, the conversion current is determined from the target torque-current mapping relationship, and the first compensation current for eliminating the harmonics caused by the conversion current is determined. The first compensation current is used to compensate the conversion current to obtain a current command. Finally, based on the current command, the motor in the joint servo is controlled to generate the target torque corresponding to the torque command. In this way, not only can the robot's diversified torque control modes be realized without a torque sensor, but the influence of harmonics can also be eliminated to obtain a current command that can accurately control the output torque of the motor, ensure the consistency of the torque output, and improve the accuracy of the torque control, so that the accuracy of the robot's movement is finally improved.

[0047] Next, the control method of the robot provided in the embodiment of the present application will be described. It should be noted that the robot in the embodiment of the present application includes a joint servo.

[0048] See also Figure 2 , Figure 2 This is a schematic diagram of the process of the robot control method provided in the embodiment of the present application. Figure 1 , will combine Figure 2 The steps shown are explained, Figure 2 The main body of the step is the robot.

[0049] Step 101: Determine the energy conversion state of the motor according to the rotation direction and current direction of the motor in the joint servo.

[0050] The embodiment of the present application is implemented in the scenario of controlling the action of a robot, which is a robot with a joint servo, such as a humanoid robot, a bionic robot, etc.; the action of the robot here can be an autonomous response made by the upper processing system of the robot to the external environment or the interaction of the user, such as autonomous obstacle avoidance, autonomous steering, etc., or it can be a response made by the upper processing system in response to the instructions issued by the user. In the control process of the robot, the robot first needs to obtain the rotation direction of the motor in the joint servo, and the current direction of the motor, and determine the current energy conversion state of the motor based on the determined rotation direction and current direction.

[0051] It should be noted that the joint servo is a component that enables the joints of the robot to move flexibly. The joint servo contains a motor. The rotation direction of the motor in the joint servo refers to the orientation of the rotational motion output by the motor shaft, which can be clockwise or counterclockwise. The current direction of the motor refers to the direction of the current flowing through the motor winding; for an AC motor, the direction of the current will change over time. This is because the voltage provided by the AC power supply is alternating, which causes the current of the motor to change direction periodically.

[0052] The motor in the articulated servo can be a permanent magnet synchronous motor (PMSM) or an AC synchronous motor (ACSM), which is not limited in the embodiments of the present application.

[0053] Energy conversion state refers to the conversion mode between electrical energy and mechanical energy. In the embodiment of the present application, the energy conversion state of the motor can be any one of a discharge state and a power generation state. Among them, the discharge state refers to the state of converting electrical energy into mechanical energy; the power generation state refers to the state of converting mechanical energy into electrical energy.

[0054] The upper processing system of the robot (i.e., the host computer) refers to a system that plans the actions or reactions of the robot based on the external environment or the interaction with the user. The upper processing system of the robot can be integrated inside the robot (for example, integrated into the central processing unit of the robot), so that the robot can autonomously respond to the external environment or the interaction with the user, such as autonomous obstacle avoidance and autonomous turn signals; the upper processing system of the robot can also be set in an electronic device, such as a terminal, or a server, so that the robot can respond to the external environment or the interaction with the user according to the control of the operator, and the embodiments of the present application are not limited here. The upper processing system of the robot can communicate with the joint servo of the robot through a wired or wireless network, so that the joint servo can receive the torque command sent by the upper processing system of the robot.

[0055] It should be noted that whether the energy conversion state is a discharge state or a power generation state can be determined based on the rotation direction and current direction of the motor.

[0056] In some embodiments of the present application, Figure 2 Step 101 in, i.e., determining the energy conversion state of the motor according to the rotation direction and current direction of the motor in the joint servo, can be achieved by the following processing: when the rotation direction and current direction of the motor in the joint servo meet the discharge condition, the energy conversion state is determined to be the discharge state; when the rotation direction and current direction of the motor meet the power generation condition, the energy conversion state is determined to be the power generation state.

[0057] In other words, the robot will determine whether the rotation direction and current direction of the motor meet the discharge condition or the power generation condition, and determine the state corresponding to the condition hit by the rotation direction and current direction as the current energy conversion state. That is, when the rotation direction and current direction meet the discharge condition, the discharge state is used as the current energy conversion state of the motor, and when the rotation direction and current direction meet the power generation condition, the power generation state is used as the current energy conversion state of the motor.

[0058] In the embodiment of the present application, the discharge condition may include: the rotation direction is positive and the current direction is positive, or the rotation direction is negative and the current direction is negative.

[0059] The power generation conditions may include: the power generation conditions include: the rotation direction is positive and the current direction is negative, or the rotation direction is negative and the current direction is positive.

[0060] That is to say, the discharge condition includes two conditions, one is that the rotation direction is positive and the current direction is positive, and the other is that the rotation direction is negative and the current direction is also negative. When any one of these two conditions is met, it can be regarded as meeting the discharge condition, and the energy conversion state of the motor will be determined as the discharge state.

[0061] Similarly, the power generation condition also includes two conditions, one is that the rotation direction is positive and the current direction is negative, and the other is that the rotation direction is negative and the current direction is positive. When either of these two conditions is met, it can be regarded as meeting the power generation condition, so the robot will determine the energy state as the power generation state.

[0062] In the embodiment of the present application, the positive direction of rotation means that the motor shaft rotates in a specified direction; the negative direction of rotation means that the motor shaft rotates in a direction opposite to the specified direction. The direction specified here can be clockwise or counterclockwise. Thus, when the specified direction is clockwise, if the motor shaft rotates clockwise, then the rotation direction of the motor can be regarded as positive, and if the motor shaft rotates counterclockwise, then the rotation direction of the motor can be regarded as negative; when the specified direction is counterclockwise, if the motor shaft rotates clockwise, then the rotation direction of the motor can be regarded as negative, and if the motor shaft rotates counterclockwise, then the rotation direction of the motor can be regarded as positive.

[0063] The positive direction of the current means that the direction of the current is consistent with the specified reference direction, and thus, the negative direction of the current means that the direction of the current is opposite to the specified reference direction. Here, the specified reference direction may refer to the direction of the current flow in the positive half cycle. Thus, when the direction of the current flow of the motor is the same as the direction of the current flow in the positive half cycle, the direction of the current of the motor can be regarded as positive; and when the direction of the current flow of the motor is opposite to the direction of the current flow in the negative half cycle, the direction of the current of the motor can be regarded as negative.

[0064] It should be noted that in the embodiment of the present application, the robot can complete this step through its processor. When the processor includes a torque current converter and a motor control circuit, the process of determining the energy conversion state of the motor according to the rotation direction and current direction of the motor in the joint servo can be achieved through the torque current converter.

[0065] Step 102: Determine a target torque-current mapping relationship from a plurality of torque-current mapping relationships based on the energy conversion state.

[0066] The robot first obtains multiple different torque-current mapping relationships, and then selects a torque-current mapping relationship suitable for the current energy conversion state of the motor from the multiple torque-current mapping relationships based on the obtained energy conversion state. The torque-current calibration model is the target torque-current mapping relationship.

[0067] The torque-current mapping relationship here is used to provide a conversion relationship between torque and current, so that the torque command can be converted into a corresponding current command through the torque-current mapping relationship. By controlling the rotation of the motor through the current command, the motor can be controlled to generate the target torque required by the torque command without a torque sensor.

[0068] It should be noted that the conversion relationship between the torque command and the current command may also be affected by the real-time speed of the motor, that is, for the same torque command, if the real-time speed of the motor is different, the corresponding current command may also be different. Figure 3 Schematic diagram of the relationship between the torque command and the current command provided in the embodiment of the present application. Figure 3 It can be seen that when the torque command 3-1 is the same, the value of the current command 3-2 is different at different speeds, that is, speed 1 to speed 6. Therefore, the torque-current mapping relationship in the embodiment of the present application can provide the relationship between the torque command, the speed and the current command.

[0069] In some embodiments, the torque-current mapping relationship can be implemented as a two-dimensional table, which records all optional torque instructions and the current value corresponding to each torque instruction at different speeds, and the current value can be used as the current instruction. In this way, the processor can directly find the current instruction corresponding to the torque instruction based on the torque instruction received by the joint servo and the real-time speed of the motor.

[0070] In other embodiments, the torque-current mapping relationship can be implemented as a deep learning model, such as a convolutional neural network, a recurrent neural network, etc. The deep learning model can obtain the ability to convert the torque command into the current command through model training. At this time, the training data can be composed of a certain number of sample pairs, each of which is composed of a training torque command, a motor speed, and a current command label corresponding to the training torque command at the motor speed. For example, the first sample pair includes training torque command 1, motor speed 1, and current command label 1 corresponding to the training torque 1 at motor speed 1; the second sample pair includes training torque command 1, motor speed 2, and current command label 2 corresponding to the training torque command 1 at motor speed 2; the third sample pair includes training torque command 2, motor speed 1, and current command label 3 corresponding to the training torque command 2 at motor speed 1...

[0071] Since in the embodiment of the present application, the energy conversion state of the motor can be any one of the discharge state and the power generation state, and the discharge state and the power generation state each have their corresponding torque-current mapping relationship, the robot needs to combine the specific energy conversion state of the motor and determine the target torque-current mapping relationship to be queried from the torque-current mapping relationships corresponding to different states.

[0072] In some embodiments of the present application, Figure 2 Step 102, i.e., determining a target torque current mapping relationship from a plurality of torque current mapping relationships based on the energy conversion state, can be achieved by the following processing: when the energy conversion state includes a discharge state, determining a discharge torque current mapping relationship from a plurality of torque current mapping relationships as the target torque current mapping relationship; when the energy conversion state includes a power generation state, determining a power generation torque current mapping relationship from a plurality of torque current mapping relationships as the target torque current mapping relationship.

[0073] That is to say, when the motor is in the discharge state, it is necessary to convert the torque command into the corresponding current command through the discharge torque-current mapping relationship, and when the motor is in the power generation state, it is necessary to convert the torque command into the corresponding current command through the power generation torque-current mapping relationship.

[0074] It can be understood that the target torque-current mapping relationship determined by the robot is the most suitable torque-current mapping relationship for the energy conversion state. According to the target torque-current mapping relationship corresponding to the energy conversion state, the torque-current conversion can be performed more accurately. It can be seen that in the embodiment of the present application, by determining the most suitable target torque-current mapping relationship for the energy conversion state, the torque-current conversion can be performed for different energy conversion states using the most suitable torque-current mapping relationship, thereby helping to improve the accuracy of the torque-current conversion, and thus improving the accuracy of the current instruction.

[0075] It should be noted that the robot completes the processing of this step through its processor. When the processor includes a torque current converter and a motor control circuit, the process of determining the target torque current calibration model from multiple torque current calibration models based on the energy conversion state can be implemented by the torque current conversion circuit.

[0076] Step 103: Determine the conversion current from the target torque current calibration model according to the real-time rotation speed of the motor and the torque command received by the joint servo.

[0077] Here, the torque command is sent by the upper processing system. After determining the target torque-current mapping relationship, the robot will obtain the real-time speed of the motor and the torque command received by the joint servo, and then uniquely determine a current value from the target torque-current mapping relationship based on the real-time speed of the motor and the received torque command. This current value is the conversion current. In other words, the conversion current determined here is not the actual current formed by the flow of electrons, but a current value, which can be used as a parameter or signal (i.e., current command) to guide the action of the motor, or can be used as the basis for generating parameters or signals to guide the action of the motor.

[0078] When the target torque-current mapping relationship is implemented as a two-dimensional table, the robot can use the real-time rotation speed and torque instructions to query the two-dimensional table and determine the queried current value as the conversion current.

[0079] When the target torque-current mapping relationship is implemented as a deep learning model, the robot can read the real-time speed and torque instructions through the deep learning model to perform model reasoning, and at the end of the model reasoning, determine the current value output by the deep learning model as the conversion current.

[0080] It should be noted that the robot can determine the conversion current through its processor. When the processor includes a torque current converter and a motor control circuit, the conversion current determination process, that is, the processing process of this step, can be achieved through the torque current converter.

[0081] It should also be noted that the real-time speed here is the current speed value of the motor, which can be determined by the pulse signal output by the encoder installed on the motor. For example, for an incremental encoder, the speed can be determined by detecting the number of pulses. The torque command received by the joint servo is sent by the upper processing system. The upper processing system of the robot can process the data of the external environment or the data of the interaction with the user through the processing algorithm deployed on it to determine the action to be taken by the robot, thereby determining the corresponding torque command and sending the torque command to the joint servo.

[0082] When determining the current command of the motor, the robot will first use the real-time speed and torque command to determine the conversion current corresponding to the torque command from the target torque-current mapping relationship. The robot can then directly determine the determined conversion current as the current command of the motor, or perform feedforward compensation on the determined conversion current to eliminate the harmonics caused by the conversion current, thereby obtaining the current command of the motor.

[0083] Step 104: determine a first compensation current for eliminating harmonics caused by the conversion current, and use the first compensation current to compensate for the conversion current to obtain a current instruction.

[0084] The robot first determines the current value of the compensation current for eliminating the harmonics caused by the conversion current. In order to distinguish it from the current values ​​of other compensation currents in the following text, the current value of the compensation current for eliminating the harmonics of the conversion current is recorded as the first compensation current, so that the first compensation current is used to eliminate the harmonics caused by the conversion current as a current instruction during execution.

[0085] Since the motor is affected by some non-ideal factors during operation, such as the inconsistency of the motor's three-phase winding, the magnetization of the motor magnet, and the installation of an encoder on the motor and other non-linear factors, the current command for controlling the torque generation will introduce harmonics during execution, that is, when the conversion current is directly used as the current command for execution, harmonics will be introduced, making it impossible for the motor to accurately generate the target torque corresponding to the torque command, which leads to inconsistency in the torque output. Therefore, in order to improve the accuracy of the control of the robot, it is necessary to eliminate the influence of harmonics through the first compensation current.

[0086] In the embodiment of the present application, the robot can determine the current value of the first compensation current by looking up a table. For example, the robot looks up the table with the conversion current as a condition in a two-dimensional table recording the conversion current and the corresponding compensation current, and uses the current value found as the first compensation current.

[0087] The robot may also change the current of the second compensation current determined by the harmonic analysis current of the reference to obtain the first compensation current.

[0088] For more details, see Figure 4 , Figure 4 This is a schematic diagram of the process of the robot control method provided in the embodiment of the present application. Figure 2 In some embodiments of the present application, Figure 3 Determining the first compensation current for eliminating harmonics of the conversion current in step 104 may be achieved by the following process:

[0089] Step 1041: Calculate the proportional relationship between the conversion current and the harmonic analysis current.

[0090] It should be noted that the harmonic analysis current is the current used in the harmonic analysis, that is, the harmonic analysis is performed with the harmonic analysis current as a reference. The robot can use the current value of the conversion current and the current value of the harmonic analysis current to perform proportional calculations, thereby obtaining a proportional relationship between the conversion current and the harmonic analysis current.

[0091] Step 1042: Determine the first compensation current according to the proportional relationship and the second compensation current corresponding to the harmonic analysis current.

[0092] The robot adjusts the amplitude of the second compensation current according to the proportional relationship, for example, reducing or increasing the amplitude thereof, while other parameters in the second compensation current, such as phase and direction, are not changed, and the adjusted second compensation current is determined as the first compensation current. The determination process of the second compensation current will be described below.

[0093] For example, if the harmonic analysis current is I0, the conversion current is It, and the second compensation current is A, then the first compensation current can be written as

[0094] It should be noted that the processing of the embodiment of the present application can be completed by the processor of the robot. When the processor includes a torque current converter and a motor control circuit, the process of determining the first compensation current can be implemented by the torque current converter.

[0095] After obtaining the first compensation current, the robot can implement feedforward compensation for the conversion current by superimposing the first compensation current and the conversion current, thereby obtaining a compensated conversion current from which harmonics have been eliminated as a final current instruction.

[0096] It can be understood that in the embodiment of the present application, after the conversion current is obtained, the conversion current is feed-forward compensated using the corresponding first compensation current to eliminate the negative impact caused by the harmonics brought by the conversion current, thereby eliminating the problem of inconsistent torque output caused by the harmonics, so that the torque actually generated by the joint servo is the same as the target torque corresponding to the torque command, which helps to improve the accuracy of the robot's movement.

[0097] Step 105: Based on the current command, control the motor in the joint servo to generate a target torque, where the target torque is the torque corresponding to the torque command.

[0098] After receiving the current command, the robot will send the current command to the motor driver to control the motor driver to generate the driving current actually input into the motor to drive the rotation of the motor in the joint servo, thereby generating a suitable torque. This torque is the target torque corresponding to the torque command.

[0099] It should be noted that the robot can complete the processing of this step through its processor. When the processor includes a torque current converter and a motor control circuit, the process of controlling the motor in the joint servo to generate the target torque corresponding to the torque command based on the current command can be achieved through the motor control circuit.

[0100] In more detail, when the motor control circuit includes a current closed-loop controller, a space vector pulse width modulator, and a motor driver, the error between the current command and the actual current value of the motor can be calculated first, and then the error is processed by the current closed-loop controller to generate a signal for controlling the motor. The signal is input into the SVPWM to generate a PWM signal for controlling the inverter in the motor driver. The inverter in the motor driver generates current according to the PWM signal, and the current is input into the motor to control the motor to generate a target torque specified by the torque.

[0101] At this point, the control of the robot can be completed.

[0102] It can be understood that compared with the related art, due to the inability to install torque sensors on some robots and the inconsistent torque caused by the influence of nonlinear factors, the robot's movement accuracy is low. In the embodiment of the present application, the energy conversion state of the motor is determined based on the rotation direction and current direction of the motor in the joint servo, and then the most appropriate target torque-current mapping relationship is determined for the motor based on the energy conversion state of the motor. According to the determined target torque-current mapping relationship and the real-time speed of the motor, the torque command sent by the upper processing system is converted to obtain a conversion current, and a first compensation current is determined. The conversion current is compensated by the first compensation current to eliminate the harmonics brought by the conversion current, and a current command is obtained. Finally, the torque generation of the motor is controlled based on the obtained current command. In this way, torque-to-current conversion can be achieved based on the mapping relationship between torque and current, without the need to install a torque sensor on the robot, so that a variety of torque control modes of the robot can be realized. At the same time, the influence of harmonics can be eliminated, and current instructions that can accurately control the output torque of the motor can be obtained, thereby ensuring the consistency of torque output, improving the accuracy of torque control, and ultimately improving the accuracy of the robot's movements.

[0103] In some embodiments of the present application, Figure 4 Before step 1041 in the method, before calculating the proportional relationship between the conversion current and the harmonic analysis current, the method further includes the following processing: determining a second compensation current for the harmonic analysis current.

[0104] That is to say, before calculating the proportional relationship between the conversion current and the harmonic analysis current and determining the first compensation current in combination with the calculated proportional relationship and the second compensation current, the second compensation current needs to be determined first. At this time, the torque output harmonic of the joint servo can be detected under the harmonic analysis current, and the corresponding second compensation current can be determined based on the harmonic.

[0105] In some embodiments of the present application, the second compensation current is determined for the harmonic analysis current, which can be achieved by the following processing: when the joint servo uses the harmonic analysis current as the current command, the joint servo is subjected to N-order torque tests to obtain N groups of torque data; harmonic analysis is performed on the N groups of torque data to obtain the phase, amplitude and direction of the M-order harmonic; the second compensation current is determined according to the phase, amplitude and direction of the M-order harmonic. Wherein, N is an integer, N≥2, and M is a positive integer.

[0106] In the embodiment of the present application, the joint servo is installed on a torque test bench, or a torque tester is connected to the joint servo to achieve the test of the torque output by the joint servo. When testing the torque output by the joint servo, N magnetic pole angles can be selected as test angles, the joint servo is rotated to the positions of the selected N magnetic pole angles in sequence, and then the joint servo is blocked. Afterwards, the harmonic analysis current is used as a current command to control the output torque of the joint servo, and at the same time, the actual torque output by the joint servo is measured by the torque test bench or the torque tester, so that N groups of torque data can be obtained.

[0107] Afterwards, the obtained N groups of torque data can be subjected to harmonic analysis through Fast Fourier Transformation (FFT) to obtain Mth harmonics. Here, Mth harmonics can refer to all harmonics obtained through FFT, or can refer to harmonics selected from all harmonics that have a greater impact on the inconsistency of torque output (for example, causing the torque output gap to be greater than a threshold). Then, using the phase, amplitude and direction of the Mth harmonic, a harmonic current can be determined, and then the negative value of the harmonic current can be taken to obtain the second compensation current.

[0108] After the above operation, the phase of the obtained second compensation current is complementary to the phase of the Mth harmonic, the amplitude is the same as the amplitude of the Mth harmonic, and the direction is opposite to the direction of the Mth harmonic. Therefore, the determined Mth harmonic can be eliminated through the second compensation current, providing a basis for the determination process of the first compensation current in subsequent processing.

[0109] The following is an explanation of an exemplary application of the embodiments of the present application in a practical application scenario.

[0110] The embodiment of the present application is implemented in the scenario of controlling a humanoid robot, on which a joint servo is provided. More specifically, the embodiment of the present application controls the torque output of the joint servo provided on the humanoid robot so that the joint servo can output the target torque specified by the upper processing system of the robot through the torque instruction.

[0111] In the embodiment of the present application, the current instruction corresponding to the torque instruction is directly calculated by directly converting the torque into current, and the joint servo is controlled by the current instruction to output the target torque.

[0112] Figure 5 The system framework of the torque control of the joint servo provided in the embodiment of the present application Figure 1 . See Figure 5The system includes: a torque current converter 5-1, a current closed-loop controller 5-2, a space vector pulse width modulation 5-3, a permanent magnet synchronous motor, referred to as a motor 5-4, and a current sensor 5-5. The input of the torque current converter 5-1 is the torque instruction 5-6 sent by the upper processing system, as well as the rotation direction of the permanent magnet synchronous motor, the motor speed (called the real-time speed), and the current flow direction of the torque current (called the current direction). The torque instruction 5-6 is converted into a current instruction 5-7, and then the difference between the current instruction 5-7 and the real-time current of the permanent magnet synchronous motor 5-4 obtained by the current sensor 5-5 is calculated, and the difference is input into the current closed-loop controller 5-2, and the output of the current closed-loop controller 5-2 is used as the input of the space vector pulse width modulation 5-3, and then the output of the space vector pulse width modulation 5-3 is transmitted to the motor driver (not shown in the figure) to drive the permanent magnet synchronous motor 5-4 to generate the target torque through the motor driver.

[0113] In the embodiment of the present application, the joint servo has two torque-current correspondence diagrams (called torque-current mapping relationships), namely, a discharge torque-current diagram (called a discharge torque-current mapping relationship) and a power generation torque-current diagram (called a power generation torque-current mapping relationship). The torque-current converter first needs to select a target diagram (called a target torque-current mapping relationship) from these two diagrams to perform torque-current conversion.

[0114] Figure 6 Schematic diagram of the torque current conversion process provided by the embodiment of the present application. Figure 6 , when the target chart selection process begins, the torque current converter will first determine whether the motor is in the discharge state 6-1 or the power generation state 6-2 according to the relationship between the torque current Iq and 0 (the relationship between Iq and 0 represents the current direction) and the relationship between the motor speed Sp and 0 (the relationship between Sp and 0 represents the rotation direction). If Sp>0 and Iq>0 (called the discharge condition), or Sp<0 and Iq<0 (called the discharge condition), the motor is in the discharge state 6-1. At this time, the torque current converter will query the discharge torque current table 6-3 according to the real-time speed and the given torque to determine the current instruction; if Sp>0 and Iq<0 (called the power generation condition), or Sp<0 and Iq>0 (called the power generation condition), the motor is in the power generation state 6-2. At this time, the torque current converter will query the power generation torque current table 6-4 according to the real-time speed and the given torque to determine the current instruction. At this point, the torque current conversion is completed, and the current instruction is obtained, so that the current closed-loop control can be directly performed.

[0115] Due to the inconsistency of the three-phase winding of the motor, the magnetization of the motor magnet, and the influence of nonlinear factors caused by the installation of the motor end encoder, although the current command is the same, the output torque of the motor has a certain deviation at different magnetic pole angles. In this regard, in the embodiment of the present application, the motor output torque at different angles can be tested, and then the test data can be FFT analyzed to detect the torque output harmonics, and then feedforward compensation can be performed at the current control end to improve the inconsistency of the torque output. The torque test process is as follows:

[0116] 1. Install the joint servo on the torque test bench;

[0117] 2. Rotate the joint servo to the position where the magnetic pole angle is 0°, and then block the joint servo;

[0118] 3. For the fixed current command I0 (called harmonic analysis current), the actual torque (called torque data) output by the joint servo is tested by the torque tester on the torque test bench;

[0119] 4. Rotate the joint servo to the position where the magnetic pole angle is 10°, and then block the joint servo;

[0120] 5. For a fixed current command I0, the actual torque output by the joint servo is tested by the torque tester on the torque test bench;

[0121] Repeat the above operation, test a set of data every 10°, and finally obtain 36 sets of actual torque (called N sets of torque data). Perform FFT analysis on these 36 sets of actual torque to obtain the 6th harmonic (Mth harmonic, the reason for obtaining the 6th harmonic here is that the influence of higher harmonics is very small and can be ignored). The current formed based on the 6th harmonic can be written as formula (1):

[0122] A0+A1*COS(θ+θ1)+A2*COS(2*θ+θ2)+A3*COS(3*θ+θ3)+A4

[0123] *COS(4*θ+θ4)+A5*COS(5*θ+θ5)+A6

[0124] *COS(6*θ+θ6)(1)

[0125] Among them, θ is the motor pole angle, θ1 is the 1st harmonic phase angle, θ2 is the 2nd harmonic phase angle, θ3 is the 3rd harmonic phase angle, θ4 is the 4th harmonic phase angle, θ5 is the 5th harmonic phase angle, and θ6 is the 6th harmonic phase angle; A0 is the 0th harmonic amplitude, A1 is the 1st harmonic amplitude, A2 is the 2nd harmonic amplitude, A3 is the 3rd harmonic amplitude, A4 is the 4th harmonic amplitude, A5 is the 5th harmonic amplitude, and A6 is the 6th harmonic amplitude.

[0126] After obtaining the amplitude and phase values ​​of the six harmonics, we can use Figure 7 Based on Figure 5 , see Figure 7 , Figure 7 The system framework of the torque control of the joint servo provided in the embodiment of the present application Figure 2 After the torque current conversion 5-1 generates the current conversion value 7-1 (called the conversion current) according to the torque command 5-6, the determined compensation current Ica (called the second compensation current) is used to perform harmonic feedforward compensation 7-2, and the current after compensation is used as the current command 7-3 for subsequent processing. Among them, the compensation current Ica can be obtained by formula (2):

[0127]

[0128] Among them, It represents the torque current conversion value, and I0 represents the current command given during the FFT test.

[0129] Through Ica, the inconsistency of torque output caused by nonlinear factors such as motors and encoders can be compensated, the accuracy of torque control can be improved, and thus the control accuracy of the humanoid robot can be improved.

[0130] Based on the robot control method described in the above embodiment, an embodiment of the present application provides a robot control device, which can be a device in the robot and can be implemented in hardware. Figure 8 is a schematic diagram of the structure of the control device of the robot provided in the embodiment of the present application, see Figure 8 In the robot control device 100, it may include: a torque current converter 101 and a motor control circuit 102. These devices or currents may be arbitrarily combined or further separated according to the functions to be implemented.

[0131] The torque current converter 101 is used to determine the energy conversion state of the motor according to the rotation direction and current direction of the motor in the joint servo; based on the energy conversion state, determine the target torque current mapping relationship from multiple torque current mapping relationships; determine the conversion current from the target torque current mapping relationship according to the real-time rotation speed of the motor and the torque command received by the joint servo; wherein the torque command is sent by the upper processing system; determine a first compensation current for eliminating the harmonics caused by the conversion current, and use the first compensation current to compensate the conversion current to obtain a current command;

[0132] The motor control circuit 102 is used to control the motor in the joint servo to generate a target torque based on the current command, where the target torque is the torque corresponding to the torque command.

[0133] In the above scheme, the torque current converter 101 is also used to calculate the proportional relationship between the conversion current and the harmonic analysis current; wherein the harmonic analysis current is the current used in harmonic analysis; and the first compensation current is determined based on the proportional relationship and the second compensation current corresponding to the harmonic analysis current.

[0134] In the above scheme, Figure 8 The control device 100 of the robot may further include: a harmonic analysis circuit 103, which is used to determine the second compensation current based on the harmonic analysis current.

[0135] In the above scheme, the harmonic analysis circuit 103 is also used to perform N-th torque test on the joint servo when the joint servo uses the harmonic analysis current as the current command, so as to obtain N groups of torque data; wherein N is an integer, and N≥2; perform harmonic analysis on the N groups of the torque data to obtain the phase, amplitude and direction of the M-th harmonic; wherein M is a positive integer; determine the second compensation current based on the phase, amplitude and direction of the M-th harmonic; wherein the phase of the second compensation current is complementary to the phase of the M-th harmonic, the amplitude is the same as the amplitude of the M-th harmonic, and the direction is opposite to the direction of the M-th harmonic.

[0136] In the above scheme, the torque-to-current converter 101 is also used to determine the energy conversion state as a discharge state when the rotation direction and the current direction of the motor in the articulated servo meet the discharge condition; and to determine the energy conversion state as a power generation state when the rotation direction and the current direction of the motor meet the power generation condition.

[0137] In the above scheme, the discharge condition includes: the rotation direction is positive and the current direction is positive, or the rotation direction is negative and the current direction is negative; the power generation condition includes: the rotation direction is positive and the current direction is negative, or the rotation direction is negative and the current direction is positive.

[0138] In the above scheme, the torque current converter 101 is also used to determine the discharge torque current mapping relationship in the multiple torque current calibration models as the target torque current mapping relationship when the energy conversion state includes the discharge state; and to determine the power generation torque current mapping relationship in the multiple torque current mapping relationships as the target torque current mapping relationship when the energy conversion state includes the power generation state.

[0139] It should be noted that the description of the device of the embodiment of the present application is similar to the description of the above method embodiment, and has similar beneficial effects as the method embodiment, so it is not repeated. For technical details not disclosed in the embodiment of the device, please refer to the description of the method embodiment of the present application for understanding.

[0140] The present application embodiment provides a robot, Fig. 9 Schematic diagram of the structure of the robot provided in the embodiment of the present application. Fig. 9 As shown, the robot 200 includes: at least one processor 201 ( Fig. 9 Only one is shown), a memory 202, and executable instructions 203 stored in the memory 202 and allowed on at least one processor 201, when the processor 201 executes the executable instructions 203, the steps in the embodiments of any of the above-mentioned robot control methods are implemented.

[0141] The robot may include but is not limited to a processor 201 and a memory 202. It will be appreciated by those skilled in the art that Fig. 9 This is merely an example of the robot 200 and does not constitute a limitation of the robot 200 , which may include more or fewer components than those shown in the figure, or a combination of certain components, or different components, for example, may also include input and output devices, network access devices, etc.

[0142] The processor 201 may include: a torque current converter and a motor control circuit. The torque current conversion circuit is used to determine the energy conversion state of the motor according to the rotation direction and current direction of the motor in the joint servo; based on the energy conversion state, determine the target torque current mapping relationship from multiple torque current mapping relationships, and determine the conversion current from the target torque current mapping relationship according to the real-time speed of the motor and the torque command received by the joint servo; determine the first compensation current for eliminating the harmonics caused by the conversion current, and use the first compensation current to supplement the conversion current to obtain the current command of the motor; and the motor control circuit is used to control the motor in the joint servo of the robot based on the drive current to generate the target torque, that is, the torque corresponding to the torque command.

[0143] The torque current converter can be implemented as a general processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPG) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. The general processor can be a microprocessor or the processor can also be any conventional processor, etc. The motor control circuit can be formed by connecting a general processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPG) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc.

[0144] In some embodiments, the memory 202 may be an internal storage unit of the robot 200, such as a hard disk or memory of the robot 200. In other embodiments, the memory 202 may also be an external storage device of the robot 200, such as a plug-in hard disk, a smart memory card (SMC, Smart Media Card), a secure digital (SD, Secure Digital) card, a flash card, etc. equipped on the robot 200. Further, the memory 202 may also include both an internal storage unit of the robot 200 and an external storage device. The memory 202 is used to store an operating system, an application program, a boot loader (BootLoader), data, and other programs, such as program codes of computer programs, etc. The memory 202 may also be used to temporarily store data that has been output or is to be output.

[0145] The present application embodiment provides a computer-readable storage medium in which computer-executable instructions are stored. When the computer-executable instructions are executed by a processor, the processor will be caused to execute the robot control method provided by the present application embodiment, for example, Figure 2 The robot control method is shown.

[0146] The embodiment of the present application provides a computer program product, which includes computer executable instructions, and the computer executable instructions are stored in a computer readable storage medium. The processor of the electronic device reads the computer executable instructions from the computer readable storage medium, and the processor executes the computer executable instructions, so that the electronic device executes the robot control method described in the embodiment of the present application.

[0147] In some embodiments, the computer-readable storage medium may be a memory such as RAM, ROM, flash memory, magnetic surface memory, optical disk, or CD-ROM; or may be various devices including one or any combination of the above memories.

[0148] In some embodiments, computer executable instructions may be in the form of a program, software, software module, script or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a stand-alone program or as a module, component, subroutine or other unit suitable for use in a computing environment.

[0149] As an example, computer-executable instructions may, but need not, correspond to a file in a file system, may be stored as part of a file that stores other programs or data, such as in one or more scripts in a HyperText Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple coordinated files (e.g., files storing one or more modules, subroutines, or code portions).

[0150] As an example, computer executable instructions may be deployed to be executed on one electronic device, or on multiple electronic devices located at one site, or on multiple electronic devices distributed at multiple sites and interconnected by a communication network.

[0151] The above is only an embodiment of the present application and is not intended to limit the protection scope of the present application. Any modifications, equivalent substitutions and improvements made within the spirit and scope of the present application are included in the protection scope of the present application.

Claims

1. A robot control method, characterized in that: The robot includes a joint servo, and the method includes: Determining the energy conversion state of the motor according to the rotation direction and current direction of the motor in the joint servo; Based on the energy conversion state, determining a target torque-current mapping relationship from a plurality of torque-current mapping relationships; According to the real-time speed of the motor and the torque command received by the joint servo, the conversion current is determined from the target torque-current mapping relationship; wherein the torque command is sent by the upper processing system; Determine a first compensation current for eliminating harmonics caused by the conversion current, and use the first compensation current to compensate the conversion current to obtain a current instruction; Based on the current command, the motor in the joint steering gear is controlled to generate a target torque, where the target torque is the torque corresponding to the torque command.

2. The method according to claim 1, characterized in that The determining of a first compensation current for eliminating harmonics caused by the conversion current includes: Calculate the proportional relationship between the conversion current and the harmonic analysis current; wherein the harmonic analysis current is the current used in harmonic analysis; The first compensation current is determined according to the proportional relationship and the second compensation current corresponding to the harmonic analysis current.

3. The method according to claim 2, characterized in that Before calculating the proportional relationship between the conversion current and the harmonic analysis current, the method further includes: The second compensation current is determined based on the harmonic analysis current.

4. The method according to claim 3, characterized in that The determining the second compensation current with respect to the harmonic analysis current includes: When the joint servo uses the harmonic analysis current as the current command, N torque tests are performed on the joint servo to obtain N groups of torque data; wherein N is an integer, and N≥2; Performing harmonic analysis on the N groups of torque data to obtain the phase, amplitude and direction of the Mth harmonic; wherein M is a positive integer; Determining the second compensation current according to the phase, amplitude and direction of the Mth harmonic; The phase of the second compensation current is complementary to the phase of the Mth harmonic, the amplitude is the same as the amplitude of the Mth harmonic, and the direction is opposite to the direction of the Mth harmonic.

5. The method according to any one of claims 1 to 4, characterized in that: The step of determining the energy conversion state of the motor according to the rotation direction and current direction of the motor in the joint servo includes: When the rotation direction and the current direction of the motor in the articulated servo satisfy a discharge condition, determining the energy conversion state as a discharge state; When the rotation direction and the current direction of the motor meet a power generation condition, the energy conversion state is determined as a power generation state.

6. The method according to claim 5, characterized in that The discharge condition includes: the rotation direction is positive and the current direction is positive, or the rotation direction is negative and the current direction is negative; The power generation condition includes: the rotation direction is positive and the current direction is negative, or the rotation direction is negative and the current direction is positive.

7. The method according to any one of claims 1 to 4, characterized in that: The step of determining a target torque-current mapping relationship from a plurality of torque-current mapping relationships based on the energy conversion state includes: When the energy conversion state includes a discharge state, determining a discharge torque-current mapping relationship among the plurality of torque-current mapping relationships as the target torque-current mapping relationship; When the energy conversion state includes a power generation state, the power generation torque-current mapping relationship in the plurality of torque-current calibration models is determined as the target torque-current mapping relationship.

8. A robot control device, characterized in that: The device comprises: A torque current converter is used to determine the energy conversion state of the motor according to the rotation direction and current direction of the motor in the joint servo; based on the energy conversion state, determine a target torque current mapping relationship from a plurality of torque current mapping relationships; determine a conversion current from the target torque current mapping relationship according to the real-time rotation speed of the motor and the torque command received by the joint servo; wherein the torque command is sent by an upper processing system; determine a first compensation current for eliminating harmonics caused by the conversion current, and use the first compensation current to compensate the conversion current to obtain a current command; The motor control circuit is used to control the motor in the joint servo to generate a target torque based on the current command, and the target torque is the torque corresponding to the torque command.

9. A robot, characterized in that: The robot comprises: A memory for storing computer executable instructions or computer programs; A processor, configured to implement the method according to any one of claims 1 to 7 when executing computer executable instructions or computer programs stored in the memory.

10. A computer-readable storage medium storing computer-executable instructions or a computer program, characterized in that: When the computer executable instructions or computer programs are executed by a processor, the method according to any one of claims 1 to 7 is implemented.

11. A computer program product comprising computer executable instructions or a computer program, characterized in that: When the computer executable instructions or computer programs are executed by a processor, the method according to any one of claims 1 to 7 is implemented.

Citation Information

Cited By

  • Intelligent servo electric screwdriver torsion compensation control processing method, system and platform

    CN120065876A