Obstacle avoidance method of robot, robot and computer storage medium
Patent Information
- Application Number
- CN202510398396.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-28
- Publication Date
- 2026-09-29
AI Technical Summary
[0003]但是现有的方案中,录制的通道路径一般较为狭窄,当通道路径上出现障碍物时,机器人很可能会被困住,无法前往下一工作区域进行作业,进而影响机器人的作业效率
[0015]可以理解,本申请通过对通道路径进行膨胀处理获得可通行区域,在机器人遭遇障碍物并进行避障时,可以通过可通行区域以及障碍物的轮廓限制避障路径在安全区域内进行规划,从而可以防止机器人在狭窄地形中碰壁,避免机器人在通道路径中受困,从而提高机器人的作业效率,以及防止避障路径在规划时距离通道路径太远,进而减少机器人避障所需时间以及提高避障的效率。
Smart Images

Figure CN122837422A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of navigation technology, specifically to an obstacle avoidance method for a robot, a robot, and a computer storage medium. Background Technology
[0002] Currently, when various robotic devices need to move from the current work area to the next work area during operation, they need to move outside the work area. In this case, they need to move along a pre-recorded path to ensure safety.
[0003] However, in existing solutions, the recorded channel paths are generally quite narrow. When obstacles appear on the channel path, the robot may get stuck and be unable to move to the next work area, thus affecting the robot's work efficiency. Summary of the Invention
[0004] In view of this, this application provides an obstacle avoidance method and a robot to prevent the robot from getting stuck in a path, thereby improving the robot's operating efficiency. The technical solution of this application is as follows: This application provides a method for obstacle avoidance of a robot, comprising: expanding a preset channel path according to preset parameters to obtain a passable area; performing a following movement along the channel path and detecting obstacles in the channel path; when the obstacle is determined to be a target type obstacle, executing an obstacle avoidance strategy; under the obstacle avoidance strategy, determining an obstacle avoidance target point, the obstacle avoidance target point being located at a first preset distance behind the obstacle on the channel path; obtaining an obstacle avoidance path within the passable area based on the obstacle avoidance target point, the channel path, and the outline of the obstacle; performing a following movement along the obstacle avoidance path; and returning to the step of performing the following movement along the channel path after successful obstacle avoidance.
[0005] In one embodiment of this application, the step of expanding a preset channel path by preset parameters to obtain a passable area includes: expanding the channel path according to a preset multiple of the robot's body length to obtain the passable area, wherein the body length is based on the robot.
[0006] In one embodiment of this application, when the obstacle is determined to be a target type obstacle, executing the obstacle avoidance strategy includes: when the obstacle is determined to be a static obstacle, executing the obstacle avoidance strategy.
[0007] In one embodiment of this application, the method further includes: when it is determined that the obstacle is a dynamic obstacle, executing a stopping strategy, the stopping strategy including the robot stopping for a preset time; and when the dynamic obstacle has not left the passable area after the preset time, executing the obstacle avoidance strategy.
[0008] In one embodiment of this application, the target area includes a safe area and a secondary safe area, the safe area surrounding the passage path, and the secondary safe area surrounding the safe area; obtaining the obstacle avoidance path within the passable area based on the obstacle avoidance target point, the passage path, and the outline of the obstacle includes: obtaining the obstacle avoidance path within the safe area based on the obstacle avoidance target point and the passage path; if obtaining the obstacle avoidance path within the safe area fails, obtaining the obstacle avoidance path within the secondary safe area based on the obstacle avoidance target point and the passage path.
[0009] In one embodiment of this application, the method further includes: when the obstacle avoidance path within the secondary safe area fails to be obtained, stopping the following movement of the channel path and reporting operation suspension information.
[0010] In one embodiment of this application, the method further includes: when multiple obstacles are detected, identifying the type of the nearest obstacle; when the nearest obstacle is determined to be a target type obstacle, executing an obstacle avoidance strategy; after successfully avoiding the nearest obstacle, returning to the step of identifying the type of the nearest obstacle; and after successfully avoiding multiple obstacles, returning to the step of executing the following movement of the channel path.
[0011] In one embodiment of this application, the conditions for determining successful obstacle avoidance include: determining successful obstacle avoidance when the target angle is less than a preset angle, the target distance is less than a preset value, and there are no obstacles within a second preset distance in front, wherein the target angle is the angle between the robot's movement direction and the channel path, and the target distance is the vertical distance between the robot and the channel path.
[0012] In one embodiment of this application, the method further includes marking the target type obstacle at the corresponding position on the channel path after successfully bypassing the obstacle.
[0013] A second aspect of this application provides a robot including a processor and a memory, the processor being configured to execute a computer program stored in the memory to implement the obstacle avoidance method described above.
[0014] A third aspect of this application provides a computer storage medium storing a computer program that, when executed by a processor, causes the processor to perform the obstacle avoidance method of the robot.
[0015] It is understood that this application obtains a passable area by expanding the passageway. When the robot encounters an obstacle and tries to avoid it, the passable area and the outline of the obstacle can be used to limit the obstacle avoidance path to be planned within a safe area. This can prevent the robot from hitting walls in narrow terrain, avoid the robot from getting stuck in the passageway, thereby improving the robot's work efficiency and preventing the obstacle avoidance path from being too far from the passageway when it is planned, thus reducing the time required for the robot to avoid obstacles and improving the efficiency of obstacle avoidance. Attached Figure Description
[0016] Figure 1 This is a schematic diagram of the path of a lawnmower robot provided in an embodiment of this application.
[0017] Figure 2 This is a flowchart illustrating a robot obstacle avoidance method provided in an embodiment of this application.
[0018] Figure 3 This is a schematic diagram of a passable area and obstacle avoidance path provided in an embodiment of this application.
[0019] Figure 4 This is a flowchart illustrating the second obstacle avoidance method for a robot provided in this application embodiment.
[0020] Figure 5 This is a flowchart illustrating a method for obtaining an obstacle avoidance path provided in an embodiment of this application.
[0021] Figure 6 This is a schematic diagram of the second passable area and obstacle avoidance path provided in the embodiments of this application.
[0022] Figure 7 This is a schematic diagram of the third passable area and obstacle avoidance path provided in the embodiments of this application.
[0023] Figure 8 This is a flowchart illustrating the third obstacle avoidance method for robots provided in this application embodiment.
[0024] Figure 9 This is a flowchart illustrating the fourth obstacle avoidance method for robots provided in this application embodiment.
[0025] Figure 10 This is a schematic block diagram of a robot provided for an embodiment of this application. Detailed Implementation
[0026] It should be noted that in the embodiments of this application, "at least one" refers to one or more, and "more than one" refers to two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone, where A and B can be singular or plural. The terms "first," "second," "third," "fourth," etc. (if present) in the specification, claims, and drawings of this application are used to distinguish similar objects, not to describe a specific order or sequence.
[0027] It should also be noted that the methods disclosed in the embodiments of this application or the methods shown in the flowcharts include one or more steps for implementing the method. Without departing from the scope of the claims, the execution order of multiple steps can be interchanged, and some steps can also be deleted.
[0028] Currently, when various robotic devices need to move from the current work area to the next work area during operation, they need to move outside the work area. In this case, they need to move along a pre-recorded path to ensure safety.
[0029] However, in existing solutions, the recorded channel paths are generally quite narrow. When obstacles appear on the channel path, the robot may get stuck and be unable to move to the next work area, thus affecting the robot's work efficiency.
[0030] like Figure 1 As shown, after completing its work on the current lawn 11, the lawnmower 10 will proceed along the pre-recorded path 12 to the next lawn 13 to perform its work.
[0031] This application provides a robot obstacle avoidance method, a robot, and a computer storage medium to prevent the robot from getting stuck in a path, thereby improving the robot's operating efficiency.
[0032] Please refer to Figure 2 , Figure 2 A flowchart illustrating an obstacle avoidance method for a robot provided in this application embodiment specifically includes the following steps: Step S21: Expand the preset channel path according to preset parameters to obtain a passable area.
[0033] In this application embodiment, the robots mentioned above include intelligent robots with path tracking capabilities, such as sweeping robots, lawn mowing robots, weeding robots, and snow removal robots.
[0034] The robot is equipped with a positioning and navigation sensor, an environmental perception sensor, an obstacle detection sensor, and a controller. The controller acquires positioning data through the positioning and navigation sensor to generate a work map and perform path planning. It acquires environmental data through the environmental perception sensor to identify and follow the path. The obstacle detection sensor detects obstacles on the path to execute obstacle avoidance strategies. In some embodiments, the positioning and navigation sensor can be an RTK positioning module, the environmental perception sensor can be a vision sensor or a LiDAR, and the obstacle detection sensor can be a vision sensor, ultrasonic radar, or infrared radar; no limitation is made here.
[0035] In this embodiment of the application, the aforementioned preset channel path can be recorded by the robot user via remote control, such as... Figure 1 The lawns 11 and 13 are shown in the diagram. The user can remotely control the lawnmower robot 10 to move from lawn 11 to lawn 13. During this movement, the controller of the lawnmower robot 10 collects positioning data through positioning and navigation sensors to generate a corresponding travel trajectory. After the lawnmower robot 10 moves to lawn 13, it generates the path 12 shown in the diagram based on the travel trajectory. In the next operation, after completing the mowing work on lawn 11, the lawnmower robot 10 can autonomously travel along the path 12 to lawn 13 to perform the mowing work.
[0036] It is understandable that after the robot's controller initializes and generates the passage path, it can load it into the work map. In the work map, the passage path can be expanded by preset parameters, that is, the width of the passage path can be increased to obtain a passable area in the work map. The passable area can limit the robot's range of movement to the left and right sides while following the passage path, thereby preventing the robot from hitting the wall in narrow terrain.
[0037] In some embodiments, expanding a preset passageway path by preset parameters includes: expanding the passageway path according to a preset multiple of the robot's body length to obtain a passable area, wherein the body length is based on the robot. For example, expanding the left and right sides of the passageway path by twice the robot's body length simultaneously.
[0038] Step S22: Perform follow-up movement along the channel path and detect obstacles in the channel path.
[0039] In this embodiment, after obtaining a passable area, the robot can follow the path after receiving a work command. Specifically, the controller identifies the path using environmental perception sensors and controls the robot to move along it. Simultaneously, the controller also uses obstacle detection sensors to detect whether there are obstacles ahead of the path.
[0040] For example, the controller can acquire images from the front using a vision sensor, identify whether there are obstacles on the path based on the images, and obtain positioning data through an RTK positioning module. Based on the positioning data, the controller can control the robot to move along the path on the work map.
[0041] Step S23: When the obstacle is determined to be a target type obstacle, execute the obstacle avoidance strategy.
[0042] In this embodiment, when the controller determines that there is an obstacle ahead of the path, it further determines the type of obstacle. If the obstacle is determined to be a target type that can be avoided, then the obstacle avoidance strategy is executed. If the obstacle is determined to be an obstacle that cannot be avoided, the controller can control the robot to stop working to prevent damage to the robot, and simultaneously report the obstacle avoidance failure information to the user's terminal. The aforementioned target type obstacle can be a static obstacle. The controller executes the subsequent obstacle avoidance strategy only when it determines that the obstacle is a static obstacle, bypassing the static obstacle and returning to the path. For example, when the robot is a lawnmower robot, static obstacles can be, for example, stones, trees, and tables and chairs on the lawn, while dynamic obstacles can be, for example, people and animals on the lawn.
[0043] In some embodiments, the robot can determine the type of obstacle by using images acquired by a vision sensor. For example, the robot can also pre-store an obstacle type recognition model. When an obstacle is detected in front of the path, the controller can call the recognition model and input the image of the obstacle into the recognition model to obtain the obstacle type result output by the recognition model.
[0044] Step S24: Under the obstacle avoidance strategy, determine the obstacle avoidance target point, which is located at a first preset distance behind the obstacle on the passage path.
[0045] In this embodiment, after executing the obstacle avoidance strategy, the controller first selects an obstacle avoidance target point on the path. The obstacle avoidance target point is located behind the obstacle, meaning that the robot will bypass the obstacle after reaching the obstacle avoidance target point. Furthermore, the obstacle avoidance target point is a first preset distance from the obstacle; for example, the obstacle avoidance target point can be one meter behind the obstacle. This extends the robot's obstacle avoidance path to a certain extent, thereby avoiding blind spots immediately after bypassing the obstacle and preventing unnecessary obstacle avoidance actions when another obstacle appears within one meter behind the first obstacle.
[0046] In some embodiments, when selecting an obstacle avoidance target point, the controller also determines that the distance between the robot's current position and the obstacle avoidance target point is not greater than a third preset distance, for example, that the distance between the robot's current position and the obstacle avoidance target point is not greater than eight meters, so as to avoid the robot getting stuck in a complex group of obstacles and having to avoid obstacles.
[0047] Step S25: Obtain the obstacle avoidance path within the passable area based on the obstacle avoidance target point, the passage path, and the outline of the obstacle.
[0048] In this embodiment, after obtaining the obstacle avoidance target point, the controller first determines a safe zone that can be traversed during obstacle avoidance by using the traversable area and the outline of the obstacle. Then, within the safe zone, it plans an obstacle avoidance path based on the obstacle avoidance target point, selecting the path with the smallest vertical distance to the traversable area. It can be understood that determining a safe zone by using the traversable area and the outline of the obstacle restricts the obstacle avoidance path planning to be within the safe zone. This prevents the obstacle avoidance path from being too far from the passageway during planning, thereby avoiding the robot hitting walls in narrow terrain, reducing the time required for obstacle avoidance, and improving obstacle avoidance efficiency.
[0049] Step S26: Perform the following movement along the obstacle avoidance path.
[0050] In this embodiment, after obtaining the obstacle avoidance path, the controller can load it into the work map, identify the obstacle avoidance path through the environmental perception sensor, and control the robot to follow the path so that the robot can move around the obstacle according to the obstacle avoidance path.
[0051] like Figure 3 As shown, when the lawnmower robot 10 moves from lawn 11 to lawn 13 along the passage path 12, it expands the passage path 12 to obtain a passable area 14. When it detects an obstacle 15 on the passage path 12 and determines that it is a target type obstacle, it determines an obstacle avoidance target point 16 at a first preset distance behind the obstacle 15. Based on the obstacle avoidance target point 16, the passage path 12, and the contour of the obstacle 15, it obtains an obstacle avoidance path 17 within the passable area 14. After following the obstacle avoidance path 17, it can bypass the obstacle 15 within the passable area 14 and return to the passage path 12 at the obstacle avoidance target point 16.
[0052] Step S27: After successfully avoiding the obstacle, return to step S22, which involves following the path of the execution channel.
[0053] In this embodiment, after the controller recognizes successful obstacle avoidance through the environmental perception sensor, it returns to step S22, which involves following the path, to continue operation on the path and detect the next obstacle for obstacle avoidance. The controller determines successful obstacle avoidance either by recognizing that the robot has moved to the obstacle avoidance target point through the environmental perception sensor, or by recognizing that the distance between the robot and the path is less than a preset value; this is not limited to these specific scenarios.
[0054] In some embodiments, when it is determined that the target angle is less than a preset angle, the target distance is less than a preset value, and there is no obstacle within a second preset distance in front, obstacle avoidance is determined to be successful. Here, the target angle is the angle between the robot's moving direction and the channel path, and the target distance is the vertical distance between the robot and the channel path.
[0055] It is understandable that when moving along the obstacle avoidance path, the controller also detects the direction of movement and the angle between the robot and the path in real time using positioning sensors, as well as the vertical distance between the robot and the path. For example, inertial sensors are used to detect the angle between the robot's direction and the path, and the vertical distance between the robot and the path. Additionally, the controller uses obstacle detection sensors to detect whether there is a next obstacle ahead. The controller determines that the robot has successfully avoided the obstacle when it determines that the angle between the robot's direction and the path is less than a preset angle, the vertical distance between the robot's current position and the path is less than a preset value, and there is no next obstacle within a second preset distance ahead. For example, the preset angle could be 30 degrees, the preset value could be half the robot's width, and the second preset distance could be 1.5 meters; these are not further limited here.
[0056] It is understood that this application obtains a passable area by expanding the passageway. When the robot encounters an obstacle and tries to avoid it, the passable area and the outline of the obstacle can be used to limit the obstacle avoidance path to be planned within a safe area. This can prevent the robot from hitting walls in narrow terrain, avoid the robot from getting stuck in the passageway, thereby improving the robot's work efficiency and preventing the obstacle avoidance path from being too far from the passageway when it is planned, thus reducing the time required for the robot to avoid obstacles and improving the efficiency of obstacle avoidance.
[0057] Please refer to Figure 4 , Figure 4 This is a flowchart illustrating the second obstacle avoidance method for a robot provided in an embodiment of this application. Figure 1 Compared to the obstacle avoidance methods shown, the difference lies in that... Figure 2 Step S13 of the obstacle avoidance method shown specifically includes the following steps: Step S231: When the obstacle is determined to be a static obstacle, execute the obstacle avoidance strategy.
[0058] Step S232: When it is determined that the obstacle is a dynamic obstacle, execute the obstacle stopping strategy, which includes a preset duration for which the robot stops moving.
[0059] Step S233: If the dynamic obstacle has not left the passable area after a preset time, execute the obstacle avoidance strategy.
[0060] In this embodiment, the static obstacles include obstacles that lack autonomous movement capabilities, while dynamic obstacles can include people or animals. The controller can identify the type of obstacle using environmental perception sensors. For example, if the robot's environmental perception sensor is a vision sensor, the controller can acquire images of the obstacle using the vision sensor and identify the obstacle type based on the images. The preset timeout can be, for example, 10 seconds; that is, if a dynamic obstacle is detected and has not left the passable area after 10 seconds, an obstacle avoidance strategy is executed to avoid the obstacle.
[0061] In some embodiments, the target area includes a secure area and a secondary secure area, where the secure area surrounds the passage path and the secondary secure area surrounds the secure area. Figure 5 As shown, step S25 above may specifically include the following steps: Step S251: Obtain the obstacle avoidance path within the safe area based on the obstacle avoidance target point and the passage path.
[0062] It's understandable that, since the aforementioned safe zone surrounds the passageway, it is closest to the passageway than the secondary safe zone. Therefore, obstacle avoidance paths within the safe zone are closer to the passageway. The controller can first attempt to plan obstacle avoidance paths within the safe zone.
[0063] like Figure 6 As shown, when the lawnmower robot 10 moves from lawn 11 to lawn 13 along the path 12, it expands the path 12 to obtain a passable area 14, which includes a safe area 141 and a secondary safe area 142. When an obstacle 15 is detected on the path 12 and determined to be a target type obstacle, an obstacle avoidance target point 16 is determined at a first preset distance behind the obstacle 15. Based on the obstacle avoidance target point 16, the path 12, and the contour of the obstacle 15, an obstacle avoidance path 17 is obtained within the safe area 141. After following the obstacle avoidance path 17, the robot can bypass the obstacle 15 within the safe area 141 and return to the path 12 at the obstacle avoidance target point 16.
[0064] It is understandable that planning an obstacle avoidance path within a safe area based on the obstacle avoidance target point and the path to the obstacle can effectively shorten the robot's obstacle avoidance time and improve obstacle avoidance efficiency.
[0065] Step S252: If it fails to obtain the obstacle avoidance path within the safe area, obtain the obstacle avoidance path within the secondary safe area based on the obstacle avoidance target point and the passage path.
[0066] In this embodiment, if the controller fails to plan an obstacle avoidance path within the safe area, it can attempt to plan the path again within a secondary safe area. For example, if an obstacle avoidance path cannot be planned within the safe area, the outline of the obstacle may have completely covered the safe area. The controller can then plan the obstacle avoidance path again within the secondary safe area, and the planned path can be far from the outline of the obstacle while approaching the passageway.
[0067] like Figure 7 As shown, if the lawnmower robot 10 fails to plan an obstacle avoidance path within the safe zone 141, it can also plan an obstacle avoidance path 17 in the secondary safe zone 142 to bypass the obstacle 15 through the secondary safe zone 142 and return to the passage path 12 at the obstacle avoidance target point 16.
[0068] Step S253: If the obstacle avoidance path within the secondary safe area fails to be obtained, stop the following movement of the passage path and report the operation suspension information.
[0069] In this embodiment, if the controller fails to plan an obstacle avoidance path in both the safe area and the secondary safe area, the outline of the obstacle may cover both the safe area and the secondary safe area. That is, after determining that the outline of the obstacle covers the passable area, the remaining area cannot be passed by the robot. The controller can stop following the path to avoid the robot from hitting the wall in the narrow terrain because the obstacle avoidance path is too far from the passage path.
[0070] Please refer to Figure 8 , Figure 8 The flowchart of the third obstacle avoidance method for a robot provided in the embodiments of this application is shown, and specifically includes the following steps: Step S81: Expand the preset channel path with preset parameters to obtain the target path.
[0071] Step S82: Perform follow-up movement along the channel path and detect obstacles in the channel path.
[0072] Step S83: When multiple obstacles are detected, perform type identification on the nearest obstacle; Step S84: When the nearest obstacle is determined to be a target type obstacle, execute the obstacle avoidance strategy; Step S85: Under the obstacle avoidance strategy, determine the obstacle avoidance target point, which is located at a first preset distance behind the obstacle on the passage path.
[0073] Step S86: Obtain the obstacle avoidance path within the target path based on the obstacle avoidance target point, the passage path, and the outline of the obstacle.
[0074] Step S87: Perform the following movement along the obstacle avoidance path.
[0075] Step S88: After successfully avoiding the nearest obstacle, return to step S83, which involves identifying the type of the nearest obstacle.
[0076] Step S89: After successfully avoiding multiple obstacles, return to step S82, which involves following the path of the execution channel.
[0077] In this embodiment, steps S81-S82 are the same as steps S21-S22, and steps S85-S87 are the same as steps S24-S26, and will not be repeated here. It can be understood that when there are multiple obstacles on the path, the controller first identifies the type of the nearest obstacle and executes its obstacle avoidance strategy to obtain the obstacle avoidance path and follow it. After successfully avoiding the nearest obstacle, it then identifies the type of the next nearest obstacle and executes its obstacle avoidance strategy. This achieves continuous obstacle avoidance by repeatedly avoiding the nearest obstacle, thus avoiding the jitter caused to the obstacle avoidance path when considering multiple obstacles simultaneously, and reducing the impact of distant dynamic obstacles on the obstacle avoidance path.
[0078] Please refer to Figure 9 , Figure 9 This is a flowchart illustrating the fourth obstacle avoidance method for a robot provided in this application embodiment. Figure 2 Compared to the obstacle avoidance methods shown, the difference lies in that... Figure 9 The obstacle avoidance method shown also includes the following steps: Step S28: After successfully bypassing the obstacle, mark the target type obstacle at the corresponding position on the passage path.
[0079] In this embodiment of the application, when the controller follows the channel path, it can also record the location information and type information of the corresponding obstacle after each successful obstacle avoidance. For example, the location of the obstacle can be marked on the work map, and the obstacle can be marked as a static obstacle or a dynamic obstacle.
[0080] Please refer to Figure 10 , Figure 10 This is a schematic block diagram of a robot provided in an embodiment of this application. The robot 100 includes a processor 110 and a memory 120. The processor 110 is used to execute a computer program stored in the memory 120 to implement the obstacle avoidance method of any of the above embodiments.
[0081] It is understood that the beneficial effects of the robot 100 described above can be referred to the beneficial effects of the obstacle avoidance method in the foregoing embodiments, and will not be repeated here.
[0082] This application also provides a computer storage medium storing a computer program, which, when executed by a processor, causes the processor to perform the aforementioned obstacle avoidance method for the robot.
[0083] In the above embodiments, implementation can be achieved entirely or partially through software, hardware, firmware, or any combination thereof. When implemented using software, it can be implemented entirely or partially as a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of this application are generated. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer storage medium or transmitted through the computer storage medium. The computer instructions can be transmitted from one website, computer, server, or data center to another website, computer, server, or data center via wired (e.g., coaxial cable, fiber optic, Digital Subscriber Line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that integrates one or more available media. The available media may be magnetic media (e.g., floppy disks, hard disks, magnetic tapes), optical media (e.g., Digital Versatile Discs (DVDs)), or semiconductor media (e.g., solid-state disks (SSDs)).
[0084] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. This program can be stored in a computer-readable storage medium, and when executed, it can include the processes of the embodiments of the methods described above. The aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks. Unless otherwise specified, the technical features of this embodiment and its implementation can be combined arbitrarily.
[0085] The embodiments described above are merely preferred embodiments of this application and are not intended to limit the scope of this application. Any modifications and improvements made by those skilled in the art to the technical solutions of this application without departing from the spirit of this application should fall within the protection scope defined by the claims of this application.
Claims
1. An obstacle avoidance method for a robot, characterized in that, include: The preset channel path is expanded according to preset parameters to obtain a passable area; Perform follow-up movement along the channel path and detect obstacles in the channel path; When the obstacle is determined to be a target type obstacle, an obstacle avoidance strategy is executed; Under the obstacle avoidance strategy, an obstacle avoidance target point is determined, which is located at a first preset distance behind the obstacle on the passage path; Based on the obstacle avoidance target point, the passage path, and the outline of the obstacle, an obstacle avoidance path is obtained within the passable area; Perform the following movement along the obstacle avoidance path; After successfully avoiding the obstacle, return to the step of following the path of the channel.
2. The obstacle avoidance method as described in claim 1, characterized in that, The process of expanding the preset channel path with preset parameters to obtain a passable area includes: The passageway is expanded according to a preset multiple of the robot's body length to obtain the passable area, wherein the body length is based on the robot.
3. The obstacle avoidance method as described in claim 1, characterized in that, When the obstacle is determined to be a target type obstacle, an obstacle avoidance strategy is executed, including: When the obstacle is determined to be a static obstacle, the obstacle avoidance strategy is executed.
4. The obstacle avoidance method as described in claim 3, characterized in that, Also includes: When the obstacle is determined to be a dynamic obstacle, a stopping strategy is executed, which includes a preset duration for which the robot stops moving; If the dynamic obstacle does not leave the passable area after the preset time period, the obstacle avoidance strategy is executed.
5. The obstacle avoidance method as described in claim 1, characterized in that, The target area includes a safe area and a secondary safe area, wherein the safe area surrounds the passage path and the secondary safe area surrounds the safe area. The step of obtaining the obstacle avoidance path within the passable area based on the obstacle avoidance target point, the passage path, and the outline of the obstacle includes: Obtain the obstacle avoidance path within the safe area based on the obstacle avoidance target point and the passage path; If obtaining the obstacle avoidance path within the safe area fails, the obstacle avoidance path within the secondary safe area is obtained based on the obstacle avoidance target point and the passage path.
6. The obstacle avoidance method as described in claim 5, characterized in that, Also includes: If the obstacle avoidance path within the secondary safe area fails to be obtained, the following movement of the passage path is stopped, and the operation is suspended.
7. The obstacle avoidance method as described in claim 1, characterized in that, Also includes: When multiple obstacles are detected, the type of the nearest obstacle is identified; When the nearest obstacle is determined to be a target type obstacle, an obstacle avoidance strategy is executed; After successfully avoiding the nearest obstacle, return to the step of identifying the type of the nearest obstacle; After successfully avoiding the multiple obstacles, return to the step of following the path of the channel.
8. The obstacle avoidance method as described in claim 1, characterized in that, The conditions for determining successful obstacle avoidance include: When the target angle is less than a preset angle, the target distance is less than a preset value, and there are no obstacles within a second preset distance in front, obstacle avoidance is determined to be successful. Here, the target angle is the angle between the robot's moving direction and the channel path, and the target distance is the perpendicular distance between the robot and the channel path.
9. The obstacle avoidance method as described in claim 1, characterized in that, Also includes: After successfully bypassing the obstacle, mark the target type obstacle at the corresponding position on the passage path.
10. A robot, characterized in that, It includes a processor and a memory, the processor being used to execute a computer program stored in the memory to implement the obstacle avoidance method as described in any one of claims 1 to 9.
11. A computer storage medium, characterized in that, The computer storage medium stores a computer program, which, when executed by a processor, causes the processor to perform the obstacle avoidance method of the robot according to any one of claims 1 to 9.