Method for constructing a robot controller and robot

The robot's linear balance parameter matrix is ​​updated through adaptive dynamic programming and strategy iteration methods, which solves the problem of difficult determination of the wheel-legged robot's dynamic characteristics and achieves balance control and optimized travel effects under changes in dynamic parameters.

CN116736749BActive Publication Date: 2024-09-17TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210194306.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-01
Publication Date
2024-09-17
Estimated Expiration
2042-03-01

AI Technical Summary

Technical Problem

It is difficult to accurately obtain and update the dynamic model parameters of the robot with existing technology, making it difficult for under-actuated robots to maintain balance during motion control. Especially for wheel-legged robots, their complex mechanical structures make it difficult to determine the dynamic characteristics.

Method used

Adaptive dynamic programming and strategy iteration methods are used to dynamically update the linear balance parameter matrix of the robot by acquiring motion state data and control data to build a better controller to adapt to changes in dynamic parameters and ensure that the robot moves along the target in a balanced state. Track travel.

Benefits of technology

It realizes the dynamic iteration of the controller when the dynamic parameters change, ensuring that the robot travels with optimal control effect in a balanced state, simplifying the controller design process and reducing the amount of calculation and data requirements.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116736749B
    Figure CN116736749B
Patent Text Reader

Abstract

Disclosed are a method for constructing a controller of a robot, a robot, a non-transitory computer-readable medium, and a method for controlling a robot, the method comprising: controlling the robot motion by using a first controller, and obtaining motion state data and control data during the motion process; updating the linear balance parameter matrix of the first controller by using a policy iteration method according to the motion state data and the control data; and constructing a second controller corresponding to the dynamic characteristics of the robot based on the updated linear balance parameter matrix. The present disclosure can adaptively obtain a controller that can flexibly control the robot.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the fields of artificial intelligence and robots, and more particularly to a method for constructing a robot controller, a robot, a non-transitory computer-readable medium, and a method for controlling a robot. Background Art

[0002] With the widespread application of artificial intelligence and robotics technology in civil and commercial fields, robots based on artificial intelligence and robotics technology are playing an increasingly important role in smart transportation, smart home and other fields, and are also facing higher requirements.

[0003] When currently controlling the motion of a robot, especially an underactuated robot, it is usually necessary to design a dynamic model that accurately corresponds to the mechanical structure of the robot, and then determine the control force at each joint of the robot based on the changes in the dynamic model during movement to ensure the balance of the robot during movement. However, due to the complex mechanical structure of the robot, especially some wheel-legged robots, it is difficult to derive an accurate dynamic model even if the mechanical structure of the robot is known. In addition, even if the dynamic model is known, it is difficult to accurately identify the parameters in the dynamic model in some cases. If the parameters of the dynamic model are known but inaccurate, the controller effect of the robot will also be unsatisfactory. For this reason, it is necessary to propose a solution that can flexibly control the robot. Summary of the invention

[0004] In view of the above problems, the present disclosure provides a method for constructing a controller of a robot, a robot, a non-transitory computer-readable medium, and a method for controlling a robot. A controller capable of flexibly controlling the robot can be adaptively obtained.

[0005] On the one hand, the present disclosure provides a method for constructing a controller for a robot, the method comprising: using a first controller to control the movement of the robot, and obtaining motion state data and control data during the movement; updating the linear balance parameter matrix of the first controller using a strategy iteration method according to the motion state data and the control data; and constructing a second controller corresponding to the dynamic characteristics of the robot based on the updated linear balance parameter matrix.

[0006] For example, the linear balance parameter matrix of the first controller is a stable control gain matrix.

[0007] For example, the dynamic characteristics of the robot are associated with at least one variable parameter, and the first controller corresponds to the dynamic characteristics when the variable parameter is a first value; the second controller corresponds to the dynamic characteristics when the variable parameter is a second value.

[0008] For example, the first controller controls the robot to move in a quasi-balanced motion state, and the robot in the quasi-balanced state is near a balance point during the motion. The robot controlled by the second controller has a better control effect during the motion than the robot controlled by the first controller.

[0009] For example, the first controller and the second controller are linear controllers, and at each moment in the motion process, the control torque provided by the controller is negatively correlated to the product of the linear balance parameter matrix and the motion state data of the robot.

[0010] For example, the method of controlling the movement of the robot using the first controller and acquiring the motion state data and control data during the movement also includes: the first controller determining an initial control instruction according to the current motion state of the robot; applying a disturbance to the control data indicated by the initial control instruction to acquire the control data of the first controller; and controlling the movement of the robot according to the control data of the first controller and acquiring the motion state data during the movement.

[0011] For example, the motion state data and the control data correspond to multiple time intervals, and the linear balance parameter matrix of the first controller is updated by using a policy iteration method based on the motion state data and the control data, and also includes: nonlinearly combining the motion state data and the control data corresponding to the multiple time intervals to determine a training data set, and determining an iterative relationship function based on the training data set; and performing multiple policy iterations on the iterative target item according to the iterative relationship function to approximate the linear balance parameter matrix corresponding to the dynamic characteristics of the robot.

[0012] For example, according to the iterative relationship function, multiple policy iterations are performed on the iterative target item to approximate a linear balance parameter matrix corresponding to the dynamic characteristics of the robot, including: in each policy iteration, determining whether the iterative target item converges, and stopping the policy iteration in response to determining that the iterative target item converges; and updating the linear balance parameter matrix according to the converged iterative target item.

[0013] For example, the iterative relationship function conforms to the form of the Lyapunov equation, the iterative target item includes the linear balance parameter matrix to be iterated, and the solution of the Lyapunov equation with the linear balance parameter matrix to be iterated as parameters, and the iterative relationship function indicates: according to the linear balance parameter matrix in this policy iteration and the solution of the Lyapunov equation corresponding to this policy iteration, calculate the linear balance parameter matrix corresponding to the next policy iteration.

[0014] For example, the convergence of the iteration target item includes: the difference between the solutions of the Lyapunov equation corresponding to two adjacent strategy iterations is less than a preset value.

[0015] For example, the robot includes: a wheel leg part including multiple joints, a base part connected to the wheel leg part, and a driving motor for controlling a driving wheel in the wheel leg part; the motion data includes: the pitch angle of the base part, the pitch angular velocity of the base part, and the linear velocity of the driving wheel corresponding to multiple time intervals; and the control data includes: the output torque of the driving motor corresponding to multiple time intervals.

[0016] On the other hand, the present disclosure provides a robot, comprising: a data acquisition device, configured to: obtain motion state data of the robot when a first controller controls the movement of the robot; a data processing device, configured to: obtain control data corresponding to the motion state data; based on the motion state data and the control data, update the linear balance parameter matrix of the first controller using a strategy iteration method; and based on the updated linear balance parameter matrix, construct a second controller corresponding to the dynamic characteristics of the robot.

[0017] For example, the robot further includes: a wheel leg portion including a plurality of joints; a base portion connected to the wheel leg portion; and a driving motor disposed on the robot to control the driving wheel in the wheel leg portion based on the controller.

[0018] In yet another aspect, the present disclosure provides a non-transitory computer-readable medium having at least one instruction stored thereon, the instruction set being loaded and executed by a processor to implement at least one of the methods of claims 1 to 111.

[0019] On the other hand, the present disclosure provides a method for controlling a robot, wherein the robot is driven by a driving wheel, the method comprising: receiving a motion instruction, wherein the motion instruction indicates the motion trajectory of the robot; controlling the driving force of the driving wheel according to the motion instruction, so that the robot moves under the control of a first controller and obtains motion state data and control data during the movement; based on the motion state data and the control data, constructing a second controller corresponding to the dynamic characteristics of the robot using a strategy iteration method; and using the second controller to control the driving force of the driving wheel so that the robot moves smoothly.

[0020] The embodiments of the present disclosure optionally combine the optimal control technology and propose a strategy iteration method based on adaptive dynamic programming. The strategy iteration method based on adaptive dynamic programming can dynamically iterate the linear equilibrium parameter matrix in the controller to obtain a controller corresponding to the dynamic characteristics of the robot after the parameter changes when the dynamic parameters of the robot change. Even if the dynamic parameters of the robot change, the controller can enable the robot to move along the target trajectory with the optimal control effect in a balanced state. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work. The following drawings are not deliberately scaled according to the actual size, and the focus is on illustrating the main purpose of the present invention.

[0022] Figure 1 A schematic structural diagram of a robot having a left wheel leg portion and a right wheel leg portion of a single-wheel leg configuration according to an embodiment of the present disclosure is shown.

[0023] Figure 2 An exemplary flow chart of a method for constructing a controller of a robot according to an embodiment of the present disclosure is shown.

[0024] Figure 3 A labeled schematic diagram corresponding to a robot according to a disclosed embodiment is shown.

[0025] Figure 4 A control architecture diagram corresponding to the robot according to the disclosed embodiment is shown.

[0026] Figure 5A An exemplary flow chart of a method for constructing a controller of a robot according to an embodiment of the present disclosure is shown.

[0027] Figure 5B Another exemplary flowchart of a method for constructing a controller of a robot according to an embodiment of the present disclosure is shown.

[0028] Figure 6 Another structural view of the robot according to the embodiment of the present disclosure is shown.

[0029] Fig. 7A The motion state data and control data of the robot in the process of controlling the motion of the robot by the first controller according to the embodiment of the present disclosure are shown.

[0030] Figure 7BThe convergence process of the linear balance parameter matrix in the process of constructing the second controller according to an embodiment of the present disclosure is shown, wherein the base heights of the robot are 0.5 meters and 0.6 meters respectively.

[0031] Figure 7C The motion state data of the robot according to the embodiment of the present disclosure is shown, in which the robot is controlled by the first controller and the second controller to walk in a straight line when the base height is 0.6 meters.

[0032] Figure 8 An exemplary flow chart of a method for constructing a controller of a robot according to an embodiment of the present disclosure is shown.

[0033] Fig. 9 An exemplary schematic diagram of a method for constructing a controller of a robot according to an embodiment of the present disclosure is shown.

[0034] Fig.10 A schematic diagram of the process of collecting motion state data and control data of a robot according to an embodiment of the present disclosure is shown.

[0035] Fig.11 A graph showing motion state data and control data of a robot collected according to an embodiment of the present disclosure is shown.

[0036] Fig.12 A schematic diagram of the iteration of the linear balance parameter matrix in the process of collecting the robot according to an embodiment of the present disclosure is shown.

[0037] Fig.13 An experimental schematic diagram of a controller of a test robot according to an embodiment of the present disclosure is shown.

[0038] Fig.14 A graph showing experimental data of a controller of a test robot according to an embodiment of the present disclosure is shown. DETAILED DESCRIPTION

[0039] The technical solutions in the embodiments of the present invention will be described clearly and completely below in conjunction with the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work also fall within the scope of protection of the present invention.

[0040] As shown in the present disclosure and claims, unless the context clearly indicates an exception, the words "a", "an", "an" and / or "the" do not refer to the singular and may also include the plural. Generally speaking, the terms "include" and "comprise" only indicate the inclusion of the steps and elements that have been clearly identified, and these steps and elements do not constitute an exclusive list. The method or device may also include other steps or elements.

[0041] Although the present disclosure makes various references to certain modules in the system according to embodiments of the present disclosure, any number of different modules can be used and run on a user terminal and / or server. The modules are illustrative only, and different aspects of the systems and methods can use different modules.

[0042] Flowcharts are used in this disclosure to illustrate the operations performed by the system according to the embodiments of the present disclosure. It should be understood that the preceding or following operations are not necessarily performed precisely in order. On the contrary, various steps may be processed in reverse order or simultaneously as required. At the same time, other operations may also be added to these processes, or one or more operations may be removed from these processes.

[0043] Artificial Intelligence (AI) is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce a new intelligent machine that can respond in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines so that machines have the functions of perception, reasoning and decision-making.

[0044] The disclosed technical solution mainly relates to the robot technology in artificial intelligence technology, mainly to the intelligent control of robots. Robots are mechanical and electronic devices that can imitate certain human skills by combining mechanical transmission and modern microelectronics technology. Robots are developed on the basis of electronic, mechanical and information technology. Robots do not necessarily have to look like humans. As long as they can independently complete the tasks and commands assigned to them by humans, they belong to the large family of robots. A robot is an automated machine that has some intelligent abilities similar to those of humans or organisms, such as perception, planning, movement and coordination. It is an automated machine with high flexibility. With the development of computer technology and artificial intelligence technology, robots have been greatly improved in terms of function and technical level. Mobile robots and robot vision and touch technologies are typical representatives.

[0045] The present disclosure relates to an application of artificial intelligence in robot control. Specifically, the present disclosure proposes a method for constructing a robot controller based on artificial intelligence, wherein the solution adds the use of an arbitrary controller to be optimized to construct a controller corresponding to the dynamic characteristics of the robot. The robot under the control of the controller corresponding to the dynamic characteristics of the robot has a motion state closer to a balance point than the robot under the control of the arbitrary controller to be optimized.

[0046] The robot involved in the present disclosure may be an underactuated robot, for example, Figure 1 The wheel-legged robot shown. Specifically, Figure 1 A schematic structural diagram of a robot having a left wheel leg portion and a right wheel leg portion of a single-wheel leg configuration according to an embodiment of the present disclosure is shown.

[0047] like Figure 1 As shown, it exemplarily shows a structural schematic diagram of a robot 100. The wheel-legged robot 100 may include: a base portion 101, a wheel-leg portion 103, and a driving wheel 104 (also called a foot) in the wheel-leg portion 103. The base portion 101 refers to the main part of the robot, for example, it may be the torso of the robot, and the base portion may be, for example, a flat plate-shaped component or a rectangular parallelepiped component connected to the wheel-leg portion of the robot. As an example, one end of the wheel-leg portion 103 is connected to the base portion 101, and the other end is connected to the driving wheel 104. A power output device (for example, a motor) is mounted on the base portion 101, which can be used to drive the joints of the wheel-leg portion 103 to provide electricity. It should be understood that, according to actual needs, the robot may also include, for example, a base portion connected to the wheel-leg portion or an additional component arranged on the base portion. It should be understood that the above only gives an example of the structure of a robot, and the embodiments of the present disclosure are not limited by the specific components of the robot and their connection methods.

[0048] The active wheel 104 in the wheel-legged part 103 can enable the wheel-legged robot 100 to both walk and perform wheeled movements. Optionally, the wheel-legged robot 100 may also include a controllable additional component (e.g., a tail), which can be used to balance the wheel-legged robot or to assist the wheel-legged robot in moving. For example, the tail can assist the wheel-legged robot in maintaining balance during movement. Optionally, the wheel-legged robot may also include a controllable mechanical arm, which can be used to perform operational tasks such as carrying and picking. The wheel-legged robot may include a bipedal wheel-legged robot, a quadrupedal wheel-legged robot, etc., which is not limited in the embodiments of the present disclosure.

[0049] For example, the wheel-legged part 103 is a parallel structure leg (the two legs of the bipedal wheel-legged robot 100 are balanced). Figure 1, the wheel leg part 102 of the robot 100 includes a left wheel leg part and a right wheel leg part, each of which includes a driving wheel and two parallel legs connected to the central axis of the driving wheel and used to realize the motion control of the driving wheel. For example, the left wheel leg part includes a left driving wheel, and a first left wheel leg part and a second left wheel leg part connected in parallel; and the right wheel leg part 112 includes a right driving wheel, and a first right wheel leg part and a second right wheel leg part connected in parallel. Figure 1 As shown, the left wheel leg and the right wheel leg have mirror-symmetrical structures.

[0050] For example, the driving wheel can be a single wheel, two wheels, four wheels or other number of driving wheel configurations, and each driving wheel can be controlled by two legs in parallel or multiple legs in series. It should be understood that the embodiments of the present disclosure are not limited by the specific composition types of the left and right wheel legs and the number of driving wheels. In some embodiments, the left wheel leg and the right wheel leg are both single-wheel leg configurations. The single-wheel leg configuration means that the wheel leg only includes a single driving wheel.

[0051] For example, the left wheel leg and the right wheel leg may include the same number of joints and have the same joint configuration, or, according to actual needs, the left wheel leg and the right wheel leg may have different numbers of joints and different joint configurations. The embodiments of the present disclosure are not limited by the specific number of joints and joint configurations of the left wheel leg and the right wheel leg. Figure 1 Taking the example shown as an example, the left and right wheel legs each contain 5 joints and have a total of 2 rotational degrees of freedom. The change in the center of mass height of the wheel leg / base and the inclination angle of the base can be adjusted by adjusting the joints of the wheel leg 103.

[0052] Compared with the serial structural legs, the parallel structural legs can have stronger rigidity and can withstand the impact that may be caused by complex movements. When in contact with the ground, the active wheel 104 can provide the wheel-legged robot 100 with the ability to slide. Optionally, the bipedal wheel-legged robot 100 can also include an additional component 102, which is connected to the base part 101. A passive wheel 105 can be installed on the additional component 102. The additional component 102 includes 1 degree of freedom of rotation. The movement of the additional component 102 will also affect the changes of the base part 101 and the wheel-leg part 103, for example, driving the base part to have a certain rotation speed. Therefore, the balance and posture of the robot 100 can be adjusted by adjusting the position of the additional component 102.

[0053] The wheel-legged robot 100 has both the flexibility of a wheeled robot and the flexibility of a legged robot, so it can move quickly on flat ground and cross rough roads. Figure 1The wheel-legged robot 100 shown in the figure has only two contact points with the ground. And the wheel-legged robot 100 is a non-minimum phase system, so it is still difficult to balance control the wheel-legged robot 100 in practical applications. In addition, due to the complex mechanical structure of the (wheel-legged) robot, it is difficult to determine the dynamic characteristics of the (wheel-legged) robot. Since the traditional balance control method needs to know the dynamic characteristics of the robot, therefore, in the case of unknown dynamic characteristics, the traditional balance control method is difficult to balance control such a robot.

[0054] The method for constructing a controller of a robot provided by an embodiment of the present disclosure involves designing a controller that enables the robot to maintain balance during motion by using an adaptive dynamic programming method (ADP) and / or a whole-body dynamics method when the dynamic characteristics of the robot are unknown. ADP essentially solves the infinite time domain LQR problem, but the parameters of the system model are completely unknown. Therefore, the well-known algebraic Riccati equation cannot be solved analytically. The embodiments of the present disclosure achieve the solution of the LQR problem through an artificial intelligence solution when the LQR problem cannot be solved based on the system model.

[0055] Optionally, the adaptive dynamic programming method optionally includes two aspects, for example, a data-driven policy iteration (PI) scheme and a data-driven value iteration (VI) scheme.

[0056] For example, the embodiments of the present disclosure optionally combine the optimal control technology to propose a policy iteration method based on adaptive dynamic programming. The policy iteration method based on adaptive dynamic programming can dynamically iterate the controller to obtain a controller corresponding to the dynamic characteristics of the robot after the parameters are changed when the dynamic parameters of the robot are changed / the dynamic characteristics are unknown. The controller enables the robot to move along the target trajectory with the optimal control effect in a balanced state even if the dynamic parameters of the robot change.

[0057] As an example, the numerical iteration method based on adaptive dynamic programming may not require any initial controller, but the amount of data required is relatively large, and it is more suitable for offline iterative controllers. Although the policy iteration method based on adaptive dynamic programming requires an initial controller, the amount of data required is much smaller than the numerical iteration method based on adaptive dynamic programming. Compared with the numerical iteration method based on adaptive dynamic programming, the policy iteration method based on adaptive dynamic programming has a shorter iteration time, making iterative controllers possible.

[0058] The embodiments of the present disclosure are based on artificial intelligence technologies, such as reinforcement learning and ADP technologies, and utilize strategy iteration, numerical iteration, or whole-body dynamics control technologies to solve the optimal balance control problem of at least one joint controller of the robot when the dynamic characteristics of the robot are unknown. The process of constructing a controller in the embodiments of the present disclosure only requires the wheel-legged robot to move for a period of time / a section of trajectory under the control of a non-optimal controller / an arbitrary controller, and collect the motion state data and control data corresponding to the period of time / trajectory as training data. Therefore, the amount of training data in the embodiments of the present disclosure is much smaller than the amount of data required by traditional reinforcement learning algorithms.

[0059] Furthermore, the trained controller of the embodiment of the present disclosure gradually converges to the controller corresponding to the optimal solution of the linear quadratic regulation problem as the learning step increases, thereby ensuring the stability of the closed-loop system, and the training process is greatly simplified, and no additional restrictions are required on the training data, thereby simplifying the design process of the controller of the wheel-legged robot. Furthermore, since the various embodiments of the present disclosure are data collected from real machines, and the control strategies obtained based on these real machine data are directly applied to the robot, there is no need to consider the difference between simulated control and real control, which improves the application effect of the controller on the real robot.

[0060] To facilitate further description of the present disclosure, the meanings of various operators and sets that may be used in the following text are briefly explained here.

[0061] In this disclosure, represents the set of real numbers. |·| represents the Euclidean norm of a vector. stands for Kronecker product. Bold letters represent vectors or matrices. Italic letters represent scalars.

[0062] For any matrix A=[a1,…,a n ], For any symmetric matrix S = [s i,j ],vecs(S)=[s 1,1 ,2s 1,2 ,…,2s 1,n ,s 2,2 ,2s 2,3 ,…,2s n-1,n ,s n,n ] T For any vector

[0063] Figure 2An exemplary flow chart of a method 200 for constructing a controller of a robot 100 according to an embodiment of the present disclosure is shown.

[0064] like Figure 2 As shown, the method 200 according to at least one embodiment of the present disclosure may include steps S201 to S204. Optionally, steps S201 to S204 may be performed online or offline, and the present disclosure is not limited thereto.

[0065] As described above, the method 200 can be optionally applied to any robot including a wheel leg portion, and the wheel leg portion includes a driving wheel and a plurality of joints. Figure 1 The method 200 is further described by taking the robot 100 shown in FIG. 1 as an example. To facilitate the description of various feature quantities involved in the method 200, refer to Figure 3 right Figure 1 The robot 100 in FIG. 1 is further labeled.

[0066] For example, Figure 3 As shown, it can be Figure 1 The complex robot 100 shown in FIG. 1 is labeled in the generalized coordinate system of the robot. Figure 3 In FIG. 1 , the centers P1 and P2 of the driving wheel are shown as two separate points, and those skilled in the art should understand that P1 and P2 are substantially the same point.

[0067] Specifically, in Figure 3 In the {·,·} and τ {·,·} Identify the joints involved in the wheel and leg, where q {·,·} Identify the joint rotation angle, τ {·,·} Identifies the torque of the joint. For example, if q {1,2} Identifies the joint rotation angle between the first link of the left wheel leg of the robot and the base, and τ {1,2} Identify the rotation torque of the joint between the first link of the left wheel leg of the robot and the base. Figure 3 Not shown in the figure, the angle and rotation torque of the tail joint can be set accordingly.

[0068] For any robot with a base, To characterize the generalized coordinates of the robot. Including the base and n j Joint angles against Figure 1 and Figure 3 The robot shown in FIG. 1 can also obtain the generalized coordinate parameter q of the robot in a similar manner, where n j =12,q i Can Figure 3 China {·,·} Any one of the identified joints.

[0069] Based on the generalized coordinate parameter q of the robot, the generalized velocity set of the robot joint can be determined accordingly And the generalized acceleration set Those skilled in the art should understand that and Respectively represent the instantaneous angular velocity and instantaneous angular acceleration of the robot body. Similarly, the joint torque can also be expressed as τ = [τ1, τ2, …, τ8] T To identify.

[0070] Therefore, a general kinetic model can be constructed as shown in the following equation (1).

[0071]

[0072] in, M(q) is used to represent the mass matrix of the robot. Used to represent the robot's gravity, centrifugal, and Coriolis forces. The matrix S is used to select active joints from all joints. If an element in S is 0, it means it is an undriven joint, and if it is not 0, it is an active joint. f is the generalized force provided by the ground at the contact point when the robot contacts the ground. J f is the concatenated contact Jacobian matrix for f. λ is the closed-loop force from the front leg to the rear leg. J λ is the contact Jacob matrix of the series for λ. Here n c is the number of contact points between the driving wheel and the ground. Considering the closed-loop constraint (that is, in a real machine, the joints of the robot should be fixedly connected), n λ is the number of contact points between the open loop links. Figure 1 and Figure 3 The robot shown in c =2 and n λ =2. Specifically, the wheel leg of the robot is a five-bar linkage. The open-loop links of the closed-loop constraint of the five-bar linkage (for example, Figure 3 The number of contact points between points P1 and P2 is 2.

[0073] On the basis of obtaining the robot configuration, we can consider the robot's moving process, set the corresponding control architecture and control tasks for the robot, and describe such control architecture and control tasks through mathematical language. Figure 4 To further describe the above control architecture and control tasks. Figure 4 FIG. 1 shows a control architecture diagram corresponding to a robot according to a disclosed embodiment. Specifically, Figure 3 Take the robot marked in as an example, Figure 4 A plurality of exemplary control tasks for the robot and the associations between these control tasks are shown. The combination and association of these exemplary control tasks are also referred to as the dynamic whole body dynamics control corresponding to the robot.

[0074] For example, first, in step S201, control information for controlling the rotation of the driving wheel may be adaptively determined based on motion information during the motion process of the robot.

[0075] Optionally, the adaptively determining the control information for controlling the active rotation based on the motion information of the robot during the motion process also includes: determining a controller for controlling the rotation of the active wheel in a strategy iteration manner based on the motion information of the robot during the motion process, or determining a controller for controlling the rotation of the active wheel in a strategy iteration manner based on the motion information of the robot during the motion process.

[0076] Later, we will refer to FIG. 5A to FIG. 7C To describe in detail how to determine the controller for controlling the rotation of the driving wheel in a strategy iteration manner, and refer to Figure 8 How to determine the controller for controlling the rotation of the driving wheel in a numerical iteration manner is described in detail. It will not be described in detail here. Figure 4 Another example is also shown, which uses the measured values ​​to estimate the motion state of the robot, and then inputs the estimated state value into a data processing module for adaptively determining the control information for controlling the rotation of the driving wheel, so that the data module can learn the measured values ​​corresponding to each moment more quickly, so as to more efficiently calculate the optimal controller for controlling the rotation of the driving wheel. Of course, the present disclosure is not limited to this.

[0077] Optionally, the control information for controlling the rotation of the driving wheel can be either the acceleration of the driving wheel or the torque of the driving wheel. Although in mathematical terms, there is not much difference between these two physical quantities as the control information for controlling the rotation of the driving wheel, in actual physical systems, not both of these physical quantities can be accurately measured. Therefore, in the experiment, those skilled in the art can select physical quantities with better data test results and more consistent with the model for subsequent calculation and iteration according to specific circumstances.

[0078] In step S202, based on the control information for controlling the rotation of the active wheel, first control information for controlling the plurality of joints is determined so that the robot maintains balance.

[0079] For example, the rotation speed of the driving wheel can not only affect the linear speed of the robot, but also affect the balance of the robot. Figure 1 and Figure 3 For the robot 100 shown in FIG. 1 , if the driving wheel 104 provides too large an acceleration, the robot 100 will soon fall backwards. Therefore, the embodiment of the present disclosure uses the control information of the driving wheel as reference information for controlling each joint, so as to dynamically maintain the balance of the robot by adjusting the configuration of the robot, for example, lowering the center of gravity / raising the center of gravity when the speed of the driving wheel 104 is too fast. Figure 4 The first control information may be the output of the wheel balancing control task described in detail later.

[0080] In step S203, based on the target trajectory, second control information for controlling the plurality of joints is determined so that the robot moves along the target trajectory. If the driving wheel 104 provides too little acceleration, the robot 100 cannot reach the destination quickly, thereby failing to meet the target trajectory requirement that the robot 100 needs to meet. Figure 1 and Figure 3 The robot 100 shown in FIG. 1 can further convert potential energy into kinetic energy by adjusting the posture of the base portion to assist the robot movement.

[0081] Next, in step S204, a control torque for controlling each joint of the plurality of joints may be further determined based on the constraint conditions corresponding to the robot motion, the first control information, and the second control information.

[0082] For example, the dynamic whole-body dynamics control of the robot can be described as controlling each joint of the robot with the goal of minimizing the total input energy to each joint and minimizing the error with the target trajectory while ensuring the balance of the robot. For example, the control of the robot can be expressed as Figure 3The dynamic whole-body dynamics control objective argminz of the robot is annotated in .

[0083]

[0084] Among them, as mentioned above, A vector that is a combination of the accelerations set for each joint for the target trajectory. It is a vector composed of the acceleration of each joint during the motion process. des is a vector composed of the set of torques set for each joint in the target trajectory. τ is a vector composed of the set of torques of each joint in the actual motion process. f is the generalized force provided by the ground at the contact point when the robot is in actual contact with the ground. λ is the closed-loop force applied by the front leg to the back leg of the robot during motion. Subscript W q , W τ , W f , W λ Separately identify τ, f, and λ are weight coefficient matrices that need to be multiplied when calculating the norm of formula (2).

[0085] like Figure 4 As shown, the controller determined by adaptive dynamic programming will be used to control Figure 1 and Figure 3 The driving wheel shown in the figure. The motion state and power state of the driving wheel will provide input reference or input limit to each control task accordingly, thereby changing the posture and balance state of the robot. Correspondingly, in order to prevent the robot from losing balance, Figure 3 The active joints in {1,2} and q {7,8} ) will be on the active wheel (for example, q {5,6} ), undriven joints (e.g., q {3,4} and q {9,10} ) and joint torques (e.g., τ {1,2} and τ {5,6} ) to adjust the robot's posture so that the robot remains balanced.

[0086] like Figure 4As shown, the rotation of the driving wheel under the control of the adaptive dynamic programming controller will provide an input reference Ref to the wheel balancing control task (and / or the wheel travel and rotation control task). The target trajectory will provide an input reference to the wheel movement and rotation control task, the base posture control task, and the tail control task. Although the driving wheel and the target trajectory do not directly provide input references to other control tasks (e.g., torque control tasks and external force control tasks), considering that each control task often needs to control the same robot component (e.g., main wheel, connecting rod assembly, joint hinge, etc.), the control effects of these control tasks are often limited by the driving wheel and the target trajectory.

[0087] Further references Figure 4 ,The movement of the robot is also subject to various constraints, for example, the maximum torque that each joint can provide, ,the limitations of the mechanical configuration, and so on. Figure 4 Four example constraints are given in Figure 1: dynamic constraint, close-loop linkage constraint, nonholonomic constraint, and friction constraint.

[0088] As an example, the dynamic model shown in formula (1) can be used as an example of dynamic constraints to limit the range of energy changes of the robot during movement. Those skilled in the art should understand that the limitations of the dynamic model are not limited to this. For example, in order to facilitate the analysis of the energy changes of the robot, a simplified dynamic model can be established for the robot to simplify the dynamic model limitations corresponding to formula (1) in dynamic whole-body dynamics control.

[0089] As yet another example, formula (3) shows that Figure 3 An example of a closed-loop linkage constraint of a robot in FIG. A person skilled in the art should know that the closed-loop linkage constraint can also be shown in other ways. The present disclosure is not limited thereto.

[0090]

[0091] in, and are the Jacobian matrices corresponding to points P1 and P2 respectively. Subscript J ·,l and J ·,r Identify the left wheel leg and the right wheel leg respectively.

[0092] As another example, assuming that the wheel is in pure rolling and in contact with the ground, and there is no slip and sliding in the radial and axial directions of the wheel, formula (4) shows the Figure 3An example of a nonholonomic constraint of a robot in FIG. A person skilled in the art should know that the nonholonomic constraint can also be shown in other ways. The present disclosure is not limited thereto.

[0093]

[0094] in, are the x-axis and z-axis of the Jacobian matrix of the driving wheel-ground contact point relative to the base.

[0095] continue Figure 4 In the example in , the friction constraint can be set based on the assumption that the friction cone at the contact point between the ground and the robot during actual motion is approximated as a pyramid-shaped friction cone. The contact force f corresponding to each contact point i In the local coordinate system, given the friction coefficient μ, the friction constraint can be expressed as |f i,x |≤μf i,z and |f i,y |≤μf i,z .

[0096] Apart from Figure 4 In addition to the four constraints shown in FIG. 1 , a unilateral constraint can also be set accordingly. An example of a unilateral constraint can be f i,z > 0. Of course, the present disclosure is not limited to this.

[0097] Under the above-mentioned various constraints, the control models of various control tasks can be determined accordingly. Specifically, the rotation of the driving wheel under the control of the adaptive dynamic programming controller will provide an input reference to the wheel balancing control task, and the target trajectory will provide an input reference to other control tasks. For example, the rotation speed of the driving wheel will affect the posture and speed of the base, and the posture and speed of the base will affect the balance state of the robot.

[0098] As an example of a wheel balancing control task, to control the motion of the base, the desired acceleration of the base can be calculated by a PD control law (proportional-derivative controller): In one example, the PD control law is based at least in part on an input reference for attitude and an input reference for velocity.

[0099] Specifically, the input reference for the posture is also called the reference posture, which indicates: due to the rotation of the active wheel under the control of the adaptive dynamic programming controller, the {5,6} The input reference for speed is also called reference speed, which indicates: due to the rotation of the active wheel under the control of the adaptive dynamic programming controller, the posture changes of all joints except joint q{5,6} The changes in the speed of each joint other than the

[0100] That is, we can use formula (5) to solve the problem in formula (2): Make an approximate expression.

[0101]

[0102] In addition, formula (6) can be used to further explain the In formula (6), it is assumed that except for joint q {5,6} Other joints The torque is approximately zero.

[0103]

[0104] For example, Figures 1 to 3 Taking the robot described above as an example, the input reference for posture includes: the distance from the center of gravity of the robot to the center of the line connecting the driving wheels projected on the ground (for example, marked with state_com_p). The input reference for speed includes: the speed obtained based on the difference of the distance from the center of gravity of the robot to the center of the line connecting the driving wheels projected on the ground (for example, marked with state_com_v), and the linear speed of the wheel (marked with wheel_x_v). The above PD control law can be solved with state_com_p, state_com_v, and wheel_x_v as input states to obtain the reference acceleration / torque of the driving wheel.

[0105] The embodiments of the present disclosure optionally combine the whole-body dynamics technology to propose a whole-body dynamics control method based on adaptive dynamic programming. The whole-body dynamics control method uses the output of the controller of a certain joint of the robot calculated based on adaptive dynamic programming as a reference parameter for whole-body dynamics control, so that the controller of the joint can cooperate with the controllers of other joints, thereby improving the overall flexibility of the robot's movement.

[0106] Therefore, the embodiments of the present disclosure may optionally combine whole-body dynamics technology, and use the output of the controller of a certain joint of the robot calculated based on adaptive dynamic programming as a reference parameter for whole-body dynamics control, so that the controller of the joint can cooperate with the controllers of other joints, thereby improving the overall flexibility of the robot's movement.

[0107] According to one aspect of the present disclosure, an embodiment of the present disclosure optionally combines optimal control technology and proposes a policy iteration method based on adaptive dynamic programming. The policy iteration method based on adaptive dynamic programming can dynamically iterate the linear equilibrium parameter matrix in the controller to obtain a controller corresponding to the dynamic characteristics of the robot after the parameter change when the dynamic parameters of the robot change. The controller enables the robot to move along the target trajectory with the optimal control effect in a balanced state even if the dynamic parameters of the robot change.

[0108] Figure 5A and Figure 5B An exemplary flow chart of a method 500 for constructing a robot controller according to an embodiment of the present disclosure is shown. FIG. 5A to FIG. 5B The method 500 is described in more detail. For example, the robot may be Figures 1 to 4 The robot 100 shown in FIG. Figure 5A-Figure 5B The illustrated solution can be executed offline or online, but the present disclosure is not limited thereto.

[0109] Reference Figure 5A In step S501, the first controller is used to control the movement of the robot, and the movement state data and control data during the movement are obtained. Optionally, the precise dynamic characteristics of the robot are unknown, or only part of the dynamic characteristics of the robot can be roughly determined. In addition, the dynamic characteristics of the robot may also involve some variable parameters. Taking the robot 100 as an example, as the robot 100 moves, the height of the center of gravity of the robot 100 may change. In addition, if the robot 100 is used to carry an object, the mass of the robot 100 may also change accordingly. Whether it is a change in the height of the center of gravity or a change in the mass, it may cause changes in the kinetic energy, potential energy, momentum and other characteristics of the robot during the movement, thereby causing changes in the dynamic model corresponding to the robot 100. Although the present disclosure only describes the center of gravity height and mass as examples of variable parameters, those skilled in the art should understand that the present disclosure is not limited to this.

[0110] Optionally, the linear balance parameter matrix of the first controller is a stable initial gain matrix. Optionally, the control force provided by the controller at a time is negatively correlated to the product of the linear balance parameter matrix and the motion state data of the robot at the time. For example, the controller may have the form of u(t)=-Kx(t), where K is the linear balance parameter matrix corresponding to the robot, u(t) is the control force / torque outputted by the controller at time t, and x(t) is the motion state data corresponding to the robot at time t. Figures 1 to 4Taking the robot 100 described above as an example, the robot 100 at least includes: a wheel leg portion including a plurality of joints, a base portion connected to the wheel leg portion, and a driving motor for controlling a driving wheel in the wheel leg portion. Correspondingly, the motion data includes: a pitch angle of the base portion, a pitch angular velocity of the base portion, and a linear velocity of the driving wheel. The control data includes: an output torque of the driving motor. Correspondingly, since both the motion data and the control data can be collected discretely by relevant measuring instruments, both the motion data and the control data correspond to a plurality of discrete continuous moments or to a plurality of continuous time intervals.

[0111] Optionally, the first controller is a non-optimal controller. For example, the non-optimal controller is a controller that can only make the robot 100 move along the target trajectory in a stumbling manner. For example, the first controller as a non-optimal controller can be a controller corresponding to simplified dynamic characteristics. For example, the precise dynamic model corresponding to the complex wheel-legged robot can be simplified into an equivalent dynamic model consisting of only active wheels and a base part, etc.

[0112] As an example, the first controller can be used to control the robot to move in a quasi-equilibrium state. For example, under the control of some first controllers, the robot will swing left and right at a certain amplitude at the equilibrium point. For example, if a robot with unknown dynamic characteristics is controlled to move in a quasi-equilibrium state under the control of a first controller, the output of the first controller can be used as the control data. If the experimenter uses a remote control to control the robot to move, the control data can be obtained by collecting the output of the controller on a real machine (for example, detecting the driving force of the active wheel, etc.). The present disclosure does not limit the method of obtaining control data.

[0113] For another example, the first controller may also be a PID controller, etc. In some cases, the linear balance parameter matrix of the first controller may even be an arbitrary stable control gain matrix. Even more, the robot may be directly and randomly controlled to travel a certain distance with arbitrary control data, and the control data and motion state data of the robot before it completely loses balance (for example, falls) may be intercepted as the motion state data and control data obtained in step S501. The present disclosure does not limit the specific design of the first controller, as long as it can control the robot to not completely lose balance.

[0114] As an example, one or more first controllers obtained by a numerical iteration scheme, which will be described in detail later, can also be used to control the robot to move. For example, when the variable parameter is a first value, the first controller can be determined using a numerical iteration scheme (for example, offline). For example, let the variable parameter be the height of the robot. And let the first value be 0.38 meters and the second value be 0.5 meters. When the height of the robot 100 is 0.38 meters, the optimal controller for controlling the robot to walk in a straight line can be determined using a numerical iteration scheme, and the controller is used as the first controller. Then, by changing the joint angle, the height of the robot 100 is adjusted to 0.5 meters. Then, continue to use the first controller to control the robot with the height adjusted to travel for a period of time / a distance, and collect motion data and control data accordingly. The motion data and control data will be used as training data for the second controller later to obtain the optimal controller when the variable parameter is the second value.

[0115] Those skilled in the art should understand that the above-mentioned first value and second value are only examples, and the present disclosure is not limited thereto. Although the numerical iteration scheme can determine the first controller adapted to the robot with a height of 0.38 meters, when the height of the robot changes, it is necessary to recalculate the second controller adapted to the robot after the height change offline. Offline calculation may be time-consuming and may cause the robot's motion to be interrupted.

[0116] In order to reduce the amount of calculation, the second controller can be constructed by using the strategy iteration scheme using steps S502 to S503. Specifically, in step S502, the linear balance parameter matrix of the first controller is updated by using the strategy iteration method according to the motion state data and the control data. In step S503, based on the updated linear balance parameter matrix, a second controller corresponding to the dynamic characteristics of the robot is constructed.

[0117] For example, the robot under the control of the second controller can have a better control effect during the movement process than the robot under the control of the first controller. For example, the swing amplitude of the robot around the balance point under the second controller corresponding to the dynamic characteristics of the robot can be smaller than that under the first controller. For another example, the robot under the control of the controller can converge faster to the vicinity of the balance point, or the robot oscillates less, or the control speed is faster, or the overshoot is smaller, or the steady-state error is smaller, etc. during the movement process compared to the robot under the control of the first controller. Or, in some cases, any controller and the controller have the same control effect, but the control input of the controller is smaller. The present disclosure is not limited to this.

[0118] Take the moving robot 100 as an example for explanation. The robot 100 in a balanced state may be in a stable balanced state in the linear motion dimension and the rotational motion dimension. For example, the robot 100 in a balanced state can maintain a state that is the same as / very similar to the state defined by the balance point during the movement, or can recover to the state defined by the balance point at the fastest speed / minimum energy consumption during the movement. The state defined by the balance point may be a state in which the robot 100 is in a state in which the pitch angle is zero, the angular velocity corresponding to the pitch angle is zero, and the linear speed is at the target speed. For example, at this time, the posture of the robot 100 is in a vertically upward state, and at this time, the robot 100 does not have a speed in the rotational motion dimension but only has a target speed in the linear motion dimension.

[0119] The robot 100 in a quasi-equilibrium state is in a state defined near the equilibrium point during the movement. For example, it may be in an intermediate state transitioning from a stable equilibrium state to an unstable equilibrium state in the linear motion dimension and the rotational motion dimension. The robot 100 in a quasi-equilibrium state may need the driving wheel to provide a large force and torque to ensure that it does not fall during the movement. For example, at this time, the robot 100 can tilt left and right, and at this time the robot 100 not only has the speed in the linear motion dimension but also has the speed in the rotational motion dimension. It is worth noting that the robot 100 in a quasi-equilibrium state herein may also be in a state close to an unstable equilibrium state in the linear motion dimension or the rotational motion dimension at certain moments during the movement, as long as it can be restored to a state where it can move normally through the driving force of the driving wheel 104.

[0120] As an example, if the robot 100 moves in a straight line only under the control of the driving wheel 104, the robot 100 in a balanced state can always maintain a vertically upward posture and move in a straight line at a uniform speed, that is, the central axis of the base of the robot 100 in an unstable balanced state can always be perpendicular to the horizontal line and has no speed / acceleration in the rotational motion dimension. The base of the robot 100 in a quasi-balanced state may have an inclination angle (pitch angle) and a speed / acceleration in the rotational motion dimension.

[0121] In an embodiment of the present disclosure, the robot can first be made to move for a period of time / a track under the control of a first controller, and the motion state data and control data corresponding to the time period / track are collected as training data. Even if the dynamic characteristics of the robot 100 are unknown / inaccurate or the dynamic characteristics change during the movement, and the first controller is a non-optimal controller, the embodiment of the present disclosure can also determine the second controller as the optimal controller through policy iteration accordingly. The embodiment of the present disclosure uses a numerically driven policy iteration scheme to calculate the linear equilibrium parameter matrix, and then construct a controller. The control effect of the controller will be better than the control effect of the non-optimal controller (or, in some cases, corresponding to the first controller).

[0122] The constructed controller can converge to the controller corresponding to the optimal solution of the linear quadratic regulation problem. The controller corresponding to the optimal solution of the linear quadratic regulation problem is also the controller corresponding to the precise dynamic characteristics of the robot. And the controller corresponding to the optimal solution of the linear quadratic regulation problem can minimize the cost functional of the robot during the movement process, so that the robot moves along the target trajectory with the optimal control effect in the equilibrium state. The strategy iteration scheme and the calculation scheme of the linear equilibrium parameter matrix will be further described below, so it will not be repeated here.

[0123] Therefore, the amount of training data of the embodiment of the present disclosure is much smaller than the amount of data required by the traditional reinforcement learning algorithm. Furthermore, the trained controller of the embodiment of the present disclosure gradually converges to the controller corresponding to the optimal solution of the linear quadratic regulation problem as the learning step size increases, thereby ensuring the stability of the closed-loop system, and the training process is greatly simplified, and no additional restrictions are required on the training data, thereby simplifying the design process of the robot controller. In addition, the embodiment of the present disclosure can directly perform data collection on a real machine, and the trained controller is directly applied to the real machine. The embodiment of the present disclosure does not require data collection in a simulator based on a physical engine, and also eliminates some problems caused by the migration of data from the virtual world to the real world.

[0124] Optionally, an embodiment of the present disclosure also correspondingly discloses a method for controlling a robot using a controller corresponding to the dynamic characteristics of the robot. The robot includes a wheel leg portion and a base portion connected to the wheel leg portion, and the wheel leg portion includes a driving wheel and at least one joint. Specifically, the method includes: receiving a motion instruction, the motion instruction indicating the motion trajectory of the robot; according to the motion instruction, using a controller corresponding to the dynamic characteristics of the robot to control the driving force of the driving wheel so that the robot moves smoothly along the target trajectory. The robot under the control of the controller corresponding to the dynamic characteristics of the robot is closer to the balance point during the movement than the robot under the control of the first controller.

[0125] Optionally, an embodiment of the present disclosure also correspondingly discloses a method for controlling a robot. Specifically, the method includes: receiving a motion instruction, the motion instruction indicating the motion trajectory of the robot; according to the motion instruction, controlling the driving force of the driving wheel, so that the robot moves under the control of a first controller and obtains motion state data and control data during the motion process; based on the motion state data and the control data, using a policy iteration method to construct a second controller corresponding to the dynamic characteristics of the robot, and using the second controller to control the driving force of the driving wheel, so that the robot moves smoothly. The robot under the control of the controller has a better control effect during the movement process than the robot under the control of any other controller, for example, it is closer to the balance point.

[0126] Therefore, the method for controlling a robot according to an embodiment of the present disclosure enables a robot with unknown dynamic characteristics to learn data during movement, and gradually improve / generate a controller corresponding to the dynamic characteristics of the robot, and finally achieve smooth movement. Since the control input of the first controller can be used to control the movement of the robot for a period of time to obtain training data, in such a case, the embodiment of the present disclosure realizes the improvement of a non-optimal controller when the dynamic characteristics are unknown or changed, and generates a second controller corresponding to the (precise) dynamic characteristics of the robot. That is, the embodiment of the present disclosure can enable the robot to be flexibly controlled even without an accurate dynamic model.

[0127] For example, further reference Figure 5BFor example, the motion process of the robot 100 can be mathematically regarded as a continuous-time linear system. It is assumed that there is a controller corresponding to the optimal solution of the linear quadratic regulation problem for the robot 100, which can minimize the cost functional corresponding to the motion process of the robot. For example, the controller corresponding to the optimal solution of the linear quadratic regulation problem can minimize the cost of the robot near the equilibrium point and can move along the target trajectory with minimum energy consumption.

[0128] As an example, the linear quadratic regulation problem can be defined by Equation (7), which indicates that In the case of , solve the controller that can minimize the cost functional J of the continuous-time linear system. In which, similarly, and

[0129]

[0130] Where J is the cost functional of the continuous-time linear system, Q is a real symmetric and positive semidefinite matrix, is observable and R>0. x is related to the robot configuration and the wheel balancing task. For example, refer to Figure 4 In the example, if a controller needs to be determined for the active wheel, then x may optionally include the pitch angle, the pitch angle velocity, and the linear velocity of the robot, and u is the sum of the input torques of the two wheels.

[0131] According to optimal control theory, mathematically, the Algebraic Riccati equation (Equation (8)) can be regarded as the solution to the following linear quadratic regulation (LQR) problem defined by Equation (7).

[0132]

[0133] Among them, u * (t) is the controller corresponding to the optimal solution of the linear quadratic regulation problem, u * (t) = -K * x(t), where P * To satisfy The matrix of .

[0134] If the precise dynamic characteristics of the robot 100 are known, then the matrices A and B in formulas (7) and (8) are known. When the matrices A and B in formulas (7) and (8) are known, the corresponding solution u can be obtained. * (t).

[0135] However, as mentioned above, when the precise dynamic characteristics of the robot 100 are unknown or only part of the dynamic characteristics of the robot 100 can be determined, the above-mentioned optimal controller u cannot be determined in practical applications. * (t) = -K * Furthermore, P in formulas (7) and (8) is not linear, which makes it difficult to solve the exact P * .

[0136] In various aspects of the embodiments of the present disclosure, when the precise dynamic characteristics of the robot 100 are unknown or the variable parameters in the dynamic characteristics are changed, or when only part of the dynamic characteristics of the robot 100 can be determined, the optimal controller u is determined by a policy iteration scheme. * (t) = -K * x(t). Specifically, according to the relevant theories of policy iteration, we can determine:

[0137] Assume existence K0 is a stable control gain matrix. That is, A-BK0 is Hurwitz. Then, if K is continuously updated by formula (9): k , then when k approaches positive infinity, K k will approach K * , that is, lim k→∞ K k =K * .

[0138]

[0139] In formula (9), P k >0, and P k is the solution of the Lyapunov equation. An example of the Lyapunov equation is shown in equation (10).

[0140]

[0141] In formula (9) and formula (10), k = 0, 1, 2, ..., A k =A-BK k . With K k Similarly, lim k→∞ P k =P * Therefore, formula (9) and formula (10) describe K k+1 , K k and P k The relationship between the three.

[0142] Therefore, at least partially based on the above formula (9) and formula (10), a scheme for updating the linear balance parameter matrix of the first controller by using a policy iteration method in step S502 can be determined exemplarily.

[0143] For example, the above-mentioned step S502 may further include: performing nonlinear combination of the motion state data and the control data corresponding to the multiple time intervals to determine a training data set, and determining an iterative relationship function based on the training data set; and performing multiple strategy iterations on the iterative target item according to the iterative relationship function to approximate the linear balance parameter matrix corresponding to the dynamic characteristics of the robot.

[0144] Next, Figures 1 to 4 Step S502 is explained using the example described in Figures 1 to 4 , the first controller u0 can be used to control the robot to move, and the motion state data and the control data corresponding to the multiple time intervals can be collected accordingly. Specifically, for example, for the control strategy u=u0, the closed-loop system can be shown in formula (11).

[0145]

[0146] Then, by using equations (9) and (10), along the trajectory defined by equation (11), x(t) T P k The time derivative of x(t) can be represented by way of example by formula (12).

[0147]

[0148] in,

[0149] Furthermore, the motion state data is collected by the sensor at certain time intervals over a period of time, which respectively corresponds to the motion state of the robot at each discrete moment in the period of time. Therefore, the motion state data and the control data of the first controller can correspond to [t0, t r ] Any time interval from t to t+δt in the multiple time intervals can be recorded as [t, t+δt], and its duration δt can be determined according to the data collection time interval that the robot sensor can reach.

[0150] refer to Figure 5B, the motion state data and the control data corresponding to the multiple time intervals can be nonlinearly combined respectively to construct an iterative relationship function. The motion state data and the control data after the integration operation will be used as training data to participate in the process of performing strategy iteration on the iterative target item in step S502 to approximate the linear balance parameter matrix corresponding to the dynamic characteristics of the robot. It is worth noting that the following description is only an exemplary integration operation, and the present disclosure is not limited to this.

[0151] For example, the integral of both sides of formula (12) over the time interval [t, t+δt] can be taken, and by rearranging formula (12), exemplary formula (13) can be determined.

[0152]

[0153] In order to determine the variable P k and K k+1 , Equation (13) can be iterated at multiple time intervals. For example, r can be specified as a sufficiently large integer such that for all i = 0, 1, ..., r-1, δt ≤ t i+1 -t i .

[0154] According to formula (13), the time integral of the motion state data between any two adjacent times t and t+δt may be related to at least one of the following: the quadratic term of the motion state data at time t, the quadratic term of the motion state data at time t+δt, the product of the motion state data at time t and the motion state data at time t+δt, the product of the control data at time t and the motion state data at time t, the product of the control data at time t+δt and the motion state data at time t+δt, etc. Optionally, the control data at time t is control data for controlling the robot to move using the first controller.

[0155] To further describe the process of policy iteration, for a given integer r, the embodiment of the present disclosure optionally defines the following three matrices as example elements in the training data set using formula (14). The first matrix Δ xx , the second matrix ∑ xx , and the third matrix ∑ xu Among them, the first matrix Second Matrix and Each matrix corresponds to a nonlinear combination of the motion state data and the control data in the plurality of time intervals, for example involving integral operations and product calculations and the like.

[0156]

[0157] Where 0≤t0 <t1<…<t r . Operator represents the Kronecker product.

[0158] For example, for Figures 1 to 4 Describing the robot 100, the first matrix Δ xx Any element in Corresponding to time t i and time t i +δ t The second matrix ∑ xx Any element in Corresponding to time t i and time t i +δ t The product of any two of the base pitch angle, base pitch angular velocity, and driving wheel linear velocity, or the integral of the quadratic term of any one of them. xu Any element in Corresponding to time t i and time t i +δ t The integral of the product of any one of the base pitch angle, the base pitch angular velocity, and the linear velocity of the driving wheel and the driving force controlled by the first controller. Different robot configurations will correspond to different matrices, and the above is only shown as an example, and the present disclosure is not limited thereto.

[0159] Next, for different t, for example, t = t0, t1, ..., t r , the system of equations of formula (13) can be exemplarily written in the form of formula (15). Those skilled in the art should understand that different linear combinations of training data will correspondingly affect the form of the constructed iterative relationship function. The following is only an exemplary iterative relationship function (e.g., formula (15)) obtained based on formula (13), wherein the iterative target item includes the linear equilibrium parameter matrix to be iterated, and the solution of the Lyapunov equation with the linear equilibrium parameter matrix to be iterated as a parameter. Of course, the present disclosure is not limited to this.

[0160]

[0161] Among them, vec(·) indicates that the content in the brackets is vectorized. In addition, and It can be defined as shown in formula (16). As mentioned above, k indicates the number of policy iterations, Pk is the solution of the Lyapunov equation in the kth policy iteration, K k is the linear equilibrium parameter matrix used in the kth policy iteration, K k+1 is the linear equilibrium parameter matrix in the k+1th policy iteration.

[0162]

[0163] In the above conversion process from formula (13) to formula (15), in order to simplify the calculation, we can let

[0164] Therefore, by changing K in formula (16) k Update to K in formula (15) k+1 , the strategy iteration scheme makes the generation of the optimal controller no longer dependent on the model information (A, B). In addition, formula (16) can also collect online data and use formula (15) to change the control strategy from K k Update to K k+1 Therefore, the data collected in formula (16) can also be reused to apply formula (15) to update K for k = 0, 1, ..., l k , and the update process can be online or offline. Therefore, such a policy iteration process can also be called off-policy iteration.

[0165] In addition, to ensure that only one pair (P k ,K k+1 ) exists to satisfy the requirements of formula (15) and also needs to satisfy the rank condition defined in formula (17).

[0166] rank([∑ xx ∑ xu ])=n(n+3) / 2. (17)

[0167] Specifically, according to lim k→∞ P k =P * It can be seen that if the solution P of the Lyapunov equation corresponding to two consecutive strategy iterations k and P k+1 If the difference is less than a preset value (e.g., a very small value), the iteration target item converges and the policy iteration ends.

[0168] Next reference Figures 6 to 7B Further description of Figures 1 to 4 The method for controlling the robot shown. Figure 6 Still another structural view of the robot 100 is shown. Fig. 7AThe motion state data and control data in the process of controlling the motion of the robot using the first controller are shown. Figure 7B The convergence process of the linear equilibrium parameter matrix in the process of constructing a controller corresponding to the dynamic characteristics of the robot is shown, wherein the base height of the robot is 0.5 meter and 0.6 meter respectively. Figure 7C The motion state data of the robot is shown in which the first controller and the second controller are used to control the robot to walk in a straight line when the base height is 0.6 meters.

[0169] like Figure 6 As shown, the robot 100 has Figures 1 to 4 In addition to the wheel leg part and the base part described in the text, it also includes a data acquisition device, a data processing device and a drive motor.

[0170] The data acquisition device may be configured to acquire motion state data and control data during the motion process when the first controller is used to control the motion of the robot. For example, the data acquisition device may include: a first sensor for measuring the pitch angle θ of the base part and its angular velocity The second sensor is used to measure the rotational angular velocity of the left and right driving wheels and The first sensor may be an inertial measurement unit (IMU), which may include a three-axis gyroscope, a three-axis accelerometer, or a three-axis magnetometer. The second sensor may be a motor encoder with a sampling frequency of 200 Hz.

[0171] The data processing device is configured to: update the linear balance parameter matrix of the first controller using a policy iteration method according to the motion state data and the control data; and construct a second controller corresponding to the dynamic characteristics of the robot based on the updated linear balance parameter matrix.

[0172] The data processing device may include a microprocessor, a digital signal processor ("DSP"), an application specific integrated circuit ("ASIC"), a field programmable gate array, a state machine, or other processing device for processing the electrical signals received from the sensor line. Such processing devices may include programmable electronic devices, such as PLCs, programmable interrupt controllers ("PIC"), programmable logic devices ("PLD"), programmable read-only memories ("PROM"), electronic programmable read-only memories, etc.

[0173] For example, the data processing device can be further configured to further process the data collected by the data collection device. and The data processing device can calculate the linear velocity of the robot 100 where r w is the radius of the driving wheel. Optionally, r w =0.1m. Optionally, the data processing device can also calculate the yaw angular velocity of the robot where w d is the robot width, optionally, w d =0.47m.

[0174] For ease of explanation, the present disclosure only gives an example of using the first controller or the second controller to control the driving wheel 104. Those skilled in the art should understand that the solution of the present disclosure can also be used to control other components of the robot. Since the driving wheel is only used to control the forward and backward movement of the robot, for a curved target trajectory, a controller for controlling the yaw angle is also required to control the robot's steering. To simplify the description, the controller for controlling the yaw angle is set to in is the target yaw rate. Then by Calculate the torque on the left and right wheels. τ ψ The force along the longitudinal direction of the robot is not changed. Therefore, the yaw movement does not affect the balance of the robot. Afterwards, the angle unit is converted to "degrees (deg)" for easier reading.

[0175] Next, the data processing device calculates the control data of the first controller based on the given target trajectory. For ease of explanation, the controller u0 with the linear balance parameter matrix K=K0=[-81.99,-34.96,-16.38] is used as an example for explanation as the first controller. The first controller corresponds to the optimal controller obtained by numerical iteration when the height of the robot is the lowest, which can control the robot 100 to walk upright. Specifically, the minimum height of the robot is 0.33 meters. Furthermore, the control frequency of the data processing device can optionally be 1000Hz.

[0176] As described above, the motion data and control data will be used to calculate the first matrix Δ xx , the second matrix ∑ xx , and the third matrix ∑ xu These data require continuous signals of x and u, so when the first controller and the controller corresponding to the dynamic characteristics of the robot control the movement of the robot 100, the data processing device can further use trapezoidal integration to calculate the integral. The step size of the trapezoidal integration is 0.01s, which is the same as the sampling period.

[0177] like Fig. 7AAs shown, the height of the robot can be raised to 0.5 meters, and the first controller (whose linear balance parameter matrix K = K0 = [-81.99, -34.96, -16.38]) is used to superimpose the exploration noise β(t) to control the robot to walk for 5 seconds, and the yaw angle, yaw angular velocity, linear velocity and torque of the driving wheel are collected accordingly. Specifically, exploration noise is often used in the fields of learning and system identification. Exploration noise can trigger various system behaviors to avoid repeated data collection. As an example, exploration noise β(T) = sin(10πT) + 0.4cos(6πT).

[0178] As an example, the data processing device may be further configured with the following instructions to perform calculation of control data of the first controller and construction of the second controller. For ease of description, the instructions are shown in the form of pseudo code, and those skilled in the art can calculate the control data of the first controller and construct the second controller using any programming language based on the following pseudo code.

[0179] ******************************************************************

[0180] ■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■

[0181] 1: Select a stable initial gain matrix K0 and make t0=0.

[0182] 2: Apply u0(t)=-K0x(t)+β(t) to the robot, where β(t) is noise, and use a data acquisition device to collect data to calculate the first matrix to the third matrix until formula (17) is satisfied.

[0183] 3: Repeat k+1 assignment to k, and use formula (15) to solve P k and K k+1 .

[0184] 4: If |P k+1 -P k |<ε, the iteration stops. ε can be a very small preset threshold.

[0185] 5: Use u=-K k x as the second controller.

[0186] ******************************************************************

[0187] In the case where the data processing apparatus is configured with the above pseudo code, as Figure 7B As shown in the figure above, the linear equilibrium parameter matrix gradually converges to K = [-99.58 -35.87 -5.18]. Figure 7B As shown in the left figure, only 37 iterations are needed to make |P k+1 -P k |<ε=10 -5 .

[0188] Similarly, the embodiment of the present disclosure also uses u=-Kx as the first controller (where K=[-99.58 -35.87-5.18]), and then increases the height of the robot to 0.6 meters to conduct a similar set of experiments, such as Figure 7B As shown in the figure below, the linear equilibrium parameter matrix converges to K = [-109.64, -34.08, -11.58]. Figure 7B As shown in the figure below, only 47 iterations are needed to make |P k+1 -P k |<ε=10 -5 Obviously, the convergence speed of the policy iteration is very fast, so the embodiments of the present disclosure can be applied to online computing.

[0189] Figure 7C The comparison between the control effects of the first controller u0(t) = -K0x(t) (where K0 = [-81.99, -34.96, -16.38]) and the second controller u(t) = -K1x(t) (where K1 = [-109.64, -34.08, -11.58]) is further shown. In this comparative experiment, the same sinusoidal noise is added to both the first controller u0(t) and the second controller u(t) to simulate the external disturbance acting on the wheel. Figure 7C As shown in the upper and lower figures of , both controllers are robust to noise and have similar control performance. Figure 7C As indicated by the smaller amplitude of the second controller in the lower figure, the updated gain K1 is The control effect is better in the adjustment, so that the robot's moving state is more stable.

[0190] The embodiments of the present disclosure combine the optimal control technology and propose a numerical iteration method based on adaptive dynamic programming, which can calculate and converge to a controller corresponding to the dynamic characteristics of the robot when the dynamic characteristics of the robot are unknown. The controller corresponding to the precise dynamic characteristics of the robot is also the controller corresponding to the optimal solution of the linear quadratic regulation problem, which can make the robot move along the target trajectory with the optimal control effect in a balanced state.

[0191] Next reference Figure 8 An example of obtaining a controller corresponding to the dynamic characteristics of the robot is further described. Figure 8 A flowchart of a numerical iteration scheme according to an embodiment of the present disclosure is shown.

[0192] First, the motion process of the robot 100 can be mathematically regarded as a continuous-time linear system. It is assumed that there is a controller corresponding to the optimal solution of the linear quadratic regulation problem for the robot 100, which can minimize the cost functional corresponding to the motion process of the robot. For example, the controller corresponding to the optimal solution of the linear quadratic regulation problem can minimize the cost of the robot near the equilibrium point and can move along the target trajectory with minimum energy consumption.

[0193] As an example, as described above, formula (7) and formula (8) have been explained. If the precise dynamic characteristics of the robot 100 are known, then the matrices A and B in formula (7) and (8) are known. When the matrices A and B in formula (7) and (8) are known, u can be solved accordingly. * (t).

[0194] However, as mentioned above, when the precise dynamic characteristics of the robot 100 are unknown or only part of the dynamic characteristics of the robot 100 can be determined, the above-mentioned optimal controller u cannot be determined in practical applications. * (t) = -K * Furthermore, P in formulas (7) and (8) is not linear, which makes it difficult to solve the exact P * .

[0195] As mentioned above, according to the LQR correlation theory and the numerical iteration correlation theory, for formula (7) and formula (8), if (A, B) is stable and is observable, then for any S ≥ 0, lim s→-∞ P(s)=P * , where P(s) is the solution of the following differential Riccati equation (Formula (18)), and P * is the solution of formula (8).

[0196]

[0197] That is, when s approaches negative infinity, P(s) will converge to P * .

[0198] Based on the above theory, an embodiment of the present disclosure proposes a method 800 for constructing a controller of a robot.

[0199] In step S801, the robot is controlled to move, and motion state data and control data during the movement are acquired, wherein the diversity metrics of the motion state data and the control data are higher than a predetermined threshold.

[0200] For example, the robot can be controlled to move along a predetermined trajectory, and the motion state data and control data during the motion process can be obtained. The predetermined trajectory can be roughly estimated based on the structural characteristics, motion characteristics, and dynamic characteristics of the robot to collect the motion data of the robot in various motion situations (scenarios) so that the diversity metric of the motion state data and control data is high enough (for example, at least higher than a predetermined threshold). In one example, the diversity metric can be characterized by information entropy, which characterizes that there are enough non-repeating / non-similar values ​​in both the motion state data and the control data. In another example, the diversity metric can also be characterized by data feature quantities.

[0201] At this point, the robot can be controlled by any controller to move along a predetermined trajectory. For example, the robot can be manually controlled to move along a straight line at different accelerations, regardless of whether the robot is in a state of balanced and stable motion. Figures 1 to 4 For the robot shown, if the driving wheel 104 provides too large an acceleration, the robot 100 will soon fall backwards. If the driving wheel 104 provides too small an acceleration, the destination cannot be reached quickly and may fall forwards.

[0202] Therefore, in one example of the present disclosure, the motion state data and control data satisfying the diversity metric may be collected in the following manner.

[0203] like Fig. 9 As shown, for example, the driving motor may be controlled to output a first torque so that the robot loses balance due to low-speed motion. For example, the first torque may be a relatively small value, so that when the driving motor is controlled to output the first torque, the center of mass of the base portion of the robot first rises and then falls, and the front end of the base portion contacts the ground when the robot loses balance. That is, the robot rushes forward from a head-down state (a state in which the center of mass of the base portion is relatively low), but because the force of the rush is not strong enough, the robot raises its head halfway and then lowers it again.

[0204] Then, the drive motor may be controlled to output a second torque so that the robot loses balance due to high-speed movement. For example, the second torque may be a relatively large value. When the drive motor is controlled to output the second torque, the center of mass of the base of the robot first rises and then falls, and the rear end of the base contacts the ground when the robot loses balance. That is, the robot rushes forward from a head-down state (a state in which the center of mass of the base is relatively low), but due to excessive force, it passes the balance point (the highest point of the center of mass of the base) and falls to the rear.

[0205] Then, the drive motor may be controlled to output a third torque so that the robot maintains a balanced state for a period of time. Wherein, when the drive motor is controlled to output the third torque, the center of mass of the base of the robot maintains a constant height when the robot maintains a balanced state. Alternatively, the drive motor may be controlled to output a fourth torque so that the robot maintains a quasi-balanced state for a period of time, and the robot in the quasi-balanced state is near a balance point during movement. When the drive motor is controlled to output the fourth torque, the base of the robot sways back and forth when the robot maintains a quasi-balanced state.

[0206] As described above, instructions can be manually input into the remote controller and sent to the remote controller. After receiving the instruction, the remote controller can determine the corresponding control data. Then, the robot can be controlled to move according to the control data of the remote controller, and the motion state data during the movement can be obtained. In some embodiments, since the reaction speed of human eyes and hands cannot meet the control requirements of the robot, the balance of the robot is difficult to control manually. That is, the remote controller is not a balancing controller, which often causes the robot to lose balance.

[0207] Next, in step S802, a linear balance parameter matrix is ​​calculated using a numerical iteration method according to the motion state data and the control data. In step S803, a controller corresponding to the dynamic characteristics of the robot is constructed based on the linear balance parameter matrix. The robot under the control of the controller corresponding to the dynamic characteristics of the robot has a better control effect during the motion process than the robot under the control of the remote controller.

[0208] Optionally, the controller corresponding to the dynamic characteristics of the robot is a linear controller, and at each moment during the movement process, the control torque provided by the controller corresponding to the dynamic characteristics of the robot is negatively correlated to the product of the linear balance parameter matrix and the motion state data of the robot.

[0209] For example, for Figure 8 Step S802 in the method may further include: performing integral operations on the motion state data and the control data corresponding to the multiple time intervals to construct an iterative relationship function; and performing numerical iteration on the iterative target item according to the iterative relationship function to approximate the linear balance parameter matrix corresponding to the dynamic characteristics of the robot. Optionally, the linear balance parameter matrix K is Here, s tends to negative infinity.

[0210] Next, Figures 1 to 4Step S802 is described in detail with reference to the examples described in the following. Figures 1 to 4 According to the description, the motion state data for training and the control data for training can be obtained. Optionally, the motion state data for training and the control data for training are the motion data and control data at the moment when the robot does not fall (for example, the front end / rear end or tail of the base part does not contact the ground). That is, at least during this section of motion, based on formula (18), the following formula (19) is established.

[0211]

[0212] Where H(s) = A T P(s)+P(s)A and

[0213] Furthermore, the motion state data is collected by the sensor at certain time intervals over a period of time, which respectively corresponds to the motion state of the robot at each discrete moment in the period of time. Therefore, the motion state data and the control data of the first controller can correspond to [t0, t r ] in multiple time intervals. Any time interval t in the multiple time intervals i to i+1 It can be recorded as [t, t+δt], where the duration δt can be determined based on the data collection time interval that the robot sensor can achieve.

[0214] For example, take the integral of both sides of formula (19) over the time interval [t, t+δt] for different t, for example, t=t0, t1, …, t r , we can get formula (20).

[0215]

[0216] in, In formula (14), Δ xx ,∑ xx ,∑ xu Thus, by continuously iteratively solving formula (20) and updating formula (18), when the rank condition is satisfied and there is a unique pair (H(s), P(s)), the linear equilibrium parameter matrix K * It can be generated through numerical iteration, and the whole process no longer depends on the model information (A, B). That is, when the iteration target item converges during the numerical iteration process, the numerical iteration can be stopped; then, according to the converged iteration target item, the linear balance parameter matrix corresponding to the dynamic characteristics of the robot is reconstructed.

[0217] As described above, the embodiment of the present disclosure only collects the motion state data and control data of the robot with unknown dynamic characteristics before losing balance (falling), and constructs the first matrix to the third matrix as training data by integrating these data. Therefore, the amount of training data of the embodiment of the present disclosure is much smaller than the amount of data required by the traditional reinforcement learning algorithm. The embodiment of the present disclosure also constructs an iterative relationship function (e.g., formula (20)) correspondingly, so that the target iteration term (e.g., P(s), K(s) and H(s)) gradually converges with the increase of the learning step size. Moreover, the converged target iteration term can obtain a controller, which converges to the controller corresponding to the optimal solution of the linear quadratic regulation problem, thereby ensuring the stability of the closed-loop system, and its training process is greatly simplified. The whole process does not require additional restrictions on the training data, thereby simplifying the design process of the robot controller.

[0218] Similarly, as described above, the robot 100 Figures 1 to 4 In addition to the wheel leg part and the base part described in Figure 6 The data acquisition device, data processing device and drive motor shown.

[0219] In the example of the solution applying numerical iteration, the data acquisition device may be configured to: acquire the motion state data of the robot.

[0220] A data processing device is configured to: obtain control data corresponding to the motion state data; calculate a linear balance parameter matrix based on the motion state data and the control data using a data iteration method, wherein a diversity measure of the motion state data and the control data is higher than a predetermined threshold; and construct a controller corresponding to the dynamic characteristics of the robot based on the linear balance parameter matrix.

[0221] For example, the data processing device may be further configured to further process the data collected by the data acquisition device. For ease of explanation, the present disclosure only gives an example of controlling the active wheel 104. Those skilled in the art should understand that the scheme of the present disclosure may also be used to control other components of the robot. Next, the data processing device sets the control data for training based on the given target trajectory. As shown in reference Figure 3 As mentioned above, the present disclosure does not limit the specific control law of the controller used for training. To facilitate the non-restrictiveness of the present disclosure on the controller used for training, the following description uses the example of an experimenter manually controlling the robot movement to extract motion data and control data. Furthermore, the control frequency of the data processing device is 1000 Hz.

[0222] As mentioned above, the motion data and control data will be used to calculate Δ xx ,∑xx ,∑ xu These data require continuous signals for x and u. Fig. 7A The motion data can be collected in a similar manner, for example, when the height of the base of the robot 100 is l=0.33m, the remote controller can be used to manually input commands to determine the data of the remote controller controlling the motion of the robot. Specifically, since the experimenter cannot accurately know the dynamic characteristics of the robot 100, and the manual control of the robot often fails to accurately and timely adjust the robot controller, causing the robot to fall.

[0223] Specifically, the collected motion state data can be further processed to obtain a controller corresponding to the dynamic characteristics of the robot as quickly as possible. The following is an example experiment of using a data iteration scheme to calculate a controller corresponding to the dynamic characteristics of the robot. Fig.10 As shown, the height of the robot is the minimum height of 0.33m. And the motion command is directly given manually by the remote controller to indicate the torque of the driving wheel. In this experiment, as the torque of the driving wheel increases, the robot starts from the initial state (shown in state A), and moves using the driving wheel (shown in states B and C), and finally falls (state D). Since, the robot eventually loses balance, the remote controller in this case is not a class balance controller.

[0224] A similar process was repeated three times, and the data collected three times were plotted on Fig.11 In which, torque is the total torque of the two driving wheel motors. In particular, when the system is assumed to be linear, data close to the linear region of the simplified model is used, that is, -20 degrees < tilt angle < 20 degrees. Fig.11 As shown in the figure, the duration of the three data collection processes is 0.515 seconds, 0.155 seconds, and 0.586 seconds, respectively, for a total of 1.256 seconds. Any non-professional can easily collect these short-term data by manually inputting the torque through a remote control. In addition, since the data iteration scheme can be performed offline, various parameters can be easily adjusted to make the iteration terms converge.

[0225] against Fig.11 The motion state data and control data in the method 800 are used, and Q = diag [20000, 8000, 3000], R = 20, t i+1 -t i = 0.1s, we can get Fig.12 The iterative diagram of P and K is shown. According to the test of the experimenter, after the 3275th numerical iteration, the converged K = [-81.99, -34.96, -16.38] can be obtained.

[0226] Based on K = [-81.99, -34.96, -16.38], a controller corresponding to the dynamic characteristics of the robot is constructed. The controller is used to control the real machine in Fig.13 Traveling along the path shown, we collected Fig.14 The test data of the tilt angle (which is roughly within plus or minus 2 degrees), linear speed, and yaw speed data shown in the figure show that the data iteration scheme can obtain a controller with sufficient robustness and stability.

[0227] Those skilled in the art will appreciate that the controller can also be used to control other motions, and the present disclosure is not limited thereto. In addition, according to tests, the robustness of the controller is much higher than that of the PID controller, that is, when the robot 100 is disturbed externally, the robot under the control of the controller can quickly restore balance.

[0228] Therefore, the embodiment of the present disclosure is based on reinforcement learning and ADP technology in artificial intelligence, and uses a numerical iteration scheme to solve the optimal balance control problem of the robot under the condition of unknown dynamic characteristics of the robot. The process of constructing a controller in the embodiment of the present disclosure only requires the wheel-legged robot to move for a period of time / a section of trajectory under the control of a non-optimal controller / an arbitrary controller, and collects motion state data and control data corresponding to the time period / trajectory as training data. Therefore, the amount of training data in the embodiment of the present disclosure is much smaller than the amount of data required by the traditional reinforcement learning algorithm. Furthermore, the trained controller of the embodiment of the present disclosure gradually converges to the controller that best corresponds to the optimal solution of the linear quadratic regulation problem as the learning step size increases, thereby ensuring the stability of the closed-loop system, and its training process is greatly simplified, and no additional restrictions are required on the training data, thereby simplifying the design process of the controller of the wheel-legged robot.

[0229] According to actual needs, the robot may also include, for example, a bus, a memory, a sensor assembly, a communication module, an input and output device, etc. The embodiments of the present disclosure are not limited by the specific components of the robot.

[0230] The bus may be a circuit that interconnects the components of the robot and passes communication information (eg, control messages or data) among the components.

[0231] The sensor component can be used to perceive the physical world, such as a camera, an infrared sensor, an ultrasonic sensor, etc. In addition, the sensor component can also include a device for measuring the current operation and motion state of the robot, such as a Hall sensor, a laser position sensor, or a strain sensor.

[0232] The communication module can be connected to a network, for example, by wire or invalid, so as to communicate with the physical world (e.g., a server). The communication module can be wireless and can include a wireless interface, such as an IEEE 802.11, Bluetooth, wireless local area network ("WLAN") transceiver, or a radio interface for accessing a cellular telephone network (e.g., a transceiver / antenna for accessing a CDMA, GSM, UMTS or other mobile communication network). In another example, the communication module can be wired and can include an interface such as Ethernet, USB or IEEE 1394.

[0233] The input-output device may transmit commands or data input, for example, from a user or any other external device to one or more other components of the robot, or may output commands or data received from one or more other components of the robot to the user or other external device.

[0234] A plurality of robots may form a robot system to collaboratively complete a task, the plurality of robots being communicatively connected to a server and receiving collaborative robot instructions from the server.

[0235] According to one aspect of an embodiment of the present disclosure, there is provided a wheel-legged robot, which includes a processor and a memory, wherein the memory stores at least one instruction, at least one program, a code set or an instruction set, and the at least one instruction, the at least one program, the code set or the instruction set are loaded and executed by the processor to implement the above method.

[0236] According to one aspect of an embodiment of the present disclosure, a computer-readable storage medium is provided, in which at least one instruction, at least one program, a code set or an instruction set is stored, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by a processor to implement the above method.

[0237] The program part of the technology can be considered as a "product" or "manufactured product" in the form of executable code and / or related data, which is participated in or realized by computer-readable media. Tangible and permanent storage media can include any memory or storage used by any computer, processor, or similar device or related module. For example, various semiconductor memories, tape drives, disk drives or any similar devices that can provide storage functions for software.

[0238] All software or parts of it may sometimes be communicated over a network, such as the Internet or other communications network. Such communications can load software from one computer device or processor to another. Therefore, another medium capable of transmitting software elements may also be used as a physical connection between local devices, such as light waves, radio waves, electromagnetic waves, etc., transmitted through cables, optical cables or air. Physical media used to carry carriers, such as cables, wireless connections or optical cables and the like, can also be considered as media that carry software. As used herein, unless limited to tangible "storage" media, other terms referring to computer or machine "readable media" refer to media that participate in the process of executing any instructions by the processor.

[0239] The present disclosure uses specific words to describe the embodiments of the present disclosure. For example, "first / second embodiment", "one embodiment", and / or "some embodiments" refer to a certain feature, structure or characteristic related to at least one embodiment of the present disclosure. Therefore, it should be emphasized and noted that "one embodiment" or "an embodiment" or "an alternative embodiment" mentioned twice or more in different locations in this specification does not necessarily refer to the same embodiment. In addition, certain features, structures or characteristics in one or more embodiments of the present disclosure may be appropriately combined.

[0240] In addition, it will be appreciated by those skilled in the art that various aspects of the present disclosure may be illustrated and described by a number of patentable categories or situations, including any new and useful process, machine, product or combination of substances, or any new and useful improvements thereto. Accordingly, various aspects of the present disclosure may be performed entirely by hardware, entirely by software (including firmware, resident software, microcode, etc.), or by a combination of hardware and software. The above hardware or software may all be referred to as "data blocks", "modules", "engines", "units", "components" or "systems". In addition, various aspects of the present disclosure may be represented as a computer product located in one or more computer-readable media, the product including computer-readable program code.

[0241] Unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as commonly understood by one of ordinary skill in the art to which the invention belongs. It should also be understood that terms such as those defined in common dictionaries should be interpreted as having a meaning consistent with their meaning in the context of the relevant technology and should not be interpreted in an idealized or extremely formal sense, unless explicitly defined as such herein.

[0242] The above is an explanation of the present invention and should not be considered as a limitation thereof. Although several exemplary embodiments of the present invention have been described, it will be readily appreciated by those skilled in the art that many modifications may be made to the exemplary embodiments without departing from the novel teachings and advantages of the present invention. Therefore, all such modifications are intended to be included within the scope of the present invention as defined in the claims. It should be understood that the above is an explanation of the present invention and should not be considered as being limited to the specific embodiments disclosed, and modifications to the disclosed embodiments and other embodiments are intended to be included within the scope of the appended claims. The present invention is defined by the claims and their equivalents.

Claims

1. A method for constructing a controller for a robot, wherein: The dynamic characteristics of the robot are associated with at least one variable parameter, and the method comprises: Setting the variable parameter to a first value and determining a first controller using a numerical iteration method, wherein the first controller corresponds to a dynamic characteristic of the variable parameter being the first value; adjusting a variable parameter of the robot to a second value; Using the first controller to control the driving force of the driving wheel of the robot, so that the robot moves in a quasi-balanced motion state, and obtaining motion state data and control data during the motion process, wherein the robot in the quasi-balanced state is near a balance point during the motion process; According to the motion state data and the control data, updating the linear balance parameter matrix of the first controller by using a strategy iteration method; and Based on the updated linear balance parameter matrix, a second controller corresponding to the dynamic characteristics of the robot is constructed, wherein the second controller corresponds to the dynamic characteristics when the variable parameter is a second value.

2. The method of claim 1, wherein: The linear balance parameter matrix of the first controller is a stable control gain matrix.

3. The method of claim 1, wherein: Determining the first controller by using numerical iteration includes: Controlling the robot to move, and acquiring motion state data and control data during the motion process, wherein a diversity measure of the motion state data and the control data is higher than a predetermined threshold; Calculating a linear balance parameter matrix using a numerical iteration method according to the motion state data and the control data; Based on the linear balance parameter matrix, a first controller corresponding to the dynamic characteristics of the robot is constructed, wherein a variable parameter of the dynamic characteristics of the robot is a first value.

4. The method of claim 1, wherein: The robot controlled by the second controller has a better control effect during movement than the robot controlled by the first controller.

5. The method of claim 2, wherein: The first controller and the second controller are linear controllers. At each moment in the motion process, the control torque provided by the controller is negatively correlated to the product of the linear balance parameter matrix and the motion state data of the robot.

6. The method of claim 2, wherein: The method of controlling the movement of the robot by using the first controller and acquiring the movement state data and control data during the movement process also includes: The first controller determines an initial control instruction according to the current motion state of the robot; applying disturbance to the control data indicated by the initial control instruction to obtain control data of the first controller; and The robot is controlled to move according to the control data of the first controller, and the movement state data during the movement is collected.

7. The method of claim 6, wherein: The motion state data and the control data correspond to a plurality of time intervals, and the updating of the linear balance parameter matrix of the first controller by using a strategy iteration method according to the motion state data and the control data also includes: nonlinearly combining the motion state data and the control data corresponding to the plurality of time intervals to determine a training data set, Based on the training data set, determining an iterative relationship function; and According to the iterative relationship function, multiple policy iterations are performed on the iterative target item to approximate the linear balance parameter matrix corresponding to the dynamic characteristics of the robot.

8. The method of claim 7, wherein: The method of performing multiple strategy iterations on the iterative target item according to the iterative relationship function to approximate a linear equilibrium parameter matrix corresponding to the dynamic characteristics of the robot includes: In each strategy iteration, determine whether the iteration target item converges. In response to determining that the iteration target item has converged, stopping the policy iteration; and The linear equilibrium parameter matrix is ​​updated according to the converged iteration target item.

9. The method of claim 8, wherein: The iterative relationship function conforms to the form of the Lyapunov equation, the iterative target term includes a linear equilibrium parameter matrix to be iterated, and a solution of the Lyapunov equation with the linear equilibrium parameter matrix to be iterated as a parameter, The iterative relationship function indicates: according to the linear equilibrium parameter matrix in the current policy iteration and the solution of the Lyapunov equation corresponding to the current policy iteration, the linear equilibrium parameter matrix corresponding to the next policy iteration is calculated.

10. The method of claim 8, wherein: The convergence of the iteration target item includes: the difference between the solutions of the Lyapunov equation corresponding to two adjacent strategy iterations is less than a preset value.

11. The method of claim 1, wherein: The robot comprises: a wheel leg portion comprising a plurality of joints, a base portion connected to the wheel leg portion, and a driving motor for controlling an active wheel in the wheel leg portion; The motion data includes: a base pitch angle, a base pitch angle velocity, and a linear velocity of a driving wheel corresponding to a plurality of time intervals; and The control data includes: output torque of the driving motor corresponding to a plurality of time intervals.

12. A robot, wherein: The dynamic characteristics of the robot are associated with at least one variable parameter, and the robot comprises: The data acquisition device is configured as follows: Acquiring motion state data having a diversity metric higher than a predetermined threshold; When the first controller controls the driving force of the driving wheel of the robot so that the robot moves in a quasi-balanced motion state, acquiring motion state data of the robot under the control of the first controller, wherein the robot in the quasi-balanced state is near a balance point during the motion process; A data processing device configured to: Acquire control data corresponding to motion state data having a diversity metric above a predetermined threshold; Based on the motion state data and control data with a diversity metric above a predetermined threshold, a linear equilibrium parameter matrix is ​​calculated using a numerical iteration method; Based on the linear balance parameter matrix, construct a first controller corresponding to the dynamic characteristics of the robot, wherein the first controller corresponds to the dynamic characteristics when the variable parameter is a first value; adjusting the variable parameter from a first value to a second value, and acquiring control data corresponding to the motion state data of the robot under the control of the first controller; Based on the motion state data and control data of the robot under the control of the first controller, updating the linear balance parameter matrix of the first controller by using a policy iteration method; and Based on the updated linear balance parameter matrix, a second controller corresponding to the dynamic characteristics of the robot is constructed, wherein the second controller corresponds to the dynamic characteristics when the variable parameter is a second value.

13. The robot according to claim 12, further comprising: The wheel leg part includes a plurality of joints; a base portion connected to the wheel leg portion; A driving motor is provided on the robot to control the driving wheel in the wheel leg based on the controller.

14. A non-transitory computer-readable medium having at least one instruction stored thereon, wherein the instruction set is loaded and executed by a processor to implement at least one of the methods of claims 1 to 11.

15. A method of controlling a robot, wherein: The robot is driven by active wheels, and the dynamic characteristics of the robot are associated with at least one variable parameter. The method comprises: receiving a motion instruction indicating a motion trajectory for collecting motion data with a diversity metric above a predetermined threshold; According to the motion instruction, the driving force of the driving wheel is controlled to obtain motion state data and control data whose diversity metric is higher than a predetermined threshold value; Calculating a linear equilibrium parameter matrix using a numerical iteration method according to the motion state data and the control data where the diversity metric is higher than a predetermined threshold; Based on the linear balance parameter matrix, construct a first controller corresponding to the dynamic characteristics of the robot, wherein the first controller corresponds to the dynamic characteristics when the variable parameter is a first value; adjusting a variable parameter of the robot from a first value to a second value; receiving a motion instruction, wherein the motion instruction indicates a motion trajectory of the robot under the control of the first controller; According to the motion instruction, the driving force of the active wheel is controlled so that the robot moves in a quasi-balanced motion state under the control of the first controller and acquires motion state data and control data during the motion process, wherein the robot in the quasi-balanced state is near a balance point during the motion process; Based on the motion state data and the control data, constructing a second controller corresponding to the dynamic characteristics of the robot by using a policy iteration method; and The driving force of the active wheel is controlled by the second controller so that the robot moves smoothly, wherein the second controller corresponds to the dynamic characteristics in which the variable parameter is a second value.