Robot automatic pile returning method, device and equipment and medium
By designing the status transfer process and infrared signal monitoring mechanism in the robot's automatic pile return system, the offset problem during pile return is solved and the success rate of pile return is improved.
Patent Information
- Application Number
- CN202411501217.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-25
- Publication Date
- 2025-03-14
AI Technical Summary
Existing robots have offset problems when charging automatically when charging piles, especially in scenarios such as lifting, which leads to a decrease in the success rate of piles.
When the robot receives the automatic pile return instruction, it executes the home state transfer process corresponding to the home behavior and continuously monitors the infrared signal. If the infrared signal with a preset number of frames is monitored or the moving state transfer process returns successfully after the execution is completed, it enters the infrared pile state, and executes the pile state transfer process corresponding to the infrared pile behavior until the charging current is successful or the charging current is detected.
Through the design of the state transfer process and the monitoring of infrared signals, the offset generated by sensor data during pile return can be neutralized, thereby improving the success rate of pile return.
Smart Images

Figure CN119620745A_ABST
Abstract
Description
Technical Field
[0001] The present application is applicable to the field of robotics technology, and in particular relates to a method, device, equipment and medium for automatic return of a robot to a pile. Background Art
[0002] With the development of the robot industry, especially the widespread application of sweeping robots, industrial robots, etc., since robots mostly use electricity, the self-charging control of the robot needs to keep up with the pace of robot automation, without the need for human participation in the charging of the robot.
[0003] At present, robots mostly use complex sensor structures to perform the function of automatic charging. If the pure inertial navigation system is based only on the inertial measurement unit (IMU) data, there will definitely be an offset problem (caused by device characteristics). This problem is particularly obvious in scenarios where the z-axis changes drastically due to the robot tilting, so most products on the market use multi-sensor fusion to interact and eliminate errors. In order to save resources and reduce costs, many robots currently only have IMU and infrared data to assist in charging, and there will be a tilting problem in the structure. According to the previous article, the pure IMU inertial navigation system itself will have a long-term operation offset problem, and frequent tilting will further aggravate the offset. In addition, the selected infrared transmitting pile has a low frequency, transmitting once every 400ms, resulting in a short delay.
[0004] Therefore, how to optimize the product status without significantly modifying the structure and reduce the offset when returning to the pile becomes an urgent problem to be solved. Summary of the invention
[0005] In view of this, the embodiments of the present application provide a method, device, equipment and medium for automatic return of a robot to a pile, so as to solve the problem of how to optimize the product status and reduce the deviation when returning to a pile without significantly modifying the structure.
[0006] In a first aspect, an embodiment of the present application provides a method for automatically returning a robot to a pile, the method comprising: When the robot receives the automatic return command, it executes the return state transition process corresponding to the return behavior; If the home state transition process enters the moving to target point state, the moving state transition process corresponding to the moving to target point behavior is executed, and the infrared signal is continuously monitored; If a preset number of infrared signals are detected or the mobile state transfer process returns successfully after execution, the infrared pairing state in the home state transfer process is entered; The pile state transfer process corresponding to the infrared pile-pile behavior is executed until the pile state transfer process is successfully executed or a charging current is detected during the execution of the pile state transfer process, and it is determined that the robot automatically returns to the pile successfully.
[0007] In a second aspect, an embodiment of the present application provides a robot automatic return to pile device, the robot automatic return to pile device comprising: The return behavior module is used to execute the return state transition process corresponding to the return behavior when the robot receives the automatic return command; A move to target point behavior module, for executing a moving state transition process corresponding to the move to target point behavior and continuously monitoring infrared signals if the home state transition process enters the move to target point state; An infrared pairing state module is used to enter the infrared pairing state in the home state transition process if a preset number of infrared signals are detected or the mobile state transition process returns successfully after execution; The infrared pile-to-pile behavior module is used to execute the pile-to-pile state transfer process corresponding to the infrared pile-to-pile behavior until the pile-to-pile state transfer process is successfully executed or a charging current is detected during the execution of the pile-to-pile state transfer process, and it is determined that the robot automatically returns to the pile successfully.
[0008] In a third aspect, an embodiment of the present application provides a computer device, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the robot automatic return method as described in the first aspect is implemented.
[0009] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the robot automatic return method as described in the first aspect is implemented.
[0010] Compared with the prior art, the embodiments of the present application have the following beneficial effects: when the robot receives an automatic return-to-pile instruction, the present application executes the home state transfer process corresponding to the home behavior, and if the home state transfer process enters the move-to-target point state, the mobile state transfer process corresponding to the move-to-target point behavior is executed, and the infrared signal is continuously monitored, and if a preset number of infrared signals are monitored or the mobile state transfer process returns successfully after execution, the infrared pile state in the home state transfer process is entered, and the pile state transfer process corresponding to the infrared pile behavior is executed until the pile state transfer process is successfully executed or a charging current is detected during the execution of the pile state transfer process, and it is determined that the robot automatically returns to the pile successfully. The state transfer process based on different behaviors is used to realize the movement control of the robot when it returns to the pile for charging, and the offset generated by relying on the existing sensor data when returning to the pile can be neutralized based on the state transfer, thereby improving the success rate of returning to the pile. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0012] Figure 1 It is a flowchart of a method for automatically returning a robot to a pile provided in Example 1 of the present application; Figure 2 This is a schematic diagram of a process of a robot automatically returning to a pile provided in Embodiment 2 of the present application; Figure 3 It is a flowchart of a method for automatically returning a robot to a pile provided in Embodiment 3 of the present application; Figure 4 This is a flow chart of a method for automatically returning a robot to a pile provided in Embodiment 4 of the present application; Figure 5 This is a schematic diagram of a process of a robot automatic return method provided in Embodiment 5 of the present application; Figure 6 This is a flow chart of a method for automatically returning a robot to a pile provided in Example 6 of the present application; Figure 7 This is a flow chart of a method for automatically returning a robot to a pile provided in Embodiment 7 of the present application; Figure 8 This is a schematic diagram of the structure of a robot automatic pile return device provided in Example 8 of the present application; Fig. 9 It is a structural diagram of a computer device provided in Example 9 of the present application. DETAILED DESCRIPTION
[0013] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.
[0014] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.
[0015] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0016] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.
[0017] In addition, in the description of the present application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.
[0018] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0019] The embodiments of the present application can acquire and process relevant data based on artificial intelligence technology. Among them, artificial intelligence is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results.
[0020] AI basic technologies generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, mechatronics, etc. AI software technologies mainly include computer vision technology, robotics technology, biometrics technology, speech processing technology, natural language processing technology, and machine learning / deep learning.
[0021] It should be understood that the size of the serial numbers of the steps in the following embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0022] In order to illustrate the technical solution of the present application, a specific embodiment is provided below for illustration.
[0023] A robot automatic return to pile method provided in the first embodiment of the present application can be applied to robot scenarios, such as sweeping robots, industrial robots, etc. Of course, in scenarios with a higher degree of automation, the robot automatic return to pile method can also be executed when charging vehicles, robot toys, etc.
[0024] See also Figure 1 , is a flow chart of a method for automatically returning a robot to a pile provided in Embodiment 1 of the present application. The method for automatically returning a robot to a pile may include the following steps: Step S101, when the robot receives the automatic return command, it executes the return state transfer process corresponding to the return behavior.
[0025] In this embodiment, the robot's automatic return to the pile method adopts a state transfer method to control the robot's motion, which can specifically include the following three behaviors: returning home behavior, moving to the target point behavior, and infrared matching behavior. Among them, the moving to the target point behavior and the infrared matching behavior can be sub-behaviors of the returning home behavior, that is, entering the corresponding state in the returning home behavior triggers the moving to the target point behavior and the infrared matching behavior.
[0026] For example, when the user sends a command for the robot to automatically return to the pole, the robot will trigger the return-home behavior accordingly. When the return-home behavior enters the move-to-target point state, the move-to-target point behavior is called; when the return-home behavior enters the infrared pole-to-pole state, the infrared pole-to-pole behavior is called.
[0027] The automatic return to charging pile control command can be issued by the user or generated after the robot reaches a preset condition (for example, low battery). The automatic return to charging pile control command is just a subsequent operation performed by the robot to enable the robot to return to the charging pile for charging.
[0028] The return home behavior can include the following 10 states: return home initialization state, return home start state, return home initial inspection state, return home rotation to find the pole state, return home after finding the pole state, move to the target point state, infrared pole state, return home success state, return home failure state and failure retry state.
[0029] Of course, in some specific implementations, one or more of these states may be included in one item. The names of the above states can be customized, and the function implemented by each state is the direct reflection of the state. In addition, the home-returning initialization state, the home-returning start state, the home-returning rotation to find the pile state, the home-returning posture reset state after finding the pile, the home-returning success state, the home-returning failure state, and the failure retry state can all be used as further functions to achieve a more accurate return to the pile result.
[0030] The behavior of moving to the target point can include the following 7 states: moving initialization state, path finding state, waiting for path update state, moving state, calibration state, completion state and error state. Among them, not all states need to be involved in a return to pile control process at the same time. In a return to pile control, the robot can be moved to the target point by only using the moving initialization state or the path finding state, waiting for path update state and moving state.
[0031] The infrared pile-to-pile behavior includes the following 9 states: infrared initialization state, infrared start state, infrared initial inspection state, infrared rotation pile-finding state, infrared posture reset state after finding the pile, pile-returning state, tilting-off state, infrared failure state and infrared success state. Among them, not all states need to be involved in a pile-returning control process at the same time. In a pile-returning control, the result of pile-finding success or failure can be obtained through the infrared initial inspection state. Of course, the pile-finding process can also be adjusted through the infrared rotation pile-finding state, the infrared posture reset state after finding the pile, and the pile-returning state, so as to improve the pile-finding success rate. In addition, the tilting-off state can also be used to solve the problem of the robot tilting the pile, which is also a means to improve the pile-finding success rate.
[0032] Step S102, if the home state transition process enters the moving to target point state, the moving state transition process corresponding to the moving to target point behavior is executed, and the infrared signal is continuously monitored.
[0033] In this embodiment, when the return home state transition process enters the move to target point state, the move to target point behavior is called. The move to target point behavior includes the move state transfer process. Similar to the return home behavior, the move state transfer process includes states and can perform procedural switching, jumping or calling in various states.
[0034] In addition, when executing the move to the target point behavior, the return home behavior will continue to monitor the infrared signal. If an infrared signal is detected, it means that the robot is close to the charging pile. Otherwise, it means that the robot cannot directly perform infrared charging.
[0035] Step S103, if a preset number of infrared signals are detected or the mobile state transfer process returns successfully after execution, then the infrared pairing state in the home state transfer process is entered.
[0036] In this embodiment, two situations are provided to express that the robot moves to the vicinity of the charging pile, so that the robot can enter the infrared charging pile state, wherein the infrared signal of the preset frame number is for continuously monitoring the infrared signal during the returning home behavior, and the monitoring of the infrared signal indicates that the infrared charging pile state can be executed. In addition, the purpose of moving to the target point behavior is to find the infrared signal, that is, to move the robot to the vicinity of the charging pile. Similarly, the successful return after the completion of the mobile state transfer process also indicates that the robot has moved to the vicinity of the charging pile and can enter the infrared charging pile state.
[0037] Step S104, executing the pile state transfer process corresponding to the infrared pile behavior, until the pile state transfer process is successfully executed or a charging current is detected during the execution of the pile state transfer process, and it is determined that the robot automatically returns to the pile successfully.
[0038] In this embodiment, infrared pairing behavior is performed in the infrared pairing state, and the infrared pairing behavior corresponds to a pairing state transfer process, which guides the robot to pair with the charging pile through infrared signals to achieve charging. Among them, the successful execution of the pairing state transfer process indicates that the robot and the charging pile are successfully paired. Of course, during the execution of the pairing state transfer process, if a charging current is detected, it can also indicate that the robot and the charging pile are successfully paired.
[0039] In the embodiment of the present application, when the robot receives the automatic return to the pile instruction, it executes the home state transfer process corresponding to the home behavior. If the home state transfer process enters the move to target point state, it executes the mobile state transfer process corresponding to the move to target point behavior, and continuously monitors the infrared signal. If a preset number of infrared signals are monitored or the mobile state transfer process returns successfully after execution, it enters the infrared pile state in the home state transfer process, and executes the pile state transfer process corresponding to the infrared pile behavior until the pile state transfer process is successfully executed or the charging current is detected during the execution of the pile state transfer process, and it is determined that the robot automatically returns to the pile successfully. The state transfer process based on different behaviors is used to realize the movement control of the robot when it returns to the pile for charging. The offset generated by relying on the existing sensor data when returning to the pile can be neutralized based on the state transfer, thereby improving the success rate of returning to the pile.
[0040] See also Figure 2 , which is a flow chart of a robot automatic return method provided in the second embodiment of the present application. The return state transition process also includes the return initial inspection state. After executing the return state transition process corresponding to the return behavior, the following steps may also be included: Step S201, if the return home state transfer process is executed to the return home initial inspection state, it is detected whether the robot receives the infrared signal and whether the distance between the robot and the charging pile is less than a preset value.
[0041] Step S202: If it is detected that the robot receives an infrared signal and the distance between the robot and the charging pile is less than a preset value, the process switches to the infrared charging pile state.
[0042] In this embodiment, the return home state transfer process also includes a return home initial inspection state. This state enables the robot to respond to infrared signals and, when the distance between the robot and the charging pile obtained based on the infrared signals is small, it can be considered that the robot and the charging pile are close and directly enter the infrared charging pile state, eliminating the intermediate state process and improving execution efficiency.
[0043] See also Figure 3 , is a flow chart of a robot automatic return method provided in Example 3 of the present application. Figure 3 As shown, the home state transition process also includes the home rotation and pile-finding state, the home posture reset state after finding the pile, the failure retry state and the home failure state. After executing the movement state transition process corresponding to the movement to the target point behavior and continuously monitoring the infrared signal, the following steps may also be included: Step S301, if the infrared signal of the preset number of frames is not detected and the mobile state transfer process returns failure after completion, the robot enters the home-turning and searching-for-pile state. In the home-turning and searching-for-pile state, the robot tries to find the infrared signal by rotating itself and continuously updates the first accumulated rotation angle.
[0044] Step S302, if the first accumulated rotation angle finds an infrared signal within the first preset number of circles, then enter the attitude reset state after returning home to find the pile. In the attitude reset state after returning home to find the pile, the robot rotates in the direction opposite to the direction of rotation in the state of returning home to find the pile for a second preset delay, and then returns to the initial inspection state of returning home.
[0045] Step S303, if the first cumulative rotation angle does not find the infrared signal after the first preset number of circles, the first cumulative rotation angle is cleared to zero and the system enters the failed retry state. In the failed enrichment state, if it is detected that the number of failed retries is less than the retry threshold, the system returns to the home initial check state and adds 1 to the number of failed retries. If it is detected that the number of failed retries is not less than the retry threshold, the system enters the home failure state.
[0046] Among them, the home state transition process also includes the home initialization state, the home start state and the home success state. The home state transition process in the above home behavior is as follows: 1) Return home initialization state: Initialize the cumulative rotation angle and number of failed retries that will be used in the behavior later, and then jump unconditionally to the return home start state.
[0047] 2) Return to start state: Unconditionally jump to the initial check state the next time the loop is entered.
[0048] 3) Initial check state after returning home: Set the number of infrared hits to the initial value 0, and then jump to the moving to target point state or infrared facing state according to whether the current robot has received infrared signals and the distance from the charging pile. When the robot has received infrared signals and the distance from the charging pile is less than 0.6m, it jumps to the infrared facing state, otherwise it jumps to the moving to target point state.
[0049] In the above two jumps in the initial inspection state of returning home, when an infrared signal is received and the distance from the charging pile is less than 0.6m, the corresponding robot is within the infrared stability range of the charging pile (for example, within a certain angle range in front of the charging pile). At this time, the robot can continuously and stably obtain infrared signals, and thus directly return to the pile through infrared. In other cases, the robot is too far away from the pile or is in the blind spot of the infrared signal. It is necessary to return to the front of the charging pile through the map established in the robot, and then process it according to the situation where an infrared signal is received and the distance from the charging pile is less than 0.6m. For example, the charging pile is in room A, and the robot walks to room B. Of course, it is not limited to this situation. In room A, if the jump conditions of situation 1 are not met due to occlusion or other reasons, this branch will also be entered.
[0050] The map established in the robot is established only through the data obtained by the IMU and the odometer data (i.e. pure inertial navigation). The map is stored in a grid map. A completely blank map is initially generated according to the set map size and single grid size, and the charging pile is marked at the center of the map. The initial states of other grids are marked as unknown. Based on the movement distance fed back by the odometer and the angle data fed back by the IMU when the robot moves, the grids on the map where the corresponding points are located are marked as reachable. During the movement of the robot, the marking is continuously updated. This process is an integral process. The position of the robot is described by (x, y), where x represents the horizontal distance from the charging pile and y represents the longitudinal distance from the charging pile. From time t to time t+1, the robot is deflected by yaw degrees through the IMU data, and the robot moves a distance of d through the odometer. Then the movement distance of the robot on the x-axis and y-axis can be decomposed using trigonometric functions: x_d = d×cosyaw, y_d = d×sinyaw, and the robot coordinates will be updated to (x+x_d, y+y_d), and the grid corresponding to this coordinate on the map is marked as reachable.
[0051] In order to solve the problem mentioned in the background of the invention that a pure inertial navigation system based only on IMU data must have an offset problem (caused by device characteristics), the following logic is added to the map processing part in addition to the above basic logic: (a) After each successful return to the charging station, the map and robot position and posture are reset, and the accumulated errors of historical data are cleared; (b) When a short-term severe shake is detected (the angle jump exceeds the threshold within one frame or one cycle), the robot state is reverted to the previous state; (c) Place of grant Figure 1 In addition to the map grid marking mentioned above, the radius around the grid where the robot is located is r (for example, set to 1, i.e. adjacent grids), which are also marked as reachable. Here, adjustments can be made based on the selected IMU accuracy and the map grid accuracy to select a radius r that meets the usage scenario. Based on the calculation of a grid length and width of 0.1m mentioned above, an offset tolerance of 0.2m is added, and the drastic jump backoff of (b) can meet the IMU offset error solution in most scenarios.
[0052] 4) Move to target point state: The Move to target point behavior will be called. During the execution of the Move to target point sub-behavior, the Go Home behavior will continue to detect infrared signals. If infrared signals are detected for 5 consecutive frames, the execution of the Move to target point behavior will be terminated directly and jump to the Infrared Pile state. If the above logic is not triggered, the Move to target point behavior will return success / failure to the Go Home behavior after the complete execution. If it returns success, it will jump to the Infrared Pile state, otherwise it will jump to the Rotate to find the pile state.
[0053] 5) Infrared pairing state: The infrared pairing behavior will be called. During the execution of the infrared pairing behavior, the return home behavior will remain silent and wait for the infrared pairing behavior feedback. If the return is successful, it will jump to the return home success state, otherwise it will jump to the failure retry state.
[0054] 6) Return home and rotate to find the pole state: The robot will slowly rotate to try to find the infrared signal and continuously update the accumulated rotation angle. If the infrared signal is found, it will jump to the attitude reset state after returning home and finding the pole. If the infrared signal is not found after two rotations, it will jump to the failed retry state and clear the accumulated rotation angle.
[0055] 7) Attitude reset state after returning home and finding a stake: The purpose of this state is to solve the problem that after scanning the infrared signal in the rotating and finding stake state, the robot does not stop rotating immediately, and there must be a certain delay (even if this delay is small). After entering this state, the robot will slowly rotate in the opposite direction of the rotation direction of the rotating and finding stake state for X frames (for example, set it to 0.5 times the speed and reverse for 1s, and X is adjustable) to eliminate the delay effect. After the rotation is completed, it will unconditionally jump to the return home start state.
[0056] 8) Both the return success status and the return failure status are end status, the difference is whether the feedback is the return success or return failure.
[0057] 9) Failed retry state: Different jumps will be made according to the number of failed retries. If the number of failed retries is less than the threshold, it will jump to the home start state and increase the number of failed retries by 1. Otherwise, it will jump to the home failure state.
[0058] See also Figure 4 , is a flow chart of a method for automatically returning a robot to a pile provided in the fourth embodiment of the present application. Figure 4 As shown, the state transfer process of the pile includes the pile starting state, the pile initial inspection state, the pile rotation and pile search state, the pile posture reset state after the pile is found, the pile failure state and the pile success state, and the movement state transfer process includes the path finding state, the waiting path update state, the movement state, the calibration state and the completion state. The execution of the pile state transfer process corresponding to the infrared pile behavior may include the following steps: Step S401, entering the pile-pile starting state, in which it is detected whether there is a charging current. If a charging current is detected, the robot enters the pile-pile success state, which is used to indicate that the robot automatically returns to the pile successfully.
[0059] Step S402, if the charging current cannot be detected, then check whether there is an infrared signal. If no infrared signal is detected, enter the initial pile inspection state. In the initial pile inspection state, check whether the number of lost signals exceeds the loss threshold. If the number of lost signals detected exceeds the loss threshold, enter the pile failure state. The pile failure state is used to indicate entering the failure retry state.
[0060] Step S403, if it is detected that the number of lost signals does not exceed the lost threshold, the robot enters the pile-rotating pile-finding state. In the pile-rotating pile-finding state, the robot tries to find the infrared signal by rotating itself and continuously updates the second accumulated rotation angle.
[0061] Step S404, if the second accumulated rotation angle finds the infrared signal within the second preset number of circles, then enter the posture reset state after the pile is found. In the posture reset state after the pile is found, the robot rotates in the direction opposite to the self-rotation direction of the robot in the pile rotation state for a second preset delay, and then returns to the starting state of the pile.
[0062] Step S405: If the second accumulated rotation angle does not find the infrared signal after the second preset number of turns, the second accumulated rotation angle is cleared to zero and the alignment failure state is entered.
[0063] In this embodiment, a starting state for pile alignment, an initial pile inspection state, a pile rotation state for finding a pile, a posture resetting state after finding a pile, a pile alignment failure state, and a pile alignment success state are set. By transferring between the above states, the posture adjustment of the robot during pile alignment is achieved, which can effectively improve the reliability of pile alignment.
[0064] See also Figure 5 , is a flow chart of a robot automatic return method provided in Embodiment 5 of the present application. Figure 5 As shown, the process of transferring the pile state also includes returning to the pile state, and after detecting whether there is an infrared signal, it can also include the following steps: Step S501, if an infrared signal is detected, the robot enters the return-to-pile state. In the return-to-pile state, the robot is controlled to align with the charging pile, and the robot is controlled to move backward to detect whether there is a charging current and the backward distance.
[0065] Step S502: If the charging current is detected, the charging state is entered into a successful state; if the charging current is still not detected when the backward distance exceeds the distance threshold, the charging state is entered into a failed state.
[0066] In this embodiment, the robot is controlled to align with the charging pile by setting the return-to-pile status, and then the robot is controlled to move backward after alignment to achieve the connection between the robot and the charging pile, wherein the charging interface of the robot defaults to the rear of the robot, and thus the robot moves backward to dock with the charging pile. Of course, when the charging interface defaults to the front of the robot, the robot's movement forward can also be considered as moving backward.
[0067] See also Figure 6 , is a flow chart of a robot automatic return method provided in Example 6 of the present application. Figure 6 As shown, the pile state transfer process also includes a tilting and disengaging state, and the pile state transfer process corresponding to the infrared pile action may also include the following steps: Step S601, obtaining the pitch angle detected by the inertial measurement unit in the robot.
[0068] Step S602, detect whether the difference between the pitch angle and the initial angle exceeds the angle threshold. If it is detected that the difference exceeds the angle threshold, enter the tilt-off state. In the tilt-off state, control the robot to move forward a preset distance at a preset speed and then enter the return-to-pile state.
[0069] Among them, the infrared state transfer process in the infrared pile behavior is as follows: 1) Initialization state of stake alignment: record the robot's starting position, initialize the pitch angle (the initialization of this pitch angle corresponds to the deviation of the IMU data. On the same plane, the data settlement will also be different. When entering the infrared stake alignment behavior, recording the initial angle is equivalent to eliminating the deviation and taking the current plane as the initial plane), initialize the number of losses, initialize the number of tilting attempts to 0, and then unconditionally jump to the start state of stake alignment.
[0070] 2) Starting state of the pile: First, determine whether there is a charging current. If so, it means that it is already on the pile and jumps to the success state. If not, then determine whether there is an infrared signal. The judgment of the infrared signal here uses 16 sliding windows, that is, it takes 16 consecutive detections without infrared data to consider that the infrared signal is lost. For example, the infrared transmission frequency is about 400ms, while the cycle in the robot program varies from 20ms to 50ms, which is a big difference. Although the infrared reception can be used as a holding function, the longer the holding time, the longer the control delay and the worse the control accuracy.
[0071] For example: When the charging pile behavior is in the state of returning to the charging pile, the movement is controlled based on the infrared data (see 6 for details). When the infrared transmission (6, 6) is received at time t, it is considered to be facing the charging pile. In the next frame (20ms after the next cycle of the robot), due to the infrared hold, the reception is still the original (6, 6), but in fact the robot no longer conforms to the posture of (6, 6). In this case, the hold function of the infrared reception will have a counter-effect on the return to the charging pile. Therefore, in order to minimize this hold time, the hold function of the infrared reception program is cancelled in the overall design. The obvious problem after removing the infrared hold is that since the robot frequency is greater than the infrared transmission frequency, in some frames, the robot does not receive the infrared signal even if it is within the infrared range (the infrared is not emitted at this time), so a sliding window is designed here, that is, the signal is considered to be lost only when no infrared signal is received for 16 consecutive frames. On the one hand, it can ensure the immediacy of data update, and on the other hand, it will not be mistakenly judged as no signal due to frequency differences. Back to the description of state transition, if there is an infrared signal, it will jump to the state of returning to the charging pile, otherwise it will jump to the state of initial inspection of the charging pile.
[0072] 3) Initial pile inspection status: Determine whether the number of lost signals exceeds the threshold. If so, jump to the pile failure status; otherwise, jump to the pile rotation and pile search status.
[0073] 4) Rotating to find the stake: The robot will slowly rotate to try to find the infrared signal and continuously update the accumulated rotation angle. If the infrared signal is found, it will jump to the posture reset state after finding the stake. If the infrared signal is not found after two rotations, it will jump to the failure state.
[0074] 5) After finding the pile, the posture reset state: This state aims to solve the problem that after scanning the infrared signal in the pile rotation state, the robot does not stop rotating immediately, and there must be a certain delay (even if this delay is very small). After entering this state, the robot will slowly rotate in the opposite direction of the rotation direction in the pile rotation state for x frames (currently set to 0.5 times the speed and reverse for 1s, this value can be adjusted) to eliminate the delay effect. After the rotation is completed, it will jump to the pile start state unconditionally.
[0075] 6) Return to the charging pile status: First, describe the infrared signal: There are two infrared receivers on the robot (left and right), and there are two transmitters on the charging pile (left and right). Encode the infrared transmitter of the charging pile, the left is coded as 2, and the right is coded as 4. Then the infrared receiver on the robot receives the signal emitted by the left transmitter of the charging pile as 2, and the signal emitted by the right transmitter as 4. If both are received at the same time, it is described as 6, and if neither is received, it is described as 0. Then the possible states of the robot will be as follows: (0, 0) (0, 2) (0, 4) (0, 6) (2,0)(2,2)(2,4)(2,6) (4,0)(4,2)(4,4)(4,6) (6,0)(6,2)(6,4)(6,6) Taking (2, 2) as an example, it means that the left receiver has received the left transmitter, and the right receiver has also received the left transmitter, so it can be confirmed that the robot is roughly in which area. Different movement logic is set for each state. The robot is retreating during the entire pile-to-pile action. The right turn is written later, which is actually a right turn and retreat. Different angular velocities are set for different states, that is, they are both right turns, but the angular velocities of (0, 2) and (2, 2) are different. In (2, 4) and (6, 6), it is considered to be very correct, so it retreats in a straight line. There may be multiple postures in the (2, 2) state. Some postures may lose the signal after turning right. This is also taken into consideration in the design. After losing the signal, it will jump to the pile initial check state. In the pile initial check state, it will continue to jump according to the number of losses. Later, when it rotates to find the pile, it can return to (2, 2), and its posture meets the right turn and retreat conditions.
[0076] (0, 0) keep the previous action, (0, 2) turn right, (0, 4) turn left, (0, 6) turn right, (2, 0) turn right, (2, 2) turn right, (2, 4) go straight, (2, 6) turn right, (4, 0) turn left, (4, 2) turn left, (4, 4) turn left, (4, 6) turn left, (6, 0) turn left, (6, 2) turn right, (6, 4) turn left, (6, 6) go straight.
[0077] Note that the specific angular velocity is not mentioned above, because different speed matching is required according to the structure / transmission and reception characteristics / motor control effect of different charging piles and robots, but the overall logic remains the same as above.
[0078] Theoretically, (0, 0) indicates a no-signal state. In order to satisfy the sliding window and cancel the infrared hold, for example, in a sliding window of length 16, the infrared transmission frequency is slow. In order to respond in the first time, the infrared reception hold is canceled, resulting in 0 in the normal receiving range. For (0, 0) here, it is a false signal disappearance (that is, it disappears in a single frame and is not lost in 16 frames), so it must be processed to maintain the movement of the previous frame. Relying on the (0, 0) action design and sliding window here, the problem of control delay and infrared data loss caused by slow infrared data update when using a low-emission frequency infrared charging pile is solved. In the above movement process, if the charging current is detected, it jumps to the success state. In the state of returning to the pile, the robot keeps retreating. If the retreat distance exceeds the threshold, it is considered a failure and jumps to the pile failure state. If the signal is lost, it jumps to the pile initial inspection state.
[0079] 7) Pile failure state and staking success state: Both the staking failure state and the staking success state are end states. The difference is the return value returned to the return home behavior. The staking success state returns to the return home success state in the return home behavior, and the staking failure state returns to the return home failure state in the return home behavior.
[0080] In addition, in the entire pile-pole behavior, each loop will determine whether the current robot is tilted. The tilting judgment is based on the pitch angle calculated by the IMU. If the current angle minus the angle at the time of initialization exceeds the threshold, it is considered to be tilted. If the number of tilting-out attempts has not exceeded, it will jump to the tilting-out state, otherwise it will return to the pile-pole initialization state.
[0081] 8) Tilt-up state: Keep moving forward slowly at Z m (Z is currently set to 0.3) and then jump to the state of returning to the pile. In this embodiment, the tilt-up state can help improve the success rate of pile placement. After the above three behaviors and logical jumps, it can be ensured that the robot tilts up because it hits the charging pile. The tilt-up state is to go down the pile in a straight line and then face the pile, so that it can be guaranteed to start facing the pile with a more correct posture.
[0082] See also Figure 7 , is a flow chart of a robot automatic return method provided in Embodiment 7 of the present application, such as Figure 6 As shown, the mobile state transfer process includes a path-finding state, a waiting path update state, a moving state, a calibration state, a completion state, and an error state. The mobile state transfer process corresponding to the action of moving to the target point may include the following steps: Step S701, entering the path-finding state, in which the reachable path of the robot from the current position to the preset position in front of the charging pile is calculated based on the path-finding algorithm.
[0083] Step S702, after entering the path-finding state, jump to the path-waiting update state. In the path-waiting update state, detect whether the path-finding algorithm in the path-finding state has finished running. If it is detected that the path-finding algorithm has finished running, detect whether there is at least one path in the reachable path.
[0084] Step S703: if it is detected that there is no path in the reachable path, an error state is entered, and the error state is used to indicate that the mobile state transfer process returns failure after execution is completed.
[0085] Step S704: If it is detected that there is at least one path in the reachable path, the robot enters the moving state. In the moving state, the robot is controlled according to the positional relationship between the current point and the next point on the path until it reaches the preset position in front of the charging pile.
[0086] Step S705, entering the calibration state. In the calibration state, the robot is controlled to rotate until the charging port of the robot faces the charging pile, and then entering the completion state. The completion state is used to indicate that the mobile state transfer process returns successfully after execution is completed.
[0087] The moving state transition process in the moving to target point behavior is as follows: 1) Movement initialization state: After initializing the pathfinder, movement method, etc. used in the movement to the target point behavior, it unconditionally jumps to the pathfinder state.
[0088] 2) Pathfinding state: According to the map, the pathfinding algorithm is used to start calculating the reachable path from the current point to the point 0.5m in front of the charging pile. According to the description of map construction above, each grid on the map is divided into three states: reachable, unknown, and charging pile. The pathfinding algorithm searches for whether there is a path from the current grid to the grid 0.5m in front of the charging pile, and all grids on this path are marked as reachable. The specific pathfinding algorithm is not the focus of the present invention. Currently, the well-known A* pathfinding algorithm is used. After starting the calculation, it unconditionally jumps to the waiting path update state.
[0089] 3) Waiting for path update state: Determine whether the path-finding algorithm has finished running. If it has finished running, further determine whether the obtained path exists. If there is a reachable path, jump to the moving state. If there is no reachable path, jump to the error state.
[0090] 4) Moving state: Calculate the speed that should be set based on the positional relationship between the current point and the previous and next points on the path, and send it to the walking motor for motion control. Specifically, calculate the vector from the current position to the target position, and calculate the angle between the vector and the positive direction of the x-axis. If the absolute value of the deviation angle is greater than the angle corresponding to the maximum angular velocity (which means that the robot needs to turn significantly to face the target), set the linear velocity to 0, and set the angular velocity to the maximum or minimum angular velocity based on the positive or negative value of the deviation angle. If the deviation angle is small, adjust the linear velocity according to the distance to the end of the path (if the distance is greater than the threshold, the linear velocity is larger; otherwise, the linear velocity is smaller). At this time, the angular velocity is directly set to the deviation angle. When the last point on the path is reached, jump to the calibration state. The way to judge whether point xx has been reached is: whether it is in the same grid of the grid map above (including being in the tolerance range) 5) Calibration state: Perform motion control based on the current robot angle and charging pile angle. The goal is to rotate the robot until the tail (the direction of the infrared receiving tube) is facing the charging pile for subsequent charging pile actions. After completing the calibration, jump to the completion state.
[0091] 6) Both the completion status and the error status are end statuses. The difference is that the return value returned to the home-going behavior is different. The completion status returns to the home-going success status in the home-going behavior, and the error status returns to the home-going failure status in the home-going behavior.
[0092] Corresponding to the robot automatic return method of the above embodiment, Figure 8 The structural block diagram of the robot automatic pile return device provided in the eighth embodiment of the present application is shown. For the convenience of explanation, only the part related to the embodiment of the present application is shown.
[0093] See also Figure 8 The robot automatic pile return device includes: A return behavior module 81 is used to execute a return state transition process corresponding to the return behavior when the robot receives an automatic return command; The move to target point behavior module 82 is used to execute the moving state transition process corresponding to the move to target point behavior and continuously monitor the infrared signal if the home state transition process enters the move to target point state; Infrared pairing state module 83, for entering the infrared pairing state in the home state transition process if a preset number of infrared signals are detected or the mobile state transition process returns successfully after execution; The infrared pile-to-pile behavior module 84 is used to execute the pile-to-pile state transfer process corresponding to the infrared pile-to-pile behavior until the pile-to-pile state transfer process is successfully executed or a charging current is detected during the execution of the pile-to-pile state transfer process, and it is determined that the robot automatically returns to the pile successfully.
[0094] Optionally, the return state transfer process also includes the return initial inspection state, and the robot automatic return device also includes: The home initial check state module is used to detect whether the robot receives the infrared signal and whether the distance between the robot and the charging pile is less than a preset value after executing the home state transition process corresponding to the home behavior, if the home state transition process is executed to the home initial check state; The first state jump module is used to jump to the infrared charging pile state if it is detected that the robot receives an infrared signal and the distance between the robot and the charging pile is less than a preset value.
[0095] Optionally, the home state transfer process also includes a home rotation and pile-finding state, a posture reset state after home finding the pile, a failure retry state, and a home failure state. The robot automatic pile return device also includes: The home rotation and pile-finding state module is used to enter the home rotation and pile-finding state after executing the mobile state transition process corresponding to the movement to the target point behavior and continuously monitoring the infrared signal. If the infrared signal of the preset number of frames is not detected and the mobile state transition process returns failure after execution, the robot will enter the home rotation and pile-finding state. In the home rotation and pile-finding state, the robot tries to find the infrared signal by rotating itself and continuously updates the first accumulated rotation angle. The module for resetting the state of the robot after returning home and finding the pile is used to enter the state of resetting the state of the robot after returning home and finding the pile if the first accumulated rotation angle finds the infrared signal within the first preset number of circles. In the state of resetting the state of the robot after returning home and finding the pile, the robot rotates in the direction opposite to the direction of the robot's self-rotation in the state of rotating to find the pile at home for a second preset time delay, and then returns to the state of initial inspection at home; The return home failure state module is used to clear the first cumulative rotation angle to zero if no infrared signal is found after the first preset number of circles, and enter the failure retry state. In the failure enrichment state, if it is detected that the number of failed retries is less than the retry threshold, it returns to the return home initial check state and adds 1 to the number of failed retries. If it is detected that the number of failed retries is not less than the retry threshold, it enters the return home failure state.
[0096] Optionally, the pile state transfer process includes a pile start state, a pile initial check state, a pile rotation and pile search state, a pile posture reset state after the pile is found, a pile failure state and a pile success state, and the movement state transfer process includes a path finding state, a path update waiting state, a movement state, a calibration state and a completion state. The infrared pile behavior module 84 includes: The pile alignment start state unit is used to enter the pile alignment start state. In the pile alignment start state, it detects whether there is a charging current. If the charging current is detected, the pile alignment success state is entered. The pile alignment success state is used to indicate that the robot automatically returns to the pile successfully; A failure retry state unit is used to detect whether there is an infrared signal if no charging current is detected. If no infrared signal is detected, the unit enters the initial pile inspection state. In the initial pile inspection state, the unit detects whether the number of lost signals exceeds the loss threshold. If the number of lost signals exceeds the loss threshold, the unit enters the pile failure state. The pile failure state is used to indicate entering the failure retry state. A pile rotation and pile finding state unit is used to enter a pile rotation and pile finding state if it is detected that the number of lost signals does not exceed the loss threshold. In the pile rotation and pile finding state, the robot tries to find the infrared signal by rotating itself and continuously updates the second accumulated rotation angle; A post-posture reset state unit is used for entering a post-posture reset state after the pile is found if the second accumulated rotation angle finds an infrared signal within a second preset number of circles. In the post-posture reset state after the pile is found, the robot rotates in a direction opposite to the self-rotation direction of the robot in the post-posture rotation state for a second preset time delay, and then returns to the post-posture start state; The staking failure state unit is used to clear the second accumulated rotation angle to zero and enter the staking failure state if no infrared signal is found after the second preset number of revolutions of the second accumulated rotation angle.
[0097] Optionally, the pile state transfer process also includes a pile return state, and the infrared pile behavior module 84 also includes: The back-to-pile state unit is used to detect whether there is an infrared signal. If an infrared signal is detected, the robot enters the back-to-pile state. In the back-to-pile state, the robot is controlled to align with the charging pile, and the robot is controlled to reverse, and whether there is a charging current and the reverse distance are detected; The charging success state unit is used to enter the charging success state if the charging current is detected, and enter the charging failure state if the charging current is still not detected when the backing distance exceeds the distance threshold.
[0098] Optionally, the pile state transfer process also includes a tilting and disengaging state, and the infrared pile behavior module 84 further includes: A pitch angle acquisition unit, used to acquire the pitch angle detected by an inertial measurement unit in the robot; The tilt-off state unit is used to detect whether the difference between the pitch angle and the initial angle exceeds the angle threshold. If it is detected that the difference exceeds the angle threshold, the tilt-off state is entered. In the tilt-off state, the robot is controlled to move forward a preset distance at a preset speed and then enter the return to pile state.
[0099] Optionally, the mobile state transfer process includes a path-finding state, a waiting path update state, a moving state, a calibration state, a completion state and an error state, and the moving to the target point behavior module 82 includes: A path-finding state unit, used to enter a path-finding state, in which a reachable path of the robot from a current position to a preset position in front of the charging pile is calculated based on a path-finding algorithm; A waiting path update state unit is used to jump into the waiting path update state after entering the path finding state. In the waiting path update state, it is detected whether the path finding algorithm in the path finding state has finished running. If it is detected that the path finding algorithm has finished running, it is detected whether there is at least one path in the reachable path. An error state unit, used to enter an error state if it is detected that no path exists in the reachable path. The error state is used to indicate that the mobile state transfer process returns failure after execution is completed; A mobile state unit, for entering a mobile state if at least one path is detected in the reachable path, in which the robot is controlled according to the positional relationship between the current point and the next point on the path until it reaches a preset position in front of the charging pile; The calibration state unit is used to enter the calibration state. In the calibration state, the robot is controlled to rotate until the charging port of the robot is facing the charging pile, and then enters the completion state. The completion state is used to indicate that the mobile state transfer process returns successfully after execution.
[0100] It should be noted that the information interaction, execution process and other contents between the above-mentioned modules are based on the same concept as the method embodiment of the present application. Their specific functions and technical effects can be found in the method embodiment part and will not be repeated here.
[0101] Fig. 9 This is a schematic diagram of the structure of a computer device provided in Example 9 of the present application. Fig. 9 As shown, the computer device of this embodiment includes: at least one processor ( Fig. 9 Only one is shown), a memory, and a computer program stored in the memory and executable on at least one processor, wherein when the processor executes the computer program, the steps in any of the above-mentioned robot automatic return method embodiments are implemented.
[0102] The computer device may include, but is not limited to, a processor and a memory. Those skilled in the art will appreciate that Fig. 9 This is merely an example of a computer device and does not constitute a limitation on the computer device. The computer device may include more or fewer components than those shown in the figure, or a combination of certain components, or different components. For example, it may also include a network interface, a display screen, and an input device.
[0103] The processor may be a CPU, or other general-purpose processors, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.
[0104] The memory includes a readable storage medium, an internal memory, etc., wherein the internal memory may be the memory of a computer device, and the internal memory provides an environment for the operation of the operating system and computer-readable instructions in the readable storage medium. The readable storage medium may be a hard disk of a computer device, and in other embodiments, it may also be an external storage device of the computer device, for example, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc. equipped on the computer device. Further, the memory may also include both an internal storage unit of the computer device and an external storage device. The memory is used to store an operating system, an application program, a boot loader (BootLoader), data, and other programs, such as the program code of a computer program, etc. The memory may also be used to temporarily store data that has been output or is to be output.
[0105] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device is divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated into a processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned device can refer to the corresponding process in the above-mentioned method embodiment, which will not be repeated here. If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, which can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium. When the computer program is executed by the processor, the steps of the above-mentioned method embodiment can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may at least include: any entity or device capable of carrying computer program code, recording medium, computer memory, read-only memory (ROM), random access memory (RAM), electric carrier signal, telecommunication signal and software distribution medium. For example, a USB flash drive, a mobile hard disk, a magnetic disk or an optical disk. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electric carrier signals and telecommunication signals.
[0106] The present application implements all or part of the processes in the above-mentioned embodiment method, and may also be completed through a computer program product. When the computer program product runs on a computer device, the computer device can implement the steps in the above-mentioned method embodiment when executing the computer program product.
[0107] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0108] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0109] In the embodiments provided in the present application, it should be understood that the disclosed devices / computer equipment and methods can be implemented in other ways. For example, the device / computer equipment embodiments described above are only schematic, for example, the division of modules or units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0110] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0111] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. A robot automatic pile return method, characterized in that: The robot automatic pile return method comprises: When the robot receives the automatic return command, it executes the return state transition process corresponding to the return behavior; If the home state transition process enters the moving to target point state, the moving state transition process corresponding to the moving to target point behavior is executed, and the infrared signal is continuously monitored; If a preset number of infrared signals are detected or the mobile state transfer process returns successfully after execution, the infrared pairing state in the home state transfer process is entered; The pile state transfer process corresponding to the infrared pile-pile behavior is executed until the pile state transfer process is successfully executed or a charging current is detected during the execution of the pile state transfer process, and it is determined that the robot automatically returns to the pile successfully.
2. The robot automatic return method according to claim 1, characterized in that: The home state transition process also includes the home initial inspection state, and after the home state transition process corresponding to the execution of the home behavior, it also includes: If the return state transfer process is executed to the return initial check state, it is detected whether the robot receives the infrared signal and whether the distance between the robot and the charging pile is less than a preset value; If it is detected that the robot receives an infrared signal and the distance between the robot and the charging pile is less than a preset value, the robot switches to the infrared charging pile state.
3. The robot automatic return method according to claim 2, characterized in that: The home state transition process also includes the home rotation and pile-finding state, the home posture reset state after finding the pile, the failure retry state and the home failure state. After executing the movement state transition process corresponding to the movement to the target point behavior and continuously monitoring the infrared signal, it also includes: If the infrared signal of the preset number of frames is not detected and the mobile state transfer process returns failure after execution, the robot enters the home-turning and searching-stakes state, in which the robot tries to find the infrared signal by rotating itself and continuously updates the first accumulated rotation angle; If the first accumulated rotation angle finds an infrared signal within the first preset number of circles, the robot enters the attitude reset state after returning home and finding the pile. In the attitude reset state after returning home and finding the pile, the robot rotates in the direction opposite to the direction of the robot's self-rotation in the state of rotating to return home and finding the pile for a second preset delay, and then returns to the initial inspection state of returning home; If the first cumulative rotation angle does not find an infrared signal after the first preset number of circles, the first cumulative rotation angle is cleared to zero and the system enters the failed retry state. In the failed enrichment state, if it is detected that the number of failed retries is less than the retry threshold, the system returns to the home initial check state and adds 1 to the number of failed retries. If it is detected that the number of failed retries is not less than the retry threshold, the system enters the home failure state.
4. The robot automatic return method according to claim 3, characterized in that: The state transfer process of the pile alignment includes the starting state of the pile alignment, the initial inspection state of the pile alignment, the rotation state of the pile alignment to find the pile, the posture reset state after the pile alignment finds the pile, the pile alignment failure state and the pile alignment success state. The movement state transfer process includes the path finding state, the waiting path update state, the movement state, the calibration state and the completion state. The execution of the infrared pile alignment behavior corresponding to the state transfer process of the pile alignment includes: Entering the pile-pile starting state, in which whether there is a charging current is detected, and if the charging current is detected, entering the pile-pile success state, the pile-pile success state is used to indicate that the robot automatically returns to the pile successfully; If the charging current cannot be detected, whether there is an infrared signal is detected. If no infrared signal is detected, the initial pile inspection state is entered. In the initial pile inspection state, whether the number of lost signals exceeds the loss threshold is detected. If the number of lost signals exceeds the loss threshold, the pile failure state is entered. The pile failure state is used to indicate entering the failure retry state; If it is detected that the number of lost signals does not exceed the loss threshold, the robot enters the pile-rotating pile-finding state, in which the robot attempts to find the infrared signal by rotating itself and continuously updates the second accumulated rotation angle; If the second accumulated rotation angle finds an infrared signal within the second preset number of turns, the robot enters the pile-finding posture reset state, and in the pile-finding posture reset state, the robot rotates in a direction opposite to the self-rotation direction of the robot in the pile-finding rotation state for a second preset time delay, and then returns to the pile-finding start state; If the second accumulated rotation angle does not find an infrared signal after the second preset number of turns, the second accumulated rotation angle is cleared to zero, and the staking failure state is entered.
5. The robot automatic return method according to claim 4, characterized in that: The process of transferring the pile status also includes returning to the pile status, and after detecting whether there is an infrared signal, it also includes: If an infrared signal is detected, the robot enters the return-to-pile state, in which the robot is controlled to align with the charging pile, and the robot is controlled to move backward, and whether there is a charging current and a backward distance are detected; If the charging current is detected, the charging success state is entered; if the charging current is still not detected when the backing distance exceeds the distance threshold, the charging failure state is entered.
6. The robot automatic return method according to claim 5, characterized in that: The pile state transfer process also includes a tilting and disengaging state, and the pile state transfer process corresponding to the infrared pile action also includes: Obtaining a pitch angle detected by an inertial measurement unit in the robot; Detect whether the difference between the pitch angle and the initial angle exceeds an angle threshold. If it is detected that the difference exceeds the angle threshold, enter the tilt-out state. In the tilt-out state, control the robot to move forward a preset distance at a preset speed and then enter the return-to-pile state.
7. The robot automatic return method according to any one of claims 1 to 6, characterized in that: The mobile state transfer process includes a path-finding state, a waiting path update state, a moving state, a calibration state, a completion state, and an error state. The mobile state transfer process corresponding to the execution of the moving to the target point behavior includes: Entering the path-finding state, in which a reachable path of the robot from a current position to a preset position in front of the charging pile is calculated based on a path-finding algorithm; After entering the path-finding state, jumping to the waiting path update state, in the waiting path update state, detecting whether the path-finding algorithm in the path-finding state has finished running, if it is detected that the path-finding algorithm has finished running, detecting whether there is at least one path in the reachable path; If it is detected that no path exists in the reachable path, the error state is entered, and the error state is used to indicate that the mobile state transfer process returns failure after execution is completed; If it is detected that there is at least one path in the reachable path, the moving state is entered, in which the robot is controlled according to the positional relationship between the current point and the next point on the path until it reaches a preset position in front of the charging pile; Enter the calibration state, in which the robot is controlled to rotate until the charging port of the robot faces the charging pile, and enter the completion state, which is used to indicate that the mobile state transfer process returns successfully after execution is completed.
8. A robot automatic pile return device, characterized in that: The robot automatic pile return device comprises: The return behavior module is used to execute the return state transition process corresponding to the return behavior when the robot receives the automatic return command; A move to target point behavior module, for executing a moving state transition process corresponding to the move to target point behavior and continuously monitoring infrared signals if the home state transition process enters the move to target point state; An infrared pairing state module is used to enter the infrared pairing state in the home state transition process if a preset number of infrared signals are detected or the mobile state transition process returns successfully after execution; The infrared pile-to-pile behavior module is used to execute the pile-to-pile state transfer process corresponding to the infrared pile-to-pile behavior until the pile-to-pile state transfer process is successfully executed or a charging current is detected during the execution of the pile-to-pile state transfer process, and it is determined that the robot automatically returns to the pile successfully.
9. A computer device, characterized in that: The computer device includes a processor, a memory, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the robot automatic return method as described in any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the robot automatic return method as described in any one of claims 1 to 7 is implemented.
Citation Information
Patent Citations
Automatic recharging method and system based on infrared laser, robot and charging dock
CN110928307A
Robot charging method and device, robot and storage medium
CN111103870A
Charging method, robot, robot charging system and storage medium
CN111403989A
Recharging method and system based on infrared and tracking
CN112486154A
Robot and automatic return charging method therefor, control device, and storge medium
WO2023006104A1