Robot navigation method and device, robot and storage medium
By using a line-based navigation method in the robot navigation system to generate and detect paths, the problems of navigation failure and inefficiency in the existing technology are solved, and a more stable, reliable and efficient navigation effect is achieved.
Patent Information
- Application Number
- CN202411983131.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-31
- Publication Date
- 2025-04-15
AI Technical Summary
In scenarios where existing robot navigation methods need to go through a specific path or move close to a wall, it is difficult to meet specific usage needs, resulting in navigation failure or inefficiency.
Using a line drawing navigation method, by reading pre-stored steering point information, generating a path and performing rationality detection, ensuring the feasibility of the path, and then using line drawing navigation, state detection and real-time speed planning are performed until the navigation is completed.
It effectively avoids navigation failures caused by improper path planning, improves the stability and reliability of the navigation system, ensures that the robot reaches the target point efficiently and safely, and optimizes the overall navigation efficiency.
Smart Images

Figure CN119826827A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of robot technology, and in particular to a robot navigation method, device, robot and storage medium. Background Art
[0002] At present, the mainstream navigation method of service robots is to send the target point, and the robot will autonomously plan the path to the target point. However, for some use scenarios, such as disinfection and transportation, there are requirements for the robot's movement path, and it needs to pass through certain paths or move close to walls. In this case, the navigation method of autonomous path planning does not meet the use requirements. Summary of the invention
[0003] In view of this, the purpose of the embodiments of the present invention is to provide a robot navigation method, device, robot and storage medium, which adopts a navigation solution based on line navigation, can control the movement path of the robot, and meet the use scenarios of the robot passing through the set movement path.
[0004] On the one hand, an embodiment of the present invention provides a robot navigation method, the method comprising the following steps: In response to the received navigation task, read the pre-stored turning point information; wherein the turning point information includes the position and posture of the turning point in the global map; Generate a path according to the turning point information, perform a rationality check on the path, and determine whether the path is feasible; wherein the path includes a plurality of continuous line segments, and the two endpoints of each line segment are turning points; When the path is feasible, after navigating the robot to the starting turning point, the navigation status is detected by line drawing navigation, and the robot speed is continuously planned and published according to the map information until the navigation is completed; wherein, the navigation status detection includes determining whether the robot is on the path, clipping the path, and performing passability detection on the path points in front of the robot.
[0005] Optionally, generating a path according to the turning point information includes: Get the position and posture of the turning point; Select two turning points in sequence, establish a straight line equation according to the positions and postures of the two turning points, and obtain a line segment of the two turning points; Starting from the turning point at one end of the line segment, sampling path points on the line segment according to a preset sampling distance until reaching the turning point at the other end of the line segment, obtaining all path points on the line segment, and storing the line segment containing all path points as an element of a path container; After it is determined that all turning points are selected, each line segment in the path container is sequentially connected to form a path.
[0006] Optionally, the performing rationality detection on the path includes: Traverse each path point in the path; Get the format of the waypoints and their positions on the static map; Determine that the waypoint is in the correct format and, based on the waypoint's position on the static map, determine whether the waypoint is within the traversable area of the static map; If the format of the waypoint is normal and is within the traversable area of the static map, it is determined that the rationality check of the waypoint has passed; If it is determined that the rationality test of each path point in the path passes, it is determined that the rationality test of the path passes.
[0007] Optionally, the detecting of navigation status by line drawing navigation includes: Traversing the path points, calculating the Euclidean distance between the path points and the robot, and when a path point whose Euclidean distance is within the clipping distance is found for the first time, clipping the path to remove the portion of the path before the path point; For the path points after this path point, determine whether there are path points whose Euclidean distance is within the detection range. If there are path points whose Euclidean distance is within the detection range, determine whether all path points whose Euclidean distance is within the detection range are located in the passable area of the cost map. If all path points whose Euclidean distance is within the detection range are located in the passable area, it is determined that the navigation status test has passed.
[0008] Optionally, the performing navigation state detection by line drawing navigation further includes: If it is determined that the navigation state detection fails, it is determined whether the robot is on the path; If it is determined that the robot is not on the path, the robot is controlled to navigate toward the starting turning point and the number of navigations is recorded; if the robot navigates to the starting turning point before the number of navigations exceeds the number threshold, the process jumps to the step of executing the navigation task received and reading the pre-stored turning point information; If it is determined that the robot is on the path, the starting time when the waypoint is detected to be in the obstacle area is recorded, and the duration from the starting time to the current time is taken as the waiting time of the robot; if it is detected that the waypoint is no longer in the obstacle area before the waiting time exceeds the tolerance time, it is determined that the exception handling is completed and navigation continues.
[0009] Optionally, the performing navigation state detection by line drawing navigation further includes: If the number of navigations exceeds the threshold and the robot has not navigated to the starting turning point; or if the waiting time exceeds the tolerance time and the waypoint is detected to be in an obstacle area, the navigation task is terminated and an exception is reported.
[0010] Optionally, the continuously planning and publishing the robot speed according to the map information until the navigation execution is completed includes: Calculate the distance between the robot and the end path point, and when the distance is less than the arrival tolerance distance, determine that the robot has reached the turning point and publish zero speed; When the distance is not less than the arrival tolerance distance, the dual-loop PID method is used to plan the robot's speed, and the trajectory is generated according to the control frequency and sampling frequency to detect whether the trajectory is in the passable area of the cost map. If so, the robot's speed is published, otherwise zero speed is published.
[0011] On the other hand, an embodiment of the present invention provides a robot navigation device, characterized in that the device comprises: The first module is used to read pre-stored turning point information in response to the received navigation task; wherein the turning point information includes the position and posture of the turning point in the global map; The second module is used to generate a path according to the turning point information, perform a rationality check on the path, and determine whether the path is feasible; wherein the path includes a plurality of continuous line segments, and the two endpoints of each line segment are turning points; The third module is used to navigate the robot to the starting turning point when the path is feasible, perform navigation status detection through line drawing navigation, and continuously plan and publish the robot speed according to the map information until the navigation is completed; wherein, the navigation status detection includes determining whether the robot is on the path, clipping the path, and performing passability detection on the path points in front of the robot.
[0012] On the other hand, an embodiment of the present invention provides a robot, comprising: at least one processor; at least one memory for storing at least one program; When the at least one program is executed by the at least one processor, the at least one processor implements the above method.
[0013] On the other hand, an embodiment of the present invention provides a computer-readable storage medium, in which a program executable by a processor is stored. When the program executable by the processor is executed by the processor, it is used to perform the above method.
[0014] The embodiments of the present invention include the following beneficial effects: In this embodiment, through line drawing navigation and path rationality detection, the robot's navigation failure caused by obstacles or improper path planning is effectively avoided, and the stability and reliability of the navigation system are improved. At the same time, real-time speed planning ensures that the robot reaches the target point efficiently and safely, optimizing the overall navigation efficiency.
[0015] By presetting turning points in the global map and using these turning points to generate paths, the complexity of path planning is simplified, ensuring that the robot reaches the target efficiently and accurately. Through line navigation and path rationality detection, real-time monitoring and adjustment mechanisms, emergencies can be effectively responded to, ensuring the safety and stability of the navigation process. The stability and reliability of the navigation system are improved. Real-time speed planning ensures that the robot reaches the target point efficiently and safely, optimizing the overall navigation efficiency. The present invention can control the movement path of the robot to meet the use scenario of the robot passing through the set movement path. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0017] Figure 1 is a schematic diagram of a process flow of a robot navigation method provided by an embodiment of the present invention; Figure 2 is a schematic diagram of a robot navigation path provided by an embodiment of the present invention; Figure 3 is a structural block diagram of a robot navigation device provided by an embodiment of the present invention; Figure 4 It is a structural block diagram of a robot provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0018] In order to make the purpose, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the embodiments of the present invention. They are only examples of devices and methods consistent with some aspects of the embodiments of the present invention as detailed in the attached claims.
[0019] It is understood that the terms "first", "second", etc. used in the present invention may be used herein to describe various concepts, but unless otherwise specified, these concepts are not limited by these terms. These terms are only used to distinguish one concept from another. For example, without departing from the scope of the embodiments of the present invention, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the words "if" and "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining".
[0020] The terms "at least one", "multiple", "each", "any", etc. used in the present invention, at least one includes one, two or more, multiple includes two or more, each refers to each of the corresponding multiple, and any refers to any one of the multiple.
[0021] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which the present invention belongs. The terms used herein are only for the purpose of describing the embodiments of the present invention and are not intended to limit the present invention.
[0022] First, the technical terms involved in the present invention are explained below: Static map: The robot uses laser radar, depth and other sensors to scan the surrounding environment to create a two-dimensional grid map. Each grid has a value: generally represented by three values: 0, -1, and 100: free (passable), unknown, and obstructed (impassable); Cost map: Based on the static map, it reads sensor information and is generated in real time to represent obstacle information in the environment and robot posture information. The cost map can represent the passability of the grid, which can be divided into passable area (passable), expansion area (close to obstacles), and fatal area (there is a risk of collision or unknown); Pose: Pose is composed of horizontal coordinate, vertical coordinate and heading angle: (x, y, yaw). A three-dimensional coordinate origin map is set on the cost map. For objects in the map, the present invention uses pose to represent their relative position relative to the coordinate system, so as to obtain their position and posture in the scene; like Figure 1 As shown, an embodiment of the present invention provides a robot navigation method, the method comprising the following steps: S100, in response to the received navigation task, reading pre-stored turning point information; wherein the turning point information includes the position and posture of the turning point in the global map; S200, generating a path according to the turning point information, performing a rationality check on the path, and determining whether the path is feasible; wherein the path includes a plurality of continuous line segments, and two endpoints of each line segment are turning points; S300, when the path is feasible, after navigating the robot to the starting turning point, the navigation status is detected by line drawing navigation, and the robot speed is continuously planned and published according to the map information until the navigation is completed; wherein, the navigation status detection includes determining whether the robot is on the path, clipping the path, and performing passability detection on the path points in front of the robot.
[0023] In the embodiment provided by the present invention, the execution process of navigation is as follows: When executing a navigation task, the robot reads the stored turning point information, generates a path based on the turning point information, and performs a rationality check on the path to preliminarily confirm the feasibility of the path; when the path is feasible, the autonomous navigation method is first called to navigate the robot to the starting turning point, and then line drawing navigation is started, continuously planning and publishing the robot speed based on the map information until the navigation is completed; during the navigation process, if an exception occurs, the exception handling operation will be executed.
[0024] The process of drawing a path is as follows: first, for the convenience of implementation, the present invention makes the path consist of multiple line segments, and the two endpoints of the line segments are turning points. The robot moves along the line segments, adjusts the direction when it reaches the turning points, and then moves along the line segments; therefore, it is only necessary to determine the turning points as needed in the global map, and then sample the path points according to the coordinates of every two turning points and the appropriate spacing to generate the path.
[0025] In this embodiment, by presetting turning points in the global map and using these turning points to generate paths, the complexity of path planning is simplified, ensuring that the robot reaches the target efficiently and accurately. At the same time, the real-time monitoring and adjustment mechanism effectively responds to emergencies and ensures the safety and stability of the navigation process. Through dynamic path adjustment, the robot can respond flexibly in complex environments and ensure the smooth completion of each navigation task. The present invention can control the movement path of the robot and meet the use scenarios of the robot passing through the set movement path.
[0026] In some embodiments, in S200, generating a path according to the turning point information includes: S211, obtaining the position and posture of the turning point; S212, selecting two turning points in sequence, establishing a straight line equation according to the positions and postures of the two turning points, and obtaining a line segment of the two turning points; S213, starting from the turning point at one end of the line segment, sampling path points on the line segment according to a preset sampling distance until reaching the turning point at the other end of the line segment, obtaining all path points on the line segment, and storing the line segment containing all path points as an element of a path container; S214, when it is determined that all turning points are selected, each line segment in the path container is sequentially connected to form a path.
[0027] For path generation, the equation of the straight line between the two turning points is calculated based on the turning point information, and the path points are sampled on the line segment according to the preset sampling distance to finally form a path; the corresponding path is determined through the turning point information to ensure that the robot meets different navigation requirements and adapts to changing environments. The efficient path generation method can ensure the accuracy and real-time performance of the navigation path and improve the robot's autonomous navigation capabilities. The real-time monitoring mechanism dynamically adjusts the path to ensure the safe and efficient completion of the task.
[0028] In some embodiments, in S200, the performing rationality detection on the path includes: S221, traversing each path point in the path; S221, obtaining the format of the waypoint and the position and posture on the static map; S221, determining that the format of the waypoint is normal, and determining whether the waypoint is within a traversable area of the static map based on the position of the waypoint on the static map; S221, if the format of the waypoint is normal and is within the traversable area of the static map, it is determined that the rationality check of the waypoint has passed; S221: If it is determined that the rationality test of each path point in the path has passed, it is determined that the rationality test of the path has passed.
[0029] The path rationality check is mainly to check whether the format of the path points on the path is normal, and set the path points with abnormal formats as failing the rationality check; at the same time, check whether the path points are located in the passable area on the static map, and set the path points beyond the passable area as failing the rationality check; avoid the situation where the path passes through the obstacle area in the static map. If there is a path point that fails the rationality check, the navigation task is terminated and the abnormality is reported.
[0030] In some embodiments, in S300, the detecting of navigation status by line-drawing navigation includes: Traversing the path points, calculating the Euclidean distance between the path points and the robot, and when a path point whose Euclidean distance is within the clipping distance is found for the first time, clipping the path to remove the portion of the path before the path point; For the path points after this path point, determine whether there are path points whose Euclidean distance is within the detection range. If there are path points whose Euclidean distance is within the detection range, determine whether all path points whose Euclidean distance is within the detection range are located in the passable area of the cost map. If all path points whose Euclidean distance is within the detection range are located in the passable area, it is determined that the navigation status test has passed.
[0031] It should be noted that the navigation status detection is mainly to check whether the robot is on the path, clip the path, and detect the passability of the path points in front of the robot; Specifically, for each path point, the Euclidean distance between the path point and the robot is calculated. When a path point with a Euclidean distance within the clipping distance is found, path clipping is performed to remove the path before this path point. If the Euclidean distance of all path points is greater than the clipping distance, it means that the robot is not on the path and the navigation state detection fails. After clipping the path, the subsequent path points with Euclidean distance within the detection range are checked to see if they are located in the traversable area of the cost map. If a path point is located in the obstacle area, it means there is an obstacle and the navigation status test fails. Finally, only when the path is clipped and all the path points within the detection range are located in the passable area, the navigation status detection is determined to have passed.
[0032] In some embodiments, in S300, the performing navigation state detection by line drawing navigation further includes: If it is determined that the navigation state detection fails, it is determined whether the robot is on the path; If it is determined that the robot is not on the path, the robot is controlled to navigate toward the starting turning point and the number of navigations is recorded; if the robot navigates to the starting turning point before the number of navigations exceeds the number threshold, the process jumps to the step of executing the navigation task received and reading the pre-stored turning point information; If it is determined that the robot is on the path, the starting time when the waypoint is detected to be in the obstacle area is recorded, and the duration from the starting time to the current time is taken as the waiting time of the robot; if it is detected that the waypoint is no longer in the obstacle area before the waiting time exceeds the tolerance time, it is determined that the exception handling is completed and navigation continues.
[0033] In some embodiments, in S300, the performing navigation state detection by line drawing navigation further includes: If the number of navigations exceeds the threshold and the robot has not navigated to the starting turning point; or if the waiting time exceeds the tolerance time and the waypoint is detected to be in an obstacle area, the navigation task is terminated and an exception is reported.
[0034] Specifically, if it is determined that the navigation status detection fails, determine whether the robot is on the path. If it is determined that the robot is not on the path, try to navigate to the starting turning point. If the navigation is successful, update the path and continue navigation; otherwise, try to navigate to the starting turning point again. If multiple navigations fail, end the navigation task and report the exception.
[0035] If it is determined that the robot is on the path, the starting time when the waypoint is detected in the obstacle area is recorded, and then the waiting time of the robot is calculated; if the tolerance time is exceeded, the waypoint is detected; if within the tolerance time, it is detected that the waypoint is no longer in the obstacle area, the exception handling is completed and navigation continues; if the tolerance time is exceeded and the waypoint is still detected in the obstacle area, the navigation task is terminated and the exception is reported.
[0036] In some embodiments, in S300, continuously planning and publishing the robot speed according to the map information until the navigation execution is completed includes: Calculate the distance between the robot and the end path point, and when the distance is less than the arrival tolerance distance, determine that the robot has reached the turning point and publish zero speed; When the distance is not less than the arrival tolerance distance, the dual-loop PID method is used to plan the robot's speed, and the trajectory is generated according to the control frequency and sampling frequency to detect whether the trajectory is in the passable area of the cost map. If so, the robot's speed is published, otherwise zero speed is published.
[0037] Specifically, for robot speed planning, the distance between the robot and the end point of the path is first calculated. When the distance is less than the arrival tolerance distance, it means that the robot has reached the turning point, and the zero speed is released, and the speed planning is completed; If the end point is not reached, the dual-loop PID method is used for speed planning. The robot's speed is planned according to the robot's posture, the error between the robot and the path, and the dynamic constraints. The trajectory is generated according to the control frequency and sampling frequency to detect whether the trajectory is in the passable area of the cost map (reducing the risk of collision). If so, the speed is released, otherwise zero speed is released.
[0038] See also Figure 3 , an embodiment of the present invention provides a robot navigation device, the device comprising: The first module is used to read pre-stored turning point information in response to the received navigation task; wherein the turning point information includes the position and posture of the turning point in the global map; The second module is used to generate a path according to the turning point information, perform a rationality check on the path, and determine whether the path is feasible; wherein the path includes a plurality of continuous line segments, and the two endpoints of each line segment are turning points; The third module is used to navigate the robot to the starting turning point when the path is feasible, perform navigation status detection through line drawing navigation, and continuously plan and publish the robot speed according to the map information until the navigation is completed; wherein, the navigation status detection includes determining whether the robot is on the path, clipping the path, and performing passability detection on the path points in front of the robot.
[0039] It can be understood that the contents of the above method embodiments are all applicable to the present device embodiments, the functions specifically implemented by the present device embodiments are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.
[0040] refer to Figure 4 An embodiment of the present invention further provides a robot, the robot comprising a memory and a processor, the memory storing a computer program, and the processor implementing the method in the above embodiment when executing the computer program.
[0041] It can be understood that the contents of the above method embodiments are all applicable to this embodiment, the functions specifically implemented by this embodiment are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.
[0042] An embodiment of the present invention further provides a computer-readable storage medium, which stores a computer program. When the computer program is executed by a processor, the above method is implemented.
[0043] It can be understood that the contents of the above method embodiments are all applicable to the present storage medium embodiments, the functions specifically implemented by the present storage medium embodiments are the same as those of the above method embodiments, and the beneficial effects achieved are also the same as those achieved by the above method embodiments.
[0044] The memory, as a non-transient computer-readable storage medium, can be used to store non-transient software programs and non-transient computer executable programs. In addition, the memory may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some embodiments, the memory may optionally include a memory remotely disposed relative to the processor, and these remote memories may be connected to the processor via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0045] The embodiments described in the embodiments of the present invention are intended to more clearly illustrate the technical solutions of the embodiments of the present invention, and do not constitute a limitation on the technical solutions provided by the embodiments of the present invention. Those skilled in the art can appreciate that with the evolution of technology and the emergence of new application scenarios, the technical solutions provided by the embodiments of the present invention are also applicable to similar technical problems.
[0046] Those skilled in the art will appreciate that the technical solutions shown in the figures do not limit the embodiments of the present invention and may include more or fewer steps than shown in the figures, or a combination of certain steps, or different steps.
[0047] The device embodiments described above are merely illustrative, and the units described as separate components may or may not be physically separated, that is, they may be located in one place or distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0048] Those skilled in the art will appreciate that all or some of the steps in the methods disclosed above, and the functional modules / units in the systems and devices may be implemented as software, firmware, hardware, or a suitable combination thereof.
[0049] The terms "first", "second", "third", "fourth", etc. (if any) in the specification of the present invention 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 data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.
[0050] It should be understood that in the present invention, "at least one (item)" refers to one or more, and "plurality" refers to two or more. "And / or" is used to describe the association relationship of associated objects, indicating that three relationships may exist. For example, "A and / or B" can represent: only A exists, only B exists, and A and B exist at the same time, where A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship. "At least one of the following items" or similar expressions refers to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b or c can represent: a, b, c, "a and b", "a and c", "b and c", or "a and b and c", where a, b, c can be single or multiple.
[0051] In the several embodiments provided by the present invention, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the above units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0052] The units described above as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0053] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0054] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of the technical solution can be embodied in the form of a software product. The computer software product is stored in a storage medium, including multiple instructions to enable a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the methods of various embodiments of the present invention. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (Read-Only Memory, referred to as ROM), random access memory (Random-Access-Memory, referred to as RAM), disk or optical disk and other media that can store programs.
[0055] The preferred embodiments of the present invention are described above with reference to the accompanying drawings, but the scope of the rights of the embodiments of the present invention is not limited thereby. Any modification, equivalent substitution and improvement made by those skilled in the art without departing from the scope and essence of the embodiments of the present invention shall be within the scope of the rights of the embodiments of the present invention.
Claims
1. A robot navigation method, characterized in that: The method comprises the following steps: In response to the received navigation task, read the pre-stored turning point information; wherein the turning point information includes the position and posture of the turning point in the global map; Generate a path according to the turning point information, perform a rationality check on the path, and determine whether the path is feasible; wherein the path includes a plurality of continuous line segments, and the two endpoints of each line segment are turning points; When the path is feasible, after navigating the robot to the starting turning point, the navigation status is detected by line drawing navigation, and the robot speed is continuously planned and published according to the map information until the navigation is completed; wherein, the navigation status detection includes determining whether the robot is on the path, clipping the path, and performing passability detection on the path points in front of the robot.
2. The method according to claim 1, characterized in that The generating a path according to the turning point information comprises: Get the position and posture of the turning point; Select two turning points in sequence, establish a straight line equation according to the positions and postures of the two turning points, and obtain a line segment of the two turning points; Starting from the turning point at one end of the line segment, sampling path points on the line segment according to a preset sampling distance until reaching the turning point at the other end of the line segment, obtaining all path points on the line segment, and storing the line segment containing all path points as an element of a path container; After it is determined that all turning points are selected, each line segment in the path container is sequentially connected to form a path.
3. The method according to claim 2, characterized in that The performing rationality detection on the path includes: Traverse each path point in the path; Get the format of the waypoints and their positions on the static map; Determine that the waypoint is in the correct format and, based on the waypoint's position on the static map, determine whether the waypoint is within the traversable area of the static map; If the format of the waypoint is normal and is within the traversable area of the static map, it is determined that the rationality check of the waypoint has passed; If it is determined that the rationality test of each path point in the path passes, it is determined that the rationality test of the path passes.
4. The method according to claim 1, characterized in that: The navigation state detection by line drawing navigation includes: Traversing the path points, calculating the Euclidean distance between the path points and the robot, and when a path point whose Euclidean distance is within the clipping distance is found for the first time, clipping the path to remove the portion of the path before the path point; For the path points after this path point, determine whether there are path points whose Euclidean distance is within the detection range. If there are path points whose Euclidean distance is within the detection range, determine whether all path points whose Euclidean distance is within the detection range are located in the passable area of the cost map. If all path points whose Euclidean distance is within the detection range are located in the passable area, it is determined that the navigation status test has passed.
5. The method according to claim 4, characterized in that The navigation state detection by line drawing navigation also includes: If it is determined that the navigation state detection fails, it is determined whether the robot is on the path; If it is determined that the robot is not on the path, the robot is controlled to navigate toward the starting turning point and the number of navigations is recorded; if the robot navigates to the starting turning point before the number of navigations exceeds the number threshold, the process jumps to the step of executing the navigation task received and reading the pre-stored turning point information; If it is determined that the robot is on the path, the starting time when the waypoint is detected to be in the obstacle area is recorded, and the duration from the starting time to the current time is taken as the waiting time of the robot; if it is detected that the waypoint is no longer in the obstacle area before the waiting time exceeds the tolerance time, it is determined that the exception handling is completed and navigation continues.
6. The method according to claim 5, characterized in that The navigation state detection by line drawing navigation also includes: If the number of navigations exceeds the threshold and the robot has not navigated to the starting turning point; or if the waiting time exceeds the tolerance time and the waypoint is detected to be in an obstacle area, the navigation task is terminated and an exception is reported.
7. The method according to claim 1, characterized in that The robot speed is continuously planned and released according to the map information until the navigation execution is completed, including: Calculate the distance between the robot and the end path point, and when the distance is less than the arrival tolerance distance, determine that the robot has reached the turning point and publish zero speed; When the distance is not less than the arrival tolerance distance, the dual-loop PID method is used to plan the robot's speed, and the trajectory is generated according to the control frequency and sampling frequency to detect whether the trajectory is in the passable area of the cost map. If so, the robot's speed is published, otherwise zero speed is published.
8. A robot navigation device, characterized in that: The device comprises: The first module is used to read pre-stored turning point information in response to the received navigation task; wherein the turning point information includes the position of the turning point in the global map; The second module is used to generate a path according to the turning point information, perform a rationality check on the path, and determine whether the path is feasible; wherein the path includes a plurality of continuous line segments, and the two endpoints of each line segment are turning points; The third module is used to navigate the robot to the starting turning point when the path is feasible, perform navigation status detection through line drawing navigation, and continuously plan and publish the robot speed according to the map information until the navigation is completed; wherein, the navigation status detection includes determining whether the robot is on the path, clipping the path, and performing passability detection on the path points in front of the robot.
9. A robot, characterized in that: The robot comprises: at least one processor; at least one memory for storing at least one program; When the at least one program is executed by the at least one processor, the at least one processor implements the method according to any one of claims 1 to 7.
10. A computer-readable storage medium storing a program executable by a processor, characterized in that: The processor-executable program is used to perform the method according to any one of claims 1 to 7 when executed by the processor.