A non-transitory computer-readable storage medium, having an executable code stored therein, the executable code, when executed by a processor of a computer device, causing the computer device to perform a method for controlling the landing of a legged robot on a plane, the legged robot comprising a base and at least two robotic legs, each of the robotic legs comprising at least one joint, the method comprising:
- determining a first expected moving trajectory and a second expected moving trajectory and a third expected moving trajectory, each corresponding to a respective portion of the legged robot in response to determining an instantaneous moment that each robotic leg of the legged robot contacts the plane,
- the first expected moving trajectory indicating an expected moving trajectory of a center of mass of the legged robot,
- the second expected moving trajectory indicating an expected moving trajectory of a foot end of each robotic leg, and
- the third expected moving trajectory indicating an expected moving trajectory of a change in a tilt angle of the legged robot;
- and
- controlling, based on a dynamic model corresponding to the legged robot, the first expected moving trajectory, the second expected moving trajectory, and the third expected moving trajectory, an action of each joint after the legged robot contacts the plane, until a height of the base of the legged robot reaches a constant value and the tilt angle of the legged robot stops changing, wherein the controlling the action of each joint after the legged robot contacts the plane comprises:
- obtaining a toppling direction of the legged robot and offset information corresponding to the toppling direction of each robotic leg at the instantaneous moment that each robotic leg contacts the plane;
- determining a first position component corresponding to an initial foot end position of each robotic leg in the toppling direction of the legged robot;
- combining the offset information with the first position component corresponding to the initial foot end position of each robotic leg in the toppling direction, to obtain a first offset position component corresponding to each robotic leg in the toppling direction;
- controlling each robotic leg of the legged robot to move along the toppling direction of the legged robot by the first offset position component into a compressed state;
- and
- controlling each robotic leg to rebound from the compressed state to a rebound state until the center of mass of the legged robot reaches an expected resting height and a rotation angle in the direction of the tilt angle of the legged robot is zero.