WO2021238222A1 - Obstacle avoidance method for robot, obstacle avoidance device for robot, robot, and storage medium - Google Patents

Obstacle avoidance method for robot, obstacle avoidance device for robot, robot, and storage medium Download PDF

Info

Publication number
WO2021238222A1
WO2021238222A1 PCT/CN2020/142473 CN2020142473W WO2021238222A1 WO 2021238222 A1 WO2021238222 A1 WO 2021238222A1 CN 2020142473 W CN2020142473 W CN 2020142473W WO 2021238222 A1 WO2021238222 A1 WO 2021238222A1
Authority
WO
WIPO (PCT)
Prior art keywords
robot
obstacle
virtual
collision zone
collision
Prior art date
Application number
PCT/CN2020/142473
Other languages
French (fr)
Chinese (zh)
Inventor
缪昭侠
Original Assignee
深圳市银星智能科技股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 深圳市银星智能科技股份有限公司 filed Critical 深圳市银星智能科技股份有限公司
Publication of WO2021238222A1 publication Critical patent/WO2021238222A1/en

Links

Images

Classifications

    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05DSYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
    • G05D1/00Control of position, course, altitude or attitude of land, water, air or space vehicles, e.g. using automatic pilots
    • G05D1/02Control of position or course in two dimensions
    • G05D1/021Control of position or course in two dimensions specially adapted to land vehicles
    • G05D1/0231Control of position or course in two dimensions specially adapted to land vehicles using optical position detecting means
    • AHUMAN NECESSITIES
    • A47FURNITURE; DOMESTIC ARTICLES OR APPLIANCES; COFFEE MILLS; SPICE MILLS; SUCTION CLEANERS IN GENERAL
    • A47LDOMESTIC WASHING OR CLEANING; SUCTION CLEANERS IN GENERAL
    • A47L11/00Machines for cleaning floors, carpets, furniture, walls, or wall coverings
    • A47L11/24Floor-sweeping machines, motor-driven
    • AHUMAN NECESSITIES
    • A47FURNITURE; DOMESTIC ARTICLES OR APPLIANCES; COFFEE MILLS; SPICE MILLS; SUCTION CLEANERS IN GENERAL
    • A47LDOMESTIC WASHING OR CLEANING; SUCTION CLEANERS IN GENERAL
    • A47L11/00Machines for cleaning floors, carpets, furniture, walls, or wall coverings
    • A47L11/28Floor-scrubbing machines, motor-driven
    • AHUMAN NECESSITIES
    • A47FURNITURE; DOMESTIC ARTICLES OR APPLIANCES; COFFEE MILLS; SPICE MILLS; SUCTION CLEANERS IN GENERAL
    • A47LDOMESTIC WASHING OR CLEANING; SUCTION CLEANERS IN GENERAL
    • A47L11/00Machines for cleaning floors, carpets, furniture, walls, or wall coverings
    • A47L11/40Parts or details of machines not provided for in groups A47L11/02 - A47L11/38, or not restricted to one of these groups, e.g. handles, arrangements of switches, skirts, buffers, levers
    • A47L11/4002Installations of electric equipment
    • AHUMAN NECESSITIES
    • A47FURNITURE; DOMESTIC ARTICLES OR APPLIANCES; COFFEE MILLS; SPICE MILLS; SUCTION CLEANERS IN GENERAL
    • A47LDOMESTIC WASHING OR CLEANING; SUCTION CLEANERS IN GENERAL
    • A47L11/00Machines for cleaning floors, carpets, furniture, walls, or wall coverings
    • A47L11/40Parts or details of machines not provided for in groups A47L11/02 - A47L11/38, or not restricted to one of these groups, e.g. handles, arrangements of switches, skirts, buffers, levers
    • A47L11/4011Regulation of the cleaning machine by electric means; Control systems and remote control systems therefor
    • AHUMAN NECESSITIES
    • A47FURNITURE; DOMESTIC ARTICLES OR APPLIANCES; COFFEE MILLS; SPICE MILLS; SUCTION CLEANERS IN GENERAL
    • A47LDOMESTIC WASHING OR CLEANING; SUCTION CLEANERS IN GENERAL
    • A47L11/00Machines for cleaning floors, carpets, furniture, walls, or wall coverings
    • A47L11/40Parts or details of machines not provided for in groups A47L11/02 - A47L11/38, or not restricted to one of these groups, e.g. handles, arrangements of switches, skirts, buffers, levers
    • A47L11/4061Steering means; Means for avoiding obstacles; Details related to the place where the driver is accommodated
    • AHUMAN NECESSITIES
    • A47FURNITURE; DOMESTIC ARTICLES OR APPLIANCES; COFFEE MILLS; SPICE MILLS; SUCTION CLEANERS IN GENERAL
    • A47LDOMESTIC WASHING OR CLEANING; SUCTION CLEANERS IN GENERAL
    • A47L11/00Machines for cleaning floors, carpets, furniture, walls, or wall coverings
    • A47L11/40Parts or details of machines not provided for in groups A47L11/02 - A47L11/38, or not restricted to one of these groups, e.g. handles, arrangements of switches, skirts, buffers, levers
    • A47L11/4072Arrangement of castors or wheels
    • AHUMAN NECESSITIES
    • A47FURNITURE; DOMESTIC ARTICLES OR APPLIANCES; COFFEE MILLS; SPICE MILLS; SUCTION CLEANERS IN GENERAL
    • A47LDOMESTIC WASHING OR CLEANING; SUCTION CLEANERS IN GENERAL
    • A47L9/00Details or accessories of suction cleaners, e.g. mechanical means for controlling the suction or for effecting pulsating action; Storing devices specially adapted to suction cleaners or parts thereof; Carrying-vehicles specially adapted for suction cleaners
    • A47L9/009Carrying-vehicles; Arrangements of trollies or wheels; Means for avoiding mechanical obstacles
    • AHUMAN NECESSITIES
    • A47FURNITURE; DOMESTIC ARTICLES OR APPLIANCES; COFFEE MILLS; SPICE MILLS; SUCTION CLEANERS IN GENERAL
    • A47LDOMESTIC WASHING OR CLEANING; SUCTION CLEANERS IN GENERAL
    • A47L9/00Details or accessories of suction cleaners, e.g. mechanical means for controlling the suction or for effecting pulsating action; Storing devices specially adapted to suction cleaners or parts thereof; Carrying-vehicles specially adapted for suction cleaners
    • A47L9/28Installation of the electric equipment, e.g. adaptation or attachment to the suction cleaner; Controlling suction cleaners by electric means
    • A47L9/2805Parameters or conditions being sensed
    • AHUMAN NECESSITIES
    • A47FURNITURE; DOMESTIC ARTICLES OR APPLIANCES; COFFEE MILLS; SPICE MILLS; SUCTION CLEANERS IN GENERAL
    • A47LDOMESTIC WASHING OR CLEANING; SUCTION CLEANERS IN GENERAL
    • A47L9/00Details or accessories of suction cleaners, e.g. mechanical means for controlling the suction or for effecting pulsating action; Storing devices specially adapted to suction cleaners or parts thereof; Carrying-vehicles specially adapted for suction cleaners
    • A47L9/28Installation of the electric equipment, e.g. adaptation or attachment to the suction cleaner; Controlling suction cleaners by electric means
    • A47L9/2836Installation of the electric equipment, e.g. adaptation or attachment to the suction cleaner; Controlling suction cleaners by electric means characterised by the parts which are controlled
    • A47L9/2852Elements for displacement of the vacuum cleaner or the accessories therefor, e.g. wheels, casters or nozzles
    • GPHYSICS
    • G05CONTROLLING; REGULATING
    • G05DSYSTEMS FOR CONTROLLING OR REGULATING NON-ELECTRIC VARIABLES
    • G05D1/00Control of position, course, altitude or attitude of land, water, air or space vehicles, e.g. using automatic pilots
    • G05D1/02Control of position or course in two dimensions
    • G05D1/021Control of position or course in two dimensions specially adapted to land vehicles
    • G05D1/0231Control of position or course in two dimensions specially adapted to land vehicles using optical position detecting means
    • G05D1/0238Control of position or course in two dimensions specially adapted to land vehicles using optical position detecting means using obstacle or wall sensors
    • AHUMAN NECESSITIES
    • A47FURNITURE; DOMESTIC ARTICLES OR APPLIANCES; COFFEE MILLS; SPICE MILLS; SUCTION CLEANERS IN GENERAL
    • A47LDOMESTIC WASHING OR CLEANING; SUCTION CLEANERS IN GENERAL
    • A47L2201/00Robotic cleaning machines, i.e. with automatic control of the travelling movement or the cleaning operation

Definitions

  • This application relates to the field of robotics, and in particular to a method for avoiding obstacles for a robot, a device for avoiding obstacles for a robot, a robot, and a storage medium.
  • cleaning robots can achieve more and more functions. If the user does not want the cleaning robot to enter a certain area for cleaning, for example, to prevent the cleaning robot from entering the bedroom or bathroom and other areas, the function of a restricted area or virtual wall can be set so that the cleaning robot can bypass the restricted area or virtual wall.
  • the restricted area is set as a rectangular area, and the rectangular area must be parallel to the map on which the robot is walking, and the direction of the virtual wall is also parallel or perpendicular to the map on which the robot is walking.
  • the robot can only walk along the rectangular area. It is impossible to walk along forbidden areas or virtual walls of other shapes, such as curved virtual walls or forbidden areas of arbitrary polygons, etc., resulting in poor cleaning effect and poor user experience.
  • this application solves at least one of the above technical problems to a certain extent.
  • this application provides a robot obstacle avoidance method, a robot, and a storage medium, which can enable the robot to walk along virtual obstacles of various shapes to achieve better The obstacle avoidance effect improves the user experience.
  • an embodiment of the present application provides a robot obstacle avoidance method, including:
  • an embodiment of the present application provides a robot obstacle avoidance device, the robot obstacle avoidance device includes an establishment module, a first acquisition module, a first determination module, a first judgment module, and a first control module,
  • the establishment module is used to establish a coordinate system based on the clean environment where the robot is located;
  • the first acquisition module is configured to acquire the position and the advancing direction of the robot in the coordinate system, and the position of obstacles in the coordinate system, and the obstacles include virtual obstacles;
  • the first determination module is used to determine the effective collision zone according to the position of the robot, the forward direction and the first safety distance;
  • the first judgment module is used to judge whether the virtual obstacle at least partially falls into the effective collision zone
  • the first control module is configured to control the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
  • an embodiment of the present application provides a robot, and the robot includes:
  • the drive wheel component is installed on the main body and is used to drive the robot to move;
  • At least one processor At least one processor
  • a memory communicatively connected with the at least one processor; wherein,
  • the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor, so that the at least one processor can execute the obstacle avoidance method for a robot as described above.
  • an embodiment of the present application provides a non-transitory computer-readable storage medium, the non-transitory computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to make the robot execute the above The robot obstacle avoidance method described.
  • this application has at least the following beneficial effects:
  • a coordinate system is first established based on the clean environment where the robot is located, and then the position and forward direction of the robot in the coordinate system and obstacles are obtained.
  • the obstacle includes virtual obstacles.
  • the effective collision zone is determined according to the robot's position, forward direction and the first safety distance, and then it is judged whether the virtual obstacle falls into the effective collision zone at least partially.
  • the robot is controlled to walk along the virtual obstacle.
  • the robot obstacle avoidance method can control the robot to walk along the virtual obstacle through the position of the robot and the first safety distance. Without restricting the shape of virtual obstacles, a better obstacle avoidance effect is achieved, thereby enhancing the user experience.
  • Fig. 1a is a three-dimensional schematic diagram of a robot provided by an embodiment of the present application.
  • Figure 1b is a bottom schematic view of the robot in Figure 1a;
  • Figure 2 is a schematic representation of a restricted area and virtual wall provided by an embodiment of the present application
  • FIG. 3 is a flowchart of a method for robot obstacle avoidance provided by an embodiment of the present application
  • FIG. 4 is a schematic flowchart of step S34 in FIG. 3;
  • FIG. 5 is a schematic diagram of determining an effective collision zone according to an embodiment of the present application.
  • FIG. 6 is a flowchart of a method for avoiding obstacles for a robot according to another embodiment of the present application.
  • FIG. 7 is a schematic flowchart of step S35 in FIG. 6;
  • FIG. 8 is a schematic diagram of determining a virtual intersection point provided by an embodiment of the present application.
  • FIG. 9 is a flowchart of a method for avoiding obstacles for a robot according to yet another embodiment of the present application.
  • FIG. 10 is a schematic diagram of determining the actual distance of a robot from a real obstacle and the actual distance from a virtual obstacle according to an embodiment of the present application;
  • FIG. 11 is a schematic diagram of a robot obstacle avoidance device provided by an embodiment of the present application.
  • FIG. 12 is a schematic structural diagram of a controller provided by an embodiment of the present application.
  • the robot 100 in the embodiment of the present application can be constructed in any suitable shape to implement specific business function operations.
  • the robot 100 in the embodiment of the present application may be a cleaning robot or a pet robot. , Handling robots, care robots, etc.
  • the cleaning robot includes, but is not limited to, a sweeping robot, a vacuuming robot, a mopping robot, or a scrubbing robot.
  • the robot 100 includes a main body 11, a driving wheel part 12, and a controller.
  • the outer shape of the main body 11 may be substantially elliptical, triangular, D-shaped or other shapes.
  • the controller is arranged in the main body 11, and the driving wheel part 12 is installed in the main body 11 to drive the robot 100 to move. If the robot 100 is a cleaning robot, the driving wheel part 12 drives the robot 100 to move on the surface to be cleaned. It can be a relatively smooth floor surface, a carpeted surface, and other surfaces that need to be cleaned.
  • the driving wheel component 12 includes a left driving wheel 121, a right driving wheel 122, and an omnidirectional wheel 123, and the left driving wheel 121 and the right driving wheel 122 are installed on opposite sides of the main body 11, respectively.
  • the omnidirectional wheel 123 is installed at the front position of the bottom of the main body 11.
  • the omnidirectional wheel 123 is a movable caster wheel that can rotate 360 degrees horizontally, so that the robot 100 can turn flexibly.
  • the left driving wheel 121, the right driving wheel 122 and the omnidirectional wheel 123 are installed to form a triangle to improve the walking stability of the robot 100.
  • the omnidirectional wheel 123 can be omitted, and only the left driving wheel 121 and the right driving wheel 122 can be used to drive the robot 100 to walk normally.
  • the controller is disposed inside the main body 11, and the controller is electrically connected to the left driving wheel 121, the right driving wheel 122, and the omnidirectional wheel 123, respectively.
  • the controller is used to control the robot 100 to walk, back and process some business logic.
  • the controller may be a general-purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), a single-chip microcomputer, an ARM (Acorn RISC Machine) or other programmable Logic devices, discrete gate or transistor logic, discrete hardware components, or any combination of these components.
  • the controller can also be any conventional processor, controller, microcontroller, or state machine.
  • the controller may also be implemented as a combination of computing devices, for example, a combination of a DSP and a microprocessor, multiple microprocessors, one or more microprocessors in combination with a DSP, and/or any other such configuration.
  • the controller uses SLAM (simultaneous localization and mapping, real-time positioning and mapping technology) technology to construct a map and positioning based on environmental data. Based on the established map and the position of the robot 100, the controller instructs the robot 100 to completely traverse an environmental space.
  • the user can preset some forbidden areas or virtual wall positions to prevent the robot 100 from entering the forbidden area or virtual wall.
  • the set forbidden area or virtual wall position is equivalent to the position of a virtual obstacle.
  • the map can indicate the area that the robot 100 needs to traverse. And the coordinate position of the obstacle in the traversed area.
  • the controller can also identify the traversed location or area according to a variety of ways, or identify obstacles, so as to make a control strategy that meets product requirements.
  • the representation of the virtual wall in the map can be a line segment composed of continuous points with a spacing of less than or equal to 1cm.
  • the line segment can be a straight line or a curve.
  • the forbidden area can be set in any polygonal shape, and even the polygonal line segments can be curved.
  • a curved virtual wall A1 a first forbidden area A2 composed of a five-pointed star area, and a second forbidden area A3 composed of a polygon are set in this area.
  • the robot 100 when the robot 100 avoids virtual obstacles, it can only walk along rectangular or linear virtual obstacles, and cannot walk along virtual obstacles of arbitrary shapes, and the obstacle avoidance effect is not good.
  • the robot obstacle avoidance method S30 includes:
  • the robot 100 will encounter some obstacles during walking or cleaning. These obstacles include real obstacles and virtual obstacles.
  • the obstacle avoidance process of the robot 100 for real obstacles is that the collision sensor detects the collision and then performs subsequent processing. Virtual obstacles include forbidden areas and virtual walls.
  • the simulated robot 100 and the virtual obstacle Virtual collision of objects If a virtual collision occurs, the robot 100 takes corresponding measures, such as braking or walking along obstacles, and the first safety distance is set as the effective braking range of the robot 100. Within this range, the robot 100 can brake in time to prevent collisions. To the obstacle.
  • the method first establishes a coordinate system based on the clean environment in which the robot 100 is located, and sets an effective collision area in the coordinate system, such as A4, A5, and A6 in Figure 5, as long as the virtual obstacle L1 at least partially falls into the effective collision Within the area, it is considered that the robot 100 has a virtual collision with the virtual obstacle L1.
  • the effective collision areas A4, A5, and A6 are determined according to the position, forward direction and the first safety distance of the robot 100.
  • the specific method for determining the effective collision areas A4, A5, and A6 is to first obtain the coordinates of the robot 100 The position and direction of advancement in the system, as well as the position of the virtual obstacle L1 in the coordinate system, according to the position, direction of advancement and the first safety distance of the robot 100, first determine the virtual collision area around the robot 100, and the boundary of the virtual collision area The distance to the robot 100 is equal to the first safety distance, and only those within the first safety distance are the virtual collision zone. The area outside the first safety distance, even if there is a virtual obstacle L1, can be ignored because it is far away from the robot 100 .
  • a part close to the forward direction of the robot 100 constitutes an effective collision area, and the angle between any point on the boundary of the effective collision area and the center of the robot 100 and the forward direction is less than or equal to the first predetermined direction.
  • Set the angle that is, the area within the preset range on the left and right of the advancing direction.
  • the first preset angle can be set to 90 degrees, and the angle between any point on the boundary of the virtual collision zone and the center of the robot 100 and the forward direction is less than 90 degrees.
  • the robot 100 is controlled according to the position of the robot 100 and the first safety distance. Walk along the virtual obstacle L1. Specifically, taking the first safety distance as the target value, the robot 100 is controlled to walk along the virtual obstacle L1 and maintain the first safety distance from the virtual obstacle L1. During the walking process, the robot 100 and the virtual obstacle L1 are also obtained in real time. According to the actual distance between the virtual obstacles L1, the robot 100 is controlled to walk along the virtual obstacle L1 according to whether the actual distance meets the first safety distance.
  • the robot 100 is controlled to walk to the right At one point, the first safety distance is reached. If the robot 100 is close to the virtual obstacle L1, the robot 100 is controlled to walk a little to the left to reach the first safety distance, that is, the control robot 100 and the virtual obstacle L1 remain at the first safety distance. A safe distance and walk along the virtual obstacle L1.
  • the robot 100 is controlled to walk along the virtual obstacle L1 according to the position of the robot 100, the position of the virtual obstacle L1, and the first safety distance.
  • the robot obstacle avoidance method does not limit the shape and type of the virtual obstacle L1, and achieves a better obstacle avoidance effect, thereby enhancing the user experience.
  • the effective collision area includes a left collision area A5, a front collision area A4, and a right collision area A6.
  • step S34 includes:
  • S341 According to the position of the robot and the position of the virtual obstacle, determine whether the virtual obstacle has an intersection with the boundary of the effective collision zone;
  • the virtual collision point is the point on the virtual obstacle that falls into the effective collision zone that is closest to the center of the robot;
  • the virtual obstacle L1 is preset by the user, for example, through software that interacts with the robot 100. After the setting, the virtual obstacle L1 exists on the map of the space where the robot 100 is walking, and the coordinates of the virtual obstacle L1 can be obtained. Location and other information. According to the coordinate information of the virtual obstacle L1 and the coordinate information of the effective collision area, it can be determined whether the virtual obstacle L1 has an intersection with the boundary of the effective collision area. Specifically, if the virtual obstacle L1 is a virtual wall, in the coordinate system, It can be expressed by a binary linear equation. The boundary of the effective collision zone can be expressed by a binary quadratic equation. The two equations are combined to solve the coordinate of the intersection point. If the virtual obstacle L1 and the boundary of the effective collision zone have an intersection point, then It is determined that the virtual obstacle L1 at least partially falls into the effective collision zone.
  • the virtual obstacle L1 is at least partially within the effective collision zone, then it is determined which effective collision zone the virtual obstacle L1 falls into at least partially, that is, it is determined that the virtual obstacle exists in the left collision zone A5 and the front collision zone.
  • A4 is also the right collision area A6.
  • the effective collision area contains multiple areas. If the forward direction is the positive direction, the range of each effective collision area may not be limited, and the size of the three areas may not be the same, for example, as shown in Figure 5. As shown, the forward direction of the robot 100 is shown by the solid arrow in the figure.
  • the angle between the two boundary lines of the front side collision area A4 is the first preset angle, which can be 90 degrees, and its area is on the left side of the forward direction.
  • the angle between the two boundary lines of the left collision area A5 is the second preset angle, which can be 45 degrees, and on the left side of the forward direction, the angle between the two boundary lines of the right collision area A6 is The second preset angle, which can be 45 degrees, and is on the right side of the advancing direction.
  • the first preset angle and the second preset angle are not limited to the above examples, and can be flexibly set according to actual needs.
  • the virtual collision point C is defined as the point on the virtual obstacle L1 that falls into the effective collision zone that is closest to the center point A of the robot 100.
  • This step can also be implemented by coordinate calculation, for example: If there are two intersection points between the virtual obstacle L1 and the effective collision zone boundary, take the coordinates of the point L1 on all the virtual obstacles between the two intersection points, and calculate the distance between all the points and the center point A of the robot 100, the point with the shortest distance That is the virtual collision point C, or if there are multiple intersection points between the virtual obstacle L1 and the effective collision zone boundary, take the coordinates of all the points on the virtual obstacle L1 between the multiple intersection points, and calculate all the points and the robot 100 The distance from the center point A. The point with the shortest distance is the virtual collision point C. Or, if there is only one intersection point between the virtual obstacle L1 and the effective collision zone boundary, the intersection point is the distance between the point on the virtual obstacle L1 and the robot 100. The closest point to the center point A, the intersection point is the virtual collision point C.
  • the left collision area A5, the front collision area A4 and the right collision area A6 it is determined that the virtual obstacle L1 at least partially falls into the specific position of the effective collision area, and it is determined that the virtual obstacle L1 specifically falls into There are many ways to determine which effective collision zone is.
  • the connection direction is the obstacle direction.
  • the virtual obstacle L1 at least partially falls into the left side collision area A4, where the second preset angle is smaller than the first preset angle, the The specific value of the second preset angle can be set by the user according to needs, and in the embodiment of the present application, it is 45 degrees. If the angle between the obstacle direction and the forward direction is greater than the second preset angle, and the obstacle direction is located on the right side of the forward direction, the virtual obstacle at least partially falls into the right collision zone A6.
  • the virtual obstacle L1 at least partially falls into Front collision zone A4.
  • the coordinates of the virtual obstacle L1 and the coordinates of each effective collision zone can also be used to directly determine the position where the virtual obstacle L1 at least partially falls into the effective collision zone, specifically, the coordinates of the virtual obstacle L1 Compare the coordinates with the coordinates of each effective collision area to determine whether there is a coordinate overlap area. If the coordinates of the virtual obstacle L1 overlap with the coordinates of the left collision area A5, it is determined that the virtual obstacle L1 at least partially falls on the left side In the collision area A5, if the coordinates of the virtual obstacle L1 are still coincident with the coordinates of the right collision area A6, it is determined that the virtual obstacle L1 at least partially falls into the right collision area A6. If the coordinates of the virtual obstacle L1 are still with the previous If the coordinates of the side collision area A4 overlap, it is determined that the virtual obstacle L1 at least partially falls into the front side collision area A4.
  • the position where the virtual obstacle at least partially falls into the effective collision zone can be determined by the above-mentioned various methods.
  • the robot 100 is controlled to rotate until the virtual obstacle at least partially falls into the right collision zone.
  • the robot 100 is controlled to rotate until the virtual obstacle L1 falls at least partially In the right collision area A6, the virtual collision point between the virtual obstacle L1 and the right collision area A6 is determined, and then the virtual collision is responded to according to the virtual collision point.
  • the robot 100 while the robot 100 is walking along the obstacle, it also detects the obstacle situation in the left area and the forward direction area at the same time.
  • the virtual obstacle L1 includes a first virtual obstacle and a second virtual obstacle. Obstacles.
  • the obstacle avoidance method S60 of the robot further includes:
  • the robot 100 While the robot 100 is walking along the first virtual obstacle, the first virtual obstacle at least partially falls into the right side collision area A6 of the robot 100, and at the same time, the robot 100 will detect whether the second virtual obstacle partially falls into it. In the left-side collision area A5 or the front-side collision area A4, if part of it falls, it means that the robot 100 and the second virtual obstacle in the left-side collision area A5 or the second virtual obstacle in the front-side collision area A4 have occurred Virtual collision, then immediately respond to the virtual collision, and then proceed to the process of walking along the second virtual obstacle.
  • the robot 100 when a virtual collision occurs, the robot 100 is controlled to rotate until the second virtual obstacle at least partially falls into the right side collision In area A6, according to the position of the robot 100, the position of the second virtual obstacle and the first safety distance, the robot 100 is controlled to walk along the second virtual obstacle to perform a new edge movement.
  • This method can enable the robot 100 to detect virtual obstacles in other directions at the same time during the obstacle avoidance process, so as to achieve a better obstacle avoidance effect.
  • the robot 100 is controlled to walk along the virtual obstacle L1 according to the position of the robot 100, the position of the virtual obstacle L1, and the first safety distance.
  • the robot obstacle avoidance method does not limit the shape and type of the virtual obstacle L1, and achieves a better obstacle avoidance effect, thereby enhancing the user experience.
  • step S35 includes:
  • the virtual obstacle L1 After it is determined that the virtual obstacle L1 has a virtual collision with the effective collision zone, it responds to the collision. Specifically, first, the distance between the robot 100 and the virtual collision point C is taken as the initial actual distance, and the first safe distance is taken as the target distance. Control the robot 100 to walk along the virtual obstacle L1, and in the process of walking, generate a virtual detection signal with the position of the robot 100 as the origin and the preset direction as the direction, extending to the position of the virtual obstacle L1, where the The preset direction and the forward direction of the robot 100 are set at an acute angle.
  • the origin of the virtual detection signal is the position of the robot 100, specifically, it may be the center point A of the robot 100, the direction is a preset direction, and it points to the virtual position.
  • the preset direction is the direction in which the origin A points to the tof sensor of the robot 100. If the forward direction of the robot 100 is the positive direction, the tof sensor is arranged at the upper right position of the positive direction of the robot 100, which can detect real obstacles and The distance between the robots 100 is installed in the upper right position instead of the right position. You can predict the distance of the obstacle on the right side, prepare for obstacle avoidance in advance, and better control the realization of the obstacle along the way. Things walking. Therefore, the acute angle set between the preset direction and the advancing direction of the robot 100 is the included angle between the tof sensor of the robot 100 and the advancing direction of the robot 100.
  • S354 Control the robot to walk along the virtual obstacle according to whether the first actual distance meets the first safety distance.
  • the virtual detection signal points to the virtual position. If it is extended endlessly, it must have an intersection with the virtual obstacle L1. The intersection is determined as the virtual intersection C. Finally, it is determined that the distance between the robot 100 and the virtual intersection C is the first actual distance, that is, the robot The actual distance between the position of 100 and the position of the virtual wall.
  • the virtual wall L1 is a curve, and is represented by a dashed line segment
  • the forward direction of the robot 100 is shown by the solid arrow in the figure
  • the origin of the robot 100 is point A
  • the tof sensor of the robot 100 is located
  • the position is point B, with point A as the origin, and the direction from point A to point B as the preset direction.
  • a virtual detection signal is generated toward the position of the virtual wall L1.
  • the virtual detection signal is represented by a straight line l.
  • the point of intersection is point C
  • point C is the virtual point of intersection
  • the length of the line segment BC is taken as the first actual distance, that is, the distance between the robot 100 and the virtual point of intersection C.
  • the robot 100 is controlled to walk along the virtual obstacle L1 according to whether the first actual distance meets the first safety distance. Specifically, the first actual distance is actually the actual distance between the right side of the robot 100 and the virtual wall L1. If the first actual distance is greater than the first safe distance, the robot 100 is controlled to walk to the right side until the robot 100 is between the virtual wall L1 If the first actual distance is less than the first safety distance, the robot 100 is controlled to walk to the left until the distance between the robot 100 and the virtual wall L1 is maintained at the first safety distance.
  • the first safety distance can be set to 5cm, and the user can also set it as needed, and this step can be implemented through PID control algorithms.
  • the first actual distance of the robot 100 from the virtual obstacle L1 is determined by the actual distance between the right side of the robot 100 and the virtual obstacle L1. Even if it is detected that the virtual obstacle L1 at least partially falls into the effective collision area in the left collision area A5 or the front collision area A4, the obstacle avoidance method of the robot can also achieve obstacle avoidance well and achieve a better obstacle avoidance effect.
  • the virtual collision is responded to according to the preset priority, specifically ,
  • the preset priority can be left collision area A5 response priority> front collision area A4 response priority> right collision area A6 response priority, that is, to respond to the virtual collision in the left collision area A5 first, if there is a virtual obstacle If L1 does not fall at least partially into the left collision zone A5, first respond to the virtual collision of the front collision zone A4. If the virtual obstacle L1 does not fall at least partially into the left collision zone A5 and does not fall at least partially into the front collision zone A4 , Then respond to the virtual collision in the right collision zone A6.
  • the robot 100 is controlled to walk along the virtual obstacle L1 according to the position of the robot 100, the position of the virtual obstacle L1, and the first safety distance.
  • the robot obstacle avoidance method does not limit the shape and type of the virtual obstacle L1, and achieves a better obstacle avoidance effect, thereby enhancing the user experience.
  • the obstacles also include real obstacles. If the real obstacle and the virtual obstacle L1 exist at the same time, please refer to FIG. 9.
  • the robot obstacle avoidance method S90 includes:
  • the robot 100 When the robot 100 is walking along an obstacle, it may encounter a situation where the real obstacle and the virtual obstacle L1 exist at the same time.
  • the robot 100 is set in the robot while walking along the virtual obstacle L1.
  • the tof sensor on the upper right of 100 detects that there is a real obstacle on the right side, so in the space on the right side of the robot 100, there are both virtual obstacles L1 and real obstacles.
  • the safe distance of the robot 100 is the second safe distance.
  • the robot 100 keeps within the second safe distance from the real obstacle, while walking along the real obstacle, and moving along the real obstacle.
  • the second safety distance is 1 cm, and the user can also set it as needed.
  • the robot 100 uses the tof sensor to measure the distance between the real obstacle and the robot 100 in real time. This distance is called For the second actual distance, first obtain the first difference between the first actual distance and the first safety distance, and then obtain the second difference between the second actual distance and the second safety distance, and take different values according to the magnitude of the two differences. If the first difference is less than the second difference, the robot 100 is controlled to walk along the virtual obstacle L1 according to the first actual distance and the first safety distance. If the first difference is greater than the second difference, then according to the first difference The second actual distance and the second safety distance are used to control the robot 100 to walk along the real obstacle.
  • the smaller difference is selected as the feedback value of motion control.
  • the control target value can be set to zero, and the smaller difference is used as the feedback value to control the robot 100 to move along the smaller The obstacle corresponding to the difference is walking.
  • the forward direction of the robot 100 is shown by the arrow in the figure
  • the actual distance of the robot 100 from the virtual obstacle L1 is S1
  • the safety distance is S2
  • the actual distance of the robot 100 from the first real obstacle L2 Is S3
  • the safety distance is S4
  • the actual distance between the robot 100 and the second real obstacle L3 is S5
  • the safety distance is S4 (not shown in the figure)
  • S2 is set equal to S4
  • this method can seamlessly switch the obstacles that the robot walks along. According to the actual situation of the obstacles, control the robot to walk along the corresponding obstacles. Better obstacle avoidance effect.
  • the robot when the virtual obstacle falls into the effective collision zone of the robot at least partially, the robot is controlled to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
  • the robot obstacle avoidance method does not limit the shape and type of virtual obstacles, and achieves a better obstacle avoidance effect, thereby enhancing user experience.
  • the embodiments of the present application provide a robot obstacle avoidance device.
  • the robot obstacle avoidance device may be a software module
  • the software module includes a number of instructions, which are stored in a memory in the ESC, and the processor can access the memory and call the instructions for execution, so as to complete the above-mentioned various embodiments.
  • Robot obstacle avoidance method may be a software module
  • the software module includes a number of instructions, which are stored in a memory in the ESC, and the processor can access the memory and call the instructions for execution, so as to complete the above-mentioned various embodiments.
  • Robot obstacle avoidance method may be a software module
  • the software module includes a number of instructions, which are stored in a memory in the ESC, and the processor can access the memory and call the instructions for execution, so as to complete the above-mentioned various embodiments.
  • the robot obstacle avoidance device can also be built by hardware devices.
  • the robot obstacle avoidance device can be built by one or more than two chips, and each chip can work in coordination with each other to complete the above implementations.
  • the robot obstacle avoidance device can also be built by various logic devices, such as general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA), single-chip computers, Built by ARM (Acorn RISC Machine) or other programmable logic devices, discrete gates or transistor logic, discrete hardware components, or any combination of these components.
  • the robot obstacle avoidance device 200 includes an establishment module 21, a first acquisition module 22, a first determination module 23, a first judgment module 24, and a first determination module.
  • One control module 25 is a control module.
  • the establishment module 21 is used to establish a coordinate system based on the clean environment in which the robot is located;
  • the first acquiring module 22 is configured to acquire the position and forward direction of the robot in the coordinate system, and the position of obstacles in the coordinate system, the obstacles including virtual obstacles;
  • the first determining module 23 is configured to determine an effective collision zone according to the position of the robot, the forward direction, and the first safety distance;
  • the first judgment module 24 is configured to judge whether the virtual obstacle at least partially falls into the effective collision zone
  • the first control module 25 is configured to control the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
  • the robot obstacle avoidance device controls the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
  • the robot obstacle avoidance method does not limit the shape and type of virtual obstacles, and achieves a better obstacle avoidance effect, thereby enhancing user experience.
  • the first determining module 23 is specifically configured to: determine a virtual collision area located on the peripheral side of the robot, and the distance between the boundary of the virtual collision area and the robot is equal to the first safety distance; A part of the virtual collision area close to the forward direction of the robot constitutes the effective collision area, and the angle between any point on the boundary of the effective collision area and the center of the robot and the forward direction is less than or Equal to the first preset angle.
  • the effective collision zone includes a left collision zone, a front collision zone, and a right collision zone.
  • the first determining module 23 is also specifically configured to: according to the position of the robot and the position of the virtual obstacle Position, determine whether the virtual obstacle has an intersection with the boundary of the effective collision zone; if so, determine that the virtual obstacle at least partially falls within the effective collision zone; if it is determined that the virtual obstacle is at least partially Falling into the effective collision zone, and determining a virtual collision point based on the position of the virtual obstacle falling into the effective collision zone and the position of the robot, and the virtual collision point is falling into the effective collision zone The point on the virtual obstacle that is closest to the center of the robot; the virtual obstacle is determined according to the virtual collision point, the left collision zone, the front collision zone, and the right collision zone The object at least partially falls into the position of the effective collision zone.
  • the first determining module 23 is further specifically configured to mark the direction of the connection line between the virtual collision point and the center of the robot as an obstacle direction,
  • the virtual obstacle at least partially falls into the left side collision zone ;
  • the virtual obstacle at least partially falls into the right side collision zone ;
  • the virtual obstacle is at least partially Fall into the front side collision zone
  • the second predetermined angle is smaller than the first predetermined angle.
  • the first judging module 24 is specifically configured to control the robot to rotate if the virtual obstacle does not fall into the right side collision zone until the virtual obstacle at least partially falls into the right side. Side impact zone.
  • the virtual obstacle includes a first virtual obstacle and a second virtual obstacle.
  • the robot avoids obstacles
  • the device 200 further includes a second judging module 26 for judging whether the second virtual obstacle at least partially falls into the left side collision zone or the front side collision zone; the second control module 27 is used for controlling the The robot rotates until the second virtual obstacle at least partially falls into the right-side collision zone, and then according to the position of the robot, the position of the second virtual obstacle, and the first safety distance, control The robot walks along the second virtual obstacle.
  • the first control module 25 is specifically configured to generate a virtual detection signal extending to the position of the virtual obstacle with the position of the robot as the origin and a preset direction as the direction. It is set at an acute angle to the forward direction of the robot; the intersection of the virtual detection signal and the virtual obstacle is determined to be a virtual intersection; the distance between the robot and the virtual intersection is the first actual distance; Whether an actual distance meets the first safety distance, control the robot to walk along the virtual obstacle.
  • the robot obstacle avoidance device 200 further includes a second obtaining module 28 for obtaining the first actual distance A first difference between the first safety distance and the first safety distance; acquiring a second actual distance between the robot and the real obstacle; acquiring a second difference between the second actual distance and the second safety distance; The third control module 29 is used to determine whether the first difference is less than the second difference; if so, according to whether the first actual distance meets the first safety distance, control the robot to move along the virtual Obstacle walking; if not, control the robot to walk along the real obstacle according to whether the second actual distance meets the second safety distance.
  • the foregoing robot obstacle avoidance device can execute the robot obstacle avoidance method provided in the embodiments of the present application, and has the corresponding functional modules and beneficial effects of the execution method.
  • the robot obstacle avoidance method provided in the embodiment of the present application.
  • FIG. 12 is a schematic structural diagram of a controller provided by an embodiment of the present application.
  • the controller 300 includes one or more processors 31 and a memory 32. Among them, one processor 31 is taken as an example in FIG. 12.
  • the processor 31 and the memory 32 may be connected by a bus or in other ways.
  • the connection by a bus is taken as an example.
  • the memory 32 can be used to store non-volatile software programs, non-volatile computer-executable programs, and modules, such as the program corresponding to the robot obstacle avoidance method in the embodiment of the present application Instructions/modules.
  • the processor 31 executes various functional applications and data processing of the robot obstacle avoidance device by running the non-volatile software programs, instructions, and modules stored in the memory 32, that is, realizes the robot obstacle avoidance method provided by the above method embodiment and The function of each module or unit of the above-mentioned device embodiment.
  • the memory 32 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other non-volatile solid-state storage devices.
  • the memory 32 may optionally include memories remotely provided with respect to the processor 31, and these remote memories may be connected to the processor 31 through a network. Examples of the aforementioned networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
  • the program instructions/modules are stored in the memory 32, and when executed by the one or more processors 31, the robot obstacle avoidance method in any of the foregoing method embodiments is executed.
  • the embodiment of the present application also provides a non-transitory computer-readable storage medium, the non-transitory computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are executed by one or more processors, for example
  • One processor 31 in FIG. 12 can enable the aforementioned one or more processors to execute the robot obstacle avoidance method in any of the aforementioned method embodiments.
  • the embodiments of the present application also provide a computer program product.
  • the computer program product includes a computer program stored on a non-transitory computer-readable storage medium.
  • the computer program includes program instructions. During execution, the electronic device is caused to execute any one of the robot obstacle avoidance methods.
  • the robot obstacle avoidance device controls the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
  • the robot obstacle avoidance method does not limit the shape and type of virtual obstacles, and achieves a better obstacle avoidance effect, thereby enhancing user experience.
  • the device or device embodiments described above are merely illustrative, and the unit modules described as separate components may or may not be physically separated, and the components displayed as modular units may or may not be physical units. , Which can be located in one place, or can be distributed to multiple network module units. Some or all of the modules can be selected according to actual needs to achieve the objectives of the solutions of the embodiments.
  • each implementation manner can be implemented by means of software plus a general hardware platform, and of course, it can also be implemented by hardware.
  • the above technical solution essentially or the part that contributes to the related technology can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM/RAM, magnetic disk , CD-ROM, etc., including several instructions to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute the methods described in each embodiment or some parts of the embodiment.

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Mechanical Engineering (AREA)
  • Electromagnetism (AREA)
  • Aviation & Aerospace Engineering (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • General Physics & Mathematics (AREA)
  • Automation & Control Theory (AREA)
  • Control Of Position, Course, Altitude, Or Attitude Of Moving Bodies (AREA)
  • Manipulator (AREA)

Abstract

Disclosed are an obstacle avoidance method for a robot, an obstacle avoidance device for a robot, a robot, and a storage medium. The obstacle avoidance method for a robot comprises: firstly, establishing a coordinate system on the basis of a cleaning environment where a robot is located (S31); then obtaining the positions of the robot and obstacles in the coordinate system and the advancing direction of the robot, with the obstacles comprising a virtual obstacle (S32); determining an effective collision area according to the position and the advancing direction of the robot and a first safety distance (S33); determining whether the virtual obstacle at least partially falls in the effective collision area (S34); and if 'yes', controlling, according to the position of the robot, the position of the virtual obstacle and the first safety distance, the robot to travel along the virtual obstacle (S35). According the obstacle avoidance method for a robot, the robot can be controlled, according to the position of the robot, the position of the virtual obstacle and the first safety distance, to travel along the virtual obstacle, and there are no limits on the shape of the virtual obstacle, so as to achieve a better obstacle-avoidance effect, thereby improving the user experience.

Description

机器人避障方法、机器人避障装置、机器人以及存储介质Robot obstacle avoidance method, robot obstacle avoidance device, robot and storage medium
本申请要求2020年5月29日向中国国家知识产权局递交的申请号为202010478923.3,申请名称为“一种机器人避障方法、机器人以及存储介质”的在先申请的优先权,上述在先申请的内容以引入的方式并入本文本中。This application requires the priority of an earlier application filed with the State Intellectual Property Office of China on May 29, 2020, with the application number 202010478923.3 and the application titled "A method for avoiding obstacles by robots, robots and storage media". The content is incorporated into this text by way of introduction.
技术领域Technical field
本申请涉及机器人领域,特别是涉及一种机器人避障方法、机器人避障装置、机器人以及存储介质。This application relates to the field of robotics, and in particular to a method for avoiding obstacles for a robot, a device for avoiding obstacles for a robot, a robot, and a storage medium.
背景技术Background technique
随着智能家居不断迭代升级,清洁机器人能够实现的功能也越来越多。若用户不想让清洁机器人进入某个区域进行清扫,例如防止清洁机器人进入卧室或卫生间等区域,可以设置禁区或者虚拟墙的功能,使得清洁机器人能够绕开禁区或者虚拟墙。As smart homes continue to iteratively upgrade, cleaning robots can achieve more and more functions. If the user does not want the cleaning robot to enter a certain area for cleaning, for example, to prevent the cleaning robot from entering the bedroom or bathroom and other areas, the function of a restricted area or virtual wall can be set so that the cleaning robot can bypass the restricted area or virtual wall.
但目前的传统技术中,禁区被设置成矩形区域,且该矩形区域必须是与机器人行走的地图平行,而虚拟墙的方向也是与行走的地图平行或者垂直,机器人只能沿着矩形区域行走,无法实现沿着其他形状的禁区或者虚拟墙行走,例如曲线形状的虚拟墙或者任意多边形的禁区等,导致清扫效果不好,使用体验感不好。However, in the current traditional technology, the restricted area is set as a rectangular area, and the rectangular area must be parallel to the map on which the robot is walking, and the direction of the virtual wall is also parallel or perpendicular to the map on which the robot is walking. The robot can only walk along the rectangular area. It is impossible to walk along forbidden areas or virtual walls of other shapes, such as curved virtual walls or forbidden areas of arbitrary polygons, etc., resulting in poor cleaning effect and poor user experience.
申请内容Application content
本申请至少在一定程度上解决上述技术问题之一,为此本申请提供一种机器人避障方法、机器人以及存储介质,其能够使得机器人能够沿着各种形状的虚拟障碍物行走,实现更好的避障效果,改善用户体验。This application solves at least one of the above technical problems to a certain extent. To this end, this application provides a robot obstacle avoidance method, a robot, and a storage medium, which can enable the robot to walk along virtual obstacles of various shapes to achieve better The obstacle avoidance effect improves the user experience.
一方面,本申请实施例提供一种机器人避障方法,包括:On the one hand, an embodiment of the present application provides a robot obstacle avoidance method, including:
基于所述机器人所处清洁环境建立坐标系;Establishing a coordinate system based on the clean environment in which the robot is located;
获取所述机器人在所述坐标系中的位置和前进方向,以及障碍物在所述坐标系中的位置,所述障碍物包括虚拟障碍物;Acquiring the position and forward direction of the robot in the coordinate system, and the position of an obstacle in the coordinate system, the obstacle including a virtual obstacle;
根据所述机器人的位置、所述前进方向以及第一安全距离,确定有效碰撞区;Determine an effective collision zone according to the position of the robot, the forward direction and the first safety distance;
判断所述虚拟障碍物是否至少部分落入所述有效碰撞区内;Judging whether the virtual obstacle at least partially falls into the effective collision zone;
若是,根据所述机器人的位置、所述虚拟障碍物的位置和所述第一安全距离,控制所述机器人沿着所述虚拟障碍物行走。If so, control the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
第二方面,本申请实施例提供一种机器人避障装置,所述机器人避障装置包括建立模块、第一获取模块、第一确定模块、第一判断模块以及第一控制模块,In a second aspect, an embodiment of the present application provides a robot obstacle avoidance device, the robot obstacle avoidance device includes an establishment module, a first acquisition module, a first determination module, a first judgment module, and a first control module,
建立模块用于基于所述机器人所处清洁环境建立坐标系;The establishment module is used to establish a coordinate system based on the clean environment where the robot is located;
第一获取模块用于获取所述机器人在所述坐标系中的位置和前进方向,以及障碍物在所述坐标系中的位置,所述障碍物包括虚拟障碍物;The first acquisition module is configured to acquire the position and the advancing direction of the robot in the coordinate system, and the position of obstacles in the coordinate system, and the obstacles include virtual obstacles;
第一确定模块用于根据所述机器人的位置、所述前进方向以及第一安全距离,确定有效碰撞区;The first determination module is used to determine the effective collision zone according to the position of the robot, the forward direction and the first safety distance;
第一判断模块用于判断所述虚拟障碍物是否至少部分落入所述有效碰撞区内;The first judgment module is used to judge whether the virtual obstacle at least partially falls into the effective collision zone;
第一控制模块用于根据所述机器人的位置、所述虚拟障碍物的位置和所述第一安全距离,控制所述机器人沿着所述虚拟障碍物行走。The first control module is configured to control the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
第三方面,本申请实施例提供一种机器人,所述机器人包括:In a third aspect, an embodiment of the present application provides a robot, and the robot includes:
主体;main body;
驱动轮部件,安装于所述主体,用于驱动所述机器人移动;The drive wheel component is installed on the main body and is used to drive the robot to move;
至少一个处理器;和At least one processor; and
与所述至少一个处理器通信连接的存储器;其中,A memory communicatively connected with the at least one processor; wherein,
所述存储器存储有可被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器能够执行如上所述的机器人避障方法。The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor, so that the at least one processor can execute the obstacle avoidance method for a robot as described above.
第四方面,本申请实施例提供一种非暂态计算机可读存储介质,所述非暂态计算机可读存储介质存储有计算机可执行指令,所述计算机可执行指令用于使机器人执行如上所述的机器人避障方法。In a fourth aspect, an embodiment of the present application provides a non-transitory computer-readable storage medium, the non-transitory computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to make the robot execute the above The robot obstacle avoidance method described.
本申请与现有技术相比至少具有以下有益效果:在本申请中的机器人避障方法,首先基于机器人所处清洁环境建立坐标系,然后获取机器人在坐标系中的位置和前进方向,以及障碍物在坐标系中的位置,该障碍物包括虚拟障碍物,再根据机器人的位置、前进方向以及第一安全距离,确定有效碰撞区,然后判断虚拟障碍物是否至少部分落入有效碰撞区,若是,最后根据机器人的位置、虚拟障碍物的位置和第一安全距离,控制机器人沿着虚拟障碍物行走。因此,无论何种形状的虚拟障碍物,只要该虚拟障碍物存在于有效碰撞区内,该机器人避障方法均可以通过机器人的位置和第一安全距离,控制机器人沿着该虚拟障碍物行走,不限制虚拟障碍物的形状,实现更好的避障效果,进而提升用户体验。Compared with the prior art, this application has at least the following beneficial effects: In the obstacle avoidance method of the robot in this application, a coordinate system is first established based on the clean environment where the robot is located, and then the position and forward direction of the robot in the coordinate system and obstacles are obtained. The position of the object in the coordinate system. The obstacle includes virtual obstacles. Then, the effective collision zone is determined according to the robot's position, forward direction and the first safety distance, and then it is judged whether the virtual obstacle falls into the effective collision zone at least partially. Finally, according to the position of the robot, the position of the virtual obstacle and the first safety distance, the robot is controlled to walk along the virtual obstacle. Therefore, regardless of the shape of the virtual obstacle, as long as the virtual obstacle exists in the effective collision zone, the robot obstacle avoidance method can control the robot to walk along the virtual obstacle through the position of the robot and the first safety distance. Without restricting the shape of virtual obstacles, a better obstacle avoidance effect is achieved, thereby enhancing the user experience.
附图说明Description of the drawings
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的变形形式。In order to explain the embodiments of the present application or the technical solutions in the prior art more clearly, the following will briefly introduce the drawings required for the embodiments. Obviously, the drawings in the following description are only some implementations of the present application. For example, for those of ordinary skill in the art, without creative work, other variants can be obtained based on these drawings.
一个或多个实施例通过与之对应的附图中的图片进行示例性说明,这些示例性说明并不构成对实施例的限定,附图中具有相同参考数字标号的元件表示为类似的元件,除非有特别申明,附图中的图不构成比例限制。One or more embodiments are exemplified by the pictures in the corresponding drawings. These exemplified descriptions do not constitute a limitation on the embodiments. The elements with the same reference numerals in the drawings are denoted as similar elements. Unless otherwise stated, the figures in the attached drawings do not constitute a scale limitation.
图1a是本申请实施例提供的一种机器人的立体示意图;Fig. 1a is a three-dimensional schematic diagram of a robot provided by an embodiment of the present application;
图1b是图1a中机器人的底部示意图;Figure 1b is a bottom schematic view of the robot in Figure 1a;
图2是本申请实施例提供的一种禁区和虚拟墙的表示示意图;Figure 2 is a schematic representation of a restricted area and virtual wall provided by an embodiment of the present application;
图3是本申请实施例提供一种机器人避障方法的流程图;FIG. 3 is a flowchart of a method for robot obstacle avoidance provided by an embodiment of the present application;
图4是图3中步骤S34的流程示意图;FIG. 4 is a schematic flowchart of step S34 in FIG. 3;
图5是本申请实施例提供的一种确定有效碰撞区示意图;FIG. 5 is a schematic diagram of determining an effective collision zone according to an embodiment of the present application;
图6是本申请另一实施例提供的一种机器人避障方法的流程图;FIG. 6 is a flowchart of a method for avoiding obstacles for a robot according to another embodiment of the present application;
图7是图6中步骤S35的流程示意图;FIG. 7 is a schematic flowchart of step S35 in FIG. 6;
图8是本申请实施例提供的一种确定虚拟交点的示意图;FIG. 8 is a schematic diagram of determining a virtual intersection point provided by an embodiment of the present application;
图9是本申请又另一实施例提供的一种机器人避障方法的流程图;FIG. 9 is a flowchart of a method for avoiding obstacles for a robot according to yet another embodiment of the present application;
图10是本申请实施例提供的一种确定机器人距离真实障碍物的实际距离和距离虚拟障碍物的实际距离的示意图;FIG. 10 is a schematic diagram of determining the actual distance of a robot from a real obstacle and the actual distance from a virtual obstacle according to an embodiment of the present application;
图11是本申请实施例提供一种机器人避障装置示意图;FIG. 11 is a schematic diagram of a robot obstacle avoidance device provided by an embodiment of the present application;
图12是本申请实施例提供一种控制器结构示意图。FIG. 12 is a schematic structural diagram of a controller provided by an embodiment of the present application.
具体实施方式Detailed ways
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行详细地描述,显然,所描述的实施例仅仅是本申请的一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。The technical solutions in the embodiments of the present application will be described in detail below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in this application, all other embodiments obtained by a person of ordinary skill in the art without creative work shall fall within the protection scope of this application.
请一并参阅图1a、图1b以及图1c,本申请实施例的机器人100可以被构造成任何合适形状,以便实现特定业务功能操作,例如,本申请实施例机器人100可以为清洁机器人、宠物机器人、搬运机器人、看护机器人等等。其中,清洁机器人包括且不限于扫地机器人、吸尘机器人、拖地机器人或洗地机器人。Please refer to FIGS. 1a, 1b, and 1c together. The robot 100 in the embodiment of the present application can be constructed in any suitable shape to implement specific business function operations. For example, the robot 100 in the embodiment of the present application may be a cleaning robot or a pet robot. , Handling robots, care robots, etc. Among them, the cleaning robot includes, but is not limited to, a sweeping robot, a vacuuming robot, a mopping robot, or a scrubbing robot.
机器人100包括主体11和驱动轮部件12以及控制器。主体11的外形可以大体上呈椭圆形、三角形、D形或其他形状。控制器设置于主体11,驱动轮 部件12安装于主体11,用于驱动机器人100移动,若机器人100为清洁机器人,则驱动轮部件12驱动机器人100在待清洁面上移动,其中,待清洁面可以是较为光滑的地板表面、铺设有地毯的表面以及其他需要清洁的表面。The robot 100 includes a main body 11, a driving wheel part 12, and a controller. The outer shape of the main body 11 may be substantially elliptical, triangular, D-shaped or other shapes. The controller is arranged in the main body 11, and the driving wheel part 12 is installed in the main body 11 to drive the robot 100 to move. If the robot 100 is a cleaning robot, the driving wheel part 12 drives the robot 100 to move on the surface to be cleaned. It can be a relatively smooth floor surface, a carpeted surface, and other surfaces that need to be cleaned.
在一些实施例中,驱动轮部件12包括左驱动轮121、右驱动轮122及全向轮123,左驱动轮121和右驱动轮122分别安装于主体11的相对两侧。全向轮123安装于主体11的底部的靠前位置,全向轮123为活动脚轮,可以水平360度旋转,以使得机器人100可以灵活转向。左驱动轮121、右驱动轮122及全向轮123的安装构成三角形,以提高机器人100行走的平稳性。In some embodiments, the driving wheel component 12 includes a left driving wheel 121, a right driving wheel 122, and an omnidirectional wheel 123, and the left driving wheel 121 and the right driving wheel 122 are installed on opposite sides of the main body 11, respectively. The omnidirectional wheel 123 is installed at the front position of the bottom of the main body 11. The omnidirectional wheel 123 is a movable caster wheel that can rotate 360 degrees horizontally, so that the robot 100 can turn flexibly. The left driving wheel 121, the right driving wheel 122 and the omnidirectional wheel 123 are installed to form a triangle to improve the walking stability of the robot 100.
在一些实施例中,全向轮123可被省略,只留左驱动轮121与右驱动轮122亦可以驱动机器人100正常行走。In some embodiments, the omnidirectional wheel 123 can be omitted, and only the left driving wheel 121 and the right driving wheel 122 can be used to drive the robot 100 to walk normally.
在一些实施例中,控制器设置于主体11内部,控制器分别与左驱动轮121、右驱动轮122以及全向轮123电连接。控制器作为机器人100的控制核心,用于控制机器人100行走、后退以及一些业务逻辑处理。In some embodiments, the controller is disposed inside the main body 11, and the controller is electrically connected to the left driving wheel 121, the right driving wheel 122, and the omnidirectional wheel 123, respectively. As the control core of the robot 100, the controller is used to control the robot 100 to walk, back and process some business logic.
在一些实施例中,控制器可以为通用处理器、数字信号处理器(DSP)、专用集成电路(ASIC)、现场可编程门阵列(FPGA)、单片机、ARM(Acorn RISC Machine)或其它可编程逻辑器件、分立门或晶体管逻辑、分立的硬件组件或者这些部件的任何组合。还有,控制器还可以是任何传统处理器、控制器、微控制器或状态机。控制器也可以被实现为计算设备的组合,例如,DSP和微处理器的组合、多个微处理器、一个或多个微处理器结合DSP和/或任何其它这种配置。In some embodiments, the controller may be a general-purpose processor, a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA), a single-chip microcomputer, an ARM (Acorn RISC Machine) or other programmable Logic devices, discrete gate or transistor logic, discrete hardware components, or any combination of these components. In addition, the controller can also be any conventional processor, controller, microcontroller, or state machine. The controller may also be implemented as a combination of computing devices, for example, a combination of a DSP and a microprocessor, multiple microprocessors, one or more microprocessors in combination with a DSP, and/or any other such configuration.
在一些实施例中,上述机器人100在活动的过程中,控制器采用SLAM(simultaneous localization and mapping,即时定位与建图技术)技术,根据环境数据构建地图和定位。控制器基于被建立好的地图以及机器人100的位置,指示机器人100完全遍历一个环境空间。另外,用户可以预先设置一些禁区或者虚拟墙位置,防止机器人100进入该禁区或虚拟墙以内,设置的禁区或者虚拟墙位置相当于一个虚拟障碍物的位置,该地图可以指示机器人100需要遍历的区域以及位于遍历区域中的障碍物所在的坐标位置。可以理解的是,控制器还可以根据多种方式识别已遍历位置或区域,或者,识别障碍物,从而作出满足产品需求的控制策略。并且,由于虚拟障碍物在地图中是以坐标方式被标记,例如:虚拟墙在地图中的表示方式可以间距小于或等于1cm连续的点组成的线段,该线段可以为直线段,也可以为曲线线段,同样地,禁区也可以设置为任意多边形的形状,甚至多边形的线段也可以是弯曲的。如图2所示,该区域内设置有一段曲线的虚拟墙A1,五角星区域组成的第一禁区A2以及多边形组成的第二禁区A3。而在传统技术中,机器人100在对虚拟障碍物避障时,只 能沿着矩形或者直线段的虚拟障碍物行走,无法实现沿着任意形状的虚拟障碍物行走,避障效果不好。In some embodiments, during the movement of the aforementioned robot 100, the controller uses SLAM (simultaneous localization and mapping, real-time positioning and mapping technology) technology to construct a map and positioning based on environmental data. Based on the established map and the position of the robot 100, the controller instructs the robot 100 to completely traverse an environmental space. In addition, the user can preset some forbidden areas or virtual wall positions to prevent the robot 100 from entering the forbidden area or virtual wall. The set forbidden area or virtual wall position is equivalent to the position of a virtual obstacle. The map can indicate the area that the robot 100 needs to traverse. And the coordinate position of the obstacle in the traversed area. It is understandable that the controller can also identify the traversed location or area according to a variety of ways, or identify obstacles, so as to make a control strategy that meets product requirements. Moreover, because virtual obstacles are marked in the map by coordinates, for example: the representation of the virtual wall in the map can be a line segment composed of continuous points with a spacing of less than or equal to 1cm. The line segment can be a straight line or a curve. Similarly, the forbidden area can be set in any polygonal shape, and even the polygonal line segments can be curved. As shown in Figure 2, a curved virtual wall A1, a first forbidden area A2 composed of a five-pointed star area, and a second forbidden area A3 composed of a polygon are set in this area. However, in the traditional technology, when the robot 100 avoids virtual obstacles, it can only walk along rectangular or linear virtual obstacles, and cannot walk along virtual obstacles of arbitrary shapes, and the obstacle avoidance effect is not good.
请一并参阅图3和图5,本申请实施例提供一种机器人避障方法,如图3所示,该机器人避障方法S30包括:Please refer to FIG. 3 and FIG. 5 together. An embodiment of the present application provides a robot obstacle avoidance method. As shown in FIG. 3, the robot obstacle avoidance method S30 includes:
S31、基于所述机器人所处清洁环境建立坐标系;S31. Establish a coordinate system based on the clean environment where the robot is located;
S32、获取所述机器人在所述坐标系中的位置和前进方向,以及障碍物在所述坐标系中的位置,所述障碍物包括虚拟障碍物;S32. Acquire the position and the forward direction of the robot in the coordinate system, and the position of an obstacle in the coordinate system, where the obstacle includes a virtual obstacle;
S33、根据所述机器人的位置、所述前进方向以及第一安全距离,确定有效碰撞区;S33. Determine an effective collision zone according to the position of the robot, the forward direction, and the first safety distance;
S34、判断所述虚拟障碍物是否至少部分落入所述有效碰撞区内;S34. Determine whether the virtual obstacle at least partially falls within the effective collision zone;
S35、若是,根据所述机器人的位置、所述虚拟障碍物的位置和所述第一安全距离,控制所述机器人沿着所述虚拟障碍物行走。S35. If yes, control the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
机器人100在行走或者清扫过程中会遇到一些障碍物,这些障碍物包括真实障碍物和虚拟障碍物,机器人100对真实障碍物的避障处理是碰撞传感器检测到碰撞,再进行后续处理。虚拟障碍物包括禁区和虚拟墙等,而机器人100与虚拟障碍物之间不会发生真实的碰撞,相应的传感器也检测不到碰撞,因此,在本申请实施例中,模拟机器人100与虚拟障碍物的虚拟碰撞。若发生虚拟碰撞以后,机器人100采取相应措施,例如刹车或者沿着障碍物行走等,而第一安全距离则设置为机器人100的有效刹车范围,在该范围内,机器人100能够及时刹车,防止撞到障碍物。The robot 100 will encounter some obstacles during walking or cleaning. These obstacles include real obstacles and virtual obstacles. The obstacle avoidance process of the robot 100 for real obstacles is that the collision sensor detects the collision and then performs subsequent processing. Virtual obstacles include forbidden areas and virtual walls. However, there will be no real collision between the robot 100 and the virtual obstacle, and the corresponding sensor cannot detect the collision. Therefore, in the embodiment of the present application, the simulated robot 100 and the virtual obstacle Virtual collision of objects. If a virtual collision occurs, the robot 100 takes corresponding measures, such as braking or walking along obstacles, and the first safety distance is set as the effective braking range of the robot 100. Within this range, the robot 100 can brake in time to prevent collisions. To the obstacle.
为了模拟虚拟碰撞,该方法首先基于机器人100所处清洁环境建立坐标系,在坐标系中设置有效碰撞区,如图5中的A4、A5以及A6,只要虚拟障碍物L1至少部分落入有效碰撞区内,则认为机器人100与虚拟障碍物L1发生了虚拟碰撞。而有效碰撞区A4、A5以及A6,根据机器人100的位置、前进方向以及第一安全距离确定,在一些实施例中,确定有效碰撞区A4、A5以及A6的具体方式为首先获取机器人100在坐标系中的位置和前进方向,以及虚拟障碍物L1在坐标系中的位置,根据机器人100的位置、前进方向以及第一安全距离,先确定机器人100周侧的虚拟碰撞区域,虚拟碰撞区域的边界与机器人100的距离等于第一安全距离,只有在第一安全距离以内的才为虚拟碰撞区,第一安全距离以外的区域,即使存在虚拟障碍物L1,由于离机器人100较远,可以不考虑。在虚拟碰撞区域内,其靠近机器人100前进方向的一部分构成有效碰撞区,且有效碰撞区的边界上任意一点与机器人100的中心的连线方向均与前进方向的夹角小于或等于第一预设角度,也就是在前进方向的左、右预设范围内的区域。在本申请实施例中,该第一预设角度可设为90度,则在虚拟 碰撞区的边界上的任意一点与机器人100中心的连线方向,均与前进方向的夹角小于90度。同时,对于机器人100来说,避障时候,也是只需考虑机器人100前进方向的区域即可,对于机器人100后方的各个区域,均不用考虑障碍物L1的存在,因为机器人100需要向后运动时候,都是先旋转至后方方向,再向前行走。因此,根据机器人100的位置、前进方向以及第一安全距离,就可以确定出有效碰撞区。In order to simulate a virtual collision, the method first establishes a coordinate system based on the clean environment in which the robot 100 is located, and sets an effective collision area in the coordinate system, such as A4, A5, and A6 in Figure 5, as long as the virtual obstacle L1 at least partially falls into the effective collision Within the area, it is considered that the robot 100 has a virtual collision with the virtual obstacle L1. The effective collision areas A4, A5, and A6 are determined according to the position, forward direction and the first safety distance of the robot 100. In some embodiments, the specific method for determining the effective collision areas A4, A5, and A6 is to first obtain the coordinates of the robot 100 The position and direction of advancement in the system, as well as the position of the virtual obstacle L1 in the coordinate system, according to the position, direction of advancement and the first safety distance of the robot 100, first determine the virtual collision area around the robot 100, and the boundary of the virtual collision area The distance to the robot 100 is equal to the first safety distance, and only those within the first safety distance are the virtual collision zone. The area outside the first safety distance, even if there is a virtual obstacle L1, can be ignored because it is far away from the robot 100 . In the virtual collision area, a part close to the forward direction of the robot 100 constitutes an effective collision area, and the angle between any point on the boundary of the effective collision area and the center of the robot 100 and the forward direction is less than or equal to the first predetermined direction. Set the angle, that is, the area within the preset range on the left and right of the advancing direction. In the embodiment of the present application, the first preset angle can be set to 90 degrees, and the angle between any point on the boundary of the virtual collision zone and the center of the robot 100 and the forward direction is less than 90 degrees. At the same time, for the robot 100, when avoiding obstacles, it is only necessary to consider the area of the forward direction of the robot 100. For each area behind the robot 100, there is no need to consider the existence of the obstacle L1, because the robot 100 needs to move backwards. , All rotate to the rear direction first, and then walk forward. Therefore, according to the position, the forward direction and the first safety distance of the robot 100, the effective collision zone can be determined.
若虚拟障碍物L1至少部分落入有效碰撞区A4、A5以及A6,则认为机器人100与虚拟障碍物L1之间发生了虚拟碰撞,再根据机器人100的位置和第一安全距离,控制机器人100沿着虚拟障碍物L1行走。具体地,以第一安全距离为目标值,控制机器人100沿着虚拟障碍物L1行走并与虚拟障碍物L1之间保持在第一安全距离,在行走的过程中,还会实时获取机器人100与虚拟障碍物L1之间的实际距离,根据该实际距离是否满足第一安全距离控制机器人100沿着虚拟障碍物L1行走,若机器人100距离虚拟障碍物L1远了,则控制机器人100向右侧行走一点,达到第一安全距离,若机器人100距离虚拟障碍物L1近了,则控制机器人100向左侧行走一点,达到第一安全距离,即控制机器人100与虚拟障碍物之间L1保持在第一安全距离,并沿着虚拟障碍物L1行走。If the virtual obstacle L1 at least partially falls into the effective collision areas A4, A5, and A6, it is considered that a virtual collision has occurred between the robot 100 and the virtual obstacle L1, and then the robot 100 is controlled according to the position of the robot 100 and the first safety distance. Walk along the virtual obstacle L1. Specifically, taking the first safety distance as the target value, the robot 100 is controlled to walk along the virtual obstacle L1 and maintain the first safety distance from the virtual obstacle L1. During the walking process, the robot 100 and the virtual obstacle L1 are also obtained in real time. According to the actual distance between the virtual obstacles L1, the robot 100 is controlled to walk along the virtual obstacle L1 according to whether the actual distance meets the first safety distance. If the robot 100 is far away from the virtual obstacle L1, the robot 100 is controlled to walk to the right At one point, the first safety distance is reached. If the robot 100 is close to the virtual obstacle L1, the robot 100 is controlled to walk a little to the left to reach the first safety distance, that is, the control robot 100 and the virtual obstacle L1 remain at the first safety distance. A safe distance and walk along the virtual obstacle L1.
综上所述,当虚拟障碍物L1至少部分落入机器人100的有效碰撞区时,根据机器人100的位置、虚拟障碍物L1的位置和第一安全距离,控制机器人100沿着虚拟障碍物L1行走。该机器人避障方法对虚拟障碍物L1的形状和类型不做限制,实现更好的避障效果,进而提升用户体验。In summary, when the virtual obstacle L1 at least partially falls into the effective collision zone of the robot 100, the robot 100 is controlled to walk along the virtual obstacle L1 according to the position of the robot 100, the position of the virtual obstacle L1, and the first safety distance. . The robot obstacle avoidance method does not limit the shape and type of the virtual obstacle L1, and achieves a better obstacle avoidance effect, thereby enhancing the user experience.
在一些实施例中,请一并参阅图4和图5,有效碰撞区包括左侧碰撞区A5、前侧碰撞区A4和右侧碰撞区A6,请参阅图4,步骤S34包括:In some embodiments, please refer to FIGS. 4 and 5 together. The effective collision area includes a left collision area A5, a front collision area A4, and a right collision area A6. Please refer to FIG. 4, and step S34 includes:
S341、根据所述机器人的位置和所述虚拟障碍物的位置,判断所述虚拟障碍物是否与所述有效碰撞区的边界有交点;S341: According to the position of the robot and the position of the virtual obstacle, determine whether the virtual obstacle has an intersection with the boundary of the effective collision zone;
S342、若是,则确定所述虚拟障碍物至少部分落入所述有效碰撞区内;S342. If yes, determine that the virtual obstacle at least partially falls within the effective collision zone;
S343、若判断到所述虚拟障碍物至少部分落入所述有效碰撞区内,根据落入所述有效碰撞区内的虚拟障碍物的位置和所述机器人的位置,确定虚拟碰撞点,所述虚拟碰撞点为落入所述有效碰撞区内的虚拟障碍物上的点距离所述机器人的中心最近的点;S343. If it is determined that the virtual obstacle falls at least partially within the effective collision area, determine a virtual collision point according to the position of the virtual obstacle falling into the effective collision area and the position of the robot, the The virtual collision point is the point on the virtual obstacle that falls into the effective collision zone that is closest to the center of the robot;
S344、根据所述虚拟碰撞点、所述左侧碰撞区、所述前侧碰撞区和所述右侧碰撞区,确定所述虚拟障碍物至少部分落入所述有效碰撞区的位置。S344. Determine a position where the virtual obstacle at least partially falls into the effective collision zone according to the virtual collision point, the left collision zone, the front collision zone, and the right collision zone.
虚拟障碍物L1为用户预先设置的,例如通过与机器人100交互的软件进行设置等,设置以后,该虚拟障碍物L1存在于机器人100行走的空间的地图 上,可以获取该虚拟障碍物L1的坐标位置等信息。根据虚拟障碍物L1的坐标信息和有效碰撞区的坐标信息,可以确定虚拟障碍物L1是否与有效碰撞区的边界有交点,具体地,若虚拟障碍物L1为虚拟墙,在坐标系中,其可以通过二元一次方程表示,有效碰撞区的边界可以通过二元二次方程表示,两个方程组合求解,可以求得交点的坐标,若虚拟障碍物L1与有效碰撞区的边界有交点,则确定虚拟障碍物L1至少部分落入有效碰撞区。The virtual obstacle L1 is preset by the user, for example, through software that interacts with the robot 100. After the setting, the virtual obstacle L1 exists on the map of the space where the robot 100 is walking, and the coordinates of the virtual obstacle L1 can be obtained. Location and other information. According to the coordinate information of the virtual obstacle L1 and the coordinate information of the effective collision area, it can be determined whether the virtual obstacle L1 has an intersection with the boundary of the effective collision area. Specifically, if the virtual obstacle L1 is a virtual wall, in the coordinate system, It can be expressed by a binary linear equation. The boundary of the effective collision zone can be expressed by a binary quadratic equation. The two equations are combined to solve the coordinate of the intersection point. If the virtual obstacle L1 and the boundary of the effective collision zone have an intersection point, then It is determined that the virtual obstacle L1 at least partially falls into the effective collision zone.
若判断到虚拟障碍物L1至少部分落入有效碰撞区内以后,再判断虚拟障碍物L1至少部分落入哪个有效碰撞区,即判断该虚拟障碍物存在于左侧碰撞区A5、前侧碰撞区A4还是右侧碰撞区A6,有效碰撞区包含多个区域,若以前进方向为正方向,每个有效碰撞区的范围可以不限制,三个区域的大小也不一定相同,例如,如图5所示,机器人100的前进方向如图中实线箭头所示,前侧碰撞区A4的两个边界线夹角为第一预设角度,其可以为90度,其区域在前进方向的左侧或者右侧,左侧碰撞区A5的两个边界线夹角为第二预设角度,其可以为45度,且在前进方向的左侧,右侧碰撞区A6的两个边界线夹角为第二预设角度,其可以为45度,且在前进方向的右侧。当然,在其他实施方式中,第一预设角度和第二预设角度也不局限于上述举例,可以根据实际需要灵活设置。If it is determined that the virtual obstacle L1 is at least partially within the effective collision zone, then it is determined which effective collision zone the virtual obstacle L1 falls into at least partially, that is, it is determined that the virtual obstacle exists in the left collision zone A5 and the front collision zone. A4 is also the right collision area A6. The effective collision area contains multiple areas. If the forward direction is the positive direction, the range of each effective collision area may not be limited, and the size of the three areas may not be the same, for example, as shown in Figure 5. As shown, the forward direction of the robot 100 is shown by the solid arrow in the figure. The angle between the two boundary lines of the front side collision area A4 is the first preset angle, which can be 90 degrees, and its area is on the left side of the forward direction. Or on the right, the angle between the two boundary lines of the left collision area A5 is the second preset angle, which can be 45 degrees, and on the left side of the forward direction, the angle between the two boundary lines of the right collision area A6 is The second preset angle, which can be 45 degrees, and is on the right side of the advancing direction. Of course, in other embodiments, the first preset angle and the second preset angle are not limited to the above examples, and can be flexibly set according to actual needs.
若判断到虚拟障碍物L1至少落入有效碰撞区内,则认为机器人100和该虚拟障碍物L1发生了虚拟碰撞,则首先根据落入有效碰撞区内的虚拟障碍物和机器人100的位置,确定该虚拟碰撞点C,该虚拟碰撞点C被定义为落入有效碰撞区内的虚拟障碍物L1上的点距离机器人100的中心点A最近的点,该步骤同样可通过坐标计算实现,例如:若虚拟障碍物L1与有效碰撞区边界存在两个交点,则取两个交点之间的所有虚拟障碍物上L1的点的坐标,计算所有点与机器人100中心点A的距离,距离最短的点即为虚拟碰撞点C,又或者,若虚拟障碍物L1与有效碰撞区边界存在多个交点,则取多个交点之间的所有虚拟障碍物L1上的点的坐标,计算所有点与机器人100中心点A的距离,距离最短的点即为虚拟碰撞点C,又或者,若虚拟障碍物L1与有效碰撞区边界只存在一个交点,则该交点为虚拟障碍物L1上的点距离机器人100的中心点A最近的点,该交点为虚拟碰撞点C。If it is judged that the virtual obstacle L1 falls into the effective collision zone at least, it is considered that the robot 100 and the virtual obstacle L1 have a virtual collision, and the position of the virtual obstacle and the robot 100 in the effective collision zone is determined first. The virtual collision point C, the virtual collision point C is defined as the point on the virtual obstacle L1 that falls into the effective collision zone that is closest to the center point A of the robot 100. This step can also be implemented by coordinate calculation, for example: If there are two intersection points between the virtual obstacle L1 and the effective collision zone boundary, take the coordinates of the point L1 on all the virtual obstacles between the two intersection points, and calculate the distance between all the points and the center point A of the robot 100, the point with the shortest distance That is the virtual collision point C, or if there are multiple intersection points between the virtual obstacle L1 and the effective collision zone boundary, take the coordinates of all the points on the virtual obstacle L1 between the multiple intersection points, and calculate all the points and the robot 100 The distance from the center point A. The point with the shortest distance is the virtual collision point C. Or, if there is only one intersection point between the virtual obstacle L1 and the effective collision zone boundary, the intersection point is the distance between the point on the virtual obstacle L1 and the robot 100. The closest point to the center point A, the intersection point is the virtual collision point C.
最后,根据虚拟碰撞点C、左侧碰撞区A5、前侧碰撞区A4和右侧碰撞区A6,判断虚拟障碍物L1至少部分落入有效碰撞区的具***置,判断虚拟障碍物L1具体落入哪个有效碰撞区,有很多判断方法,在一些实施例中,首先标记虚拟碰撞点C与机器人100的中心A的连线方向,该连线方向为障碍方向,若该障碍方向与前进方向的夹角大于第二预设角度,且障碍方向位于前进方向 的左侧,则该虚拟障碍物L1至少部分落入左侧碰撞区A4,其中,该第二预设角度小于第一预设角度,该第二预设角度的具体数值,可以由用户根据需要而设置,在本申请实施例中,其为45度。若障碍方向与前进方向的夹角大于第二预设角度,且障碍方向位于前进方向的右侧,则虚拟障碍物至少部分落入右侧碰撞区A6。若障碍方向与前进方向的夹角小于或等于第二预设角度,且障碍方向位于前进方向的左侧或右侧,又或者障碍方向与前进方向同侧,则虚拟障碍物L1至少部分落入前侧碰撞区A4。Finally, according to the virtual collision point C, the left collision area A5, the front collision area A4 and the right collision area A6, it is determined that the virtual obstacle L1 at least partially falls into the specific position of the effective collision area, and it is determined that the virtual obstacle L1 specifically falls into There are many ways to determine which effective collision zone is. In some embodiments, first mark the connection direction between the virtual collision point C and the center A of the robot 100. The connection direction is the obstacle direction. If the angle is greater than the second preset angle, and the obstacle direction is on the left side of the forward direction, the virtual obstacle L1 at least partially falls into the left side collision area A4, where the second preset angle is smaller than the first preset angle, the The specific value of the second preset angle can be set by the user according to needs, and in the embodiment of the present application, it is 45 degrees. If the angle between the obstacle direction and the forward direction is greater than the second preset angle, and the obstacle direction is located on the right side of the forward direction, the virtual obstacle at least partially falls into the right collision zone A6. If the angle between the obstacle direction and the forward direction is less than or equal to the second preset angle, and the obstacle direction is located on the left or right side of the forward direction, or the obstacle direction is on the same side as the forward direction, the virtual obstacle L1 at least partially falls into Front collision zone A4.
在一些实施例中,还可以通过虚拟障碍物L1的坐标和各个有效碰撞区的坐标,直接进行确定该虚拟障碍物L1至少部分落入有效碰撞区的位置,具体地,虚拟障碍物L1的坐标与各个有效碰撞区的坐标进行坐标比对,判断是否有坐标重合区域,若虚拟障碍物L1的坐标与左侧碰撞区A5的坐标有重合,则确定该虚拟障碍物L1至少部分落入左侧碰撞区A5,若虚拟障碍物L1的坐标还与右侧碰撞区A6的坐标有重合,则确定该虚拟障碍物L1至少部分落入右侧碰撞区A6,若虚拟障碍物L1的坐标还与前侧碰撞区A4的坐标有重合,则确定该虚拟障碍物L1至少部分落入前侧碰撞区A4。In some embodiments, the coordinates of the virtual obstacle L1 and the coordinates of each effective collision zone can also be used to directly determine the position where the virtual obstacle L1 at least partially falls into the effective collision zone, specifically, the coordinates of the virtual obstacle L1 Compare the coordinates with the coordinates of each effective collision area to determine whether there is a coordinate overlap area. If the coordinates of the virtual obstacle L1 overlap with the coordinates of the left collision area A5, it is determined that the virtual obstacle L1 at least partially falls on the left side In the collision area A5, if the coordinates of the virtual obstacle L1 are still coincident with the coordinates of the right collision area A6, it is determined that the virtual obstacle L1 at least partially falls into the right collision area A6. If the coordinates of the virtual obstacle L1 are still with the previous If the coordinates of the side collision area A4 overlap, it is determined that the virtual obstacle L1 at least partially falls into the front side collision area A4.
因此,可以通过上述的多种方法确定虚拟障碍物至少部分落入有效碰撞区的位置。在一些实施例中,若所述虚拟障碍物未落入右侧碰撞区,则控制所述机器人100旋转,直至所述虚拟障碍物至少部分落入所述右侧碰撞区。Therefore, the position where the virtual obstacle at least partially falls into the effective collision zone can be determined by the above-mentioned various methods. In some embodiments, if the virtual obstacle does not fall into the right collision zone, the robot 100 is controlled to rotate until the virtual obstacle at least partially falls into the right collision zone.
因此,若虚拟障碍物L1未落入右侧碰撞区A6,而是至少部分落入于左侧碰撞区A5或者前侧碰撞区A4,则控制机器人100旋转,直至虚拟障碍物L1至少部分落入右侧碰撞区A6,再确定该虚拟障碍物L1与右侧碰撞区A6的虚拟碰撞点,然后再根据虚拟碰撞点响应该虚拟碰撞。Therefore, if the virtual obstacle L1 does not fall into the right side collision area A6, but at least partially falls into the left side collision area A5 or the front side collision area A4, the robot 100 is controlled to rotate until the virtual obstacle L1 falls at least partially In the right collision area A6, the virtual collision point between the virtual obstacle L1 and the right collision area A6 is determined, and then the virtual collision is responded to according to the virtual collision point.
在一些实施例中,机器人100在沿着障碍物行走的过程中,还同时检测左方区域和前进方向区域的障碍物情况,具体地,虚拟障碍物L1包括第一虚拟障碍物和第二虚拟障碍物,当机器人100沿着第一虚拟障碍物行走时,请参阅图6,该机器人避障方法S60还包括:In some embodiments, while the robot 100 is walking along the obstacle, it also detects the obstacle situation in the left area and the forward direction area at the same time. Specifically, the virtual obstacle L1 includes a first virtual obstacle and a second virtual obstacle. Obstacles. When the robot 100 walks along the first virtual obstacle, please refer to FIG. 6. The obstacle avoidance method S60 of the robot further includes:
S61、判断所述第二虚拟障碍物是否至少部分落入所述左侧碰撞区或所述前侧碰撞区内;S61. Determine whether the second virtual obstacle at least partially falls into the left side collision zone or the front side collision zone;
S62、若是,控制所述机器人旋转,直至所述第二虚拟障碍物至少部分落入所述右侧碰撞区内,再根据所述机器人的位置、所述第二虚拟障碍物的位置以及所述第一安全距离,控制所述机器人沿着所述第二虚拟障碍物行走。S62. If yes, control the rotation of the robot until the second virtual obstacle at least partially falls into the right side collision zone, and then according to the position of the robot, the position of the second virtual obstacle, and the The first safety distance controls the robot to walk along the second virtual obstacle.
机器人100在沿着第一虚拟障碍物行走的过程中,该第一虚拟障碍物至少部分落入机器人100的右侧碰撞区A6,同时,机器人100会检测第二虚拟障碍物是否部分落入其左侧碰撞区A5或者前侧碰撞区A4内,若部分落入,则 代表机器人100与左侧碰撞区A5内的第二虚拟障碍物或者前侧碰撞区A4内的第二虚拟障碍物发生了虚拟碰撞,那么就立即响应该虚拟碰撞,再进行沿着第二虚拟障碍物行走的过程,具体地,发生虚拟碰撞时,控制机器人100旋转,直至第二虚拟障碍物至少部分落入右侧碰撞区A6,再根据机器人100的位置、第二虚拟障碍物的位置与第一安全距离,控制机器人100沿着第二虚拟障碍物行走,进行新的沿边运动。该方法可以使得机器人100在避障的过程中,同时检测其他方向的虚拟障碍物情况,实现更好地避障效果。While the robot 100 is walking along the first virtual obstacle, the first virtual obstacle at least partially falls into the right side collision area A6 of the robot 100, and at the same time, the robot 100 will detect whether the second virtual obstacle partially falls into it. In the left-side collision area A5 or the front-side collision area A4, if part of it falls, it means that the robot 100 and the second virtual obstacle in the left-side collision area A5 or the second virtual obstacle in the front-side collision area A4 have occurred Virtual collision, then immediately respond to the virtual collision, and then proceed to the process of walking along the second virtual obstacle. Specifically, when a virtual collision occurs, the robot 100 is controlled to rotate until the second virtual obstacle at least partially falls into the right side collision In area A6, according to the position of the robot 100, the position of the second virtual obstacle and the first safety distance, the robot 100 is controlled to walk along the second virtual obstacle to perform a new edge movement. This method can enable the robot 100 to detect virtual obstacles in other directions at the same time during the obstacle avoidance process, so as to achieve a better obstacle avoidance effect.
综上所述,当虚拟障碍物L1至少部分落入机器人100的有效碰撞区时,根据机器人100的位置、虚拟障碍物L1的位置和第一安全距离,控制机器人100沿着虚拟障碍物L1行走。该机器人避障方法对虚拟障碍物L1的形状和类型不做限制,实现更好的避障效果,进而提升用户体验。In summary, when the virtual obstacle L1 at least partially falls into the effective collision zone of the robot 100, the robot 100 is controlled to walk along the virtual obstacle L1 according to the position of the robot 100, the position of the virtual obstacle L1, and the first safety distance. . The robot obstacle avoidance method does not limit the shape and type of the virtual obstacle L1, and achieves a better obstacle avoidance effect, thereby enhancing the user experience.
在一些实施例中,请一并参阅图7和图8,步骤S35包括:In some embodiments, please refer to FIG. 7 and FIG. 8 together, and step S35 includes:
S351、生成以所述机器人的位置为原点,以预设方向为方向,延伸至所述虚拟障碍物的位置的虚拟探测信号,所述预设方向与所述机器人的前进方向呈锐角设置;S351. Generate a virtual detection signal extending to the position of the virtual obstacle with the position of the robot as the origin and a preset direction as a direction, where the preset direction is set at an acute angle with the forward direction of the robot;
确定虚拟障碍物L1与有效碰撞区发生虚拟碰撞以后,就响应该碰撞,具体地,首先以机器人100与虚拟碰撞点C的连线距离作为最初的实际距离,以第一安全距离作为目标距离,控制机器人100沿着虚拟障碍物L1行走,而在行走的过程中,生成以机器人100的位置为原点,以预设方向为方向,延伸至虚拟障碍物L1的位置的虚拟探测信号,其中,该预设方向与机器人100的前进方向呈锐角设置。该虚拟探测信号的原点为机器人100位置,具体地,其可以为机器人100的中心点A,方向为预设方向,且指向虚拟位置。一般地,该预设方向为原点A指向机器人100tof传感器的方向,其中,若以机器人100前进方向为正方向,则tof传感器设置于机器人100正方向的右上方位置,其可以检测真实障碍物与机器人100之间的距离,且安装于右上方位置,而不是正右侧位置,可以对右侧障碍物的距离进行一下预判,提前做好避障准备,也更好地控制实现沿着障碍物行走。因此,预设方向与机器人100的前进方向之间设置的锐角为机器人100的tof传感器与机器人100前进方向的夹角。After it is determined that the virtual obstacle L1 has a virtual collision with the effective collision zone, it responds to the collision. Specifically, first, the distance between the robot 100 and the virtual collision point C is taken as the initial actual distance, and the first safe distance is taken as the target distance. Control the robot 100 to walk along the virtual obstacle L1, and in the process of walking, generate a virtual detection signal with the position of the robot 100 as the origin and the preset direction as the direction, extending to the position of the virtual obstacle L1, where the The preset direction and the forward direction of the robot 100 are set at an acute angle. The origin of the virtual detection signal is the position of the robot 100, specifically, it may be the center point A of the robot 100, the direction is a preset direction, and it points to the virtual position. Generally, the preset direction is the direction in which the origin A points to the tof sensor of the robot 100. If the forward direction of the robot 100 is the positive direction, the tof sensor is arranged at the upper right position of the positive direction of the robot 100, which can detect real obstacles and The distance between the robots 100 is installed in the upper right position instead of the right position. You can predict the distance of the obstacle on the right side, prepare for obstacle avoidance in advance, and better control the realization of the obstacle along the way. Things walking. Therefore, the acute angle set between the preset direction and the advancing direction of the robot 100 is the included angle between the tof sensor of the robot 100 and the advancing direction of the robot 100.
S352、确定所述虚拟探测信号与所述虚拟障碍物的交点为虚拟交点;S352. Determine that the intersection of the virtual detection signal and the virtual obstacle is a virtual intersection;
S353、确定所述机器人距离所述虚拟交点的距离为第一实际距离;S353. Determine that the distance between the robot and the virtual intersection point is the first actual distance;
S354、根据所述第一实际距离是否满足所述第一安全距离,控制所述机器人沿所述虚拟障碍物行走。S354: Control the robot to walk along the virtual obstacle according to whether the first actual distance meets the first safety distance.
该虚拟探测信号指向虚拟位置,若无尽延长,则肯定与虚拟障碍物L1有交点,该交点则确定为虚拟交点C,最后确定机器人100距离虚拟交点C的距 离为第一实际距离,也即机器人100的位置距离虚拟墙位置的实际距离。例如:如图8所示,虚拟墙L1为一段曲线,且以虚线段进行表示,机器人100的前进方向如图中实线箭头所示,机器人100原点为点A,机器人100的tof传感器所在的位置为点B,以点A为原点,以点A指向点B的方向为预设方向,向虚拟墙L1位置生成虚拟探测信号,该虚拟探测信号以直线l表示,该直线l与虚拟墙的交点为C点,C点则为虚拟交点,则将线段BC的长度作为第一实际距离,即机器人100距离虚拟交点C点的距离。The virtual detection signal points to the virtual position. If it is extended endlessly, it must have an intersection with the virtual obstacle L1. The intersection is determined as the virtual intersection C. Finally, it is determined that the distance between the robot 100 and the virtual intersection C is the first actual distance, that is, the robot The actual distance between the position of 100 and the position of the virtual wall. For example: as shown in Figure 8, the virtual wall L1 is a curve, and is represented by a dashed line segment, the forward direction of the robot 100 is shown by the solid arrow in the figure, the origin of the robot 100 is point A, and the tof sensor of the robot 100 is located The position is point B, with point A as the origin, and the direction from point A to point B as the preset direction. A virtual detection signal is generated toward the position of the virtual wall L1. The virtual detection signal is represented by a straight line l. The point of intersection is point C, and point C is the virtual point of intersection, and the length of the line segment BC is taken as the first actual distance, that is, the distance between the robot 100 and the virtual point of intersection C.
在一些实施例中,确定了第一实际距离以后,根据第一实际距离是否满足第一安全距离,控制机器人100沿着虚拟障碍物L1行走。具体地,第一实际距离其实为机器人100右侧与虚拟墙L1的实际距离,若第一实际距离大于第一安全距离,则控制机器人100向右侧行走,直至使得机器人100与虚拟墙L1之间的距离保持在第一安全距离,若第一实际距离小于第一安全距离,则控制机器人100向左侧行走,直至使得机器人100与虚拟墙L1之间的距离保持在第一安全距离。第一安全距离可以设置为5cm,用户也可以根据需要而设置,而该步骤可以通过PID控制算法实现。In some embodiments, after the first actual distance is determined, the robot 100 is controlled to walk along the virtual obstacle L1 according to whether the first actual distance meets the first safety distance. Specifically, the first actual distance is actually the actual distance between the right side of the robot 100 and the virtual wall L1. If the first actual distance is greater than the first safe distance, the robot 100 is controlled to walk to the right side until the robot 100 is between the virtual wall L1 If the first actual distance is less than the first safety distance, the robot 100 is controlled to walk to the left until the distance between the robot 100 and the virtual wall L1 is maintained at the first safety distance. The first safety distance can be set to 5cm, and the user can also set it as needed, and this step can be implemented through PID control algorithms.
因此,无论虚拟障碍物L1至少部分落入有效碰撞区的哪个部分,均是以机器人100右侧与虚拟障碍物L1的实际距离确定机器人100距离虚拟障碍物L1的第一实际距离。即使在左侧碰撞区A5或者前侧碰撞区A4检测到虚拟障碍物L1至少部分落入该有效碰撞区,该机器人避障方法也能很好地实现避障,达到更好地避障效果。Therefore, no matter which part of the effective collision zone the virtual obstacle L1 at least partially falls into, the first actual distance of the robot 100 from the virtual obstacle L1 is determined by the actual distance between the right side of the robot 100 and the virtual obstacle L1. Even if it is detected that the virtual obstacle L1 at least partially falls into the effective collision area in the left collision area A5 or the front collision area A4, the obstacle avoidance method of the robot can also achieve obstacle avoidance well and achieve a better obstacle avoidance effect.
在一些实施例中,若左侧碰撞区A5、右侧碰撞区A6和前侧碰撞区A4均检测到有虚拟障碍物L1至少部分落入,则根据预设优先级,响应虚拟碰撞,具体地,预设优先级可以为左侧碰撞区A5响应优先级>前侧碰撞区A4响应优先级>右侧碰撞区A6响应优先级,即先响应左侧碰撞区A5的虚拟碰撞,若虚拟障碍物L1未至少部分落入左侧碰撞区A5,则先响应前侧碰撞区A4的虚拟碰撞,若虚拟障碍物L1未至少部分落入左侧碰撞区A5且未至少部分落入前侧碰撞区A4,则响应右侧碰撞区A6的虚拟碰撞。In some embodiments, if the left collision area A5, the right collision area A6, and the front collision area A4 all detect that the virtual obstacle L1 falls at least partially, the virtual collision is responded to according to the preset priority, specifically , The preset priority can be left collision area A5 response priority> front collision area A4 response priority> right collision area A6 response priority, that is, to respond to the virtual collision in the left collision area A5 first, if there is a virtual obstacle If L1 does not fall at least partially into the left collision zone A5, first respond to the virtual collision of the front collision zone A4. If the virtual obstacle L1 does not fall at least partially into the left collision zone A5 and does not fall at least partially into the front collision zone A4 , Then respond to the virtual collision in the right collision zone A6.
综上所述,当虚拟障碍物L1至少部分落入机器人100的有效碰撞区时,根据机器人100的位置、虚拟障碍物L1的位置和第一安全距离,控制机器人100沿着虚拟障碍物L1行走。该机器人避障方法对虚拟障碍物L1的形状和类型不做限制,实现更好的避障效果,进而提升用户体验。In summary, when the virtual obstacle L1 at least partially falls into the effective collision zone of the robot 100, the robot 100 is controlled to walk along the virtual obstacle L1 according to the position of the robot 100, the position of the virtual obstacle L1, and the first safety distance. . The robot obstacle avoidance method does not limit the shape and type of the virtual obstacle L1, and achieves a better obstacle avoidance effect, thereby enhancing the user experience.
在一些实施例中,所述障碍物还包括真实障碍物,若真实障碍物和虚拟障碍物L1同时存在,请参阅图9,该机器人避障方法S90包括:In some embodiments, the obstacles also include real obstacles. If the real obstacle and the virtual obstacle L1 exist at the same time, please refer to FIG. 9. The robot obstacle avoidance method S90 includes:
S91、获取所述第一实际距离与所述第一安全距离的第一差值;S91. Obtain a first difference between the first actual distance and the first safe distance;
S92、获取所述机器人距离所述真实障碍物的第二实际距离;S92. Acquire a second actual distance of the robot from the real obstacle;
S93、获取所述第二实际距离与所述第二安全距离的第二差值;S93. Obtain a second difference between the second actual distance and the second safety distance;
S94、判断所述第一差值是否小于所述第二差值;S94. Determine whether the first difference value is less than the second difference value;
S95、若是,根据所述第一实际距离是否满足所述第一安全距离,控制所述机器人沿着所述虚拟障碍物行走;S95. If yes, control the robot to walk along the virtual obstacle according to whether the first actual distance meets the first safety distance;
S96、若否,根据所述第二实际距离是否满足所述第二安全距离,控制所述机器人沿着所述真实障碍物行走。S96. If not, control the robot to walk along the real obstacle according to whether the second actual distance meets the second safety distance.
机器人100在沿着某个障碍物行走的过程中,可能会碰到真实障碍物和虚拟障碍物L1同时存在的情况,例如:机器人100在沿着虚拟障碍物L1行走的过程中,设置在机器人100右上方的tof传感器检测到右侧存在真实障碍物,那么在机器人100的右侧空间内,则既存在虚拟障碍物L1,又存在真实障碍物。对于真实障碍物来说,机器人100的安全距离为第二安全距离,机器人100与真实障碍物保持在第二安全距离范围内,同时沿着真实障碍物行走,沿着真实障碍物进行沿边运动。其中,在本申请实施例中,第二安全距离为1cm,用户也可以根据需要而设置。When the robot 100 is walking along an obstacle, it may encounter a situation where the real obstacle and the virtual obstacle L1 exist at the same time. For example, the robot 100 is set in the robot while walking along the virtual obstacle L1. The tof sensor on the upper right of 100 detects that there is a real obstacle on the right side, so in the space on the right side of the robot 100, there are both virtual obstacles L1 and real obstacles. For real obstacles, the safe distance of the robot 100 is the second safe distance. The robot 100 keeps within the second safe distance from the real obstacle, while walking along the real obstacle, and moving along the real obstacle. Among them, in the embodiment of the present application, the second safety distance is 1 cm, and the user can also set it as needed.
针对这种在沿边行走的过程中,机器人100右侧空间内真实障碍物和虚拟障碍物L1同时存在的情况,机器人100利用该tof传感器实时测量真实障碍物距离机器人100的距离,该距离称为第二实际距离,首先获取第一实际距离与第一安全距离的第一差值,然后获取第二实际距离与第二安全距离的第二差值,根据两个差值的大小,采取不同的措施,若第一差值小于第二差值,则根据第一实际距离和第一安全距离,控制机器人100沿着虚拟障碍物L1行走,若第一差值大于第二差值,则根据第二实际距离和第二安全距离,控制机器人100沿着真实障碍物行走。即选择较小的差值作为运动控制的反馈值,机器人100沿着障碍物行走的控制过程中,控制目标值可设为零,较小的差值作为反馈值,控制机器人100沿着较小差值对应的障碍物行走。例如:如图10所示,机器人100的前进方向如图中箭头所示,机器人100距离虚拟障碍物L1的实际距离为S1,安全距离为S2,机器人100距离第一真实障碍物L2的实际距离为S3,安全距离为S4,机器人100距离第二真实障碍物L3的实际距离为S5,安全距离为S4(图中未示出),则分别获取各个实际距离与对应安全距离的差值,为了更好地说明,此处将S2设为与S4相等,均设为1cm,在其他实施例中,两者也可以不等,例如S2=5cm,S4=1cm。若S2与S4相等,那么对于虚拟墙L1来说,差值ΔS1=S1-S2=0,对于第一真实障碍物L2来说,差值ΔS2=S3-S4<0,对于第二真实障碍物L3来说,差值ΔS3=S5-S4>0,则将差值ΔS2反馈给机器人100,机器人100以差值ΔS2作为反馈值,以零作为目标值, 控制机器人100沿着第一真实障碍物L2行走,进行沿边运动。In view of this situation where the real obstacle and the virtual obstacle L1 coexist in the space on the right side of the robot 100 while walking along the edge, the robot 100 uses the tof sensor to measure the distance between the real obstacle and the robot 100 in real time. This distance is called For the second actual distance, first obtain the first difference between the first actual distance and the first safety distance, and then obtain the second difference between the second actual distance and the second safety distance, and take different values according to the magnitude of the two differences. If the first difference is less than the second difference, the robot 100 is controlled to walk along the virtual obstacle L1 according to the first actual distance and the first safety distance. If the first difference is greater than the second difference, then according to the first difference The second actual distance and the second safety distance are used to control the robot 100 to walk along the real obstacle. That is, the smaller difference is selected as the feedback value of motion control. During the control process of the robot 100 walking along the obstacle, the control target value can be set to zero, and the smaller difference is used as the feedback value to control the robot 100 to move along the smaller The obstacle corresponding to the difference is walking. For example: as shown in Figure 10, the forward direction of the robot 100 is shown by the arrow in the figure, the actual distance of the robot 100 from the virtual obstacle L1 is S1, the safety distance is S2, and the actual distance of the robot 100 from the first real obstacle L2 Is S3, the safety distance is S4, the actual distance between the robot 100 and the second real obstacle L3 is S5, and the safety distance is S4 (not shown in the figure), then the difference between each actual distance and the corresponding safety distance is obtained respectively, in order to To better illustrate, here S2 is set equal to S4, both of which are set to 1 cm. In other embodiments, the two may also be different, for example, S2 = 5 cm and S4 = 1 cm. If S2 is equal to S4, then for the virtual wall L1, the difference ΔS1=S1-S2=0, for the first real obstacle L2, the difference ΔS2=S3-S4<0, for the second real obstacle For L3, the difference ΔS3=S5-S4>0, the difference ΔS2 is fed back to the robot 100, and the robot 100 uses the difference ΔS2 as the feedback value and zero as the target value to control the robot 100 along the first real obstacle L2 walks and moves along the edge.
当在行走的过程中,若真实障碍物和虚拟障碍物同时存在时,该方法可以无缝切换机器人沿边行走的障碍物,根据障碍物的实际情况,控制机器人沿着对应的障碍物行走,实现更好地避障效果。When walking, if real obstacles and virtual obstacles exist at the same time, this method can seamlessly switch the obstacles that the robot walks along. According to the actual situation of the obstacles, control the robot to walk along the corresponding obstacles. Better obstacle avoidance effect.
综上所述,当虚拟障碍物至少部分落入机器人的有效碰撞区时,根据机器人的位置、虚拟障碍物的位置和第一安全距离,控制机器人沿着虚拟障碍物行走。该机器人避障方法对虚拟障碍物的形状和类型不做限制,实现更好的避障效果,进而提升用户体验。In summary, when the virtual obstacle falls into the effective collision zone of the robot at least partially, the robot is controlled to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance. The robot obstacle avoidance method does not limit the shape and type of virtual obstacles, and achieves a better obstacle avoidance effect, thereby enhancing user experience.
需要说明的是,在上述各个实施例中,上述各步骤之间并不必然存在一定的先后顺序,本领域普通技术人员,根据本申请实施例的描述可以理解,不同实施例中,上述各步骤可以有不同的执行顺序,亦即,可以并行执行,亦可以交换执行等等。It should be noted that in each of the foregoing embodiments, there is not necessarily a certain sequence between the foregoing steps. A person of ordinary skill in the art can understand from the description of the embodiments of the present application that in different embodiments, the foregoing steps There can be different execution orders, that is, they can be executed in parallel, they can be executed interchangeably, and so on.
作为本申请实施例的另一方面,本申请实施例提供一种机器人避障装置。其中,机器人避障装置可以为软件模块,所述软件模块包括若干指令,其存储在电调中的存储器内,处理器可以访问该存储器,调用指令进行执行,以完成上述各个实施例所阐述的机器人避障方法。As another aspect of the embodiments of the present application, the embodiments of the present application provide a robot obstacle avoidance device. Among them, the robot obstacle avoidance device may be a software module, the software module includes a number of instructions, which are stored in a memory in the ESC, and the processor can access the memory and call the instructions for execution, so as to complete the above-mentioned various embodiments. Robot obstacle avoidance method.
在一些实施例中,机器人避障装置亦可以由硬件器件搭建成的,例如,机器人避障装置可以由一个或两个以上的芯片搭建而成,各个芯片可以互相协调工作,以完成上述各个实施例所阐述的机器人避障方法。再例如,机器人避障装置还可以由各类逻辑器件搭建而成,诸如由通用处理器、数字信号处理器(DSP)、专用集成电路(ASIC)、现场可编程门阵列(FPGA)、单片机、ARM(Acorn RISC Machine)或其它可编程逻辑器件、分立门或晶体管逻辑、分立的硬件组件或者这些部件的任何组合而搭建成。In some embodiments, the robot obstacle avoidance device can also be built by hardware devices. For example, the robot obstacle avoidance device can be built by one or more than two chips, and each chip can work in coordination with each other to complete the above implementations. The robot obstacle avoidance method described in the example. For another example, the robot obstacle avoidance device can also be built by various logic devices, such as general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field programmable gate arrays (FPGA), single-chip computers, Built by ARM (Acorn RISC Machine) or other programmable logic devices, discrete gates or transistor logic, discrete hardware components, or any combination of these components.
请参阅图11,图11是本申请实施例提供一种机器人避障装置,该机器人避障装置200包括建立模块21、第一获取模块22、第一确定模块23、第一判断模块24以及第一控制模块25。Please refer to FIG. 11, which is a robot obstacle avoidance device provided by an embodiment of the present application. The robot obstacle avoidance device 200 includes an establishment module 21, a first acquisition module 22, a first determination module 23, a first judgment module 24, and a first determination module. One control module 25.
建立模块21用于基于所述机器人所处清洁环境建立坐标系;The establishment module 21 is used to establish a coordinate system based on the clean environment in which the robot is located;
第一获取模块22用于获取所述机器人在所述坐标系中的位置和前进方向,以及障碍物在所述坐标系中的位置,所述障碍物包括虚拟障碍物;The first acquiring module 22 is configured to acquire the position and forward direction of the robot in the coordinate system, and the position of obstacles in the coordinate system, the obstacles including virtual obstacles;
第一确定模块23用于根据所述机器人的位置、所述前进方向以及第一安全距离,确定有效碰撞区;The first determining module 23 is configured to determine an effective collision zone according to the position of the robot, the forward direction, and the first safety distance;
第一判断模块24用于判断所述虚拟障碍物是否至少部分落入所述有效碰撞区内;The first judgment module 24 is configured to judge whether the virtual obstacle at least partially falls into the effective collision zone;
第一控制模块25用于根据所述机器人的位置、所述虚拟障碍物的位置和 所述第一安全距离,控制所述机器人沿着所述虚拟障碍物行走。The first control module 25 is configured to control the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
因此,当虚拟障碍物至少部分落入机器人的有效碰撞区时,该机器人避障装置根据机器人的位置、虚拟障碍物的位置和第一安全距离,控制机器人沿着虚拟障碍物行走。该机器人避障方法对虚拟障碍物的形状和类型不做限制,实现更好的避障效果,进而提升用户体验。Therefore, when the virtual obstacle at least partially falls into the effective collision zone of the robot, the robot obstacle avoidance device controls the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance. The robot obstacle avoidance method does not limit the shape and type of virtual obstacles, and achieves a better obstacle avoidance effect, thereby enhancing user experience.
在一些实施例中,第一确定模块23具体用于:确定位于所述机器人周侧的虚拟碰撞区域,所述虚拟碰撞区域的边界与所述机器人的距离等于所述第一安全距离;所述虚拟碰撞区域靠近所述机器人前进方向的一部分构成所述有效碰撞区,所述有效碰撞区的边界上的任意一点与所述机器人的中心的连线方向均与所述前进方向的夹角小于或等于第一预设角度。In some embodiments, the first determining module 23 is specifically configured to: determine a virtual collision area located on the peripheral side of the robot, and the distance between the boundary of the virtual collision area and the robot is equal to the first safety distance; A part of the virtual collision area close to the forward direction of the robot constitutes the effective collision area, and the angle between any point on the boundary of the effective collision area and the center of the robot and the forward direction is less than or Equal to the first preset angle.
在一些实施例中,所述有效碰撞区包括左侧碰撞区、前侧碰撞区和右侧碰撞区,第一确定模块23还具体用于:根据所述机器人的位置和所述虚拟障碍物的位置,判断所述虚拟障碍物是否与所述有效碰撞区的边界有交点;若是,则确定所述虚拟障碍物至少部分落入所述有效碰撞区内;若判断到所述虚拟障碍物至少部分落入所述有效碰撞区内,根据落入所述有效碰撞区内的虚拟障碍物的位置和所述机器人的位置,确定虚拟碰撞点,所述虚拟碰撞点为落入所述有效碰撞区内的虚拟障碍物上的点距离所述机器人的中心最近的点;根据所述虚拟碰撞点、所述左侧碰撞区、所述前侧碰撞区和所述右侧碰撞区,确定所述虚拟障碍物至少部分落入所述有效碰撞区的位置。In some embodiments, the effective collision zone includes a left collision zone, a front collision zone, and a right collision zone. The first determining module 23 is also specifically configured to: according to the position of the robot and the position of the virtual obstacle Position, determine whether the virtual obstacle has an intersection with the boundary of the effective collision zone; if so, determine that the virtual obstacle at least partially falls within the effective collision zone; if it is determined that the virtual obstacle is at least partially Falling into the effective collision zone, and determining a virtual collision point based on the position of the virtual obstacle falling into the effective collision zone and the position of the robot, and the virtual collision point is falling into the effective collision zone The point on the virtual obstacle that is closest to the center of the robot; the virtual obstacle is determined according to the virtual collision point, the left collision zone, the front collision zone, and the right collision zone The object at least partially falls into the position of the effective collision zone.
在一些实施例中,第一确定模块23还具体用于:标记所述虚拟碰撞点与所述机器人的中心的连线方向为障碍方向,In some embodiments, the first determining module 23 is further specifically configured to mark the direction of the connection line between the virtual collision point and the center of the robot as an obstacle direction,
若所述障碍方向与所述前进方向的夹角大于第二预设角度,且所述障碍方向位于所述前进方向的左侧,则所述虚拟障碍物至少部分落入所述左侧碰撞区;If the angle between the obstacle direction and the forward direction is greater than a second preset angle, and the obstacle direction is located on the left side of the forward direction, the virtual obstacle at least partially falls into the left side collision zone ;
若所述障碍方向与所述前进方向的夹角大于第二预设角度,且所述障碍方向位于所述前进方向的右侧,则所述虚拟障碍物至少部分落入所述右侧碰撞区;If the angle between the obstacle direction and the forward direction is greater than a second preset angle, and the obstacle direction is located on the right side of the forward direction, the virtual obstacle at least partially falls into the right side collision zone ;
若所述障碍方向与所述前进方向的夹角小于或等于第二预设角度,且所述障碍方向位于所述前进方向的左侧或右侧或同侧,则所述虚拟障碍物至少部分落入所述前侧碰撞区,If the angle between the obstacle direction and the forward direction is less than or equal to a second preset angle, and the obstacle direction is located on the left or right side or the same side of the forward direction, the virtual obstacle is at least partially Fall into the front side collision zone,
其中所述第二预设角度小于所述第一预设角度。The second predetermined angle is smaller than the first predetermined angle.
在一些实施例中,第一判断模块24具体用于若所述虚拟障碍物未落入所述右侧碰撞区,则控制所述机器人旋转,直至所述虚拟障碍物至少部分落入所述右侧碰撞区。In some embodiments, the first judging module 24 is specifically configured to control the robot to rotate if the virtual obstacle does not fall into the right side collision zone until the virtual obstacle at least partially falls into the right side. Side impact zone.
在一些实施例中,所述虚拟障碍物包括第一虚拟障碍物和第二虚拟障碍物,当所述机器人沿着所述第一虚拟障碍物行走时,请继续参阅图11,该机器人避障装置200还包括第二判断模块26,用于判断所述第二虚拟障碍物是否至少部分落入所述左侧碰撞区或所述前侧碰撞区内;第二控制模块27,用于控制所述机器人旋转,直至所述第二虚拟障碍物至少部分落入所述右侧碰撞区内,再根据所述机器人的位置、所述第二虚拟障碍物的位置以及所述第一安全距离,控制所述机器人沿着所述第二虚拟障碍物行走。In some embodiments, the virtual obstacle includes a first virtual obstacle and a second virtual obstacle. When the robot walks along the first virtual obstacle, please continue to refer to FIG. 11, the robot avoids obstacles The device 200 further includes a second judging module 26 for judging whether the second virtual obstacle at least partially falls into the left side collision zone or the front side collision zone; the second control module 27 is used for controlling the The robot rotates until the second virtual obstacle at least partially falls into the right-side collision zone, and then according to the position of the robot, the position of the second virtual obstacle, and the first safety distance, control The robot walks along the second virtual obstacle.
在一些实施例中,第一控制模块25具体用于生成以所述机器人的位置为原点,以预设方向为方向,延伸至所述虚拟障碍物的位置的虚拟探测信号,所述预设方向与所述机器人的前进方向呈锐角设置;确定所述虚拟探测信号与所述虚拟障碍物的交点为虚拟交点;确定所述机器人距离所述虚拟交点的距离为第一实际距离;根据所述第一实际距离是否满足所述第一安全距离,控制所述机器人沿所述虚拟障碍物行走。In some embodiments, the first control module 25 is specifically configured to generate a virtual detection signal extending to the position of the virtual obstacle with the position of the robot as the origin and a preset direction as the direction. It is set at an acute angle to the forward direction of the robot; the intersection of the virtual detection signal and the virtual obstacle is determined to be a virtual intersection; the distance between the robot and the virtual intersection is the first actual distance; Whether an actual distance meets the first safety distance, control the robot to walk along the virtual obstacle.
在一些实施例中,若所述真实障碍物和所述虚拟障碍物同时存在,请继续参阅图11,该机器人避障装置200还包括第二获取模块28,用于获取所述第一实际距离与所述第一安全距离的第一差值;获取所述机器人距离所述真实障碍物的第二实际距离;获取所述第二实际距离与所述第二安全距离的第二差值;第三控制模块29,用于判断所述第一差值是否小于所述第二差值;若是,根据所述第一实际距离是否满足所述第一安全距离,控制所述机器人沿着所述虚拟障碍物行走;若否,根据所述第二实际距离是否满足所述第二安全距离,控制所述机器人沿着所述真实障碍物行走。In some embodiments, if the real obstacle and the virtual obstacle exist at the same time, please continue to refer to FIG. 11. The robot obstacle avoidance device 200 further includes a second obtaining module 28 for obtaining the first actual distance A first difference between the first safety distance and the first safety distance; acquiring a second actual distance between the robot and the real obstacle; acquiring a second difference between the second actual distance and the second safety distance; The third control module 29 is used to determine whether the first difference is less than the second difference; if so, according to whether the first actual distance meets the first safety distance, control the robot to move along the virtual Obstacle walking; if not, control the robot to walk along the real obstacle according to whether the second actual distance meets the second safety distance.
需要说明的是,上述机器人避障装置可执行本申请实施例所提供的机器人避障方法,具备执行方法相应的功能模块和有益效果。未在机器人避障装置实施例中详尽描述的技术细节,可参见本申请实施例所提供的机器人避障方法。It should be noted that the foregoing robot obstacle avoidance device can execute the robot obstacle avoidance method provided in the embodiments of the present application, and has the corresponding functional modules and beneficial effects of the execution method. For technical details that are not described in detail in the embodiment of the robot obstacle avoidance device, please refer to the robot obstacle avoidance method provided in the embodiment of the present application.
请参阅图12,图12是本申请实施例提供的一种控制器的结构示意图。如图12所示,该控制器300包括一个或多个处理器31以及存储器32。其中,图12中以一个处理器31为例。Please refer to FIG. 12, which is a schematic structural diagram of a controller provided by an embodiment of the present application. As shown in FIG. 12, the controller 300 includes one or more processors 31 and a memory 32. Among them, one processor 31 is taken as an example in FIG. 12.
处理器31和存储器32可以通过总线或者其他方式连接,图12中以通过总线连接为例。The processor 31 and the memory 32 may be connected by a bus or in other ways. In FIG. 12, the connection by a bus is taken as an example.
存储器32作为一种非易失性计算机可读存储介质,可用于存储非易失性软件程序、非易失性计算机可执行程序以及模块,如本申请实施例中的机器人避障方法对应的程序指令/模块。处理器31通过运行存储在存储器32中的非易失性软件程序、指令以及模块,从而执行机器人避障装置的各种功能应用以及数据处理,即实现上述方法实施例提供的机器人避障方法以及上述装置实施 例的各个模块或单元的功能。As a non-volatile computer-readable storage medium, the memory 32 can be used to store non-volatile software programs, non-volatile computer-executable programs, and modules, such as the program corresponding to the robot obstacle avoidance method in the embodiment of the present application Instructions/modules. The processor 31 executes various functional applications and data processing of the robot obstacle avoidance device by running the non-volatile software programs, instructions, and modules stored in the memory 32, that is, realizes the robot obstacle avoidance method provided by the above method embodiment and The function of each module or unit of the above-mentioned device embodiment.
存储器32可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他非易失性固态存储器件。在一些实施例中,存储器32可选包括相对于处理器31远程设置的存储器,这些远程存储器可以通过网络连接至处理器31。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。The memory 32 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, or other non-volatile solid-state storage devices. In some embodiments, the memory 32 may optionally include memories remotely provided with respect to the processor 31, and these remote memories may be connected to the processor 31 through a network. Examples of the aforementioned networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
所述程序指令/模块存储在所述存储器32中,当被所述一个或者多个处理器31执行时,执行上述任意方法实施例中的机器人避障方法。The program instructions/modules are stored in the memory 32, and when executed by the one or more processors 31, the robot obstacle avoidance method in any of the foregoing method embodiments is executed.
本申请实施例还提供了一种非暂态计算机可读存储介质,所述非暂态计算机可读存储介质存储有计算机可执行指令,该计算机可执行指令被一个或多个处理器执行,例如图12中的一个处理器31,可使得上述一个或多个处理器可执行上述任意方法实施例中的机器人避障方法。The embodiment of the present application also provides a non-transitory computer-readable storage medium, the non-transitory computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are executed by one or more processors, for example One processor 31 in FIG. 12 can enable the aforementioned one or more processors to execute the robot obstacle avoidance method in any of the aforementioned method embodiments.
本申请实施例还提供了一种计算机程序产品,所述计算机程序产品包括存储在非暂态计算机可读存储介质上的计算机程序,所述计算机程序包括程序指令,当所述程序指令被电子设备执行时,使所述电子设备执行任一项所述的机器人避障方法。The embodiments of the present application also provide a computer program product. The computer program product includes a computer program stored on a non-transitory computer-readable storage medium. The computer program includes program instructions. During execution, the electronic device is caused to execute any one of the robot obstacle avoidance methods.
综上所述,当虚拟障碍物至少部分落入机器人的有效碰撞区时,该机器人避障装置根据机器人的位置、虚拟障碍物的位置和第一安全距离,控制机器人沿着虚拟障碍物行走。该机器人避障方法对虚拟障碍物的形状和类型不做限制,实现更好的避障效果,进而提升用户体验。In summary, when the virtual obstacle falls into the effective collision zone of the robot at least partially, the robot obstacle avoidance device controls the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance. The robot obstacle avoidance method does not limit the shape and type of virtual obstacles, and achieves a better obstacle avoidance effect, thereby enhancing user experience.
以上所描述的装置或设备实施例仅仅是示意性的,其中所述作为分离部件说明的单元模块可以是或者也可以不是物理上分开的,作为模块单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络模块单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。The device or device embodiments described above are merely illustrative, and the unit modules described as separate components may or may not be physically separated, and the components displayed as modular units may or may not be physical units. , Which can be located in one place, or can be distributed to multiple network module units. Some or all of the modules can be selected according to actual needs to achieve the objectives of the solutions of the embodiments.
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到各实施方式可借助软件加通用硬件平台的方式来实现,当然也可以通过硬件。基于这样的理解,上述技术方案本质上或者说对相关技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品可以存储在计算机可读存储介质中,如ROM/RAM、磁碟、光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行各个实施例或者实施例的某些部分所述的方法。Through the description of the foregoing implementation manners, those skilled in the art can clearly understand that each implementation manner can be implemented by means of software plus a general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution essentially or the part that contributes to the related technology can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM/RAM, magnetic disk , CD-ROM, etc., including several instructions to make a computer device (which may be a personal computer, a server, or a network device, etc.) execute the methods described in each embodiment or some parts of the embodiment.
在本说明书的描述中,参考术语“第一个实施例”、“第二个实施例”、“本申请的实施例”、“一个实施方式”、“一种实施方式”、“一个实施例”、“示例”、 “具体示例”或“一些示例”等的描述意指结合该实施例或示例描述的具体特征、结构、材料或者特点包含于本申请的至少一个实施例或示例中。在本说明书中,对上述术语的示意性表述不一定指的是相同的实施例或示例。而且,描述的具体特征、结构、材料或特点可以在任何的一个或多个实施例或示例中以合适的方式结合。In the description of this specification, reference is made to the terms "first embodiment", "second embodiment", "an embodiment of the present application", "an embodiment", "an embodiment", "an embodiment" The description of "," "example", "specific example" or "some examples" means that the specific feature, structure, material or characteristic described in combination with the embodiment or example is included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above-mentioned terms do not necessarily refer to the same embodiment or example. Moreover, the described specific features, structures, materials or characteristics can be combined in any one or more embodiments or examples in a suitable manner.
以上所述的实施方式,并不构成对该技术方案保护范围的限定。任何在上述实施方式的精神和原则之内所作的修改、等同替换和改进等,均应包含在该技术方案的保护范围之内。The above-mentioned embodiments do not constitute a limitation on the protection scope of the technical solution. Any modification, equivalent replacement and improvement made within the spirit and principle of the above-mentioned embodiments shall be included in the protection scope of the technical solution.

Claims (20)

  1. 一种机器人避障方法,其特征在于,包括:An obstacle avoidance method for a robot, which is characterized in that it includes:
    基于所述机器人所处清洁环境建立坐标系;Establishing a coordinate system based on the clean environment in which the robot is located;
    获取所述机器人在所述坐标系中的位置和前进方向,以及障碍物在所述坐标系中的位置,所述障碍物包括虚拟障碍物;Acquiring the position and forward direction of the robot in the coordinate system, and the position of an obstacle in the coordinate system, the obstacle including a virtual obstacle;
    根据所述机器人的位置、所述前进方向以及第一安全距离,确定有效碰撞区;Determine an effective collision zone according to the position of the robot, the forward direction and the first safety distance;
    判断所述虚拟障碍物是否至少部分落入所述有效碰撞区内;Judging whether the virtual obstacle at least partially falls into the effective collision zone;
    若是,根据所述机器人的位置、所述虚拟障碍物的位置和所述第一安全距离,控制所述机器人沿着所述虚拟障碍物行走。If so, control the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
  2. 根据权利要求1所述的方法,其特征在于,所述根据所述机器人的位置、前进方向以及第一安全距离,确定有效碰撞区,包括:The method according to claim 1, wherein the determining the effective collision zone according to the position, the advancing direction and the first safety distance of the robot comprises:
    确定位于所述机器人周侧的虚拟碰撞区域,所述虚拟碰撞区域的边界与所述机器人的距离等于所述第一安全距离;Determining a virtual collision area located on the periphery of the robot, and the distance between the boundary of the virtual collision area and the robot is equal to the first safety distance;
    所述虚拟碰撞区域靠近所述机器人前进方向的一部分构成所述有效碰撞区,所述有效碰撞区的边界上的任意一点与所述机器人的中心的连线方向均与所述前进方向的夹角小于或等于第一预设角度。A part of the virtual collision area close to the forward direction of the robot constitutes the effective collision zone, and the line connecting any point on the boundary of the effective collision zone and the center of the robot is an angle between the forward direction and the forward direction. Less than or equal to the first preset angle.
  3. 根据权利要求2所述的方法,其特征在于,所述有效碰撞区包括左侧碰撞区、前侧碰撞区和右侧碰撞区,所述判断所述虚拟障碍物是否至少部分落入所述有效碰撞区内,包括:The method according to claim 2, wherein the effective collision zone includes a left collision zone, a front side collision zone, and a right collision zone, and the determining whether the virtual obstacle at least partially falls into the effective collision zone The collision zone includes:
    根据所述机器人的位置和所述虚拟障碍物的位置,判断所述虚拟障碍物是否与所述有效碰撞区的边界有交点;Judging whether the virtual obstacle has an intersection with the boundary of the effective collision zone according to the position of the robot and the position of the virtual obstacle;
    若是,则确定所述虚拟障碍物至少部分落入所述有效碰撞区内;If yes, it is determined that the virtual obstacle at least partially falls into the effective collision zone;
    若判断到所述虚拟障碍物至少部分落入所述有效碰撞区内,根据落入所述有效碰撞区内的虚拟障碍物的位置和所述机器人的位置,确定虚拟碰撞点,所述虚拟碰撞点为落入所述有效碰撞区内的虚拟障碍物上的点距离所述机器人的中心最近的点;If it is determined that the virtual obstacle falls at least partially within the effective collision zone, a virtual collision point is determined according to the position of the virtual obstacle falling into the effective collision zone and the position of the robot, and the virtual collision The point is the point on the virtual obstacle that falls into the effective collision zone that is closest to the center of the robot;
    根据所述虚拟碰撞点、所述左侧碰撞区、所述前侧碰撞区和所述右侧碰撞区,确定所述虚拟障碍物至少部分落入所述有效碰撞区的位置。According to the virtual collision point, the left collision zone, the front collision zone, and the right collision zone, determine the position where the virtual obstacle at least partially falls into the effective collision zone.
  4. 根据权利要求3所述的方法,其特征在于,所述根据所述虚拟碰撞点、所述左侧碰撞区、所述前侧碰撞区和所述右侧碰撞区,确定所述虚拟障碍物至少部分落入所述有效碰撞区的位置,包括:The method according to claim 3, wherein the determining that the virtual obstacle is at least The locations that partially fall into the effective collision zone include:
    标记所述虚拟碰撞点与所述机器人的中心的连线方向为障碍方向,Mark the direction of the line connecting the virtual collision point and the center of the robot as the obstacle direction,
    若所述障碍方向与所述前进方向的夹角大于第二预设角度,且所述障碍方向位于所述前进方向的左侧,则所述虚拟障碍物至少部分落入所述左侧碰撞区;If the angle between the obstacle direction and the forward direction is greater than a second preset angle, and the obstacle direction is located on the left side of the forward direction, the virtual obstacle at least partially falls into the left side collision zone ;
    若所述障碍方向与所述前进方向的夹角大于第二预设角度,且所述障碍方向位于所述前进方向的右侧,则所述虚拟障碍物至少部分落入所述右侧碰撞区;If the angle between the obstacle direction and the forward direction is greater than a second preset angle, and the obstacle direction is located on the right side of the forward direction, the virtual obstacle at least partially falls into the right side collision zone ;
    若所述障碍方向与所述前进方向的夹角小于或等于第二预设角度,且所述障碍方向位于所述前进方向的左侧或右侧或同侧,则所述虚拟障碍物至少部分落入所述前侧碰撞区,If the angle between the obstacle direction and the forward direction is less than or equal to a second preset angle, and the obstacle direction is located on the left or right side or the same side of the forward direction, the virtual obstacle is at least partially Fall into the front side collision zone,
    其中所述第二预设角度小于所述第一预设角度。The second predetermined angle is smaller than the first predetermined angle.
  5. 根据权利要求3所述的方法,其特征在于,所述判断所述虚拟障碍物是否至少部分落入所述有效碰撞区内,还包括:The method according to claim 3, wherein the judging whether the virtual obstacle at least partially falls within the effective collision zone further comprises:
    若所述虚拟障碍物未落入所述右侧碰撞区,则控制所述机器人旋转,直至所述虚拟障碍物至少部分落入所述右侧碰撞区。If the virtual obstacle does not fall into the right collision zone, the robot is controlled to rotate until the virtual obstacle at least partially falls into the right collision zone.
  6. 根据权利要求3所述的方法,其特征在于,所述虚拟障碍物包括第一虚拟障碍物和第二虚拟障碍物,当所述机器人沿着所述第一虚拟障碍物行走时,所述方法还包括:The method according to claim 3, wherein the virtual obstacle includes a first virtual obstacle and a second virtual obstacle, and when the robot walks along the first virtual obstacle, the method Also includes:
    判断所述第二虚拟障碍物是否至少部分落入所述左侧碰撞区或所述前侧碰撞区内;Determining whether the second virtual obstacle at least partially falls into the left side collision zone or the front side collision zone;
    若是,控制所述机器人旋转,直至所述第二虚拟障碍物至少部分落入所述右侧碰撞区内,再根据所述机器人的位置、所述第二虚拟障碍物的位置以及所述第一安全距离,控制所述机器人沿着所述第二虚拟障碍物行走。If yes, control the rotation of the robot until the second virtual obstacle falls into the right collision zone at least partially, and then according to the position of the robot, the position of the second virtual obstacle, and the first The safe distance is to control the robot to walk along the second virtual obstacle.
  7. 根据权利要求1所述的方法,其特征在于,所述根据所述机器人的位置、所述虚拟障碍物的位置和所述第一安全距离,控制所述机器人沿着所述虚拟障碍物行走,包括:The method according to claim 1, wherein the controlling the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance, include:
    生成以所述机器人的位置为原点,以预设方向为方向,延伸至所述虚拟障碍物的位置的虚拟探测信号,所述预设方向与所述机器人的前进方向呈锐角设置;Generating a virtual detection signal extending to the position of the virtual obstacle with the position of the robot as the origin and a preset direction as the direction, the preset direction being set at an acute angle with the forward direction of the robot;
    确定所述虚拟探测信号与所述虚拟障碍物的交点为虚拟交点;Determining that the intersection of the virtual detection signal and the virtual obstacle is a virtual intersection;
    确定所述机器人距离所述虚拟交点的距离为第一实际距离;Determining that the distance between the robot and the virtual intersection point is the first actual distance;
    根据所述第一实际距离是否满足所述第一安全距离,控制所述机器人沿所述虚拟障碍物行走。According to whether the first actual distance meets the first safety distance, the robot is controlled to walk along the virtual obstacle.
  8. 根据权利要求7所述的方法,其特征在于,所述障碍物还包括真实障碍物,若所述真实障碍物和所述虚拟障碍物同时存在,所述方法还包括:The method according to claim 7, wherein the obstacle further comprises a real obstacle, and if the real obstacle and the virtual obstacle exist at the same time, the method further comprises:
    获取所述第一实际距离与所述第一安全距离的第一差值;Acquiring a first difference between the first actual distance and the first safety distance;
    获取所述机器人距离所述真实障碍物的第二实际距离;Acquiring a second actual distance of the robot from the real obstacle;
    获取所述第二实际距离与所述第二安全距离的第二差值;Acquiring a second difference between the second actual distance and the second safety distance;
    判断所述第一差值是否小于所述第二差值;Determine whether the first difference is less than the second difference;
    若是,根据所述第一实际距离是否满足所述第一安全距离,控制所述机器人沿着所述虚拟障碍物行走;If yes, control the robot to walk along the virtual obstacle according to whether the first actual distance meets the first safety distance;
    若否,根据所述第二实际距离是否满足所述第二安全距离,控制所述机器人沿着所述真实障碍物行走。If not, control the robot to walk along the real obstacle according to whether the second actual distance meets the second safety distance.
  9. 根据权利要求3所述的方法,其特征在于,所述根据落入所述有效碰撞区内的虚拟障碍物的位置和所述机器人的位置,确定虚拟碰撞点,包括:The method according to claim 3, wherein the determining the virtual collision point according to the position of the virtual obstacle falling into the effective collision zone and the position of the robot comprises:
    若所述虚拟障碍物与所述有效碰撞区边界只存在一个交点,则所述交点为虚拟碰撞点;If there is only one intersection point between the virtual obstacle and the boundary of the effective collision zone, the intersection point is a virtual collision point;
    若所述虚拟障碍物与所述有效碰撞区边界存在两个交点,则取所述两个交点之间的所有虚拟障碍物上的点的坐标,计算所有点与机器人中心点的距离,距离最短的点即为虚拟碰撞点;If there are two intersection points between the virtual obstacle and the boundary of the effective collision zone, take the coordinates of all the points on the virtual obstacle between the two intersection points, and calculate the distance between all the points and the center point of the robot, with the shortest distance The point of is the virtual collision point;
    若所述虚拟障碍物与所述有效碰撞区的边界存在多个交点,则取所述多个交点之间的所有虚拟障碍物上的点的坐标,计算所有点与机器人中心点的距离,距离最短的点即为虚拟碰撞点。If there are multiple intersection points between the virtual obstacle and the boundary of the effective collision zone, take the coordinates of the points on all virtual obstacles between the multiple intersection points, and calculate the distance between all the points and the center point of the robot. The shortest point is the virtual collision point.
  10. 根据权利要求3所述的方法,其特征在于,所述根据所述虚拟碰撞点、所述左侧碰撞区、所述前侧碰撞区和所述右侧碰撞区,确定所述虚拟障碍物至少部分落入所述有效碰撞区的位置,包括:The method according to claim 3, wherein the determining that the virtual obstacle is at least The locations that partially fall into the effective collision zone include:
    将所述虚拟障碍物的坐标与所述左侧碰撞区的坐标、所述前侧碰撞区的坐标以及所述右侧碰撞区的坐标进行坐标比对,判断是否有坐标重合区域,Compare the coordinates of the virtual obstacle with the coordinates of the left collision zone, the coordinates of the front collision zone, and the coordinates of the right collision zone to determine whether there is a coordinate overlap area,
    若所述虚拟障碍物的坐标与所述左侧碰撞区的坐标有重合,则确定所述虚拟障碍物至少部分落入所述左侧碰撞区,If the coordinates of the virtual obstacle overlap with the coordinates of the left side collision zone, it is determined that the virtual obstacle at least partially falls into the left side collision zone,
    若所述虚拟障碍物的坐标还与所述右侧碰撞区的坐标有重合,则确定所述虚拟障碍物至少部分落入所述右侧碰撞区,If the coordinates of the virtual obstacle also overlap with the coordinates of the right collision zone, it is determined that the virtual obstacle at least partially falls into the right collision zone,
    若所述虚拟障碍物的坐标还与所述前侧碰撞区的坐标有重合,则确定所述虚拟障碍物至少部分落入所述前侧碰撞区。If the coordinates of the virtual obstacle also overlap with the coordinates of the front collision zone, it is determined that the virtual obstacle at least partially falls into the front collision zone.
  11. 根据权利要求3所述的方法,其特征在于,所述根据所述虚拟碰撞点、所述左侧碰撞区、所述前侧碰撞区和所述右侧碰撞区,确定所述虚拟障碍物至少部分落入所述有效碰撞区的位置的步骤之后,The method according to claim 3, wherein the determining that the virtual obstacle is at least After the step of partially falling into the position of the effective collision zone,
    若所述左侧碰撞区、所述右侧碰撞区和所述前侧碰撞区均检测到有虚拟障碍物至少部分落入,则根据预设优先级,响应虚拟碰撞。If the left collision zone, the right collision zone and the front collision zone all detect that a virtual obstacle falls at least partially, responding to the virtual collision according to a preset priority.
  12. 根据权利要求11所述的方法,其特征在于,根据预设优先级,所述左侧碰撞区的响应优先级>所述前侧碰撞区的响应优先级>所述右侧碰撞区的响应优先级。The method according to claim 11, wherein, according to a preset priority, the response priority of the left side collision area>the response priority of the front side collision area>the response priority of the right side collision area class.
  13. 根据权利要求11所述的方法,其特征在于,根据预设优先级,先响应所述左侧碰撞区的虚拟碰撞,若所述虚拟障碍物未至少部分落入所述左侧碰撞区,则先响应所述前侧碰撞区的虚拟碰撞,若所述虚拟障碍物未至少部分落入所述左侧碰撞区且未至少部分落入所述前侧碰撞区,则响应所述右侧碰撞区的虚拟碰撞。The method according to claim 11, wherein, according to a preset priority, first respond to a virtual collision in the left collision zone, and if the virtual obstacle does not at least partially fall into the left collision zone, then Respond to the virtual collision of the front side collision zone first, and respond to the right side collision zone if the virtual obstacle does not at least partially fall into the left side collision zone and does not fall at least partially into the front side collision zone Virtual collision.
  14. 一种机器人避障装置,其特征在于,所述机器人避障装置包括建立模块、第一获取模块、第一确定模块、第一判断模块以及第一控制模块,An obstacle avoidance device for a robot, characterized in that the obstacle avoidance device for a robot includes an establishment module, a first acquisition module, a first determination module, a first judgment module, and a first control module,
    所述建立模块用于基于所述机器人所处清洁环境建立坐标系;The establishment module is used to establish a coordinate system based on the clean environment where the robot is located;
    所述第一获取模块用于获取所述机器人在所述坐标系中的位置和前进方向,以及障碍物在所述坐标系中的位置,所述障碍物包括虚拟障碍物;The first acquisition module is configured to acquire the position and the forward direction of the robot in the coordinate system, and the position of an obstacle in the coordinate system, and the obstacle includes a virtual obstacle;
    所述第一确定模块用于根据所述机器人的位置、所述前进方向以及第一安全距离,确定有效碰撞区;The first determination module is configured to determine an effective collision area according to the position of the robot, the forward direction, and the first safety distance;
    所述第一判断模块用于判断所述虚拟障碍物是否至少部分落入所述有效碰撞区内;The first judgment module is used to judge whether the virtual obstacle at least partially falls into the effective collision zone;
    所述第一控制模块用于根据所述机器人的位置、所述虚拟障碍物的位置和所述第一安全距离,控制所述机器人沿着所述虚拟障碍物行走。The first control module is configured to control the robot to walk along the virtual obstacle according to the position of the robot, the position of the virtual obstacle, and the first safety distance.
  15. 根据权利要求14所述的机器人避障装置,其特征在于,The robot obstacle avoidance device according to claim 14, wherein:
    所述第一确定模块具体用于:确定位于所述机器人周侧的虚拟碰撞区域,所述虚拟碰撞区域的边界与所述机器人的距离等于所述第一安全距离;所述虚拟碰撞区域靠近所述机器人前进方向的一部分构成所述有效碰撞区,所述有效碰撞区的边界上的任意一点与所述机器人的中心的连线方向均与所述前进方向的夹角小于或等于第一预设角度。The first determining module is specifically configured to determine a virtual collision area located on the peripheral side of the robot, and the distance between the boundary of the virtual collision area and the robot is equal to the first safety distance; and the virtual collision area is close to the robot. A part of the forward direction of the robot constitutes the effective collision zone, and the angle between any point on the boundary of the effective collision zone and the center of the robot and the forward direction is less than or equal to a first preset angle.
  16. 根据权利要求15所述的机器人避障装置,其特征在于,The obstacle avoidance device for a robot according to claim 15, wherein:
    所述有效碰撞区包括左侧碰撞区、前侧碰撞区和右侧碰撞区,所述第一确定模块还用于:根据所述机器人的位置和所述虚拟障碍物的位置,判断所述虚拟障碍物是否与所述有效碰撞区的边界有交点;若是,则确定所述虚拟障碍物至少部分落入所述有效碰撞区内;若判断到所述虚拟障碍物至少部分落入所述有效碰撞区内,根据落入所述有效碰撞区内的虚拟障碍物的位置和所述机器人的位置,确定虚拟碰撞点,所述虚拟碰撞点为落入所述有效碰撞区内的虚拟障碍物上的点距离所述机器人的中心最近的点;根据所述虚拟碰撞点、所述左侧碰撞区、所述前侧碰撞区和所述右侧碰撞区,确定所述虚拟障碍物至少部分落 入所述有效碰撞区的位置。The effective collision zone includes a left collision zone, a front collision zone, and a right collision zone. The first determining module is further configured to: determine the virtual obstacle according to the position of the robot and the position of the virtual obstacle. Whether the obstacle has an intersection with the boundary of the effective collision zone; if so, it is determined that the virtual obstacle at least partially falls into the effective collision zone; if it is determined that the virtual obstacle falls at least partially into the effective collision zone According to the position of the virtual obstacle within the effective collision area and the position of the robot, a virtual collision point is determined, and the virtual collision point is a point on the virtual obstacle that falls into the effective collision area. Point to the point closest to the center of the robot; according to the virtual collision point, the left collision zone, the front side collision zone, and the right collision zone, it is determined that the virtual obstacle falls at least partially State the location of the effective collision zone.
  17. 根据权利要求16所述的机器人避障装置,其特征在于,The robot obstacle avoidance device according to claim 16, wherein:
    所述第一确定模块还用于:标记所述虚拟碰撞点与所述机器人的中心的连线方向为障碍方向,The first determining module is further configured to mark the direction of the connection line between the virtual collision point and the center of the robot as an obstacle direction,
    若所述障碍方向与所述前进方向的夹角大于第二预设角度,且所述障碍方向位于所述前进方向的左侧,则所述虚拟障碍物至少部分落入所述左侧碰撞区;If the angle between the obstacle direction and the forward direction is greater than a second preset angle, and the obstacle direction is located on the left side of the forward direction, the virtual obstacle at least partially falls into the left side collision zone ;
    若所述障碍方向与所述前进方向的夹角大于第二预设角度,且所述障碍方向位于所述前进方向的右侧,则所述虚拟障碍物至少部分落入所述右侧碰撞区;If the angle between the obstacle direction and the forward direction is greater than a second preset angle, and the obstacle direction is located on the right side of the forward direction, the virtual obstacle at least partially falls into the right side collision zone ;
    若所述障碍方向与所述前进方向的夹角小于或等于第二预设角度,且所述障碍方向位于所述前进方向的左侧或右侧或同侧,则所述虚拟障碍物至少部分落入所述前侧碰撞区,If the angle between the obstacle direction and the forward direction is less than or equal to a second preset angle, and the obstacle direction is located on the left or right side or the same side of the forward direction, the virtual obstacle is at least partially Fall into the front side collision zone,
    其中所述第二预设角度小于所述第一预设角度。The second predetermined angle is smaller than the first predetermined angle.
  18. 根据权利要求16所述的机器人避障装置,其特征在于,The robot obstacle avoidance device according to claim 16, wherein:
    所述第一控制模块用于生成以所述机器人的位置为原点,以预设方向为方向,延伸至所述虚拟障碍物的位置的虚拟探测信号,所述预设方向与所述机器人的前进方向呈锐角设置;确定所述虚拟探测信号与所述虚拟障碍物的交点为虚拟交点;确定所述机器人距离所述虚拟交点的距离为第一实际距离;根据所述第一实际距离是否满足所述第一安全距离,控制所述机器人沿所述虚拟障碍物行走。The first control module is configured to generate a virtual detection signal extending to the position of the virtual obstacle with the position of the robot as the origin and a preset direction as the direction, and the preset direction is the same as the advancement of the robot. The direction is set at an acute angle; the intersection of the virtual detection signal and the virtual obstacle is determined to be the virtual intersection; the distance between the robot and the virtual intersection is the first actual distance; according to whether the first actual distance meets the requirements The first safety distance controls the robot to walk along the virtual obstacle.
  19. 一种机器人,其特征在于,所述机器人包括:A robot, characterized in that, the robot includes:
    主体;main body;
    驱动轮部件,安装于所述主体,用于驱动所述机器人移动;The drive wheel component is installed on the main body and is used to drive the robot to move;
    至少一个处理器;和At least one processor; and
    与所述至少一个处理器通信连接的存储器;其中,A memory communicatively connected with the at least one processor; wherein,
    所述存储器存储有可被所述至少一个处理器执行的指令,所述指令被所述至少一个处理器执行,以使所述至少一个处理器能够执行如权利要求1-13任一项所述的机器人避障方法。The memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor, so that the at least one processor can execute any one of claims 1-13. Robot obstacle avoidance method.
  20. 一种非暂态计算机可读存储介质,其特征在于,所述非暂态计算机可读存储介质存储有计算机可执行指令,所述计算机可执行指令用于使机器人执行如权利要求1-13任一项所述的机器人避障方法。A non-transitory computer-readable storage medium, wherein the non-transitory computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to make a robot execute any of claims 1-13. The obstacle avoidance method of a robot described in one item.
PCT/CN2020/142473 2020-05-29 2020-12-31 Obstacle avoidance method for robot, obstacle avoidance device for robot, robot, and storage medium WO2021238222A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010478923.3A CN111857126A (en) 2020-05-29 2020-05-29 Robot obstacle avoidance method, robot and storage medium
CN202010478923.3 2020-05-29

Publications (1)

Publication Number Publication Date
WO2021238222A1 true WO2021238222A1 (en) 2021-12-02

Family

ID=72985691

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/142473 WO2021238222A1 (en) 2020-05-29 2020-12-31 Obstacle avoidance method for robot, obstacle avoidance device for robot, robot, and storage medium

Country Status (2)

Country Link
CN (1) CN111857126A (en)
WO (1) WO2021238222A1 (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114564022A (en) * 2022-03-04 2022-05-31 北京盈迪曼德科技有限公司 Robot collision processing method and device
CN114983293A (en) * 2022-06-30 2022-09-02 深圳银星智能集团股份有限公司 Self-moving robot
CN115268470A (en) * 2022-09-27 2022-11-01 深圳市云鼠科技开发有限公司 Obstacle position marking method, device and medium for cleaning robot
CN115443795A (en) * 2022-09-29 2022-12-09 宁波东贝智能科技有限公司 Mower collision detection method and system, storage medium and intelligent terminal
CN117294025A (en) * 2023-11-27 2023-12-26 泰安众诚自动化设备股份有限公司 Mining high-voltage switch protection control method, system, controller and storage medium

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111857126A (en) * 2020-05-29 2020-10-30 深圳市银星智能科技股份有限公司 Robot obstacle avoidance method, robot and storage medium
CN112698654B (en) * 2020-12-25 2024-07-12 珠海一微半导体股份有限公司 Single-point TOF-based map building and positioning method, chip and mobile robot
CN113064437A (en) * 2021-03-31 2021-07-02 成都莱洁科技有限公司 Automatic collision avoidance system and method for robot
CN117336354A (en) * 2022-06-27 2024-01-02 华为技术有限公司 Anti-collision method of Virtual Reality (VR) equipment and electronic equipment

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105717929A (en) * 2016-04-29 2016-06-29 中国人民解放军国防科学技术大学 Planning method for mixed path of mobile robot under multi-resolution barrier environment
CN107807641A (en) * 2017-10-25 2018-03-16 上海思岚科技有限公司 method for mobile robot obstacle avoidance
US10180683B1 (en) * 2015-10-29 2019-01-15 Fellow Robotics Ltd. Robotic platform configured to identify obstacles and follow a user device
CN110353573A (en) * 2019-06-05 2019-10-22 深圳市杉川机器人有限公司 The method of getting rid of poverty of sweeping robot, calculates equipment and storage medium at sweeping robot
EP3627250A1 (en) * 2018-09-21 2020-03-25 Tata Consultancy Services Limited Method and system for free space detection in a cluttered environment
CN111857126A (en) * 2020-05-29 2020-10-30 深圳市银星智能科技股份有限公司 Robot obstacle avoidance method, robot and storage medium

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP4658155B2 (en) * 2008-03-17 2011-03-23 株式会社日立製作所 Autonomous mobile robot apparatus and avoidance method of autonomous mobile robot apparatus
CN107688342B (en) * 2017-03-27 2019-05-10 平安科技(深圳)有限公司 The obstruction-avoiding control system and method for robot
CN108908331B (en) * 2018-07-13 2022-04-22 哈尔滨工业大学(深圳) Obstacle avoidance method and system for super-redundant flexible robot and computer storage medium

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10180683B1 (en) * 2015-10-29 2019-01-15 Fellow Robotics Ltd. Robotic platform configured to identify obstacles and follow a user device
CN105717929A (en) * 2016-04-29 2016-06-29 中国人民解放军国防科学技术大学 Planning method for mixed path of mobile robot under multi-resolution barrier environment
CN107807641A (en) * 2017-10-25 2018-03-16 上海思岚科技有限公司 method for mobile robot obstacle avoidance
EP3627250A1 (en) * 2018-09-21 2020-03-25 Tata Consultancy Services Limited Method and system for free space detection in a cluttered environment
CN110353573A (en) * 2019-06-05 2019-10-22 深圳市杉川机器人有限公司 The method of getting rid of poverty of sweeping robot, calculates equipment and storage medium at sweeping robot
CN111857126A (en) * 2020-05-29 2020-10-30 深圳市银星智能科技股份有限公司 Robot obstacle avoidance method, robot and storage medium

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114564022A (en) * 2022-03-04 2022-05-31 北京盈迪曼德科技有限公司 Robot collision processing method and device
CN114983293A (en) * 2022-06-30 2022-09-02 深圳银星智能集团股份有限公司 Self-moving robot
CN115268470A (en) * 2022-09-27 2022-11-01 深圳市云鼠科技开发有限公司 Obstacle position marking method, device and medium for cleaning robot
CN115268470B (en) * 2022-09-27 2023-08-18 深圳市云鼠科技开发有限公司 Obstacle position marking method, device and medium for cleaning robot
CN115443795A (en) * 2022-09-29 2022-12-09 宁波东贝智能科技有限公司 Mower collision detection method and system, storage medium and intelligent terminal
CN115443795B (en) * 2022-09-29 2024-01-30 宁波东贝智能科技有限公司 Mower collision detection method, mower collision detection system, storage medium and intelligent terminal
CN117294025A (en) * 2023-11-27 2023-12-26 泰安众诚自动化设备股份有限公司 Mining high-voltage switch protection control method, system, controller and storage medium
CN117294025B (en) * 2023-11-27 2024-02-27 泰安众诚自动化设备股份有限公司 Mining high-voltage switch protection control method, system, controller and storage medium

Also Published As

Publication number Publication date
CN111857126A (en) 2020-10-30

Similar Documents

Publication Publication Date Title
WO2021238222A1 (en) Obstacle avoidance method for robot, obstacle avoidance device for robot, robot, and storage medium
JP7061337B2 (en) Robots for maneuvering along the route, systems for dynamic navigation and dynamic route planning of robots in the environment, methods for dynamic navigation and dynamic route planning of robots, and their non-temporary Computer media and their programs
KR102492242B1 (en) Terrain Aware Step Planning System
WO2021232669A1 (en) Robot motion planning method, path planning method, grabbing method and devices thereof
JP6716178B2 (en) Robot obstacle avoidance control system, method, robot and program
CN109984689B (en) Cleaning robot and path optimization method thereof
EP3552072B1 (en) Robotic cleaning device with operating speed variation based on environment
JP2020512644A (en) System and method for robot path planning
US9969086B1 (en) Achieving a target gait in a legged robot based on steering commands
CN108733065B (en) Obstacle avoidance method and device for robot and robot
WO2015090398A1 (en) Robotic vacuum cleaner with side brush moving in spiral pattern
JP6937260B2 (en) Grip control device, grip system, and program
CN107608363A (en) Avoidance processing method, device and the robot of robot
US11712802B2 (en) Construction constrained motion primitives from robot maps
EP4203760B1 (en) Cleaning control method and device, cleaning robot and storage medium
WO2023125698A1 (en) Cleaning device, and control method and control apparatus therefor
WO2022140173A1 (en) Door opening behavior and robot presenting the behaviour
WO2024067852A1 (en) Ground medium detection method and apparatus and cleaning device
US20210401250A1 (en) Cleaning device and method for controlling same
WO2024113261A1 (en) Robot and obstacle avoidance method therefor, and robot system and storage medium
TWI846276B (en) Path planning method and autonomous travelling robot
US11927961B2 (en) Constrained robot autonomy language
CN115145276A (en) Robot edgewise movement method and equipment, robot and storage medium
JP2012256209A (en) Mobile robot

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20937628

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20937628

Country of ref document: EP

Kind code of ref document: A1