Path walking method, system, and terminal device

By determining whether the current index coordinates are in the preset path coordinate array, and by adjusting and correcting the path according to whether the end coordinate can be directly reached or the path deviation exists, the problem of complex and inefficient calculation of robot walking path planning in the existing technology is solved, and more efficient walking path planning and execution is achieved.

CN114527764BActive Publication Date: 2025-04-22SHENZHEN UMOUSE TECH DEV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210199625.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-03-01
Publication Date
2025-04-22
Estimated Expiration
2042-03-01

AI Technical Summary

Technical Problem

The existing robot walking path planning method is complex and has low walking efficiency, making it difficult to effectively solve the problem of robots' efficient path planning in grid maps.

Method used

By determining whether the current index coordinates are in the preset path coordinate array, if so, determine whether the end coordinate can be directly reached. If it cannot be directly reached, determine the longest straight line path, and adjust the walking direction when there are obstacles in the path; if otherwise, correct deviation operations are performed according to the degree of path deviation until the end coordinate is reached.

Benefits of technology

It reduces the time and space complexity required to calculate the walking path, improves the efficiency of the robot walking, is stronger robust, and does not have high requirements for the robot position information and real-time obstacles during walking.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114527764B_ABST
    Figure CN114527764B_ABST
Patent Text Reader

Abstract

The present invention discloses a path walking method, system and terminal device, the steps of the path walking method include: S10, judging whether the current index coordinate is the index coordinate in the preset path coordinate array; S20, if yes, determining whether the terminal coordinate in the path coordinate array can be directly reached, directly going to the terminal coordinate when the terminal coordinate can be directly reached, determining the longest straight path when the terminal coordinate cannot be directly reached, so as to walk along the straight path, and adjusting the current walking direction when there are obstacles in the straight path, and executing step S10 based on the adjusted walking direction; S30, if no, determining the path deviation degree based on the current index coordinate, performing a deviation correction operation for the current walking direction according to the path deviation degree, and executing step S20 when walking based on the walking direction after the deviation correction operation, until the terminal coordinate in the path coordinate array is reached. The present invention can improve the walking efficiency of the robot when walking.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of terminal equipment, and in particular to a path walking method, system and terminal equipment. Background Art

[0002] At present, sweeping robots mainly clean based on grid maps. When the robot walks from point A to point B, it can directly calculate the grid coordinate array that it needs to pass through through various algorithms.

[0003] How to find an efficient path based on these grid coordinates has always been a common concern. If each grid coordinate is traversed in sequence, the robot's path will have too many turns and low efficiency; if the angular velocity and acceleration in each time period are directly calculated, a lot of time and space are required to complete the calculation.

[0004] In summary, the existing planning methods for robot walking paths have the problems of complex calculation methods and low walking efficiency. Summary of the invention

[0005] The main purpose of the present invention is to provide a path walking method, system and terminal device, aiming to improve the walking efficiency of a robot when walking.

[0006] To achieve the above object, the present invention provides a path walking method, the path walking comprising:

[0007] S10, determining whether the current index coordinate is an index coordinate in a preset path coordinate array;

[0008] S20, if yes, determine whether the terminal coordinates in the path coordinate array can be directly reached, go directly to the terminal coordinates if the terminal coordinates can be directly reached, determine the longest straight path if the terminal coordinates cannot be directly reached, walk along the straight path, and adjust the current walking direction if there are obstacles in the straight path, and execute step S10 based on the adjusted walking direction;

[0009] S30. If not, determine the path deviation degree based on the current index coordinates, perform a deviation correction operation on the current walking direction according to the path deviation degree, and execute step S20 while walking in the walking direction after the deviation correction operation until reaching the end point coordinates in the path coordinate array.

[0010] Optionally, the step of determining the longest straight line path includes:

[0011] The first index coordinate corresponding to the change in walking direction is determined from the path coordinate array, and the current index coordinate and the first index coordinate are connected to obtain a straight line path.

[0012] Optionally, the step of adjusting the current walking direction when there is an obstacle in the straight path includes:

[0013] When there is an obstacle in the straight path, a first target path angle is determined, and a current walking direction is adjusted according to an angle difference between a current orientation angle of the robot and the first target path angle;

[0014] Adjusting the current walking direction according to the angle difference between the current orientation angle of the robot and the first target travel angle includes:

[0015] The wheel speed between the two wheels of the robot is adjusted in real time according to the angle difference between the current orientation angle of the robot and the first target travel angle to adjust the current walking direction.

[0016] Optionally, the step of determining a first target path angle when an obstacle exists in the straight path includes:

[0017] When an obstacle exists in the straight path, a second index coordinate adjacent to the current index coordinate is acquired, and a first target path angle is determined according to a line connecting the current index coordinate and the second index coordinate.

[0018] Optionally, the step of determining whether the destination coordinates in the path coordinate array can be directly reached includes:

[0019] Determine whether there is an obstacle between the current index coordinate and the end point coordinate;

[0020] If there are no obstacles, it is determined that the destination coordinates can be reached directly.

[0021] Optionally, the path deviation degree includes: first-level path deviation;

[0022] The step of performing a deviation correction operation on the current walking direction according to the path deviation degree comprises:

[0023] When the path deviation degree is the first-level path deviation, directly acquiring a third index coordinate corresponding to a change in the walking direction in the path coordinate array based on the current index coordinate;

[0024] A second target travel angle is determined according to a line connecting the current index coordinate and the third index coordinate, and a deviation correction operation is performed on the current walking direction based on the second target travel angle.

[0025] Optionally, the path deviation degree includes: secondary path deviation;

[0026] The step of performing a deviation correction operation on the current walking direction according to the path deviation degree also includes:

[0027] When the path deviation degree is the secondary path deviation degree, obtaining a fourth index coordinate in the path array before the path deviation, and determining a fifth index coordinate in the path array that is spaced apart from the fourth index coordinate in the forward direction;

[0028] A third target travel angle is determined according to a line connecting the current index coordinate and the fifth index coordinate, and a deviation correction operation is performed on the current walking direction according to the third target travel angle.

[0029] Optionally, the path deviation degree includes: three levels of path deviation;

[0030] The step of performing a deviation correction operation on the current walking direction according to the path deviation degree also includes:

[0031] When the path deviation degree is the third level path deviation, the fifth index coordinate in the path coordinate array which is closest to the current index coordinate is directly returned to complete the deviation correction operation on the current walking direction.

[0032] To achieve the above object, the present invention further provides a path walking system, the path walking system comprising:

[0033] A judgment module, used to judge whether the current index coordinate is an index coordinate in a preset path coordinate array;

[0034] an adjustment module, for determining whether the end point coordinates in the path coordinate array can be directly reached, and directly going to the end point coordinates when the end point coordinates can be directly reached, and determining the longest straight path when the end point coordinates cannot be directly reached, so as to walk along the straight path, and adjusting the current walking direction when there are obstacles in the straight path, and judging whether the current index coordinates are the index coordinates in the preset path coordinate array based on the adjusted walking direction;

[0035] A correction module is used to determine the degree of path deviation based on the current index coordinates, perform a correction operation on the current walking direction according to the degree of path deviation, determine the longest straight path based on the walking direction after the correction operation, and adjust the current walking direction when there are obstacles in the straight path, and determine whether the current index coordinates are the index coordinates in the preset path coordinate array based on the adjusted walking direction, until the end point coordinates in the path coordinate array are reached.

[0036] Among them, each functional module of the path walking system of the present invention implements the steps of the path walking method described above during operation.

[0037] To achieve the above-mentioned purpose, the present invention also provides a terminal device, which includes: a memory, a processor, and a path walking program stored in the memory and executable on the processor, and the path walking program implements the steps of the path walking method described above when executed by the processor.

[0038] In addition, to achieve the above-mentioned purpose, the present invention also provides a computer program product, wherein the computer program product includes a computer program, and when the computer program is executed by a processor, the steps of the path walking method described above are implemented.

[0039] The present invention provides a path walking method, system, terminal device and computer program product, the path walking method comprising the following steps: S10, judging whether the current index coordinate is an index coordinate in a preset path coordinate array; S20, if so, determining whether the terminal coordinate in the path coordinate array can be directly reached, and directly going to the terminal coordinate when the terminal coordinate can be directly reached, and determining the longest straight path when the terminal coordinate cannot be directly reached, so as to walk along the straight path, and adjusting the current walking direction when there is an obstacle in the straight path, and executing step S10 based on the adjusted walking direction; S30, if not, determining the path deviation degree based on the current index coordinate, performing a correction operation on the current walking direction according to the path deviation degree, and executing step S20 when walking based on the walking direction after the correction operation until the terminal coordinate in the path coordinate array is reached.

[0040] Compared to the robot walking method in the prior art that traverses each grid coordinate and calculates the angular velocity and acceleration in each time period, the present invention first determines whether the current index coordinate is in the preset path coordinate array. If so, it is determined whether to walk along the planned straight path based on the judgment result. If not, the walking direction is corrected, and the straight path is continued to be planned according to the walking direction after the correction operation. This time, the present invention proposes a robot walking strategy that reduces the time and space complexity required to calculate the walking path, that is, the required time and space are smaller, and at the same time it has stronger robustness, and does not have high requirements on the robot's posture information and real-time obstacles during walking. The present invention further improves the efficiency of robot path planning and walking. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] Figure 1 A schematic diagram of the structure of the hardware operating environment involved in the embodiment of the present invention;

[0042] Figure 2 A schematic diagram of a flow chart of an embodiment of a path walking method of the present invention;

[0043] Figure 3This is a schematic diagram of the functional modules of an embodiment of a path walking system of the present invention.

[0044] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0045] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.

[0046] like Figure 1 As shown, Figure 1 It is a schematic diagram of the device structure of the hardware operating environment involved in the embodiment of the present invention.

[0047] It should be noted that the terminal device in the embodiment of the present invention may be a terminal device for implementing path walking, and the terminal device may specifically be a robot or the like.

[0048] like Figure 1 As shown, the device may include: a processor 1001, such as a CPU, a network interface 1004, a user interface 1003, a memory 1005, and a communication bus 1002. Among them, the communication bus 1002 is used to realize the connection and communication between these components. The user interface 1003 may include a display screen (Display), an input unit such as a keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a WI-FI interface). The memory 1005 may be a high-speed RAM memory, or a stable memory (non-volatile memory), such as a disk memory. The memory 1005 may also be a storage device independent of the aforementioned processor 1001.

[0049] Those skilled in the art will understand that Figure 1 The device structure shown in the figure does not constitute a limitation of the device, and may include more or less components than shown in the figure, or combine certain components, or arrange the components differently.

[0050] like Figure 1 As shown, the memory 1005 as a computer storage medium may include an operating system, a network communication module, a user interface module, and a path walking program. The operating system is a program that manages and controls the hardware and software resources of the device and supports the operation of the path walking program and other software or programs. Figure 1 In the device shown, the user interface 1003 is mainly used for data communication with the client; the network interface 1004 is mainly used for establishing a communication connection with the server; and the processor 1001 can be used to call the path walking program stored in the memory 1005 and perform the following operations:

[0051] S10, determining whether the current index coordinate is an index coordinate in a preset path coordinate array;

[0052] S20, if yes, determine whether the terminal coordinates in the path coordinate array can be directly reached, go directly to the terminal coordinates if the terminal coordinates can be directly reached, determine the longest straight path if the terminal coordinates cannot be directly reached, walk along the straight path, and adjust the current walking direction if there are obstacles in the straight path, and execute step S10 based on the adjusted walking direction;

[0053] S30. If not, determine the path deviation degree based on the current index coordinates, perform a deviation correction operation on the current walking direction according to the path deviation degree, and execute step S20 while walking in the walking direction after the deviation correction operation until reaching the end point coordinates in the path coordinate array.

[0054] Furthermore, the processor 1001 may also be used to call a path walking program stored in the memory 1005, and perform the following operations:

[0055] The first index coordinate corresponding to the change in walking direction is determined from the path coordinate array, and the current index coordinate and the first index coordinate are connected to obtain a straight line path.

[0056] Furthermore, the processor 1001 may also be used to call a path walking program stored in the memory 1005, and perform the following operations:

[0057] When there is an obstacle in the straight path, a first target path angle is determined, and a current walking direction is adjusted according to an angle difference between a current orientation angle of the robot and the first target path angle;

[0058] The processor 1001 may also be used to call the path walking program stored in the memory 1005, and perform the following operations:

[0059] The wheel speed between the two wheels of the robot is adjusted in real time according to the angle difference between the current orientation angle of the robot and the first target travel angle to adjust the current walking direction.

[0060] Furthermore, the processor 1001 may also be used to call a path walking program stored in the memory 1005, and perform the following operations:

[0061] When an obstacle exists in the straight path, a second index coordinate adjacent to the current index coordinate is acquired, and a first target path angle is determined according to a line connecting the current index coordinate and the second index coordinate.

[0062] Furthermore, the processor 1001 may also be used to call a path walking program stored in the memory 1005, and perform the following operations:

[0063] Determine whether there is an obstacle between the current index coordinate and the end point coordinate;

[0064] If there are no obstacles, it is determined that the destination coordinates can be reached directly.

[0065] Further, the path deviation degree includes: first-level path deviation;

[0066] The processor 1001 may also be used to call the path walking program stored in the memory 1005, and perform the following operations:

[0067] When the path deviation degree is the first-level path deviation, directly acquiring a third index coordinate corresponding to a change in the walking direction in the path coordinate array based on the current index coordinate;

[0068] A second target travel angle is determined according to a line connecting the current index coordinate and the third index coordinate, and a deviation correction operation is performed on the current walking direction based on the second target travel angle.

[0069] Further, the path deviation degree includes: secondary path deviation;

[0070] The processor 1001 may also be used to call the path walking program stored in the memory 1005, and perform the following operations:

[0071] When the path deviation degree is the secondary path deviation degree, obtaining a fourth index coordinate in the path array before the path deviation, and determining a fifth index coordinate in the path array that is spaced apart from the fourth index coordinate in the forward direction;

[0072] A third target travel angle is determined according to a line connecting the current index coordinate and the fifth index coordinate, and a deviation correction operation is performed on the current walking direction according to the third target travel angle.

[0073] Further, the path deviation degree includes: three levels of path deviation;

[0074] The processor 1001 may also be used to call the path walking program stored in the memory 1005, and perform the following operations:

[0075] The step of performing a deviation correction operation on the current walking direction according to the path deviation degree also includes:

[0076] When the path deviation degree is the third level path deviation, the fifth index coordinate in the path coordinate array which is closest to the current index coordinate is directly returned to complete the deviation correction operation on the current walking direction.

[0077] Reference Figure 2 , Figure 2 Schematic diagram of the flow chart of the first embodiment of the path walking method of the present invention.

[0078] In this embodiment, an embodiment of a path walking method is provided. The path walking method of the present invention can be applied to a cleaning robot (such as a sweeper, a mop, a scrubber, or a sweeper and mop all-in-one). It should be noted that although the logical order is shown in the flow chart, in some cases, the steps shown or described may be executed in a different order than here.

[0079] Step S10, determining whether the current index coordinate is an index coordinate in a preset path coordinate array;

[0080] After determining the walking strategy from the starting point to the end point, the robot starts walking, and during the walking process, it determines whether the current index coordinate is the index coordinate in the path coordinate array. Only when it is determined that the current index coordinate is the index coordinate in the path coordinate array, it continues to determine the longest straight line path based on the current index coordinate to walk along the straight line path.

[0081] It should be noted that the robot may include a sweeping robot. The robot sends the dual-wheel speed in real time to control the robot to walk from point A to point B based on the path array, the real-time position of the robot, and the status of each point on the grid map (cleaned / obstacle). In this embodiment, before walking, the robot needs to calculate the path coordinate array (arr) based on the grid map. The path coordinate array contains multiple groups of index coordinates. For example, the path coordinate array from point A to point B is [(1,2)(1,3)(2,4)(2,5)(3,6)(4,7)], where (1,2) is the coordinate of the starting point A, and (4,7) is the coordinate of the end point B. When starting to walk, the robot is located at the position of array index 0, that is, (1,2), and calculates the spin angle based on the coordinates of index 0 and index 1 (1,3) to adjust the spin direction. Therefore, the initial action must be a spin, unless the calculated spin angle is exactly equal to the current orientation angle of the robot.

[0082] Step S20: if yes, determine whether the destination coordinate in the path coordinate array can be directly reached, go directly to the destination coordinate if the destination coordinate can be directly reached, determine the longest straight path if the destination coordinate cannot be directly reached, walk along the straight path, and adjust the current walking direction if there is an obstacle in the straight path, and execute step S10 based on the adjusted walking direction;

[0083] It should be noted that in this embodiment, since a straight path is the most efficient way of walking, a straight path is pre-set as the optimal path in this embodiment. When there are obstacles in the straight path, the straight path will no longer be feasible, and the current orientation angle of the robot needs to be adjusted to re-plan the straight path.

[0084] When the robot determines that the current index coordinate is the index coordinate in the path coordinate array, it first needs to determine whether it can directly reach the end coordinate from the current index coordinate. When it can directly reach the end coordinate, it will go to the end coordinate in a straight line without obstacles and complete the walking quickly. When it cannot directly reach the end coordinate, the longest straight path will be determined according to the current index coordinate, and then when walking along the straight path, it will further determine whether there are obstacles in the straight path, so as to determine different walking paths according to different judgment results, wherein the judgment result may include: there are obstacles in the straight path and there are no obstacles in the straight path. In addition, when walking along the walking path, the robot needs to determine whether the current index coordinate is the index coordinate in the path coordinate array at any time, so as to decide whether the walking path of the robot needs to be corrected according to the judgment result.

[0085] It should be noted that, in this embodiment, the cleaning robot (e.g., a sweeper / mop / sweeper-mop / scrubber) may determine whether there are obstacles in the walking path by: sensing the obstacles in the walking path in real time through the sensors carried by the cleaning robot, or marking the obstacles in advance during the cleaning and mapping process based on historical walking records. Among them, sensing the obstacles in the walking path in real time through the sensors carried by the cleaning robot may include: the cleaning robot may detect whether there are obstacles through the laser radar signal emitted by the laser machine or feedback whether there are obstacles through the infrared signal of the inertial navigation sweeper.

[0086] Step S30, if not, determine the path deviation degree based on the current index coordinates, perform a correction operation on the current walking direction according to the path deviation degree, and execute step S20 while walking in the walking direction after the correction operation until reaching the end coordinates in the path coordinate array.

[0087] When the robot determines that the current index coordinate is not the index coordinate in the path coordinate array, it means that the current walking path has been offset. Therefore, the current walking direction needs to be corrected so that the robot returns to the walking path containing the index coordinate in the path coordinate array. After the correction is completed, the longest straight path is determined again according to the corrected walking direction and whether there are obstacles in the straight path to determine the walking path.

[0088] It should be noted that in this embodiment, due to the control error of the robot's wheel speed and the positioning error of the coordinates, it is impossible to ensure that the robot is always located at a certain point in the path coordinate array when walking. Therefore, when the machine deviates from arr, it is necessary to judge the degree of deviation at this time to perform corresponding correction operations according to the degree of deviation for the walking direction.

[0089] In this embodiment, the robot starts walking after determining the walking strategy from the starting point to the end point, and judges whether the current index coordinate is the index coordinate in the path coordinate array during the walking process. When it is judged that the current index coordinate is the index coordinate in the path coordinate array, it is pre-judged whether the end point coordinate can be directly reached from the current coordinate index coordinate. When it is not possible to directly reach the end point coordinate, the longest straight line path is determined based on the current index coordinate to walk along the straight line path. It is further judged whether there are obstacles in the straight line path to determine different walking paths according to different judgment results. When the robot walks along the walking path, it needs to continue to judge whether the current index coordinate is the index coordinate in the path coordinate array to decide whether it needs to plan the straight line path again for walking according to the judgment result. When the robot judges that the current index coordinate is not the index coordinate in the path coordinate array, it determines that the current walking path has been offset, so it is necessary to correct the current walking direction. After the correction is completed, the longest straight line path is determined again according to the corrected walking direction and whether there are obstacles in the straight line path to determine the walking path.

[0090] Compared to the robot walking method in the prior art that traverses each grid coordinate and calculates the angular velocity and acceleration in each time period, the present invention first determines whether the current index coordinate is in the preset path coordinate array. If so, it is determined whether to walk along the planned straight path based on the judgment result. If not, the walking direction is corrected, and the straight path is continued to be planned according to the walking direction after the correction operation. This time, the present invention proposes a robot walking strategy that reduces the time and space complexity required to calculate the walking path, that is, the required time and space are smaller, and at the same time it has stronger robustness, and does not have high requirements on the robot's posture information and real-time obstacles during walking. On this basis, the present invention further improves the efficiency of robot path planning and walking.

[0091] Furthermore, based on the first embodiment of the path walking method of the present invention, a second embodiment of the path walking method of the present invention is proposed.

[0092] The difference between this embodiment and the first embodiment is that, in this embodiment, in the above step S20, the step of "determining the longest straight line path" may include:

[0093] Step S201, determining the first index coordinate corresponding to the change in walking direction from the path coordinate array, and connecting the current index coordinate and the first index coordinate to obtain a straight line path.

[0094] When the robot plans a straight path, it first obtains the index coordinate corresponding to the change in walking direction, that is, the first index coordinate, which also belongs to the path coordinate array, and then connects the current index coordinate with the first index coordinate to obtain a straight path, so that the robot can walk along the straight path.

[0095] Specifically, for example, when the robot determines that the current index coordinate is the index coordinate in the path coordinate array, in order to improve walking efficiency, it will directly plan a straight path to walk along the straight path. Assuming that the current index coordinate (cur) is at index i of arr, it is determined whether i+1, i+2, i+3, ..., i+n are in the same direction (in this embodiment, the eight directions are 0°, 45°, 90°, 135°, 180°, 225°, 270° and 315°). Assuming that the direction changes at i+n, cur (index i) is connected with index i+n at this time, and the angle between the current direction and the connection line is directly calculated. The robot can lock this straight line and go forward.

[0096] Furthermore, in the above step S20, “adjusting the current walking direction when there is an obstacle in the straight path” may include:

[0097] Step S202, determining a first target travel angle when there is an obstacle in the straight path, and adjusting the current walking direction according to the angle difference between the current orientation angle of the robot and the first target travel angle.

[0098] It should be noted that, in this embodiment, when the robot determines whether there is an obstacle in the straight path, the determination result can be divided into: there is an obstacle in the straight path; and there is no obstacle in the straight path.

[0099] When it is determined that there are no obstacles in the straight path, the robot can walk directly along the straight path; when it is determined that there are obstacles in the straight path, the first target path angle is obtained, and the angle difference between the current orientation angle of the robot and the first target path angle is determined to adjust the direction of travel according to the angle difference, wherein the current orientation angle of the robot is the angle between the current orientation of the robot and the X-axis. In this embodiment, the Y-axis can also be used as a reference axis.

[0100] Wherein, adjusting the current walking direction according to the angle difference between the current orientation angle of the robot and the first target travel angle may include:

[0101] Step a: adjusting the wheel speed between the two wheels of the robot in real time according to the angle difference between the current orientation angle of the robot and the first target travel angle to adjust the current walking direction.

[0102] After determining the first target travel angle, the robot can adjust the wheel speed between the two wheels of the robot in real time according to the angle difference between the robot's current orientation angle and the target travel angle to adjust the robot's current walking direction, thereby realizing the robot's real-time rapid adjustment of the walking direction and thus improving the robot's walking efficiency.

[0103] Furthermore, in the above step S202, “determining a first target path angle when an obstacle exists in the straight path” may include:

[0104] Step b, when there is an obstacle in the straight path, obtaining a second index coordinate adjacent to the current index coordinate, and determining a first target path angle according to a line connecting the current index coordinate and the second index coordinate.

[0105] It should be noted that, in this embodiment, when the robot detects the presence of an obstacle in a straight path, it needs to adjust the speed of the two wheels, and then adjust the walking direction of the robot.

[0106] Specifically, for example, when the current index coordinate of the robot is i, the second index coordinate i+1 is obtained, wherein the second index coordinate i+1 is the coordinate adjacent to the right of the index coordinate i, and the angle between the line between the index coordinate i and the second index coordinate i+1 and the X coordinate axis is used as the first target path angle. It should be noted that in this embodiment, the Y coordinate axis can also be used as the reference axis.

[0107] Furthermore, in the above step S202, "determining whether the end point coordinates in the path coordinate array can be directly reached" may include:

[0108] Step c, determining whether there is an obstacle between the line connecting the current index coordinate and the end point coordinate;

[0109] Step d: If there is no obstacle, it is determined that the destination coordinates can be reached directly.

[0110] When it is determined that the current index coordinate is the index coordinate in the path coordinate array, in order to reach the end coordinate in the path coordinate array as quickly as possible, the robot needs to determine in advance whether it can go directly from the current index coordinate to the end coordinate before walking.

[0111] Specifically, for example, the robot needs to determine in advance whether there will be an obstacle in the middle of the line connecting the current index coordinate and the end point coordinate. If there is no obstacle on the line, the robot can go to the end point coordinate in a straight line. If there is an obstacle on the line, the robot cannot go to the end point coordinate in a straight line. At this time, the robot will further plan the longest straight line path to achieve efficient walking.

[0112] In this embodiment, when planning a straight path, the robot first obtains the index coordinate corresponding to the change in walking direction, that is, the first index coordinate, which also belongs to the path coordinate array, and then connects the current index coordinate with the first index coordinate to obtain the straight path. When it is determined that there is no obstacle in the straight path, the robot can walk directly along the straight path; when it is determined that there is an obstacle in the straight path, the first target path angle is obtained, and the angle difference between the current orientation angle of the robot and the first target path angle is determined, so as to adjust the path direction according to the angle difference.

[0113] The present invention connects the index coordinate corresponding to the change in walking direction and the current index coordinate to obtain a straight path, and when there is an obstacle in the straight path, adjusts the direction of the robot according to the current index coordinate and the index coordinate adjacent to the current index coordinate, thereby realizing flexible adjustment of the robot's walking direction, avoiding the calculation of complex angular velocity and acceleration, and improving the robot's walking efficiency.

[0114] Furthermore, based on the first and second embodiments of the path walking method of the present invention, a third embodiment of the path walking method of the present invention is proposed.

[0115] In this embodiment, in the above step S30, “performing a deviation correction operation on the current walking direction according to the path deviation degree” may include:

[0116] Step S301, when the path deviation degree is the first-level path deviation, directly acquiring a third index coordinate corresponding to a change in the walking direction in the path coordinate array based on the current index coordinate;

[0117] Step S302: determine a second target travel angle according to a line connecting the current index coordinate and the third index coordinate, and perform a deviation correction operation on the current walking direction based on the second target travel angle.

[0118] It should be noted that, in this embodiment, when the robot detects that the current walking path has deviated, it is necessary to predetermine the degree of deviation before correcting the walking direction. In this embodiment, three degrees of path deviation are defined, namely, the first-level path deviation degree, the second-level path deviation degree and the third-level path deviation degree. Among them, the first-level path deviation degree is the case where the deviation degree of the walking direction is the lightest, and the third-level path deviation degree is the case where the deviation degree of the walking direction is the heaviest.

[0119] Specifically, for example, when the path deviation degree is the first level path deviation degree, although the current index coordinate is not in the path coordinate array, it is adjacent to a certain index coordinate in the path coordinate array. At this time, the path deviation can be ignored, and a straight line path is planned directly based on the current index coordinate. That is, first obtain the index coordinate corresponding to the change in walking direction, that is, the third index coordinate, and connect the current index coordinate with the third index coordinate to obtain a straight line path, so that the robot can walk along the straight line path to complete the deviation correction operation.

[0120] Furthermore, in the above step S30, “performing a deviation correction operation on the current walking direction according to the path deviation degree” may include:

[0121] Step S303, when the path deviation degree is the secondary path deviation degree, obtaining the fourth index coordinate in the path array before the path deviation, and determining the fifth index coordinate in the path array that is spaced apart from the fourth index coordinate in the forward direction;

[0122] Step S304: determine a third target travel angle according to a line connecting the current index coordinate and the fifth index coordinate, and perform a deviation correction operation on the current walking direction according to the third target travel angle.

[0123] It should be noted that, in this embodiment, when the path deviation degree is a secondary path deviation degree, assuming that the machine is located at index i of arr just before the loss of position, in order to make the transition smooth, the target path angle is calculated from the coordinates of cur and i+2.

[0124] Specifically, for example, when it is determined that the degree of path deviation is a secondary path deviation degree, the fourth index coordinate in the path coordinate array before the walking path deviation is obtained, and then based on the fourth index coordinate, if the index at the fourth index coordinate is i, then the index coordinate corresponding to the index i+2 is determined as the fifth index coordinate, and then the angle between the line between the current index coordinate and the fifth index coordinate and the X-coordinate axis is determined as the third target travel angle, and the angle difference between the third target travel angle and the current orientation angle of the robot is determined, and then the travel direction of the robot is adjusted according to the angle difference.

[0125] Furthermore, in the above step S30, “performing a deviation correction operation on the current walking direction according to the path deviation degree” may include:

[0126] Step S305 , when the path deviation degree is the third level path deviation, directly return the sixth index coordinate in the path coordinate array that is closest to the current index coordinate to complete the deviation correction operation on the current walking direction.

[0127] When the path deviation degree is the third level, it means that the robot's path deviation is serious at this time. The robot will directly return the index coordinate in the path coordinate array closest to the current index coordinate, that is, the sixth index coordinate, to plan a straight line path for walking again, thereby improving the robot's walking efficiency.

[0128] In this embodiment, the path deviation degree of the robot is confirmed in advance, and then corresponding correction operations are taken according to different path deviation degrees, and after the correction is completed, the robot continues to walk along the straight path preferentially. Therefore, in the process of walking along the straight path preferentially, the present invention takes targeted correction operations according to different path deviation degrees, realizes flexible correction during the robot's walking process, and in this embodiment, there is no high requirement for the robot's posture information and real-time obstacles during the walking process, which improves the robot's walking efficiency, so that the robot can quickly and accurately reach the end coordinates in the path coordinate array.

[0129] In addition, the embodiment of the present invention also provides a path walking system, referring to Figure 3 , Figure 3 This is a functional module diagram of an embodiment of the path walking of the present invention. Figure 3 As shown, the path walking system of the present invention comprises:

[0130] A judging module 10, used to judge whether the current index coordinate is an index coordinate in a preset path coordinate array;

[0131] An adjustment module 20, for determining whether the end point coordinates in the path coordinate array can be directly reached, and directly going to the end point coordinates when the end point coordinates can be directly reached, and determining the longest straight path when the end point coordinates cannot be directly reached, so as to walk along the straight path, and adjusting the current walking direction when there are obstacles in the straight path, and judging whether the current index coordinates are the index coordinates in the preset path coordinate array based on the adjusted walking direction;

[0132] The correction module 30 is used to determine the degree of path deviation based on the current index coordinates, perform a correction operation on the current walking direction according to the degree of path deviation, and determine the longest straight path based on the walking direction after the correction operation, and adjust the current walking direction when there are obstacles in the straight path, and determine whether the current index coordinates are the index coordinates in the preset path coordinate array based on the adjusted walking direction, until the end point coordinates in the path coordinate array are reached.

[0133] Furthermore, the adjustment module 20 includes:

[0134] A connection unit is used to determine the first index coordinate corresponding to the change in walking direction from the path coordinate array, and connect the current index coordinate and the first index coordinate to obtain a straight path.

[0135] Furthermore, the adjustment module 20 further includes:

[0136] An adjustment unit is used to determine a first target travel angle when an obstacle exists in the straight path, and adjust the current walking direction according to the angle difference between the current orientation angle of the robot and the first target travel angle.

[0137] The adjustment unit comprises:

[0138] The wheel speed adjustment subunit is used to adjust the wheel speed between the two wheels of the robot in real time according to the angle difference between the current orientation angle of the robot and the first target travel angle, so as to adjust the current walking direction.

[0139] Furthermore, the adjustment unit further includes:

[0140] A determination subunit is used to obtain a second index coordinate adjacent to the current index coordinate when an obstacle exists in the straight path, and to determine a first target path angle according to a line connecting the current index coordinate and the second index coordinate.

[0141] Furthermore, the adjustment module includes:

[0142] An obstacle determination unit is used to determine whether there is an obstacle in the middle of the line connecting the current index coordinate and the end point coordinate;

[0143] The direct access unit is used to determine whether the destination coordinate can be directly reached if there are no obstacles.

[0144] Further, the path deviation degree includes: first-level path deviation;

[0145] The correction module 30 includes:

[0146] an acquisition unit, configured to directly acquire, based on the current index coordinates, a third index coordinate corresponding to a change in the walking direction in the path coordinate array when the path deviation degree is the first-level path deviation;

[0147] The first deviation correction unit is used to determine a second target travel angle according to a line connecting the current index coordinate and the third index coordinate, and perform a deviation correction operation on the current walking direction based on the second target travel angle.

[0148] Further, the path deviation degree includes: secondary path deviation;

[0149] The correction module 30 further includes:

[0150] a determining unit, configured to obtain, when the path deviation degree is the secondary path deviation degree, a fourth index coordinate in the path array before the path deviation, and determine a fifth index coordinate in the path array that is spaced from the fourth index coordinate in a forward direction;

[0151] The second deviation correction unit is used to determine a third target travel angle according to a line connecting the current index coordinate and the fifth index coordinate, and perform a deviation correction operation on the current walking direction according to the third target travel angle.

[0152] Further, the path deviation degree includes: three levels of path deviation;

[0153] The correction module 30 further includes:

[0154] The third deviation correction unit is used to directly return the fifth index coordinate in the path coordinate array that is closest to the current index coordinate when the path deviation degree is the third level path deviation, so as to complete the deviation correction operation on the current walking direction.

[0155] The specific implementation of each functional module of the path walking system of the present invention is basically the same as the various embodiments of the path walking method described above, and will not be described in detail here.

[0156] In addition, an embodiment of the present invention further provides a computer program product, which includes a computer program. When the computer program is executed by a processor, the steps of the path walking method described in any embodiment of the above path walking method are implemented.

[0157] The specific embodiments of the computer program product of the present invention are basically the same as the embodiments of the above-mentioned path walking method, and will not be described in detail here.

[0158] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.

[0159] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.

[0160] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, a magnetic disk, or an optical disk), and includes a number of instructions for enabling a terminal device (which can be a robot, etc.) to execute the methods described in each embodiment of the present invention.

[0161] The above are only preferred embodiments of the present invention, and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A path walking method, characterized in that: The path walking method is applied to a robot, and the path walking method comprises the following steps: S10, determining whether the current index coordinate is an index coordinate in a preset path coordinate array; S20, if yes, determine whether the terminal coordinates in the path coordinate array can be directly reached, go directly to the terminal coordinates if the terminal coordinates can be directly reached, determine the longest straight path if the terminal coordinates cannot be directly reached, walk along the straight path, and adjust the current walking direction if there are obstacles in the straight path, and execute step S10 based on the adjusted walking direction; S30, if not, determining the path deviation degree according to the current index coordinates, performing a deviation correction operation on the current walking direction according to the path deviation degree, and executing step S20 based on the walking direction after the deviation correction operation until reaching the end point coordinates in the path coordinate array; The step of performing a deviation correction operation on the current walking direction according to the path deviation degree comprises: When the path deviation degree is a first-level path deviation, directly acquiring a third index coordinate corresponding to a change in the walking direction in the path coordinate array based on the current index coordinate; Determine a second target path angle according to a line connecting the current index coordinate and the third index coordinate, and perform a deviation correction operation on the current walking direction based on the second target path angle; The step of performing a deviation correction operation on the current walking direction according to the path deviation degree also includes: When the path deviation degree is a secondary path deviation degree, obtaining a fourth index coordinate in the path array before the path deviation, and determining a fifth index coordinate in the path array that is spaced apart from the fourth index coordinate in the forward direction; Determine a third target travel angle according to a line connecting the current index coordinate and the fifth index coordinate, and perform a deviation correction operation on the current walking direction according to the third target travel angle; The step of performing a deviation correction operation on the current walking direction according to the path deviation degree also includes: When the path deviation degree is the third level path deviation, the sixth index coordinate closest to the current index coordinate is directly returned to complete the deviation correction operation on the current walking direction, wherein the sixth index coordinate is the index coordinate in the path coordinate array.

2. The path walking method according to claim 1, characterized in that: The step of determining the longest straight line path comprises: The first index coordinate corresponding to the change in walking direction is determined from the path coordinate array, and the current index coordinate and the first index coordinate are connected to obtain a straight line path.

3. The path walking method according to claim 1, characterized in that: The step of adjusting the current walking direction when there is an obstacle in the straight path includes: When there is an obstacle in the straight path, a first target path angle is determined, and a current walking direction is adjusted according to an angle difference between a current orientation angle of the robot and the first target path angle; Adjusting the current walking direction according to the angle difference between the current orientation angle of the robot and the first target travel angle includes: The wheel speed between the two wheels of the robot is adjusted in real time according to the angle difference between the current orientation angle of the robot and the first target travel angle to adjust the current walking direction.

4. The path walking method according to claim 3, characterized in that: The step of determining a first target path angle when an obstacle exists in the straight path comprises: When there is an obstacle in the straight path, a second index coordinate adjacent to the current index coordinate is obtained, and a first target path angle is determined based on a line connecting the current index coordinate and the second index coordinate, wherein the second index coordinate is an index coordinate in the path coordinate array.

5. The path walking method according to claim 1, characterized in that: The step of determining whether the end point coordinates in the path coordinate array can be reached directly comprises: Determine whether there is an obstacle between the current index coordinate and the end point coordinate; If there are no obstacles, it is determined that the destination coordinates can be reached directly.

6. A path walking system, characterized in that: The path walking system comprises: A judgment module, used to judge whether the current index coordinate is an index coordinate in a preset path coordinate array; an adjustment module, for determining whether the end point coordinates in the path coordinate array can be directly reached, and directly going to the end point coordinates when the end point coordinates can be directly reached, and determining the longest straight path when the end point coordinates cannot be directly reached, so as to walk along the straight path, and adjusting the current walking direction when there are obstacles in the straight path, and judging whether the current index coordinates are the index coordinates in the preset path coordinate array based on the adjusted walking direction; A deviation correction module, used to determine the path deviation degree based on the current index coordinates, perform a deviation correction operation on the current walking direction according to the path deviation degree, determine the longest straight path based on the walking direction after the deviation correction operation, and adjust the current walking direction when there is an obstacle in the straight path, and determine whether the current index coordinates are index coordinates in a preset path coordinate array based on the adjusted walking direction, until reaching the end point coordinates in the path coordinate array; The correction module is also used to directly obtain the third index coordinate corresponding to the change of the walking direction in the path coordinate array based on the current index coordinate when the path deviation degree is the first-level path deviation; determine the second target path angle according to the connection line between the current index coordinate and the third index coordinate, and perform a correction operation on the current walking direction based on the second target path angle; The correction module is further used to obtain the fourth index coordinate in the path array before the path deviation when the path deviation degree is the secondary path deviation degree, and determine the fifth index coordinate in the path array that is spaced from the fourth index coordinate in the forward direction; determine the third target path angle according to the line connecting the current index coordinate and the fifth index coordinate, and perform a correction operation on the current walking direction according to the third target path angle; The correction module is also used to directly return the sixth index coordinate closest to the current index coordinate when the path deviation degree is the third level path deviation, so as to complete the correction operation on the current walking direction, wherein the sixth index coordinate is the index coordinate in the path coordinate array.

7. A terminal device, characterized in that: The terminal device includes a memory, a processor, and a path walking program stored in the memory and executable on the processor, wherein the path walking program implements the steps of the path walking method as claimed in any one of claims 1 to 5 when executed by the processor.

Citation Information

Patent Citations

  • Quasi three-dimensional map-based mobile robot global path planning method

    CN101769754A

  • Omnidirectional mobile AGV navigation rectification method

    CN106527443A