Robot motion control method and device, storage medium and robot
Through real -time obtaining obstacle information and controlling rotation of robotic obstacles, it solves the problem that the robot is difficult to avoid obstacles during the movement, and achieves the ability of the robot to safely and effectively achieve the target point.
Patent Information
- Application Number
- CN202411327126.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2018-06-15
- Publication Date
- 2025-01-28
AI Technical Summary
It is difficult for robots to effectively avoid obstacles during movement, resulting in the inability to safely reach the target point.
Through real -time obtaining obstacles of obstacles, including the shortest distance between robots and obstacles, when the distance reaches the preset safety distance, control the rotation of the robot's obstacles, and when it turns to the direction of the target point, Perform straight movements.
The robot has avoided obstacles in a complex environment to ensure that the target point is safely achieved by the shortest path.
Smart Images

Figure CN119376384A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the field of robot technology, and in particular to a robot motion control method, device, storage medium and robot. Background Art
[0002] With the rapid development of computer technology, sensor technology and artificial intelligence, robot autonomous navigation technology has also made great progress. However, in a complex external environment, robots will inevitably encounter obstacles during movement. How to avoid obstacles and reach the target point safely is the key issue of robot autonomous navigation. Summary of the invention
[0003] The purpose of the present disclosure is to provide a robot motion control method, device, storage medium and robot, which are used to enable the robot to avoid obstacles and reach a target point safely by the shortest path.
[0004] In order to achieve the above-mentioned object, the present disclosure provides a robot motion control method in a first aspect, comprising:
[0005] When the robot moves toward a target point, when an obstacle is detected in the moving direction of the robot, information of the obstacle is acquired in real time, wherein the obstacle information includes at least the shortest distance between the robot and the obstacle;
[0006] When the shortest distance reaches a preset safety distance, controlling the robot to rotate around the obstacle according to the obstacle information; and
[0007] When it is detected that the robot rotates to the direction pointing to the target point and it is detected that there is no obstacle in the direction, the robot is controlled to move in a straight line along the direction pointing to the target point.
[0008] A second aspect of the present disclosure provides a robot motion control device, comprising:
[0009] An acquisition module, used for acquiring information of the obstacle in real time when an obstacle is detected in the movement direction of the robot during the movement of the robot toward the target point, wherein the obstacle information includes at least the shortest distance between the robot and the obstacle;
[0010] A control module is used to control the robot to rotate around the obstacle according to the obstacle information when the shortest distance reaches a preset safety distance, and when it is detected that the robot rotates to the direction pointing to the target point and it is detected that there is no obstacle in this direction, control the robot to move in a straight line in the direction pointing to the target point.
[0011] A third aspect of the present disclosure provides a computer-readable storage medium having computer program instructions stored thereon, which, when executed by a processor, implements the method described in the first aspect of the present disclosure.
[0012] A fourth aspect of the present disclosure provides a robot motion control device, comprising:
[0013] The computer-readable storage medium according to the third aspect of the present disclosure; and
[0014] One or more processors are used to execute the program in the computer-readable storage medium.
[0015] A fifth aspect of the present disclosure provides a robot, comprising the robot motion control device described in the second aspect of the present disclosure.
[0016] By adopting the above technical solution, during the process of the robot moving towards the target point, when an obstacle is detected in the direction of movement of the robot, the obstacle information is obtained in real time, and when the shortest distance between the robot and the obstacle reaches a preset safety distance, the robot is controlled to rotate around the obstacle according to the obstacle information, and when the robot rotates to the direction pointing to the target point and detects that there is no obstacle in this direction, the robot is controlled to move in a straight line in the direction pointing to the target point, so that the robot can avoid obstacles and reach the target point safely by the shortest path. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0018] Figure 1 is a flow chart of a robot motion control method according to an exemplary embodiment of the present disclosure;
[0019] Figures 2 to 4 A schematic diagram of a scene when the robot motion control method provided by the present disclosure is implemented is shown;
[0020] Figure 5 is a schematic diagram of a robot coordinate system and an obstacle coordinate system according to an exemplary embodiment of the present disclosure;
[0021] Figure 6 is a block diagram of a robot motion control device according to an exemplary embodiment of the present disclosure;
[0022] Figure 7 is a block diagram of a robot motion control device according to another exemplary embodiment of the present disclosure. DETAILED DESCRIPTION
[0023] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.
[0024] It should be noted that the terms "first", "second", etc. in the specification and claims of the present disclosure and the above-mentioned drawings are used to distinguish similar objects and do not have to be understood as a specific order or sequence.
[0025] Figure 1 FIG. 1 is a flow chart of a robot motion control method according to an exemplary embodiment of the present disclosure. Figure 1 As shown, the method comprises the following steps:
[0026] In step S101, when the robot is moving toward a target point and an obstacle is detected in the moving direction of the robot, information of the obstacle is acquired in real time, and the obstacle information includes at least the shortest distance between the robot and the obstacle.
[0027] In one embodiment, a distance measuring sensor (such as a laser sensor or an ultrasonic sensor) provided on the robot may be used to detect obstacles in the movement direction of the robot and collect the distance between the robot and the obstacle.
[0028] In an embodiment of the present disclosure, the distance between the robot and the obstacle is the distance between the center of the robot and the edge of the obstacle. The center of the robot may be the midpoint of its maximum width.
[0029] In step S102, when the shortest distance reaches the preset safety distance, the robot is controlled to rotate around the obstacle according to the obstacle information.
[0030] In one embodiment, the obstacle information may also include the number of obstacles. If there is only one obstacle in the direction of movement of the robot, the shortest distance is the distance between the robot and the obstacle. When the shortest distance reaches a preset safety distance, the robot may be controlled to rotate around the obstacle along a first path that is spaced from the edge of the obstacle by the preset safety distance. For example, Figure 2 As shown in the figure, the robot 10 and the obstacle 21 are both cylindrical. At this time, the first path formed is: with the center O1 of the obstacle 21 as the center of the circle and the preset safety distance d rThe sum of the radius of the obstacle 21 and the radius R1 is the arc S1.
[0031] For complex scenarios where there are multiple obstacles in the robot's motion direction, in order to ensure the robot's motion trajectory is the shortest, the obstacle with the shortest distance from the robot can be used as the target obstacle, and the robot's rotation path can be determined based on the distance between the target obstacle and its adjacent obstacles. Accordingly, the acquired obstacle information also includes the distance between the target obstacle and its adjacent obstacles.
[0032] For example, if the difference between the distance between the target obstacle and its adjacent obstacle and the maximum width of the robot is greater than or equal to twice the preset safety distance, it can be determined that the robot can pass through the middle of the two obstacles, and thus the robot can be controlled to rotate around the target obstacle along a second path that is separated from the edge of the target obstacle by a preset safety distance. The second path is a path that passes between the target obstacle and the adjacent obstacle. For example, Figure 3 As shown in the figure, the number of obstacles is two and the robot 10 and obstacles 21 and 22 are all cylindrical. The obstacle 21 closest to the robot 10 is taken as the target obstacle. At this time, the second path is: with the center O1 of the obstacle 21 as the center of the circle and the preset safety distance d r The sum of the radius of the arc S2 and the radius R1 of the obstacle 21 is equal to the arc S2 , and the arc S2 passes between the obstacle 21 and the obstacle 22 .
[0033] If the difference between the distance between the target obstacle and its adjacent obstacle and the maximum width of the robot is less than twice the preset safety distance, it can be determined that the robot may not be able to pass between the two obstacles. At this time, the target obstacle and the adjacent obstacles can be regarded as a whole according to a preset geometric body envelope algorithm (such as a swept ball algorithm), and the robot can be controlled to rotate around the whole along a third path that is separated from the edge of the whole by a preset safety distance, wherein the third path is a path passing through the side of the whole close to the target obstacle. For example, if Figure 4 As shown, the number of obstacles is two and the robot 10 and obstacles 21 and 22 are all cylindrical. The obstacle 21 closest to the robot 10 is taken as the target obstacle, and the obstacles 21 and 22 are taken as a whole 20 (as shown by the dotted line). At this time, the third path is: a preset safety distance d from the edge of the whole 20 r The arc S3 passes through a side of the integral body 20 close to the obstacle 21.
[0034] In step S103, when it is detected that the robot rotates to a direction pointing to the target point and it is detected that there is no obstacle in the direction, the robot is controlled to move in a straight line in the direction pointing to the target point.
[0035] In the process of controlling the robot to rotate around an obstacle, it is possible to detect in real time whether the robot rotates to the direction pointing to the target point. In one embodiment, the robot's starting position can be used as the origin to establish a world coordinate system, thereby obtaining the position of the target point relative to the world coordinate system and the position of the robot relative to the world coordinate system at each moment. Based on the position of the robot at the previous moment and the current moment relative to the world coordinate system and the position of the target point relative to the world coordinate system, it is possible to determine whether the robot's movement direction is pointing to the target point.
[0036] When the robot turns to the direction pointing to the target point and there is no obstacle in that direction, the robot is controlled to move in a straight line to the target point. Figures 2 to 4 As shown, the total motion path of the robot formed at this time is: an arc (S1 / S2 / S3) and a straight line (L1 / L2 / L3) passing through the target point G and tangent to the arc.
[0037] It is worth mentioning that Figures 2 to 4 The robot and the obstacle are both cylinders, but in fact, the robot and the obstacle are not necessarily cylinders. In this regard, as an optional implementation, the midpoint of the maximum width of the robot can be used as the center of the robot, and when the robot is controlled to rotate around the obstacle, the center of the robot is controlled to rotate around the obstacle along a path with a preset safety distance from the edge of the obstacle, and when it is detected that the robot rotates to the direction pointing to the target point and detects that there is no obstacle in the direction, the center of the robot is controlled to move in a straight line in the direction pointing to the target point.
[0038] As another optional implementation, for a robot, the robot can be regarded as a cylinder with its maximum width as the diameter and the midpoint of the maximum width as the center of the robot; for an obstacle, the obstacle can also be regarded as a cylinder in the same way. In this case, the path of the robot's rotation around the obstacle is an arc with the center of the obstacle as the origin and the sum of the preset safety distance and the radius of the obstacle (i.e., half of the maximum width of the obstacle) as the radius (e.g. Figures 2 to 4 shown).
[0039] In other embodiments of the present disclosure, considering that most robots move by speed, the robot's movement speed can be planned to control the robot to move toward the target point at the planned movement speed. Figure 5 (Only in the XY plane), first, the center of the obstacle (O1) can be used as the origin to establish a coordinate system with the robot (O R X R Y R ) parallel to the obstacle coordinate system (O1X1Y1), where the robot's coordinate system is centered on the robot (O R), and can set the robot's first movement speed in the obstacle coordinate system As shown in equations (1) and (2). Next, according to the first motion speed Determine the second motion speed of the robot in the robot coordinate system The robot is driven to rotate around the obstacle at the second movement speed, as shown in formula (3). During the rotation of the robot, when it is detected that the robot rotates to the direction pointing to the target point G and it is detected that there is no obstacle in this direction, the third movement speed of the robot in the robot coordinate system can be set to As shown in formula (4), the robot is controlled to move in a straight line along the direction of movement pointing to the target point G at the third movement speed.
[0040]
[0041] v0=w0·(d r +L / 2)(2)
[0042]
[0043] in, is the first movement speed; is the second movement speed; is the third motion speed; v0 is the linear velocity of the robot; w0 is the angular velocity of the robot; d is the shortest distance between the robot and the obstacle; d r is the preset safety distance; L is the maximum width of the obstacle; R T O is the preset transformation matrix.
[0044] Through the robot motion control method of the above embodiment, when it is detected that there is an obstacle in the robot's movement direction and the shortest distance between the robot and the obstacle reaches a preset safety distance, the robot is controlled to rotate around the obstacle according to the obstacle information, and when the robot rotates to the direction pointing to the target point and there is no obstacle in that direction, the robot is controlled to move toward the target point along the pointing direction, so that the robot can avoid obstacles and reach the target point safely by the shortest path.
[0045] Figure 6 FIG. 1 is a block diagram of a robot motion control device according to an exemplary embodiment. Figure 6 As shown, the device 600 includes: an acquisition module 601 and a control module 602.
[0046] The acquisition module 601 is used to acquire information of the obstacle in real time when an obstacle is detected in the movement direction of the robot during the movement of the robot toward the target point. The obstacle information includes at least the shortest distance between the robot and the obstacle.
[0047] The control module 602 is used to control the robot to rotate around the obstacle according to the obstacle information when the shortest distance reaches the preset safety distance, and when it is detected that the robot rotates to the direction pointing to the target point and it is detected that there is no obstacle in this direction, control the robot to move in a straight line in the direction pointing to the target point.
[0048] In another embodiment, Figure 7 As shown, the obstacle information also includes the number of obstacles;
[0049] The control module 602 includes:
[0050] The first control submodule 621 is configured to control the robot to rotate around the obstacle along a first path spaced a preset distance from the edge of the obstacle when the number is one.
[0051] In another embodiment, Figure 7 As shown, the control module 602 also includes:
[0052] A target obstacle determination submodule 622, configured to, when the number is multiple, use the obstacle with the shortest distance to the robot as the target obstacle, wherein the obstacle information further includes the distance between the target obstacle and its adjacent obstacles;
[0053] A second control submodule 623 is configured to control the robot to rotate around the target obstacle along a second path that is spaced from the edge of the target obstacle by the preset safety distance when the difference between the distance and the maximum width of the robot is greater than or equal to twice the preset safety distance, wherein the second path is a path passing between the target obstacle and the adjacent obstacle;
[0054] The third control submodule 624 is used to control the robot to rotate around the whole along a third path that is separated from the edge of the whole by the preset safety distance when the difference is less than the preset safety distance, treating the target obstacle and the adjacent obstacle as a whole according to a preset geometric envelope algorithm, wherein the third path is a path passing through the side of the whole close to the target obstacle.
[0055] In another embodiment, Figure 7 As shown, the control module 602 includes:
[0056] The obstacle coordinate system establishment submodule 625 is used to establish an obstacle coordinate system parallel to the coordinate system of the robot by taking the center of the obstacle as the origin, wherein the center of the obstacle is the midpoint of the maximum width of the obstacle;
[0057] The first setting submodule 626 is used to set the first movement speed of the robot in the obstacle coordinate system:
[0058]
[0059] The speed determination submodule 627 is used to determine the second movement speed of the robot in the robot coordinate system according to the first movement speed:
[0060]
[0061] in, is the first movement speed; is the second motion speed; v0 is the linear speed of the robot; w0 is the angular speed of the robot; d is the shortest distance; d r is the preset safety distance; L is the maximum width of the obstacle; R T O is the preset transformation matrix;
[0062] The fourth control submodule 628 is used to control the robot to rotate around the obstacle with the center of the obstacle as the origin according to the second movement speed.
[0063] In another embodiment, Figure 7 As shown, the control module 602 includes:
[0064] A second setting submodule 629, used to set a third movement speed of the robot in the coordinate system of the robot;
[0065]
[0066] in, is the third motion speed, v0 is the linear speed of the robot;
[0067] The fifth control submodule 630 is used to control the robot to move in a straight line at the third movement speed along the movement direction pointing to the target point.
[0068] Those skilled in the art should clearly understand that, for the convenience and brevity of description, the specific working process of each module of the robot motion control device described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0069] Secondly, for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example for illustration. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above. The specific working process of the functional modules described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here.
[0070] Through the robot motion control device of the above embodiment, it is possible to enable the robot to avoid obstacles and reach the target point safely by the shortest path.
[0071] Correspondingly, an embodiment of the present disclosure further provides a computer-readable storage medium on which computer program instructions are stored. When the program instructions are executed by a processor, the robot motion control method described in the embodiment of the present disclosure is implemented.
[0072] Correspondingly, an embodiment of the present disclosure also provides a robot motion control device, including the computer-readable storage medium described in the embodiment of the present disclosure; and one or more processors for executing the program in the computer-readable storage medium.
[0073] Correspondingly, an embodiment of the present disclosure also provides a robot, comprising the robot motion control device described in the embodiment of the present disclosure.
[0074] The preferred embodiments of the present disclosure are described in detail above in conjunction with the accompanying drawings; however, the present disclosure is not limited to the specific details in the above embodiments. Within the technical concept of the present disclosure, a variety of simple modifications can be made to the technical solution of the present disclosure, and these simple modifications all fall within the protection scope of the present disclosure.
[0075] It should also be noted that the various specific technical features described in the above specific embodiments can be combined in any suitable manner without contradiction. In order to avoid unnecessary repetition, the present disclosure will not further describe various possible combinations.
[0076] In addition, various embodiments of the present disclosure may be arbitrarily combined, and as long as they do not violate the concept of the present disclosure, they should also be regarded as the contents disclosed by the present disclosure.
Claims
1. A robot motion control method, characterized in that: include: When the robot is moving toward a target point, when it is detected that there is an obstacle in the moving direction of the robot, information of the obstacle is acquired in real time, wherein the information of the obstacle includes at least the shortest distance between the robot and the obstacle and the number of obstacles; When the shortest distance reaches the preset safety distance, the robot is controlled to rotate around the obstacle according to the obstacle information, and the path of the robot rotating around the obstacle is an arc with the center of the obstacle as the origin and the sum of the preset safety distance and half of the maximum width of the obstacle as the radius; If the number is one, controlling the robot to rotate around the obstacle along a first path spaced from the edge of the obstacle by the preset safety distance; If the number is multiple, the obstacle with the shortest distance from the robot is used as the target obstacle, and the obstacle information also includes the distance between the target obstacle and its adjacent obstacles; When the number is multiple, calculating the difference between the distance between the target obstacle and its adjacent obstacle and the maximum width of the robot, comparing the difference with twice the preset safety distance, and controlling the robot to rotate around the obstacle along different paths; as well as When it is detected that the robot rotates to the direction pointing to the target point and it is detected that there is no obstacle in the direction, the robot is controlled to move in a straight line along the direction pointing to the target point.
2. The method according to claim 1, characterized in that: The controlling the robot to rotate around the obstacle according to the obstacle information includes: Taking the center of the obstacle as the origin, establishing an obstacle coordinate system parallel to the coordinate system of the robot, wherein the center of the obstacle is the midpoint of the maximum width of the obstacle; Set the first movement speed of the robot in the obstacle coordinate system: v0=w0·(d r +L / 2) Determine a second movement speed of the robot in the robot coordinate system according to the first movement speed: in, is the first movement speed; is the second motion speed; v0 is the linear speed of the robot; w0 is the angular speed of the robot; d is the shortest distance; d r is the preset safety distance; L is the maximum width of the obstacle; R T O is the preset transformation matrix; The robot is controlled to rotate around the obstacle with the center of the obstacle as the origin according to the second movement speed.
3. The method according to claim 2, characterized in that The controlling the robot to move in a straight line in a direction pointing to the target point comprises: Set the third movement speed of the robot in the coordinate system of the robot: in, is the third motion speed, v0 is the linear speed of the robot; The robot is controlled to move in a straight line along a movement direction pointing to the target point at the third movement speed.
4. The method according to claim 1 or 2, characterized in that: When the number is multiple, calculating the difference between the distance between the target obstacle and its adjacent obstacle and the maximum width of the robot, comparing the difference with twice the preset safety distance, and controlling the robot to rotate around the obstacle along different paths, specifically includes: If the difference between the distance between the target obstacle and its adjacent obstacle and the maximum width of the robot is greater than or equal to twice the preset safety distance, the robot is controlled to rotate around the target obstacle along a second path that is spaced from the edge of the target obstacle by the preset safety distance, wherein the second path is a path passing between the target obstacle and the adjacent obstacle; If the difference is less than twice the preset safety distance, the target obstacle and the adjacent obstacle are treated as a whole according to a preset geometric envelope algorithm, and the robot is controlled to rotate around the whole along a third path that is separated from the edge of the whole by the preset safety distance, wherein the third path is a path passing through a side of the whole close to the target obstacle.
5. A robot motion control device, characterized in that: include: An acquisition module, used for acquiring information of the obstacle in real time when an obstacle is detected in the movement direction of the robot during the movement of the robot toward the target point, wherein the obstacle information includes at least the shortest distance between the robot and the obstacle and the number of obstacles; a control module, configured to control the robot to rotate around the obstacle according to the obstacle information when the shortest distance reaches a preset safety distance, and to control the robot to move in a straight line in the direction pointing to the target point when it is detected that the robot rotates to the direction pointing to the target point and it is detected that there is no obstacle in the direction, wherein the path along which the robot rotates around the obstacle is an arc with a center of the obstacle as an origin and a radius equal to the sum of the preset safety distance and half of the maximum width of the obstacle; Wherein, the control module comprises: A first control submodule, configured to control the robot to rotate around the obstacle along a first path spaced from the edge of the obstacle by the preset safety distance when the number is one; a target obstacle determination submodule, configured to, when the number is multiple, use the obstacle with the shortest distance to the robot as the target obstacle, wherein the obstacle information further includes the distance between the target obstacle and its adjacent obstacles; The second and third control submodules are used to calculate the difference between the distance between the target obstacle and its adjacent obstacle and the maximum width of the robot when the number is multiple, compare the difference with twice the preset safety distance, and control the robot to rotate around the obstacle along different paths.
6. The device according to claim 5, characterized in that The control module comprises: An obstacle coordinate system establishment submodule, used to establish an obstacle coordinate system parallel to the coordinate system of the robot by taking the center of the obstacle as the origin, wherein the center of the obstacle is the midpoint of the maximum width of the obstacle; The first setting submodule is used to set the first movement speed of the robot in the obstacle coordinate system: v0=v0(d r +L / 2) A speed determination submodule is used to determine a second movement speed of the robot in the robot coordinate system according to the first movement speed: in, is the first movement speed; is the second motion speed; v0 is the linear speed of the robot; w0 is the angular speed of the robot; d is the shortest distance; d r is the preset safety distance; L is the maximum width of the obstacle; R T O is the preset transformation matrix; The fourth control submodule is used to control the robot to rotate around the obstacle with the center of the obstacle as the origin according to the second movement speed.
7. The device according to claim 6, characterized in that The control module comprises: A second setting submodule, used to set a third movement speed of the robot in the coordinate system of the robot; in, is the third motion speed, v0 is the linear speed of the robot; The fifth control submodule is used to control the robot to move in a straight line at the third movement speed along the movement direction pointing to the target point.
8. The device according to claim 5 or 6, characterized in that The second and third control submodules are used to include: a second control submodule, configured to control the robot to rotate around the target obstacle along a second path spaced from an edge of the target obstacle by the preset safety distance when the difference between the distance between the target obstacle and its adjacent obstacle and the maximum width of the robot is greater than or equal to twice the preset safety distance, wherein the second path is a path passing between the target obstacle and the adjacent obstacle; The third control submodule is used to control the robot to rotate around the whole along a third path that is separated from the edge of the whole by the preset safety distance when the difference is less than the preset safety distance, based on a preset geometric envelope algorithm, treating the target obstacle and the adjacent obstacle as a whole. The third path is a path passing through a side of the whole close to the target obstacle.
9. A robot motion control device, characterized in that: include: A computer-readable storage medium for storing program instructions corresponding to the method according to any one of claims 1 to 4; as well as One or more processors are used to execute program instructions in the computer-readable storage medium.
10. A robot, characterized in that: A robot motion control device comprising any one of claims 5 to 8.