A robot gait adjustment method, device and robot

By deploying distance measuring sensors on the robot's foot, combining the environmental information of the head vision sensor, and adjusting the gait in real time, the problem of limited topographic map accuracy in traditional gait control is solved, and the robot's obstacle avoidance and smooth movement ability is improved.

CN118642499BActive Publication Date: 2025-02-25HISENSE GRP HLDG CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411116908.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-15
Publication Date
2025-02-25
Estimated Expiration
2044-08-15

AI Technical Summary

Technical Problem

The gait control of traditional robots is limited in the topographic map accuracy due to the installation position, data quality, field of view, coordinate system conversion and alignment of other factors, and the gait control of traditional robots is unable to accurately perceive obstacles on the robot's feet in the environment, which makes it impossible to realize the robot. smooth movement.

Method used

By deploying distance measuring sensors on the robot's foot, the distance between the object in the walking direction and the foot is measured in real time, and combined with the environmental information collected by the head vision sensor, determine whether there is a collision risk. If there is, adjust the foot gait.

Benefits of technology

Accurate planning of gait trajectory is achieved, the robot's obstacle avoidance ability and adaptability are improved, and the robot's smooth movement in different environments is ensured.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118642499B_ABST
    Figure CN118642499B_ABST
Patent Text Reader

Abstract

The present application relates to the field of robot technology, and in particular to a robot gait adjustment method, device and robot, which are used to solve the problem that the traditional means of robot perception of the environment cannot accurately guide the foot to avoid obstacles. The method is: during the robot walking, a distance between an object in the walking direction and the foot is measured by a distance measuring sensor deployed on the foot of the robot; each time a distance is measured, it is determined whether there is a collision risk between the foot and the object based on the distance and environmental information of the robot's environment; if there is a collision risk, the gait of the foot is adjusted based on the current position of the foot, wherein the environmental information is obtained by image recognition of an image collected by a visual sensor deployed on the head of the robot; in this way, the distance measuring sensor deployed on the foot can achieve accurate perception of the environment around the foot, thereby achieving accurate foot obstacle avoidance.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of robot technology, and in particular to a robot gait adjustment method, device and robot. Background Art

[0002] The gait control of traditional robots mostly uses sensors installed on the robot's head to perceive the environment, obtain a topographic map, and control the robot's gait based on the topographic map; however, due to factors such as the installation position of the head sensor, data quality, field of view, coordinate system conversion alignment, etc., the accuracy of the topographic map is limited, resulting in limited perception of the environment. For example, the robot cannot accurately perceive obstacles at the robot's feet in the environment, making it impossible for the robot to avoid obstacles accurately, and thus unable to achieve smooth movement of the robot. Summary of the invention

[0003] The embodiments of the present application provide a robot gait adjustment method, device and robot, which are used to improve the robot's ability to perceive the environment, accurately guide the feet to avoid obstacles, and ensure that the robot can move smoothly.

[0004] The specific technical solutions provided by the embodiments of this application are as follows:

[0005] In a first aspect, an embodiment of the present application provides a gait adjustment method for a robot, comprising:

[0006] During the walking process of the robot, the distance between the object in the walking direction and the foot is measured by a distance measuring sensor deployed on the foot of the robot;

[0007] Whenever a distance is measured, determining whether there is a risk of collision between the foot and the object based on the distance and environmental information of the environment in which the robot is located, wherein the environmental information is obtained by performing image recognition on an image collected by a visual sensor deployed on the head of the robot;

[0008] If there is a risk of collision, the gait of the foot is adjusted based on the current position of the foot.

[0009] The above method provided in the embodiment of the present application, by deploying ranging sensors on the feet of the robot, can detect in real time whether there is a risk of collision between objects in the walking direction and the feet based on the distance measured by the ranging sensors and the environmental information of the environment in which the robot is located, thereby achieving accurate planning of gait trajectory planning, guiding the robot to accurately avoid obstacles with its feet, thereby improving the robot's obstacle avoidance ability. At the same time, the method can dynamically adjust the walking trajectory according to changes in the environment through the ranging sensors, thereby improving the adaptability of the robot in different environments and achieving smooth movement of the robot in different environments.

[0010] In a possible implementation, determining whether there is a collision risk between the foot and the object based on the distance and environmental information of the environment where the robot is located includes:

[0011] If it is determined based on the environmental information that the object is an obstacle in the walking direction of the robot, the distance is compared with a safety threshold, wherein the safety threshold is a reference value for measuring the risk of collision between the object and the foot;

[0012] If the distance is greater than or equal to the safety threshold, it is determined that there is no collision risk between the foot and the object;

[0013] If the distance is smaller than the safety threshold, and the distances measured within a first preset value of consecutive time steps before the measurement time of the distance are smaller than the safety threshold, it is determined that there is a collision risk between the foot and the object.

[0014] In the above method, by setting a safety threshold, it is possible to evaluate in real time whether there is a risk of collision between objects in the walking direction and the feet based on the measured distance. Compared with related technologies, this simplifies the calculation amount of collision assessment and improves the accuracy of foot obstacle avoidance.

[0015] In a possible implementation, the method further includes:

[0016] When it is determined that the distance is greater than the safety threshold, the distance is compared with an energy-saving threshold, wherein the energy-saving threshold is used to measure the movement amplitude of the foot in the walking direction;

[0017] If the distance is greater than the energy-saving threshold, and the distances measured within a second preset value of consecutive time steps before the measurement time of the distance are greater than the energy-saving threshold, then based on the current position of the foot and the next landing position of the foot, a target trajectory is generated; or,

[0018] If the distance is less than the energy-saving threshold, and the distances measured within the third consecutive preset value time steps before the measurement time of the distance are greater than the safety threshold and less than the energy-saving threshold, and the distance measured before the third preset value time steps is less than the safety threshold, then based on the current position of the foot and the next landing position of the foot, a target trajectory is generated.

[0019] In the above method, by setting the energy-saving threshold, the movement amplitude of the foot can be evaluated in real time based on the measured distance, so as to be optimized in time and reduce the extra energy consumption.

[0020] In a possible implementation, adjusting the gait of the foot based on the current position of the foot includes:

[0021] Based on the current position of the foot and the starting position of the next time step of the foot, determining the movement trend of the foot in a reference direction, wherein the reference direction is a preset direction of the landing surface of the foot;

[0022] If the movement trend indicates that the foot moves along the reference direction, the posture of the foot is controlled to be adjusted to a basic posture parallel to the landing surface of the foot, and the foot moves along the reference direction;

[0023] If the movement trend indicates that the foot moves in the opposite direction of the reference direction, the posture of the foot is controlled to be adjusted to the basic posture, and moves in the opposite direction;

[0024] If the movement trend indicates that the foot remains stationary, movement is performed along the current position toward an upper landing position.

[0025] In the above method, when determining that there is a risk of collision between an object in the walking direction and the foot, the movement trend of the foot in the reference direction is determined based on the current position of the foot and the starting position of the next time step, so that the gait is adjusted based on the movement trend, and the foot can be accurately guided to avoid obstacles in time, thereby completing the obstacle avoidance.

[0026] In a possible implementation, the distance measuring sensor includes a first distance measuring module and a second distance measuring module, wherein the first distance measuring module is deployed in the toe area of ​​the foot, and is used to measure a first distance between the toe of the foot and an object in front of the toe; the second distance measuring module is deployed in the heel area of ​​the foot, and is used to measure a second distance between the heel of the foot and an object behind the heel;

[0027] The step of measuring the distance between an object in a walking direction and the foot by using a distance measuring sensor disposed at the foot of the robot comprises:

[0028] If the robot walks forward, a first distance between the object in the walking direction and the foot is measured by the first distance measurement module as the distance;

[0029] If the robot walks backward, the second distance between the object in the walking direction and the foot is measured by the second distance measurement module as the distance.

[0030] In the above method, by deploying corresponding ranging modules on the toes and heels of the feet respectively, the distance between the toes and / or heels and objects around the feet can be accurately measured, thereby achieving precise obstacle avoidance.

[0031] In a possible implementation, the distance measuring sensor further includes a third distance measuring module and a fourth distance measuring module, wherein the third distance measuring module is deployed in the toe area, and is used to measure a third distance between the toe of the foot and an object under the toe; the fourth distance measuring module is deployed in the heel area, and is used to measure a fourth distance between the heel of the foot and an object under the heel;

[0032] The method further comprises:

[0033] Whenever the third distance and the fourth distance are measured, determining whether an absolute value of a difference between the third distance and the fourth distance is less than a stability threshold, wherein the stability threshold is used to measure whether a current landing position of the foot is a stable landing position;

[0034] If yes, determining that the current landing position of the foot is a stable landing position;

[0035] If not, it is determined that the current landing position of the foot is not a stable landing position.

[0036] In the above method, by setting downward ranging modules at the toes and heels of the feet, the distance between the toes and heels of the feet and the foot landing surface (the ground) can be measured in real time, so as to obtain the relationship between the foot and the ground in real time, thereby determining whether the current landing position is a stable landing position, thereby accurately guiding the foot to land steadily, reducing or minimizing the occurrence of falls caused by unstable force when the robot is standing.

[0037] In a possible implementation, the method further includes:

[0038] When it is determined that the current landing position of the foot is not a stable landing position, the posture of the foot is controlled to be adjusted to a basic posture parallel to the landing surface of the foot, and the foot is controlled to translate in a plane parallel to the landing surface of the foot in each preset direction for a fourth preset value of time steps;

[0039] Each time the translation is performed, determining whether the foothold position after the translation is a stable foothold position based on the third distance after the translation measured by the third distance measuring module, the fourth distance after the translation measured by the fourth distance measuring module, and the stability threshold;

[0040] If it is determined that the target landing position after translation is a stable landing position, the target landing position is used to determine the landing position of the foot, and the foot is controlled to perform a landing action for the target landing position;

[0041] If it is determined that there is no stable landing position, the foot is controlled to return to the previous landing position along the original trajectory.

[0042] In the above method, after determining that the current landing position is not a stable landing position, the stability of the landing position is evaluated by moving the feet of the robot and using the distance information measured by the third ranging module and the fourth ranging module after the movement, so as to find a stable landing position for the robot and ensure that the robot can move smoothly.

[0043] In a possible implementation, the foot is further equipped with a torque sensor for measuring the contact torque between the foot and the foot landing surface;

[0044] The method further comprises:

[0045] If it is determined based on the data measured by the torque sensor and the distance sensor that the gait of the foot needs to be adjusted, then a plurality of adjusted target trajectories are respectively obtained;

[0046] Performing feasibility evaluation on each target trajectory respectively to obtain evaluation values ​​corresponding to the multiple target trajectories;

[0047] A target trajectory corresponding to a target evaluation value selected from the evaluation values ​​corresponding to the multiple target trajectories is determined as a final trajectory.

[0048] In the above method, when it is determined that gait adjustment is required based on multiple data, the optimal target trajectory is selected from the target trajectories corresponding to the multiple data through feasibility evaluation, and the selected target trajectory is determined as the final trajectory, which further ensures that the robot can accurately avoid obstacles and move smoothly.

[0049] In a second aspect, an embodiment of the present application provides a gait adjustment device for a robot, comprising:

[0050] A measuring module, used to measure the distance between an object in the walking direction and the foot by using a distance measuring sensor deployed on the foot of the robot during the walking process of the robot;

[0051] a determination module, configured to determine, each time a distance is measured, whether there is a risk of collision between the foot and the object based on the distance and environmental information of the environment in which the robot is located, wherein the environmental information is obtained by performing image recognition on an image collected by a visual sensor deployed on the head of the robot;

[0052] The gait adjustment module is used to adjust the gait of the foot based on the current position of the foot if there is a risk of collision.

[0053] In a third aspect, an embodiment of the present application provides a robot, comprising:

[0054] A distance measuring sensor, deployed at the foot of the robot, for measuring the distance between an object in the walking direction and the foot;

[0055] A visual sensor, deployed on the head of the robot, for collecting images of the environment in which the robot is located;

[0056] Memory, used to store computer programs or instructions;

[0057] A processor is used to execute the computer program or instructions in the memory so that any method in the first aspect described above is executed.

[0058] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium. When instructions in the storage medium are executed by a processor, the processor is enabled to execute any one of the methods described in the first aspect above.

[0059] In a fifth aspect, an embodiment of the present application provides a computer program product, which includes: a computer program code, when the computer program code is run on a computer, enables the computer to execute the method as described in any one of the first aspects. BRIEF DESCRIPTION OF THE DRAWINGS

[0060] Figure 1 A schematic flow chart of a gait adjustment method for a robot in an embodiment of the present application;

[0061] Figure 2 This is a schematic diagram of the deployment structure of a distance measuring sensor in a robot in an embodiment of the present application;

[0062] Figure 3 A schematic diagram of a process for determining whether there is a collision risk in an embodiment of the present application;

[0063] Figure 4 A schematic diagram of an analysis process for determining whether there is a collision risk in an embodiment of the present application;

[0064] Figure 5 A schematic diagram of a process of generating a target trajectory in an embodiment of the present application;

[0065] Figure 6 This is a schematic diagram of a process of adjusting the trajectory when the motion amplitude is too large in an embodiment of the present application;

[0066] Figure 7 A schematic diagram of a gait adjustment process in an embodiment of the present application;

[0067] Figure 8 A schematic diagram of a gait adjustment process in an embodiment of the present application;

[0068] Fig. 9 This is a schematic diagram of a partial trajectory after adjustment in an embodiment of the present application;

[0069] Fig.10 This is a schematic diagram of a complete trajectory after adjustment in an embodiment of the present application;

[0070] Fig.11 A schematic diagram of the deployment structure of another distance measuring sensor in an embodiment of the present application;

[0071] Fig.12 This is a schematic diagram of the structure of a toe distance measurement sensor in an embodiment of the present application;

[0072] Fig.13 A schematic diagram of a stable footing position and an unstable footing position in an embodiment of the present application;

[0073] Fig.14 A schematic diagram of a process for determining a final trajectory in an embodiment of the present application;

[0074] Fig.15 A schematic diagram of the logical architecture of a gait adjustment device of a robot in an embodiment of the present application;

[0075] Fig.16 Schematic diagram of the physical structure of the robot in the embodiment of the present application. DETAILED DESCRIPTION

[0076] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0077] It should be noted that the terms "first", "second", "third", etc. in the specification and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the numbers used in this way can be interchanged where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein.

[0078] Below, some terms in the embodiments of the present application are explained to facilitate understanding by those skilled in the art.

[0079] (1) The term "gait" in the embodiments of the present application refers to the movement process of each leg of the robot in a certain order and trajectory, which is an important factor in ensuring the stable operation of the walking mechanism. Gait control is a control method that makes the robot move according to the planned gait.

[0080] (2) The term "Hybrid Zero Dynamics (HZD)" in the embodiments of the present application refers to a method based on nonlinear control theory that can generate stable and continuous gaits. The generation of a gait set based on HZD (such as a gait library) is a commonly used gait planning method. Its basic principle is to perform an appropriate coordinate transformation on the dynamic model of the robot and decompose it into two mutually coupled subsystems: a zero-momentum subsystem and a hybrid power subsystem. The zero-momentum subsystem describes the motion behavior of the robot under ideal conditions (i.e., without external disturbances and friction), and the hybrid power subsystem describes the motion behavior of the robot under actual conditions (i.e., with external disturbances and friction). The dynamic model describes the motion law of the robot, including the effects of force, mass, inertia and other factors on the robot's motion. The kinematic model describes the geometric motion law of the robot, including the relationship between motion parameters such as position, velocity, and acceleration. In the subsequent content of this application, only HZD is used as an example to introduce the gait set generated based on HZD. Of course, other methods can also be used in the relevant technology to obtain the gait set, which includes gaits at different motion stages under a motion mode.

[0081] The following is a brief introduction to the design concept of the embodiments of the present application.

[0082] The present application relates to the field of robot technology, and mainly to a robot gait adjustment method, device and robot.

[0083] Traditional robot gait control mostly uses visual sensors installed on the robot's head to perceive the environment, obtain a terrain map, and control / adjust the robot's gait based on the terrain map; for obstacle avoidance related technologies, the environment terrain map is constructed through visual or radar data obtained by the visual sensor on the head. After the robot's world coordinate system is aligned with the world coordinate system of the terrain map, collision detection is first performed, such as the Fast Collision Library (FCL), Bullet, and the Open Motion Planning Library (OMPL) to detect whether the robot's trajectory will collide with objects in the environment. Then, motion planning algorithms such as Rapidly-exploring Random Tree (RRT), Probabilistic Roadmaps (PRM), Covariant Hamiltonian Optimization (CHOMP), and Stochastic Trajectory Optimization (STOMP) are used to generate trajectories that avoid obstacles.

[0084] Due to factors such as friction in the real world, motor performance limitations, environmental interference, and control module errors, there is bound to be a gap between the actual gait trajectory and the ideal gait trajectory. This requires timely adjustment of the gait trajectory planning so that it can guide the robot's movement and avoid losses such as robot falls caused by error accumulation. However, regarding the construction of the terrain map, due to factors such as the installation position of the head-mounted visual sensor, data quality, field of view, algorithm accuracy, and coordinate system conversion alignment, the accuracy of the terrain map is limited, resulting in limited perception of the environment and inability to accurately perceive obstacles on the robot's feet in the environment, making it impossible to fully and accurately guide the foot to avoid obstacles, and thus unable to achieve smooth movement of the robot.

[0085] In view of this, in order to solve the problem that the robot's traditional means of perceiving the environment cannot accurately guide the robot to avoid obstacles with its feet, an embodiment of the present application provides a robot's gait adjustment method. In the embodiment of the present application, during the robot's walking, a distance between an object in the walking direction and the foot is measured by a ranging sensor deployed on the robot's foot; each time a distance is measured, it is determined whether there is a collision risk between the foot and the object based on the distance and environmental information of the robot's environment, wherein the environmental information is obtained by performing image recognition on images collected by a visual sensor deployed on the robot's head; if so, the gait of the foot is adjusted based on the current position of the foot.

[0086] In this way, by deploying ranging sensors on the feet of the robot, it is possible to detect in real time whether there is a risk of collision between objects in the walking direction and the feet based on the distance measured by the ranging sensors and the environmental information of the robot's environment, thereby achieving accurate planning of gait trajectory planning and guiding the robot to accurately avoid obstacles with its feet, thereby improving the robot's obstacle avoidance ability. At the same time, this method can dynamically adjust the walking trajectory according to changes in the environment through the ranging sensors, thereby improving the robot's adaptability in different environments and achieving smooth movement of the robot in different environments.

[0087] A robot gait adjustment method in an embodiment of the present application is applicable to robots, for example, robots, multi-legged robots, bionic humans, bipedal robots, humanoid robots, mobile robots, etc.

[0088] In some embodiments of the present application, the robot may include a ranging sensor deployed on the foot of the robot, which is used to measure the distance between an object in the walking direction and the foot. The robot can use a gait adjustment method of a robot in an embodiment of the present application to adjust the gait of the robot during walking, so that the robot can accurately sense obstacles with a risk of collision around the foot, and when it is identified that there is a risk of collision between an object in the walking direction and the foot, the robot can adjust the gait in time, thereby accurately guiding the robot to avoid obstacles with its feet, so that the robot can move and walk smoothly.

[0089] In the related art, a robot usually uses a visual sensor deployed on its head to collect images of the robot's environment, and constructs a topographic map of the environment based on the collected images to perceive the robot's environment; in the embodiment of the present application, on the basis of perceiving the environment through visual sensors, by using ranging sensors deployed on the feet, the robot can timely and accurately perceive the distance information between the feet and objects around the feet, thereby more accurately guiding the robot to avoid obstacles with its feet, and avoiding the problem of limited accuracy of the topographic map and inability to fully and accurately guide the feet to avoid obstacles due to factors such as the data quality of the visual sensor on the head, the field of view, the algorithm accuracy, and the alignment of the coordinate system conversion.

[0090] The preferred implementation modes of the present application are further described in detail below in conjunction with the accompanying drawings. It should be understood that the preferred embodiments described herein are only used to illustrate and explain the present application, and are not used to limit the present application, and the embodiments of the present application and the features in the embodiments may be combined with each other if there is no conflict.

[0091] See also Figure 1 As shown, the embodiment of the present application provides a gait adjustment method for a robot, and the specific process of the method may include but is not limited to the following steps:

[0092] Step 100: During the walking process of the robot, the distance between the object in the walking direction and the foot is measured by a distance measuring sensor deployed on the foot of the robot.

[0093] In some embodiments of the present application, the above-mentioned ranging sensors may include but are not limited to infrared ranging sensors, laser ranging sensors, ultrasonic ranging sensors, microwave ranging sensors, photoelectric ranging sensors, radar ranging sensors, electromagnetic wave ranging sensors, depth cameras, etc., which are used to assist the robot in walking in the environment where the robot is located, reducing the probability of the robot being tripped or damaged by bumps, especially in complex environments, which can greatly reduce the probability of the robot being tripped or damaged by bumps.

[0094] Optionally, the distance measuring sensor can have a higher accuracy for distances within 0.5 meters.

[0095] Taking a biped robot as an example, each foot of the biped robot 10 is equipped with a ranging sensor. Taking one foot of the biped robot 10 as an example, Figure 2 In the foot A, the distance measuring sensor deployed on the foot A may include a first distance measuring module 101 and a second distance measuring module 102, wherein the first distance measuring module 101 is deployed in the toe area of ​​the foot A, and is used to measure a first distance between the toe of the foot A and an object in front of the toe; the second distance measuring module 102 is deployed in the heel area of ​​the foot A, and is used to measure a second distance between the heel of the foot A and an object behind the heel.

[0096] Then, when executing step 100, if the robot walks forward, the first distance between the object in the walking direction and the foot is measured by the first ranging module as the distance between the object in the walking direction and the foot; if the robot walks backward, the second distance between the object in the walking direction and the foot is measured by the second ranging module as the distance between the object in the walking direction and the foot.

[0097] Step 110: Every time a distance is measured, it is determined whether there is a collision risk between the foot and the object based on the distance and the environmental information of the robot's environment, wherein the environmental information is obtained by performing image recognition on images collected by a visual sensor deployed on the head of the robot. If yes, that is, there is a collision risk, then step 120 is executed; if no, that is, there is no collision risk, then the process ends.

[0098] In some embodiments of the present application, when executing step 110, each time a distance between an object in the walking direction and the foot is measured, refer to Figure 3 As shown, the specific executable includes but is not limited to the following:

[0099] Step 1101: If it is determined based on the environmental information that the object is an obstacle in the walking direction of the robot, the distance is compared with the safety threshold.

[0100] In some embodiments of the present application, before executing step 1101, it is determined based on environmental information whether the object in the walking direction of the robot's environment is an obstacle, wherein the environmental information includes terrain information of the robot's environment. Then, it can be determined based on the terrain information whether the object is an obstacle, such as if the object is higher than the ground and the distance from the foot is less than a threshold.

[0101] If it is determined that the object is an obstacle in the walking direction of the robot, then when executing step 1101, the measured distance is compared with the safety threshold K1. If the distance is greater than or equal to the safety threshold K1, step 1102 is executed. If the distance is less than the safety threshold K1, it is necessary to further determine whether the distances measured in the first consecutive preset value time steps before the measurement time of the distance are all less than the safety threshold K1. If so, step 1103 is executed. If not, the information that the distance measured this time is less than the safety threshold K1 is recorded, such as setting a counter, adding one to the value of the counter, and the counter is cleared when the first preset value is reached, wherein the safety threshold K1 is a reference value for measuring the risk of collision between the object and the foot.

[0102] Usually, the robot perceives the terrain of the environment through the visual sensor deployed on the head, and then plans the robot's gait based on the received task and terrain to guide the robot to walk. In the related art, there are many methods for gait planning, such as bionics method, intelligent learning algorithm, model simplification, etc., which are not specifically limited in this application.

[0103] For the bionics method, this method imitates human walking motion data, records human walking motion data, and then corrects it to make it more suitable for the driving method, mass distribution, mechanical structure, etc. of the humanoid robot. Based on the corrected data, the robot's gait planning is obtained to guide the robot's walking.

[0104] For intelligent learning algorithms, this method includes reinforcement learning and other methods, which obtain the optimal control strategy through continuous sampling (trial and error). For example, in deep reinforcement learning, the strategy is replaced by a neural network to obtain the mapping relationship between the robot state and action, thereby guiding the robot to walk based on the mapping relationship.

[0105] Regarding the model simplification method, a commonly used gait planning method is the HZD method. Under the HZD framework, the goal of gait planning is to find a set of control inputs that enables the robot to generate different dynamic models for different gaits such as walking, climbing stairs, descending stairs, backflips, running, and jumping under a zero-momentum subsystem. Taking the walking of a bipedal robot as an example, the nonlinear control theory is used to divide the walking of the bipedal robot into a single-foot support stage and a double-foot switching stage. The single-foot support stage can be described by Lagrangian dynamics, and the double-foot switching can be regarded as a rigid body impact, causing a sudden change in the robot's speed.

[0106] Specifically, a gait set can be generated in the following ways: 1. Design virtual constraints: virtual constraints can be a set of equations that describe the desired motion behavior of the robot. In the HZD framework, virtual constraints can usually be functions of the robot's joint angles and joint angular velocities, that is, joint limits and speed limits contained in the humanoid robot model file. 2. Solve optimization problems: By solving a set of nonlinear optimization problems, find a set of control inputs so that the motion trajectory of each joint of the robot can satisfy the virtual constraints and conform to the kinematic model of the dynamic model of the current gait at the current stage. 3. Generate gait samples: Generate gait samples by numerical simulation, recorded as basic gait samples. 4. Store gait samples: Store the generated gait samples in a gait set. In this way, a gait set for guiding the robot to walk is obtained, and the gait set includes multiple basic gait samples, each basic gait sample includes gaits at different motion stages in a motion mode. In some embodiments of the present application, a basic gait sample can be selected from the gait set based on the current posture of the robot obtained, and the selected basic gait sample can be used to guide the robot to walk in the future.

[0107] Take the robot climbing stairs as an example. Assume that the trajectory based on gait planning is Figure 4 The trajectory A shown, where the obstacle is a step, is determined based on environmental information. The trajectory A can be decomposed into multiple key points according to a preset time step. For example, if the time step T is 0.1s, then the trajectory A is decomposed according to 0.1s. Assuming that 20 key points can be obtained, they are recorded as 1, 2, 3, ..., 20 respectively.

[0108] Assume that the currently measured distance corresponds to the distance between the position A of the foot between key points 6 and 7 in the trajectory and the step, such as Figure 4 As shown, then, when it is determined that the measured distance is less than the safety threshold K1, it is further determined whether the distances measured in the first preset value time steps before the measurement time of the distance are all less than the safety threshold K1, where it is assumed that the first preset value is 3, then, Figure 4 As shown, it is determined whether the distances between the object and the foot of the robot in the walking direction measured in three consecutive time steps before the measurement time are all less than the safety threshold K1, where K1 can be 5 cm.

[0109] Step 1102: If the distance is greater than or equal to the safety threshold, it is determined that there is no collision risk between the foot and the object.

[0110] In some embodiments of the present application, after executing step 1101 and determining that the distance is greater than or equal to the safety threshold K1, if the distance is greater than the safety threshold, then refer to Figure 5As shown, the following steps can also be performed to measure whether the foot has a possibility of excessive movement:

[0111] Step 500: When it is determined that the distance is greater than the safety threshold, the distance is compared with an energy-saving threshold, wherein the energy-saving threshold is used to measure the movement amplitude of the foot in the walking direction.

[0112] In the present application, the safety threshold K1 is less than the energy-saving threshold K2. Then, after executing step 1101 to determine that the distance is greater than the safety threshold K1, the distance is further compared with the energy-saving threshold K2 to determine whether the movement amplitude of the foot is too large. Since the movement amplitude is too large, the energy consumption increases, which also causes the robot's walking speed to decrease. Therefore, the robot's gait needs to be adjusted in time when the movement amplitude is too large.

[0113] In some embodiments of the present application, when executing step 500, if it is determined that the distance is greater than the energy-saving threshold K2, it is further determined whether the distances measured within a second consecutive preset value of time steps before the measurement time of the distance are all greater than the energy-saving threshold K2. If so, step 510 is executed. If not, the information that the distance measured this time is less than the energy-saving threshold K2 is also recorded, such as setting a counter, adding one to the value of the counter, and the counter is cleared when the second preset value is reached.

[0114] If it is determined that the distance is less than or equal to the energy-saving threshold K2, and the gait has not been adjusted before the determination, that is, the distance measured before the measurement time of the distance is greater than the safety threshold and less than or equal to the energy-saving threshold, then it means that the movement amplitude of the foot is reasonable and there is no need to adjust the gait of the foot. Therefore, there is no need to intervene again and the process can be ended. At this time, the robot still moves according to the original trajectory.

[0115] Step 510: If the distance is greater than the energy-saving threshold, and the distances measured within a second preset value of time steps before the measurement time of the distance are all greater than the energy-saving threshold, then a target trajectory is generated based on the current position of the foot and the next landing position of the foot.

[0116] In some embodiments of the present application, when executing step 510, the coordinates of the visual sensor deployed on the robot head in the world coordinate system are determined by Simultaneous Localization and Mapping (SLAM), and then the coordinates of the foot in the world coordinate system are calculated according to the structure of the robot, that is, the current position of the foot is obtained; the next landing position of the foot is obtained from the original trajectory of the foot, and based on the current position and the next landing position of the foot, a preset trajectory optimization method is used to perform smooth trajectory planning, so that the trajectory from the current position of the foot to the next landing position can be planned, and the planned trajectory is determined as the target trajectory.

[0117] In some embodiments of the present application, the above-mentioned trajectory optimization method includes methods such as cycloid trajectory, polynomial curve, spline curve or Bezier curve, and the present application does not specifically limit this.

[0118] For example, let's take the example of a robot climbing stairs. Figure 6 As shown, assuming that the original trajectory planned by the gait is trajectory B, then, refer to Figure 6 As shown, it is assumed that the currently measured distance corresponds to the distance between the position B of the foot located between key point 4 and key point 5 in the original trajectory and the step. Then, when it is determined that the measured distance is greater than the energy-saving threshold K2, it is further determined whether the distances measured in the second preset value time steps before the measurement time of the distance are all greater than the energy-saving threshold K2, wherein, assuming that the second preset value is 3, then, if Figure 6 As shown, it is determined whether the distances between the object and the foot of the robot in the walking direction measured in three consecutive time steps before the measurement time of the distance are all greater than the energy-saving threshold K2.

[0119] Assuming that the distances measured in the three consecutive time steps before the measurement time of the distance are all greater than the energy-saving threshold K2, the coordinates of the visual sensor deployed on the robot head in the world coordinate system are determined by SLAM, and then the coordinates of the foot in the world coordinate system are calculated according to the structure of the robot, that is, the current position of the foot at the measurement time, such as Figure 6 The position 1 shown (ignoring the robot's running error, the robot walks along the original trajectory at this time, which coincides with position B), obtains the next landing position of the foot in the original trajectory, that is, Figure 6 Position 2 shown in the figure, position 1 (position B) and position 2 are brought into the preset trajectory optimization curve for smooth trajectory planning, and then we can get Figure 7 The target trajectory is shown by the dotted line in . Figure 6It can be seen that by comparing the original trajectory with the newly planned target trajectory, it can be seen that the movement amplitude of the foot in the newly planned target trajectory is reduced, which reduces the additional energy consumption. Among them, the trajectory optimization curve can be part or all of the aforementioned cycloid trajectory curve, polynomial curve, spline curve or Bezier curve.

[0120] Step 520: If the distance is less than the energy-saving threshold, and the distances measured within the third consecutive preset value time steps before the measurement time of the distance are greater than the safety threshold and less than the energy-saving threshold, and the distance measured before the third preset value time steps is less than the safety threshold, then based on the current position of the foot and the next landing position of the foot, a target trajectory is generated.

[0121] For details of the specific generation of the target trajectory in step 520, please refer to the description of the aforementioned step 510, which will not be repeated here.

[0122] Step 1103: If the distance is smaller than the safety threshold, and the distances measured within a first preset value of consecutive time steps before the measurement time of the distance are smaller than the safety threshold, it is determined that there is a collision risk between the foot and the object.

[0123] In some embodiments of the present application, in order to avoid a moving object suddenly flying in the walking direction during the walking process of the robot, causing the briefly measured distance to be less than the safety threshold K1, the distances measured within a first preset value of consecutive time steps are set to be less than the safety threshold K1 before determining that there is a risk of collision between the foot and the object.

[0124] Step 120: Based on the current position of the foot, adjust the gait of the foot.

[0125] In some embodiments of the present application, if step 110 is executed and it is determined that there is a risk of collision between the foot and the object, step 120 is executed to adjust the gait of the foot to achieve obstacle avoidance.

[0126] In some embodiments of this application, refer to Figure 7 As shown, when executing step 120, the following steps may be specifically performed:

[0127] Step 700: Based on the current position of the foot and the starting position of the next time step of the foot, determine the movement trend of the foot in a reference direction, wherein the reference direction is a preset direction of the landing surface of the foot.

[0128] For example, assuming that the original trajectory is Figure 4 The trajectory A shown in Figure 1 is shown in Figure 1. Taking the robot climbing stairs as an example, Figure 8As shown, assuming that the currently measured distance corresponds to the distance between the position of the foot between key point 7 and key point 8 in the original trajectory and the step, and that the distances measured in the first consecutive preset value time steps before the measurement time of the distance are all less than the safety threshold K1, then it is determined that there is a risk of collision between the foot and the object, i.e., the step, and step 700 is executed.

[0129] See also Figure 8 As shown, when executing step 700, the coordinates of the visual sensor deployed on the robot head in the world coordinate system are determined through SLAM, and then the coordinates of the foot in the world coordinate system are calculated according to the structure of the robot, that is, the current position of the foot, recorded as position a, and the starting position of the next time step is obtained from the original trajectory of the foot, recorded as position b, and then, based on position a and position b, the movement trend of the foot in the reference direction is determined, wherein the reference direction is the preset direction of the foot landing surface of the foot.

[0130] As a specific embodiment, based on position a and position b, an ideal vector between two points is obtained. . Project the vector onto each coordinate axis (x-axis, y-axis, z-axis) in the world coordinate system to obtain the component on each coordinate axis ;So, The specific value of can represent the movement trend of the foot in the reference direction (i.e. the positive direction of the z-axis).

[0131] Step 710: If the movement trend indicates that the foot moves along the reference direction, the posture of the foot is controlled to be adjusted to a basic posture parallel to the landing surface of the foot, and moves along the reference direction.

[0132] Still taking the example of the robot climbing stairs, see Figure 8 As shown, if If it is greater than 0, it means that the movement trend of the foot is to move along the reference direction (i.e., the positive direction of the z-axis). Then, step 710 is executed to control the posture of the foot to be adjusted to the basic posture parallel to the plane of z=0, and move along the reference direction (i.e., the positive direction of the z-axis). The corresponding trajectory is as follows: Fig. 9 Trajectory 1 is shown.

[0133] Step 720: If the movement trend indicates that the foot moves in the opposite direction of the reference direction, the posture of the foot is controlled to be adjusted to the basic posture, and moves in the opposite direction.

[0134] For example, assuming that If it is less than 0, it means that the movement trend of the foot is to move along the reference direction (i.e., the negative direction of the z-axis). Then, execute step 720 to control the posture of the foot to be adjusted to the basic posture parallel to the plane of z=0, and move in the opposite direction of the reference direction, i.e., the negative direction of the z-axis.

[0135] Step 730: If the movement trend indicates that the foot remains stationary, move along the current position to an upper landing position.

[0136] For example, assuming that =0, it means that the movement trend of the foot indicates that the foot remains stationary, that is, the foot moves in a plane parallel to z=0, then, step 730 is executed to move along the current position to an upward landing position.

[0137] In an embodiment of the present application, after the gait of the foot is adjusted according to any one of the adjustment methods in steps 710 to 730, the distance between the object in the walking direction and the foot is continuously measured. After determining that the distance within the third consecutive preset value time steps is greater than the safety threshold K1, that is, the distance is less than the energy-saving threshold, and the distance measured within the third consecutive preset value time steps before the measurement time of the distance is greater than the safety threshold and less than the energy-saving threshold, and the distance measured before the third preset value time steps is less than the safety threshold, a target trajectory is generated according to the position of the foot at this time and the next landing position of the foot.

[0138] For example, still Figure 8 Assume that the currently measured distance corresponds to the distance between the position of the foot between key point 7 and key point 8 in the original trajectory and the step. After the gait adjustment is performed using the adjustment method of step 710, if it is determined that the distance measured in the third consecutive preset value time step is greater than the safety threshold K1, then based on the position of the foot at this time, recorded as position c, and the next landing position of the foot in the original trajectory, recorded as position d, a smooth trajectory planning is performed using a cycloid trajectory curve, a polynomial curve, a spline curve, a Bezier curve, etc., so as to obtain Fig.10 The trajectory 2 shown is combined with the trajectory adjusted based on the execution step 710 in the previous step, and the adjusted complete trajectory is as follows Fig.10 (Trace 1 + Trace 2) is shown.

[0139] In some embodiments of the present application, the distance measuring sensor deployed on the foot of the robot may also include a third distance measuring module and a fourth distance measuring module, wherein the third distance measuring module is deployed in the toe area of ​​the robot to measure the third distance between the toe of the foot and the object under the toe; the fourth distance measuring module is deployed in the heel area of ​​the robot to measure the fourth distance between the heel of the foot and the object under the heel. For example, still taking the foot A of the bipedal robot as an example, Fig.11 As shown, a third distance measurement module 103 may be deployed in the toe area of ​​the foot A, and a fourth distance measurement module 104 may be deployed in the heel area of ​​the foot A.

[0140] As a specific embodiment, the first distance measuring module 101 and the third distance measuring module 103 deployed in the toe area can be integrated to obtain a toe distance measuring sensor, such as Fig.12 As shown, it is used to measure the distance between the objects in front of and below the toes and the toes. Fig.12 The chip shown is used to transmit the measured distance to the processor of the robot. After receiving the data transmitted by the chip, the specific processor can obtain the distance between the foot and the object in front, and the distance to the object below based on a predefined order, such as the distance to the object in front is ranked before the distance to the object below; accordingly, the second ranging module and the fourth ranging module deployed in the heel area can also be integrated to obtain a heel ranging sensor, which is used to measure the distance between the heel and objects behind and below the heel.

[0141] In some embodiments of the present application, each time the third distance and the fourth distance are measured, it is determined whether the absolute value of the difference between the third distance and the fourth distance is less than a stable threshold value K3, wherein the stable threshold value K3 is used to measure whether the current landing position of the foot is a stable landing position; if so, it is determined that the current landing position of the foot is a stable landing position; if not, it is determined that the current landing position of the foot is not a stable landing position.

[0142] Optionally, the stability threshold K3 can be specifically set according to factors such as the structure of the robot, the position of the center of gravity, the length of the foot, the landing angle, etc., to ensure that the contact area between the foot and the ground can balance the force of the robot when it stands and prevent it from falling.

[0143] like Fig.13 As shown, Fig.13 Schematic diagram showing a stable footing position and two unstable footing positions. Fig.13 (a) shows that the foot is parallel to the ground and can be completely on the ground. At this time, the absolute value of the difference between the third distance h1 and the fourth distance h2 measured by the third distance measurement module and the fourth distance measurement module is =0<stable threshold K3, therefore, this landing position is a stable landing position; Fig.13(b) and (c) show that there are steps on the ground. The front part of the foot is projected on one step, and the rear part of the foot is projected on another step. If the robot lands at this landing position, the robot will be unstable and fall down. Therefore, this landing position is not a stable landing position.

[0144] In some embodiments of the present application, when it is determined that the current landing position of the foot is not a stable landing position, the posture of the foot can be controlled to be adjusted to a basic posture parallel to the landing surface of the foot, and the foot is controlled to be translated in a plane parallel to the landing surface of the foot for a fourth preset value of time steps in each preset direction to find a stable landing position. Each time the foot is translated, it is determined whether the landing position after translation is a stable landing position based on the third distance measured by the third distance measurement module after translation, the fourth distance measured by the fourth distance measurement module, and the stability threshold K3; if it is determined that the target landing position after translation is a stable landing position, the landing position of the foot is determined as the target landing position, and the foot is controlled to perform a landing action for the target landing position; if it is determined that there is no stable landing position, the foot is controlled to return to the previous landing position according to the original trajectory.

[0145] Specifically, you can move forward, backward, left, and right in sequence for a fourth preset value (such as 3) time steps, rotate 45° to the left front, 45° to the right front, etc., to find a stable landing position. In a specific implementation, a world coordinate system of the foot is established, in which the x-axis is defined as right, the y-axis is defined as forward, and the z-axis is defined as upward. The forward direction can be represented by a vector (0, 1, 0), the backward direction is represented by a vector (0, -1, 0), the right direction can be represented by a vector (1, 0, 0), and the left direction is a vector (-1, 0, 0). The rotation matrix for rotating 45° to the left front is [[cos(45°), -sin(45°), 0], [sin(45°), cos(45°), 0], [0, 0, 1]], and the rotation matrix for rotating 45° to the right front is [[cos(45°), -sin(45°), 0], [sin(45°), cos(45°), 0], [0, 0, 1]] The rotation matrix for a 45° rotation is [[cos(45°), sin(45°), 0], [-sin(45°), cos(45°), 0], [0, 0, 1]]. The foot is controlled to move according to the aforementioned vectors. Each time it moves, a third distance is measured by the third ranging module, and a fourth distance is measured by the fourth ranging module. Based on the third distance, the fourth distance and the stability threshold K3, the foot position after translation is evaluated to determine whether it is a stable foot position, so as to try to find a stable foot position.

[0146] In some embodiments of the present application, the robot's foot is also equipped with a torque sensor for measuring the contact torque between the foot and the foot landing surface; see Fig.14As shown, the following steps may be performed, including but not limited to, to select a target trajectory from multiple target trajectories as the final trajectory through feasibility evaluation:

[0147] Step 1400: If it is determined based on the data measured by the torque sensor and the distance sensor that the gait of the foot needs to be adjusted, a plurality of adjusted target trajectories are obtained respectively.

[0148] The robot is deployed with a variety of sensors, such as the aforementioned torque sensor, ranging sensors (such as the first ranging module, the second ranging module, the third ranging module and the fourth ranging module), etc. Among the data measured by these measuring devices, only one data may need to be adjusted after evaluation of the ideal trajectory, or multiple data may need to be adjusted after evaluation. In this case, the target trajectory adjusted based on each type of data is obtained separately, such as the target trajectory obtained based on the ranging sensor mentioned above.

[0149] In some embodiments of the present application, if there are three types of data for trajectory optimization, there are a total of seven target trajectories that need to be evaluated, which are respectively recorded as: T(a), T(b), T(c), trajectory T(d) obtained by spline interpolation of T(a) and T(b), trajectory T(e) obtained by spline interpolation of T(c) and T(c), trajectory T(f) obtained by spline interpolation of T(c) and T(c), and trajectory T(g) obtained by spline interpolation of T(d) and T(c), among which T(a), T(b), and T(c) are the target trajectories obtained by trajectory optimization based on any sensor, respectively.

[0150] Step 1410: Perform feasibility evaluation on each target trajectory respectively to obtain evaluation values ​​corresponding to multiple target trajectories.

[0151] In some embodiments of the present application, a feasibility evaluation is set to evaluate the feasibility and quality of the robot's gait trajectory, so as to select an optimal trajectory from multiple target trajectories.

[0152] Optionally, in some embodiments of the present application, a feasibility function may be used to implement a feasibility assessment of each target trajectory. The feasibility function may include factors such as the deviation between the new trajectory and the original trajectory, the smoothness of the control input trajectory, the balance of the body posture, the joint limit, and the stability of the center of gravity (COG) trajectory. Optionally, the following formula may be used in the present application to represent the feasibility function:

[0153] in, is the feasibility function;

[0154] is the deviation between the new trajectory (each of the aforementioned target trajectories) and the original trajectory, that is, the trajectory similarity. Optionally, in this application, methods such as Dynamic Time Warping (DTW) or Long Short-Term Memory (LSTM) can be used to calculate;

[0155] To control the smoothness of the input trajectory, the acceleration and curvature of the trajectory are calculated. The greater the acceleration change and the greater the curvature, the lower the trajectory smoothness;

[0156] The balance of body posture can be determined by whether the center of gravity projection is in a reasonable range (for example, for a bipedal robot, the reasonable area is the bipedal area);

[0157] For joint limit, in this application, the inverse kinematics equation can be used to calculate the value of each joint angle variable at this moment according to the foot posture to see whether it meets the joint limit range;

[0158] For center of mass (COG) trajectory stability, in this application, it can be calculated by the height change of the center of mass;

[0159] is the evaluation value.

[0160] Optionally, in this application, you can first Each is normalized to the range of 0-1, and then the evaluation value of each target trajectory is obtained by weighted average. ; Such as the evaluation values ​​of the 7 target trajectories mentioned above.

[0161] It should be noted that the setting of the feasibility function may include various forms. The above-mentioned feasibility function in this application is only an example and is not specifically limited in this application.

[0162] Step 1420: Determine the target trajectory corresponding to the target evaluation value selected from the evaluation values ​​corresponding to the multiple target trajectories as the final trajectory.

[0163] In some embodiments of the present application, after executing step 1410 to obtain the evaluation value of each target trajectory, the target trajectory corresponding to the maximum value of each evaluation value is determined as the final trajectory of the foot, and the foot is controlled to move according to the final trajectory to accurately guide the foot to avoid obstacles perfectly and enable the robot to land stably and move smoothly.

[0164] In some embodiments of the present application, after obtaining the adjusted trajectory, each joint of the robot is controlled to move precisely to achieve a predetermined gait. Gait control needs to consider the parameters of the robot's own hardware, as well as the drive mode and control algorithm of each joint. After obtaining the position and posture of the robot's foot at a certain moment, the inverse kinematics equation is used to directly calculate the value of each joint angle variable at this moment. Then, according to the current state of the robot (such as joint angle, speed, etc.) and the expected trajectory (such as the expected foot position, walking speed, etc.), the required joint torque and motor control instructions are calculated to drive the robot to walk according to the planned gait. Inside the control system, a self-feedback system is required to accurately control the motor.

[0165] In actual implementation, the robot walks under the guidance of multiple control instructions, which are usually one or more control input sequences, used to issue commands to the joints of the robot so that the joints can cooperate to complete the desired action, thereby completing the task assigned to the robot by the user. Specifically, the first control input in the obtained control input sequence is applied to the robot, and then the actual response of the robot is observed, such as the current state data of each joint of the robot (angle, angular velocity), the magnitude and direction of the ground contact force (contact torque) obtained by the torque sensor, and the distance data obtained by the ranging sensor. Based on these data, the gait is adjusted and optimized. Optionally, the feedback frequency of the data can be 10hz. At the next control moment, the control input sequence updated according to the current state of the robot is executed, such as the control input sequence corresponding to the aforementioned target trajectory or final trajectory; thus, by continuously repeating the above process, the gait of the robot can be generated and adjusted in real time.

[0166] Based on the same inventive concept, refer to Fig.15 As shown, in an embodiment of the present application, a gait adjustment device for a robot is provided, comprising:

[0167] The measuring module 1510 is used to measure the distance between an object in the walking direction and the foot by using a distance measuring sensor disposed on the foot of the robot during the walking process of the robot;

[0168] a determination module 1520, configured to determine, each time a distance is measured, whether there is a collision risk between the foot and the object based on the distance and environmental information of the environment in which the robot is located, wherein the environmental information is obtained by performing image recognition on an image collected by a visual sensor deployed on the head of the robot;

[0169] The gait adjustment module 1530 is used to adjust the gait of the foot based on the current position of the foot if there is a risk of collision.

[0170] In a possible implementation, the determining module 1520 is specifically configured to:

[0171] If it is determined based on the environmental information that the object is an obstacle in the walking direction of the robot, the distance is compared with the safety threshold, wherein the safety threshold is a reference value for measuring the risk of collision between the object and the foot;

[0172] If the distance is greater than or equal to the safety threshold, it is determined that there is no collision risk between the foot and the object;

[0173] If the distance is smaller than the safety threshold, and the distances measured within a first preset value of consecutive time steps before the measurement time of the distance are smaller than the safety threshold, it is determined that there is a collision risk between the foot and the object.

[0174] In a possible implementation, the determining module 1520 is further configured to:

[0175] When it is determined that the distance is greater than the safety threshold, the distance is compared with an energy-saving threshold, wherein the energy-saving threshold is used to measure the movement amplitude of the foot in the walking direction;

[0176] If the distance is greater than the energy-saving threshold, and the distances measured within a second preset value of consecutive time steps before the measurement time of the distance are greater than the energy-saving threshold, then based on the current position of the foot and the next landing position of the foot, a target trajectory is generated; or,

[0177] If the distance is less than the energy-saving threshold, and the distances measured within the third consecutive preset value time steps before the measurement time of the distance are greater than the safety threshold and less than the energy-saving threshold, and the distance measured before the third preset value time steps is less than the safety threshold, then based on the current position of the foot and the next landing position of the foot, a target trajectory is generated.

[0178] In a possible implementation, the gait adjustment module 1530 is specifically used to:

[0179] Based on the current position of the foot and the starting position of the next time step of the foot, determining the movement trend of the foot in a reference direction, wherein the reference direction is a preset direction of the landing surface of the foot;

[0180] If the movement trend indicates that the foot moves along the reference direction, the posture of the foot is controlled to be adjusted to a basic posture parallel to the landing surface of the foot, and the foot moves along the reference direction;

[0181] If the movement trend indicates that the foot moves in the opposite direction of the reference direction, the posture of the foot is controlled to be adjusted to the basic posture, and moves in the opposite direction;

[0182] If the movement trend indicates that the foot remains stationary, movement is performed along the current position toward an upper landing position.

[0183] In a possible implementation, the distance measuring sensor includes a first distance measuring module and a second distance measuring module, wherein the first distance measuring module is deployed in the toe area of ​​the foot, and is used to measure a first distance between the toe of the foot and an object in front of the toe; the second distance measuring module is deployed in the heel area of ​​the foot, and is used to measure a second distance between the heel of the foot and an object behind the heel;

[0184] The measuring module 1510 is specifically used for:

[0185] If the robot walks forward, a first distance between the object in the walking direction and the foot is measured by the first distance measurement module as the distance;

[0186] If the robot walks backward, the second distance between the object in the walking direction and the foot is measured by the second distance measurement module as the distance.

[0187] In a possible implementation, the distance measuring sensor further includes a third distance measuring module and a fourth distance measuring module, wherein the third distance measuring module is deployed in the toe area, and is used to measure a third distance between the toe of the foot and an object under the toe; the fourth distance measuring module is deployed in the heel area, and is used to measure a fourth distance between the heel of the foot and an object under the heel; the determination module 1520 is further used to:

[0188] Whenever the third distance and the fourth distance are measured, determining whether an absolute value of a difference between the third distance and the fourth distance is less than a stability threshold, wherein the stability threshold is used to measure whether a current landing position of the foot is a stable landing position;

[0189] If yes, determining that the current landing position of the foot is a stable landing position;

[0190] If not, it is determined that the current landing position of the foot is not a stable landing position.

[0191] In a possible implementation, the determining module 1530 is further configured to:

[0192] When it is determined that the current landing position of the foot is not a stable landing position, the posture of the foot is controlled to be adjusted to a basic posture parallel to the landing surface of the foot, and the foot is controlled to translate in a plane parallel to the landing surface of the foot in each preset direction for a fourth preset value of time steps;

[0193] Each time the translation is performed, determining whether the foothold position after the translation is a stable foothold position based on the third distance after the translation measured by the third distance measuring module, the fourth distance after the translation measured by the fourth distance measuring module, and the stability threshold;

[0194] If it is determined that the target landing position after translation is a stable landing position, the target landing position is used to determine the landing position of the foot, and the foot is controlled to perform a landing action for the target landing position;

[0195] If it is determined that there is no stable landing position, the foot is controlled to return to the previous landing position along the original trajectory.

[0196] In a possible implementation, the foot is further equipped with a torque sensor for measuring the contact torque between the foot and the foot landing surface; the gait adjustment module 1530 is used to:

[0197] If it is determined based on the data measured by the torque sensor and the distance sensor that the gait of the foot needs to be adjusted, then a plurality of adjusted target trajectories are respectively obtained;

[0198] Performing feasibility evaluation on each target trajectory respectively to obtain evaluation values ​​corresponding to the multiple target trajectories;

[0199] A target trajectory corresponding to a target evaluation value selected from the evaluation values ​​corresponding to the multiple target trajectories is determined as a final trajectory.

[0200] Based on the same inventive concept, refer to Fig.16 As shown, in an embodiment of the present application, a gait adjustment of a robot is provided, comprising:

[0201] A distance measuring sensor 161 is disposed at the foot of the robot and is used to measure the distance between an object in the walking direction and the foot;

[0202] A visual sensor 162, deployed on the head of the robot, for collecting images of the environment in which the robot is located;

[0203] Memory 163, for storing computer programs or instructions;

[0204] The processor 164 is used to execute the computer program or instructions in the memory 163 so that any one of the methods in the above embodiments is executed.

[0205] The processor 164 may include one or more central processing units (CPUs) or digital processing units, etc., for executing computer programs or instructions in the memory 163 so that any of the methods in the above embodiments is executed;

[0206] It should be noted that the specific connection medium between the memory 163 and the processor 164 is not limited in the embodiment of the present application. Fig.16 In the embodiment, the memory 163 and the processor 164 are connected via a bus 165, and the connection between other components is only for illustrative purposes and is not intended to be limiting. The bus 165 can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Fig.16 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.

[0207] Based on the same inventive concept, an embodiment of the present application provides a computer-readable storage medium. When the instructions in the storage medium are executed by a processor, the processor is enabled to execute any one of the methods in the above embodiments. Since the principle of solving the problem by the above computer-readable storage medium is similar to a gait adjustment method of a robot, the implementation of the above computer-readable storage medium can refer to the implementation of the method, and the repeated parts will not be repeated.

[0208] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present application may adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program codes.

[0209] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device produce a device for implementing the functions specified in one process or multiple processes in the flowchart and / or one box or multiple boxes in the block diagram.

[0210] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.

Claims

1. A robot gait adjustment method, characterized in that: include: During the walking process of the robot, the distance between the object in the walking direction and the foot is measured by a distance measuring sensor deployed on the foot of the robot; Whenever a distance is measured, determining whether there is a risk of collision between the foot and the object based on the distance and environmental information of the environment in which the robot is located, wherein the environmental information is obtained by performing image recognition on an image collected by a visual sensor deployed on the head of the robot; If there is a risk of collision, adjusting the gait of the foot based on the current position of the foot; If there is no risk of collision, when it is determined that the distance is greater than the energy-saving threshold, and the distances measured within a second consecutive preset value of time steps before the measurement time of the distance are greater than the energy-saving threshold, a target trajectory is generated based on the current position of the foot and the next landing position of the foot, wherein the energy-saving threshold is used to measure the movement amplitude of the foot in the walking direction.

2. The method according to claim 1, characterized in that The determining whether there is a collision risk between the foot and the object based on the distance and environmental information of the environment where the robot is located includes: If it is determined based on the environmental information that the object is an obstacle in the walking direction of the robot, the distance is compared with a safety threshold, wherein the safety threshold is a reference value for measuring the risk of collision between the object and the foot; If the distance is greater than or equal to the safety threshold, it is determined that there is no collision risk between the foot and the object; If the distance is smaller than the safety threshold, and the distances measured within a first preset value of consecutive time steps before the measurement time of the distance are smaller than the safety threshold, it is determined that there is a collision risk between the foot and the object.

3. The method according to claim 2, characterized in that The method further comprises: When it is determined that the distance is greater than the safety threshold, comparing the distance with the energy-saving threshold; If the distance is less than the energy-saving threshold, and the distances measured within the third consecutive preset value time steps before the measurement time of the distance are greater than the safety threshold and less than the energy-saving threshold, and the distance measured before the third preset value time steps is less than the safety threshold, then based on the current position of the foot and the next landing position of the foot, a target trajectory is generated.

4. The method according to claim 1, characterized in that The step of adjusting the gait of the foot based on the current position of the foot comprises: Based on the current position of the foot and the starting position of the next time step of the foot, determining the movement trend of the foot in a reference direction, wherein the reference direction is a preset direction of the landing surface of the foot; If the movement trend indicates that the foot moves along the reference direction, the posture of the foot is controlled to be adjusted to a basic posture parallel to the landing surface of the foot, and the foot moves along the reference direction; If the movement trend indicates that the foot moves in the opposite direction of the reference direction, the posture of the foot is controlled to be adjusted to the basic posture, and moves in the opposite direction; If the movement trend indicates that the foot remains stationary, movement is performed along the current position toward an upper landing position.

5. The method according to any one of claims 1 to 4, characterized in that: The distance measuring sensor includes a first distance measuring module and a second distance measuring module, wherein the first distance measuring module is deployed in the toe area of ​​the foot, and is used to measure a first distance between the toe of the foot and an object in front of the toe; the second distance measuring module is deployed in the heel area of ​​the foot, and is used to measure a second distance between the heel of the foot and an object behind the heel; The step of measuring the distance between an object in a walking direction and the foot by using a distance measuring sensor disposed at the foot of the robot comprises: If the robot walks forward, a first distance between the object in the walking direction and the foot is measured by the first distance measurement module as the distance; If the robot walks backward, the second distance between the object in the walking direction and the foot is measured by the second distance measurement module as the distance.

6. The method according to claim 5, characterized in that The distance measuring sensor further includes a third distance measuring module and a fourth distance measuring module, wherein the third distance measuring module is disposed in the toe area and is used to measure a third distance between the toe of the foot and an object below the toe; the fourth distance measuring module is disposed in the heel area and is used to measure a fourth distance between the heel of the foot and an object below the heel; The method further comprises: Whenever the third distance and the fourth distance are measured, determining whether an absolute value of a difference between the third distance and the fourth distance is less than a stability threshold, wherein the stability threshold is used to measure whether a current landing position of the foot is a stable landing position; If yes, determining that the current landing position of the foot is a stable landing position; If not, it is determined that the current landing position of the foot is not a stable landing position.

7. The method according to claim 6, characterized in that The method further comprises: When it is determined that the current landing position of the foot is not a stable landing position, the posture of the foot is controlled to be adjusted to a basic posture parallel to the landing surface of the foot, and the foot is controlled to translate in a plane parallel to the landing surface of the foot in each preset direction for a fourth preset value of time steps; Each time the translation is performed, determining whether the foothold position after the translation is a stable foothold position based on the third distance after the translation measured by the third distance measuring module, the fourth distance after the translation measured by the fourth distance measuring module, and the stability threshold; If it is determined that the target landing position after translation is a stable landing position, the target landing position is used to determine the landing position of the foot, and the foot is controlled to perform a landing action for the target landing position; If it is determined that there is no stable landing position, the foot is controlled to return to the previous landing position along the original trajectory.

8. The method according to claim 6, characterized in that The foot is also equipped with a torque sensor for measuring the contact torque between the foot and the foot landing surface; The method further comprises: If it is determined based on the data measured by the torque sensor and the distance sensor that the gait of the foot needs to be adjusted, then a plurality of adjusted target trajectories are respectively obtained; Performing feasibility evaluation on each target trajectory respectively to obtain evaluation values ​​corresponding to the multiple target trajectories; A target trajectory corresponding to a target evaluation value selected from the evaluation values ​​corresponding to the multiple target trajectories is determined as a final trajectory.

9. A gait adjustment device for a robot, characterized in that: include: A measuring module, used to measure the distance between an object in the walking direction and the foot by using a distance measuring sensor deployed on the foot of the robot during the walking process of the robot; a determination module, configured to determine, each time a distance is measured, whether there is a risk of collision between the foot and the object based on the distance and environmental information of the environment in which the robot is located, wherein the environmental information is obtained by performing image recognition on an image collected by a visual sensor deployed on the head of the robot; A gait adjustment module is used to adjust the gait of the foot based on the current position of the foot if there is a collision risk; if there is no collision risk, when it is determined that the distance is greater than an energy-saving threshold and the distances measured within a second preset value of time steps before the measurement time of the distance are all greater than the energy-saving threshold, generate a target trajectory based on the current position of the foot and the next landing position of the foot, wherein the energy-saving threshold is used to measure the movement amplitude of the foot in the walking direction.

10. A robot, characterized in that: include: A distance measuring sensor, deployed at the foot of the robot, for measuring the distance between an object in the walking direction and the foot; A visual sensor, deployed on the head of the robot, for collecting images of the environment in which the robot is located; Memory, used to store computer programs or instructions; A processor is used to execute the computer program or instructions in the memory so that the method according to any one of claims 1 to 8 is executed.

Citation Information

Patent Citations

  • Bionic autonomous robot autonomous obstacle avoidance system and obstacle avoidance method thereof

    CN112034861A

  • Stable walking method for biped robot to go downstairs

    CN112224300A

  • Humanoid robot gait real -time control system

    CN205721372U