Self-moving device relocation method and self-moving device

By generating a trajectory by driving a set distance using an autonomous mobile device, and using RTK positioning to determine the destination position and attitude, the problem of relocation after the autonomous mobile device loses its location is solved, and efficient and accurate relocation of the autonomous mobile device is achieved.

WO2026149169A1PCT designated stage Publication Date: 2026-07-16ECOVACS HOME SERVICE ROBOTICS CO LTD

Patent Information

Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
ECOVACS HOME SERVICE ROBOTICS CO LTD
Filing Date
2025-12-17
Publication Date
2026-07-16

AI Technical Summary

Technical Problem

In existing technologies, mobile devices cannot accurately relocate after losing map positioning, requiring manual intervention or cumbersome operations, resulting in poor relocation efficiency and accuracy.

Method used

By controlling the self-moving device to travel a set distance to form a driving trajectory, and using RTK positioning to determine the destination position and attitude, the self-moving device can be repositioned on the map without the need for visual or radar assistance.

Benefits of technology

It enables efficient and accurate repositioning of self-moving devices, avoids manual intervention, simplifies the repositioning process, and improves repositioning efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2025143280_16072026_PF_FP_ABST
    Figure CN2025143280_16072026_PF_FP_ABST
Patent Text Reader

Abstract

Provided in the present application are a self-moving device relocation method and a self-moving device. The self-moving device relocation method comprises: controlling a self-moving device to travel a set distance from the current position so as to form a corresponding travel trajectory; determining target coordinates of the end position of the travel trajectory in a map coordinate system; and determining a target orientation of the self-moving device on the basis of the travel trajectory, and using the target coordinates and the target orientation as a relocation pose of the self-moving device in the map coordinate system. If the location of the self-moving device in the map is lost, the self-moving device can be controlled to travel the set distance from the current position, such that by using the travel trajectory of the self-moving device, the position and orientation of the self-moving device in the map can be redetermined without human intervention, thereby improving relocation efficiency and accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Relocation method for self-moving devices and self-moving devices

[0001] This application claims priority to Chinese Patent Application No. 202510045148.5, filed on January 10, 2025, entitled “Relocation Method for Self-Moving Device and Self-Moving Device”, the entire contents of which are incorporated herein by reference. Technical Field

[0002] The embodiments in this specification relate to the field of artificial intelligence technology, and in particular to a relocation method for a self-moving device and a self-moving device. Background Technology

[0003] With the rapid development of computer technology, the internet, and artificial intelligence, self-moving devices are increasingly being used in all aspects of work and life, such as self-moving lawnmowers, self-moving lawn harvesters, and cleaning robots. To enable self-moving devices to move automatically in actual usage scenarios (i.e., actual physical spaces), it is necessary to locate the self-moving devices in a constructed map, thereby controlling their movement within the map and performing corresponding work tasks.

[0004] In existing technologies, if the location of a self-moving device is lost on a map, it cannot be correctly located to control the device to perform tasks. The common approach is to move the device back to the base station to re-trigger the task, or to relocate it by matching visual or radar map points. This often requires manual intervention, is cumbersome, and has poor relocation efficiency and accuracy. Therefore, a more efficient and accurate relocation solution for self-moving devices is urgently needed. Summary of the Invention

[0005] In view of the above, embodiments of this specification provide a method for relocating a self-moving device. One or more embodiments of this specification also relate to another method for relocating a self-moving device, yet another method for relocating a self-moving device, a relocation apparatus for a self-moving device, yet another relocation apparatus for a self-moving device, a self-moving device, a computer-readable storage medium, and a computer program product, to address the technical deficiencies existing in the prior art.

[0006] According to a first aspect of the embodiments of this specification, a first method for relocating a self-moving device is provided, comprising:

[0007] Control the mobile device to travel a set distance from its current location, forming a corresponding travel trajectory;

[0008] Determine the target coordinates of the endpoint of the driving trajectory in the map coordinate system, and determine the target attitude of the self-moving device based on the driving trajectory;

[0009] The target coordinates and the target pose are used as the repositioning pose of the self-moving device in the map coordinate system.

[0010] Optionally, the self-moving device is equipped with an odometer sensor, which is used to record parameters of the self-moving device during its travel; determining the target attitude of the self-moving device based on the travel trajectory includes:

[0011] The target posture of the self-moving device is determined based on the driving trajectory and the parameters recorded by the mileage sensor.

[0012] Optionally, after using the target coordinates and the target pose as the repositioning pose of the self-moving device in the map coordinate system, the method further includes:

[0013] Based on the repositioning pose and the pre-built map, determine whether the self-moving device is located in the map area;

[0014] If not, then issue an out-of-bounds warning.

[0015] According to a second aspect of the embodiments of this specification, a second method for relocating a self-moving device is provided, comprising:

[0016] In response to a relocation event, the self-moving device is controlled to travel a set distance from its current position to form a corresponding travel trajectory. The relocation event includes at least one of the following: the self-moving device is moved or the self-moving device is restarted.

[0017] Determine the target coordinates of the endpoint of the driving trajectory in the map coordinate system, and determine the target attitude of the self-moving device based on the driving trajectory;

[0018] The target coordinates and the target pose are used as the repositioning pose of the self-moving device in the map coordinate system.

[0019] According to a third aspect of the embodiments of this specification, a working system for a self-moving device is provided, including a self-moving device and a display device, wherein the display device is used to display a map of the working area of ​​the self-moving device, and the working system for the self-moving device includes:

[0020] A detection module, installed on the self-moving device, is used to detect whether a moving event has occurred on the self-moving device.

[0021] A positioning device includes one or more positioning tags disposed on the self-moving device and configured to receive positioning signals from one or more positioning beacons, wherein the working area has areas with strong positioning signals and areas with weak positioning signals.

[0022] At least one processor is configured as follows:

[0023] In response to the occurrence of the transport event, the self-moving device is controlled to travel a preset distance, and the coordinates of the destination of the preset distance of the mobile device are determined based on the pre-stored information of one or more positioning beacons.

[0024] The target pose of the self-moving device is determined based on the trajectory of the preset mileage, and the target coordinates and target pose of the endpoint of the preset mileage are used as the repositioning pose in the coordinate system of the map.

[0025] The preset mileage is located in an area where the positioning signal is weak.

[0026] According to a fourth aspect of the embodiments of this specification, another operating system for a self-moving device is provided, including a self-moving device, a base station, and a display device, wherein the display device is used to display a map of the operating area of ​​the self-moving device, and the operating system for the self-moving device includes:

[0027] The detection module is used to detect whether the self-moving device has engaged with the base station.

[0028] A positioning device includes one or more positioning tags disposed on the self-moving device and configured to receive positioning signals from one or more positioning beacons;

[0029] At least one processor is configured as follows:

[0030] In response to the activation of the self-moving device and the absence of the docking event, the self-moving device is controlled to travel a preset distance, and the coordinates of the endpoint of the preset distance of the mobile device are determined based on the pre-stored information of one or more positioning beacons.

[0031] The target posture of the self-moving device is determined based on the trajectory of the preset mileage, and the target coordinates and target posture of the endpoint of the preset mileage are used as the repositioning posture in the coordinate system of the map.

[0032] According to a fifth aspect of the embodiments of this specification, a third method for relocating a self-moving device is provided, comprising:

[0033] Control the mobile device to travel a set distance from its current location, forming a corresponding travel trajectory;

[0034] Determine the target coordinates of the endpoint of the driving trajectory in the map coordinate system, and determine the target attitude of the self-moving device based on the driving trajectory;

[0035] The target coordinates and the target pose are used as the repositioning pose of the self-moving device in the map coordinate system;

[0036] Based on the state parameters of the self-moving device, a corresponding task execution strategy is determined, and the self-moving device is controlled according to the repositioning pose and the task execution strategy.

[0037] Optionally, the status parameters include task status, original location distance, and base station distance, wherein the task status includes whether there are unexecuted tasks or not; determining the corresponding task execution strategy based on the status parameters of the self-moving device includes:

[0038] If the task status is that there are unexecuted tasks, then the corresponding task execution strategy is determined based on the task type of the unexecuted task, the original location distance, and the base station distance;

[0039] If the task status is that there are no unexecuted tasks, then the corresponding task execution strategy is determined based on the base station distance.

[0040] Optionally, determining the corresponding task execution strategy based on the task type of the unexecuted task, the original location distance, and the base station distance includes:

[0041] If the task type is "in execution" and the original location distance does not exceed the distance threshold, the task execution strategy is determined to continue executing the unexecuted task; or

[0042] If the task type is "in execution" and the original location distance exceeds a distance threshold, determine whether the base station distance exceeds the distance threshold. If it does, determine the task execution strategy as follows: determine and execute the target task from the pending tasks based on the repositioning pose. If it does not exceed the distance threshold, determine the task execution strategy as follows: stop task execution and return to the base station; or

[0043] When the task type is pending execution, it is determined whether the distance to the base station exceeds a distance threshold. If it does, the task execution strategy is determined to be to determine and execute the target task from the pending tasks based on the relocation pose. If it does not exceed the threshold, the task execution strategy is determined to stop executing the task and return to the base station.

[0044] Optionally, the status parameters include the original location distance and the base station distance; determining the corresponding task execution strategy based on the status parameters of the self-moving device includes:

[0045] If the distance to the original location does not exceed the distance threshold, the task execution strategy is determined to be to return to the original location;

[0046] If the distance to the original location exceeds a distance threshold, determine whether the distance to the base station exceeds the distance threshold. If it does not exceed the distance threshold, determine that the task execution strategy is to return to the base station; if it exceeds the distance threshold, determine that the task execution strategy is to create and execute a new task.

[0047] According to a sixth aspect of the embodiments of this specification, a fourth method for repositioning a self-moving device is provided, wherein the self-moving device is equipped with a visual sensor, a positioning device, and a control unit; the visual sensor is disposed on the front side of the self-moving device along the normal driving direction of the self-moving device and is used to identify environmental information of the area in front of the self-moving device; the positioning device includes a positioning tag for communicating with a satellite and at least one positioning beacon disposed outside the self-moving device, and the position of the self-moving device is obtained based on at least one positioning beacon with a known location and differential information between the positioning tags;

[0048] The method is applied to a control unit and includes:

[0049] A relocation event is triggered in response to the self-moving device being moved and / or the self-moving device being powered on again after being powered off.

[0050] In response to the relocation event, the trust status of the area in front of the self-moving device is determined by the visual sensor, the self-moving device is controlled to travel a set distance towards the trusted area in front, and a corresponding driving trajectory is formed according to the positioning device.

[0051] The target coordinates of the endpoint of the driving trajectory in the map coordinate system are determined, and the target attitude of the self-moving device is determined according to the driving trajectory. The target coordinates and the target attitude are used as the repositioning pose of the self-moving device in the map coordinate system, wherein the repositioning pose is the starting point of the subsequent navigation path.

[0052] Optionally, the operating system of the self-moving device further includes a display device; the method further includes:

[0053] In response to the self-moving device being moved and / or the self-moving device being powered on again after being powered off, the first pose of the self-moving device is displayed on a pre-built map via the display device;

[0054] During the repositioning process of the self-moving device, the self-moving device is displayed on the map along the trajectory of moving from the first pose, and the repositioned pose obtained after moving the trajectory is repositioned is displayed, wherein the pose in the first pose after moving the trajectory is repositioned jumps to the target pose in the repositioned pose.

[0055] Optionally, the self-moving device is further equipped with a mileage sensor; controlling the self-moving device to travel a set distance towards a trusted area ahead, and forming a corresponding travel trajectory based on the positioning device, includes:

[0056] Control the self-moving device to travel from its current location to a trusted area ahead to the target location point, and form a corresponding first driving trajectory based on the positioning device;

[0057] The initial posture of the self-moving device is determined based on the first driving trajectory, and the initial posture is used as the orientation reference of the mileage sensor to control the self-moving device to continue driving from the target positioning point, thereby forming a corresponding second driving trajectory.

[0058] Accordingly, determining the target attitude of the self-moving device based on the driving trajectory includes:

[0059] The target posture of the self-moving device is determined based on the first driving trajectory and the second driving trajectory. The orientation of the odometer sensor is updated based on the target posture, and subsequent tasks are controlled to be executed.

[0060] Optionally, the operating system of the self-moving device further includes a display device; after determining the initial posture of the self-moving device based on the first driving trajectory, it further includes:

[0061] The display device displays the initial posture of the self-moving device on the map;

[0062] After determining the target posture of the self-moving device based on the first driving trajectory and the second driving trajectory, the method further includes:

[0063] The initial posture of the self-moving device in the map displayed by the display device is updated to the target posture. If the error between the target posture and the initial posture is greater than a set threshold, the posture update jump amplitude of the self-moving device in the map is a first amplitude; if the error between the target posture and the initial posture is not greater than the set threshold, the posture update jump amplitude of the self-moving device in the map is a second amplitude, and the first amplitude is greater than the second amplitude.

[0064] According to a seventh aspect of the embodiments of this specification, a fifth method for repositioning a self-moving device is provided, wherein the self-moving device is equipped with a visual sensor, a positioning device, and a control unit; the visual sensor is disposed on the front side of the self-moving device along the normal driving direction of the self-moving device and is used to identify environmental information of the area in front of the self-moving device; the positioning device includes a positioning tag for communicating with a satellite and at least one positioning beacon disposed outside the self-moving device, and the position of the self-moving device is obtained based on at least one positioning beacon with a known location and differential information between the positioning tags;

[0065] The method is applied to a control unit and includes:

[0066] In response to the self-moving device being moved to the positioning shadow area, a relocation event is triggered, wherein the positioning shadow area is an area with weak positioning signal;

[0067] In response to the relocation event, the trust status of the area in front of the self-moving device is determined by the visual sensor, the self-moving device is controlled to travel a set distance towards the trusted area in front, and a corresponding driving trajectory is formed according to the positioning device.

[0068] The target coordinates of the endpoint of the driving trajectory in the map coordinate system are determined, and the target attitude of the self-moving device is determined according to the driving trajectory. The target coordinates and the target attitude are used as the repositioning pose of the self-moving device in the map coordinate system, wherein the repositioning pose is the starting point of the subsequent navigation path.

[0069] Optionally, the operating system of the self-moving device further includes a display device; the method further includes:

[0070] In response to the self-moving device being moved to the positioning shadow area, the positioning location of the self-moving device is displayed on a pre-built map via the display device, wherein the number of positioning location jumps is less than or equal to the number of repositioning calculations;

[0071] During the repositioning process of the self-moving device, the self-moving device's trajectory is displayed on the map, and the repositioned pose obtained after repositioning is also displayed. After repositioning by moving the trajectory, the pose of the self-moving device on the map changes, and the pose remains stable after the change.

[0072] Optionally, the self-moving device further includes a mileage sensor; controlling the self-moving device to travel a set distance towards a trusted area ahead, and forming a corresponding travel trajectory based on the positioning device, includes:

[0073] The self-moving device is controlled to travel from its current position to the target positioning point within the positioning shadow area, and a corresponding first driving trajectory is formed based on the positioning device.

[0074] Based on the first driving trajectory, the initial pose of the self-moving device in the map coordinate system is determined, wherein the initial pose includes initial coordinates and initial attitude;

[0075] The initial coordinates are used as the starting point of the positioning device, and the initial attitude is used as the orientation reference of the odometer sensor. The self-moving device is controlled to continue driving from the target positioning point, perform subsequent tasks, and form a corresponding second driving trajectory. The trajectory path for performing subsequent tasks includes at least a portion of the second driving trajectory.

[0076] Accordingly, determining the target attitude of the self-moving device based on the driving trajectory includes:

[0077] The target attitude of the self-moving device is determined based on the first driving trajectory and the second driving trajectory. The orientation of the odometer sensor is updated based on the target attitude, and the device is controlled to continue executing subsequent tasks.

[0078] According to an eighth aspect of the embodiments of this specification, a self-moving device is provided, comprising:

[0079] ontology,

[0080] A drive module, located on the main body, is used to drive the main body to move;

[0081] An execution module, located in the main body, is used to perform work tasks;

[0082] Memory and processor;

[0083] The memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions, which, when executed by the processor, implement the steps of the relocation method for the self-moving device described above.

[0084] According to a ninth aspect of the embodiments of this specification, a computer-readable storage medium is provided that stores computer-executable instructions, which, when executed by a processor, implement the steps of the relocation method for the self-moving device described above.

[0085] According to a tenth aspect of the embodiments of this specification, a computer program product is provided, including a computer program / instructions that, when executed by a processor, implement the steps of the relocation method for the self-moving device described above.

[0086] This specification provides a repositioning method for a self-moving device, which controls the self-moving device to travel a set distance from its current position to form a corresponding travel trajectory; determines the target coordinates of the endpoint of the travel trajectory in a map coordinate system; determines the target posture of the self-moving device based on the travel trajectory; and uses the target coordinates and the target posture as the repositioning posture of the self-moving device in the map coordinate system.

[0087] One embodiment of this specification implements a method that, if the location of a self-moving device on a map is lost, the self-moving device can be controlled to travel a set distance from its current location to locate the target coordinates of the endpoint of the travel trajectory in the map coordinate system. Furthermore, based on the travel trajectory after traveling the set distance, the target attitude of the self-moving device can be determined. The target coordinates can indicate the location of the self-moving device on the map, and the target attitude can indicate the orientation of the self-moving device. This allows for the repositioning of the self-moving device on the map, achieving repositioning of the self-moving device without having to return to the base station to re-trigger the working task or re-match visual map points or radar map points. The repositioning of the self-moving device's location and orientation on the map can be achieved using its travel trajectory, without manual intervention, thus improving repositioning efficiency and accuracy. Attached Figure Description

[0088] Figure 1 is a flowchart of a first self-moving device relocation method provided in an embodiment of this specification;

[0089] Figure 2 is a flowchart of a mapping process provided in one embodiment of this specification;

[0090] Figure 3a is a schematic diagram of the driving trajectory of a self-moving device provided in one embodiment of this specification;

[0091] Figure 3b is a schematic diagram of the driving trajectory of another self-moving device provided in one embodiment of this specification;

[0092] Figure 4 is a flowchart of a second self-moving device relocation method provided in one embodiment of this specification;

[0093] Figure 5 is a flowchart of a third self-moving device relocation method provided in one embodiment of this specification;

[0094] Figure 6 is a flowchart of a fourth self-moving device relocation method provided in one embodiment of this specification;

[0095] Figure 7 is a flowchart of a fifth self-moving device relocation method provided in one embodiment of this specification;

[0096] Figure 8 is a flowchart of the relocation method for a self-moving device provided in one embodiment of this specification;

[0097] Figure 9 is a schematic diagram of the structure of a control unit for a first type of self-moving device provided in an embodiment of this specification;

[0098] Figure 10 is a schematic diagram of the structure of a control unit for a second type of self-moving device provided in one embodiment of this specification;

[0099] Figure 11 is a schematic diagram of the structure of a control unit for a third type of self-moving device provided in one embodiment of this specification;

[0100] Figure 12 is a schematic diagram of the structure of the control unit of the fourth self-moving device provided in one embodiment of this specification;

[0101] Figure 13 is a schematic diagram of the structure of the control unit of the fifth self-moving device provided in one embodiment of this specification;

[0102] Figure 14 is a structural block diagram of a self-moving device provided in one embodiment of this specification;

[0103] Figure 15 is a structural block diagram of a working system for a self-moving device provided in one embodiment of this specification. Detailed Implementation

[0104] Many specific details are set forth in the following description to provide a full understanding of this specification. However, this specification can be implemented in many other ways than those described herein, and those skilled in the art can make similar extensions without departing from the spirit of this specification. Therefore, this specification is not limited to the specific implementations disclosed below.

[0105] The terminology used in one or more embodiments of this specification is for the purpose of describing particular embodiments only and is not intended to be limiting of the one or more embodiments of this specification. The singular forms “a” and “the” as used in one or more embodiments of this specification and the appended claims are also intended to include the plural forms, unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used in one or more embodiments of this specification refers to and includes any or all possible combinations of one or more associated listed items.

[0106] It should be understood that although the terms first, second, etc., may be used to describe various information in one or more embodiments of this specification, such information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another. For example, first may also be referred to as second without departing from the scope of one or more embodiments of this specification, and similarly, second may also be referred to as first. Depending on the context, the word "if" as used herein may be interpreted as "when," "when," or "in response to a determination."

[0107] Furthermore, it should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in one or more embodiments of this specification are all information and data authorized by the user or fully authorized by all parties. Moreover, the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions, and corresponding operation entry points are provided for users to choose to authorize or refuse.

[0108] First, the terms and concepts used in one or more embodiments of this specification will be explained.

[0109] RTK (Real-Time Kinematic) technology is a high-precision Global Navigation Satellite System (GNSS) positioning method that improves positioning accuracy by utilizing differential information between a base station at a known location and one or more rover stations. The base station, located at a known precise location, receives signals from satellites and transmits this data to the rover station. The base station is installed at a fixed location and typically uses a high-precision GNSS receiver. It continuously receives signals from satellites and transmits this raw data wirelessly or via wired connection. The rover station also receives signals directly from the same satellites and then combines this data with correction information provided by the base station to calculate a more accurate position. The rover station is carried on the target requiring precise positioning, such as a self-moving device. The rover station is also equipped with a high-precision GNSS receiver to receive satellite signals and perform differential calculations using the data from the base station.

[0110] It should be noted that, taking self-moving devices such as automatic lawnmowers as an example, their precise positioning function is a major highlight. There are various positioning methods for automatic lawnmowers, among which RTK (Real-Time Kinematic) has become the mainstream method due to its high positioning accuracy and reasonable price. RTK-based automatic lawnmowers obtain their current position through satellite signal transmission and calculation. The lawnmower's attitude is detected by its internal IMU (Inertial Measurement Unit) module. After mapping is completed, if the lawnmower is moved after being turned on or off, or after being transported, and the rotation amplitude is small, the IMU module will detect the direction of the lawnmower's offset. However, if the rotation amplitude is large, it will cause a large detection error, resulting in inaccurate orientation detection. In this case, the lawnmower will not trust the pose information detected by the IMU module, so the lawnmower's attitude information needs to be reconfirmed.

[0111] Currently, the automatic lawnmower can be moved back to the charging base station to re-trigger the task, or it can be repositioned by matching visual map points or radar map points. However, this may require manual intervention, which is cumbersome and results in poor repositioning efficiency and accuracy.

[0112] This specification provides a repositioning scheme for an automated mobile device. It eliminates the need for visual or radar assistance by using RTK to reposition an automatic lawnmower. Specifically, it controls the automated mobile device to travel a set distance from its current location, forming a corresponding travel trajectory. The endpoint of the travel trajectory is determined in the target coordinates of the target location in the map coordinate system. Based on the travel trajectory, the target attitude of the automated mobile device is determined. The target coordinates and attitude are used as the repositioning pose of the automated mobile device in the map coordinate system. The target coordinates indicate the location of the automated mobile device on the map, and the target attitude indicates its orientation. The attitude information of the automated mobile device can be calculated using its travel trajectory, thus achieving repositioning. This eliminates the need to move the automatic lawnmower back to the charging base station to re-trigger the task, or to use visual or radar map point matching for repositioning. The repositioning process is simple and convenient, requires no user intervention, and boasts high efficiency and accuracy.

[0113] This specification provides a method for relocating a self-moving device. It also relates to several other methods for relocating self-moving devices, a working system for a self-moving device, another working system for a self-moving device, a self-moving device, a computer-readable storage medium, and a computer program product, which will be described in detail in the following embodiments.

[0114] Referring to Figure 1, Figure 1 shows a flowchart of a first relocation method for a self-moving device according to an embodiment of this specification, applied to the control unit of the self-moving device, specifically including the following steps.

[0115] Step 102: Control the self-moving device to travel a set distance from the current position to form a corresponding driving trajectory.

[0116] Among them, self-moving devices refer to intelligent devices that can move autonomously, such as automatic lawnmowers, robotic vacuum cleaners, robotic floor scrubbers, and food delivery machines. The current location is the current location of the self-moving device, and the set distance is a pre-configured travel distance for repositioning. Since the current location is incorrect or inaccurate, and in order to ensure repositioning efficiency, this set distance is configured to be relatively small.

[0117] In practice, the working area of ​​the self-moving device can be equipped with a positioning benchmark, on which a base station for RTK positioning is deployed. The self-moving device also has a mobile station for RTK positioning deployed on it. When the self-moving device is used for the first time, it needs to map the working area. Specifically, the self-moving device can be manually controlled to traverse the outline of the working area sequentially, or it can explore the outline of the working area in exploration mode. Based on RTK positioning, the RTK coordinates of each location are calculated to build a map of the working area. During the mapping process, the RTK coordinates (longitude, latitude, and altitude (LLA)) of the map coordinate system origin are saved, which are the RTK coordinates corresponding to the map coordinate system origin in the RTK coordinate system. The first transformation matrix T from the RTK coordinate system to the body coordinate system can also be saved.

[0118] For example, Figure 2 is a flowchart of a mapping process provided in one embodiment of this specification. As shown in Figure 2, mapping begins. The outline of the work area can be traversed through manual control and / or exploration mode to perform RTK positioning, build a map, and determine whether the mapping is successful. If not, return to continue mapping; if so, save the RTK coordinates of the map coordinate system origin and the first transformation matrix T from the RTK coordinate system to the body coordinate system.

[0119] It should be noted that after the mapping is completed, if the mobile device is shut down and restarted, the RTK coordinates of the current location of the mobile device will be significantly different from those before shutdown, resulting in a large error in the RTK calculated position. To avoid this situation, after restarting, the current RTK coordinates are recalculated based on the RTK coordinates of the map coordinate system origin saved during mapping. Then, the RTK coordinates are transformed to the body coordinate system according to the first transformation matrix T saved during mapping, and then repositioned in the map.

[0120] It is worth noting that when the self-moving device is picked up, dragged, or powered on outside the base station, the self-moving device's body coordinate system and map coordinate system will be different. At this time, the position and orientation of the self-moving device on the map will be incorrect. However, after RTK relocation, the coordinates of the self-moving device in the map coordinate system will be correct. Therefore, the position and orientation of the self-moving device can be corrected by using the coordinates in the map coordinate system.

[0121] The purpose of relocation is to understand the coordinate position and attitude of the mobile device in the map coordinate system obtained during mapping. The coordinate position is determined based on RTK positioning calculation. RTK positioning is real-time (detection cycle 20Hz - average 20 detections per second). However, based on RTK positioning, only the coordinate position of the mobile device in the map coordinate system can be calculated, and the accurate orientation (attitude) cannot be obtained.

[0122] Therefore, in actual implementation, when the control unit detects that repositioning is required, it can control the self-moving device to travel a set distance from its current position. RTK positioning can locate multiple discrete points during this travel of the set distance to form a corresponding travel trajectory, which makes it easier to determine the orientation (attitude) of the self-moving device based on the travel trajectory.

[0123] It should be noted that this set distance can be a range, controlling the mobile device to travel a certain distance from its current location to form a corresponding travel trajectory, which is then used directly for repositioning. Alternatively, at least one positioning point can be configured within the set distance. This positioning point is used for a rough positioning calculation; that is, the mobile device can first be controlled to travel to the positioning point to obtain the trajectory before that point, and then the mobile device can continue to travel to obtain the trajectory after that point. In other words, a set distance for repositioning can be planned, with at least one positioning point configured within the set distance. By combining the trajectory before and after each positioning point, repositioning can be achieved.

[0124] In one optional implementation of this embodiment, taking the configuration of a target positioning point within a set distance as an example, controlling the self-moving device to travel a set distance from its current position to form a corresponding travel trajectory includes:

[0125] Control the mobile device to travel from its current location to the target location, forming a corresponding first driving trajectory;

[0126] Control the self-moving device to continue driving from the target location point, forming a corresponding second driving trajectory.

[0127] The first driving trajectory is the trajectory before the target positioning point, and the second driving trajectory is the trajectory after the target positioning point. The movement of the self-moving device is divided into two stages for repositioning. It can be understood that after forming the corresponding first driving trajectory, the self-moving device continues to move from the target positioning point. During this process, a corresponding Nth driving trajectory can be formed, which is the trajectory after the target positioning point. Dividing the movement of the self-moving device into multiple stages for repositioning allows for more accurate calculation of the self-moving device's attitude information.

[0128] In actual implementation, the self-moving device can be controlled to travel from its current position to the target positioning point in a set posture, and the trajectory before the target positioning point can be obtained as the first driving trajectory. Then, the self-moving device can be controlled to continue traveling from the target positioning point. After traveling a set distance, the trajectory after the target positioning point can be obtained as the second driving trajectory.

[0129] For example, assuming the distance is set to 3m and the target positioning point is the position point 0.8m away, the self-moving device can be controlled to move from the current position to the position point 0.8m to obtain the first driving trajectory, and then continue to move from the position point 0.8m. After the journey is completed, the second driving trajectory is obtained.

[0130] It should be noted that by configuring a distance point for positioning calculation within a set distance, the driving trajectory can be divided into two segments. These two segments can then be combined or optimized to determine an accurate pose over the shortest possible distance. For example, one optimization could be to use the first segment of the driving trajectory for coarse positioning, and then use both segments for precise positioning, quickly providing the self-moving device with an initial approximate pose, improving efficiency and ensuring accuracy. Another optimization could be to determine a pose based solely on the first segment and another based on the second segment, comparing the two poses and taking the average, or to progressively correct the pose segment by segment, or other optimization methods.

[0131] The set attitude is a pre-configured repositioning driving attitude. For example, the set attitude can be the attitude of the current position, that is, the attitude of the self-moving device before repositioning, or it can be directly configured to be the attitude corresponding to forward straight driving.

[0132] For example, Figure 3a is a schematic diagram of the driving trajectory of a self-moving device provided in an embodiment of this specification. As shown in Figure 3a, assuming that the self-moving device is moved from its original position to a target position, which is the current position that needs to be repositioned, the self-moving device is controlled to drive from the current position along the set driving path in its original posture to the target positioning point to obtain a first driving trajectory. Then, the self-moving device is controlled to continue driving from the target positioning point to obtain a second driving trajectory.

[0133] For example, Figure 3b is a schematic diagram of the driving trajectory of another self-moving device provided in an embodiment of this specification. As shown in Figure 3b, assuming that the self-moving device is moved from its original position to a target position, which is the current position that needs to be repositioned, the self-moving device is controlled to move forward in a straight line from the current position to the target positioning point to obtain a first driving trajectory. Then, the self-moving device is controlled to continue moving forward in a straight line from the target positioning point to obtain a second driving trajectory.

[0134] In the embodiments of this specification, the self-moving device can first be controlled to travel from its current position to the target positioning point to obtain a first driving trajectory. Then, the self-moving device can be controlled to continue traveling a certain distance from the target positioning point to form a corresponding second driving trajectory. Through multiple driving segments, the attitude of the self-moving device can be gradually corrected, avoiding the safety problem of hitting obstacles due to traveling a long distance at once, and also avoiding the problem of inaccurate repositioning due to traveling a short distance. It can improve the accuracy of repositioning while ensuring safe driving.

[0135] In one optional implementation of this embodiment, a target positioning point is configured at a set distance;

[0136] Among these, controlling the self-moving device to travel a set distance from its current location to form a corresponding travel trajectory includes:

[0137] Control the self-moving device to travel from the current location to the target location point, forming a corresponding first driving trajectory; control the self-moving device to continue traveling from the target location point, forming corresponding N driving trajectories, where N is greater than or equal to two;

[0138] The step of determining the target posture of the self-moving device based on the driving trajectory includes: determining the target posture of the self-moving device based on the first driving trajectory and / or the N segments of driving trajectory.

[0139] It should be noted that after controlling the self-moving device to travel from its current location to the target location and forming the corresponding first driving trajectory, the self-moving device can be controlled to continue traveling from the target location. During the continued travel, N corresponding driving trajectories can be formed. Combining the first driving trajectory formed before the target location and the N driving trajectories generated after the target location, the self-moving device can be repositioned. The accuracy of repositioning is improved by using the driving trajectory before the target location and the multiple driving trajectories after the target location.

[0140] In one optional implementation of this embodiment, the path length of the second driving trajectory is greater than or equal to the path length of the first driving trajectory.

[0141] It should be noted that a target positioning point can be configured in the first half of the set distance, that is, the path length of the second driving trajectory is greater than or equal to the path length of the first driving trajectory. In the event of a positioning error, the location of the self-moving device on the map is unknown. For safety, the self-moving device is first controlled to travel as short a distance as possible to achieve a rough positioning, and then the self-moving device is controlled to travel a relatively longer distance to perform correction and ensure the accuracy of repositioning.

[0142] In one optional implementation, the target positioning point can be configured based on the lengths of the two required trajectory segments. For example, the path length of the first driving trajectory can be configured to a value between 0.3m and 1m, and the path length of the second driving trajectory can be configured to a value between 1m and 3m. For instance, if the path length of the first driving trajectory is 0.8m and the path length of the second driving trajectory is 1.6m, meaning the set distance is 2.4m, the target positioning point is located at 0.8m. Alternatively, the set distance can be configured first, and then a point within the first half of the set distance can be selected as the target positioning point. Assuming the set distance is 2.4m, any point between 0 and 1.2m can be selected as the target positioning point.

[0143] In practice, the orientation of the self-moving device can be determined by its travel trajectory. The farther the trajectory, the more accurate the positioning. However, the self-moving device does not know its orientation at this time, which is unsafe. Therefore, it is necessary to locate the device by traveling the shortest possible distance. However, short trajectory positioning may lead to large errors. When repositioning the self-moving device's coordinates and attitude in the map coordinate system, the self-moving device can be controlled to travel a short distance to the target positioning point to obtain a short trajectory s1. To ensure the safety of the self-moving device, the travel distance should be minimized in the event of a positioning error. Therefore, a coarse repositioning should be performed as soon as possible based on s1 (e.g., the path length of s1 is 0.8m). After coarse repositioning correction, in order to reduce the repositioning error, the self-moving device can be controlled to travel a slightly longer distance to obtain a longer travel trajectory s2 (e.g., the path length of s2 is 1.6m) before a fine repositioning is performed. This achieves fast repositioning while ensuring repositioning accuracy.

[0144] In the embodiments of this specification, the path length of the second driving trajectory can be configured to be greater than or equal to the path length of the first driving trajectory. When repositioning the self-moving device, if a positioning error occurs, the self-moving device can be controlled to travel a small distance for coarse repositioning. After coarse repositioning, the self-moving device can be controlled to travel a relatively longer distance for fine repositioning, thereby reducing the repositioning error and achieving fast repositioning while ensuring repositioning accuracy.

[0145] Of course, in actual implementation, the relationship between the path length of the second driving trajectory and the path length of the first driving trajectory can be unrestricted, or more segments of trajectory can be used to achieve repositioning. For example, first control the self-moving device to travel a certain distance from the current position to the first positioning point to obtain the first driving trajectory, then control the self-moving device to continue traveling a certain distance from the positioning point to the second positioning point to form the corresponding second driving trajectory, and then control the self-moving device to continue traveling. Through multiple segments of travel, the attitude of the self-moving device can be gradually corrected.

[0146] For example, as shown in Figures 3a and 3b, the first driving trajectory and the second driving trajectory are two driving trajectories obtained by traveling two distances respectively. The path length of the second driving trajectory can be greater than or equal to the path length of the first driving trajectory.

[0147] In one optional implementation of this embodiment, after controlling the self-moving device to travel from its current location to the target positioning point and forming a corresponding first driving trajectory, the method further includes:

[0148] The initial attitude of the self-moving device is determined based on the first driving trajectory;

[0149] Accordingly, the self-moving device is controlled to continue traveling from the target location point, forming a corresponding second driving trajectory, including:

[0150] Based on the initial attitude, the self-moving device is controlled to continue moving from the target positioning point, forming a corresponding second driving trajectory.

[0151] The initial attitude refers to the attitude obtained by coarse positioning after traveling the first distance. This attitude can refer to the orientation of the self-moving device, such as azimuth angle, direction, etc.

[0152] In practice, after controlling the self-moving device to travel from its current location to the target location and forming a corresponding first travel trajectory, the initial attitude, or rough orientation, of the self-moving device can be determined based on the first travel trajectory. Then, the self-moving device is controlled to continue traveling from the target location according to the calculated initial attitude, forming a corresponding second travel trajectory.

[0153] Specifically, the starting and ending points of the first driving trajectory can be determined, along with their coordinates. These coordinates must correspond to the same coordinate system, such as the RTK coordinate system, the aircraft's coordinate system, or the map coordinate system. If they correspond to different coordinate systems, the starting and ending points can be transformed to the same system. Then, based on the starting and ending point coordinates, the azimuth angle between the two points is calculated to obtain the initial attitude corresponding to the first driving trajectory.

[0154] In the embodiments of this specification, before repositioning, the self-moving device cannot determine its direction of travel because it is unaware of its own attitude information. At this time, the self-moving device is in a state of distrust regarding the navigation it is about to undertake. In order to determine the attitude of the self-moving device through the shortest possible travel distance trajectory, the self-moving device can first travel a first segment of the path to the target positioning point. Based on the first travel trajectory of the first segment of the path, the initial attitude (i.e., rough orientation) of the self-moving device is obtained, and a rough attitude direction is quickly given. Subsequently, the self-moving device uses this rough orientation as the orientation reference of the self-moving device's odometer. However, since the position of the rough orientation is only a general orientation, in order to obtain the orientation information of the self-moving device more accurately, the self-moving device continues to travel from the target positioning point to obtain a second segment of the travel trajectory. The initial attitude (i.e., rough orientation) of the self-moving device is further calibrated using the second segment of the path traveled after the target positioning point and the entire travel trajectory of the first segment of the path traveled before, to obtain a precise target attitude. At the same time, the precise attitude information is used as the orientation reference of the self-moving device's odometer.

[0155] Correspondingly, users can observe the repositioning process of the self-device through the map interface that interacts with the device. When the self-device completes coarse positioning, its approximate location and orientation will be displayed on the map. After fine positioning, users will notice that the points on the map are updated; those with larger errors in coarse and fine positioning show larger fluctuations after the update, while those with smaller errors show smaller fluctuations. A segmented control optimization method is adopted to progressively optimize and determine the self-device's attitude, improving repositioning accuracy while ensuring safety.

[0156] In one optional implementation of this embodiment, controlling the self-moving device to travel from its current location to the target positioning point, forming a corresponding first driving trajectory, includes:

[0157] Control the self-moving device to travel from its current position along a straight line in its original posture to the target positioning point, where the original posture is the posture of the self-moving device before repositioning;

[0158] Accordingly, the self-moving device is controlled to continue traveling from the target location point, forming a corresponding second driving trajectory, including:

[0159] Control the self-moving device to continue traveling from the target positioning point in its original posture and along a straight line, forming a corresponding second driving trajectory.

[0160] In actual implementation, in addition to the above-mentioned implementation method of obtaining the first driving trajectory based on the first distance traveled to the target positioning point, obtaining the initial posture through coarse positioning, and continuing to drive based on the initial posture of coarse positioning, it is also possible to control the self-moving device to drive from the current position along a straight line in the original posture to the target positioning point, and then control the self-moving device to continue driving from the target positioning point in the original posture along a straight line to form the corresponding second driving trajectory.

[0161] It should be noted that the self-moving device can be controlled to travel two distances along the same straight line in its original posture. Both distances are traveled in the same straight line in the original posture. The self-moving device is controlled to travel in the same posture and direction. Before accurate repositioning is obtained, the original posture and straight line are used to avoid safety issues caused by positioning errors and to ensure the safety of the self-moving device during the repositioning process as much as possible.

[0162] In one optional implementation of this embodiment, after controlling the self-moving device to travel from its current location to the target positioning point and forming a corresponding first driving trajectory, the method further includes:

[0163] Based on the first driving trajectory, the initial pose of the self-moving device in the map coordinate system is determined, wherein the initial pose includes the initial coordinates and the initial attitude.

[0164] Accordingly, the self-moving device is controlled to continue traveling from the target location point, forming a corresponding second driving trajectory, including:

[0165] Based on the initial pose, the self-moving device is controlled to continue moving from the target positioning point, perform subsequent tasks, and form a corresponding second driving trajectory.

[0166] In one optional implementation of this embodiment, the trajectory path for performing subsequent tasks includes at least a portion of the second driving trajectory.

[0167] In actual implementation, after controlling the self-moving device to travel from its current location to the target positioning point and forming the corresponding first driving trajectory, the initial coordinates and initial attitude of the self-moving device in the map coordinate system can be determined based on the first driving trajectory to complete the coarse repositioning. Then, based on the initial coordinates and initial attitude obtained from the coarse repositioning, subsequent tasks can be executed. The second driving trajectory is obtained from the trajectory path of the subsequent tasks, that is, a part of the trajectory path of the subsequent tasks is obtained as the second driving trajectory to achieve fine positioning. The second driving trajectory is located on the trajectory path of the subsequent tasks.

[0168] Specifically, a portion of the trajectory path of the subsequent task can be selected as the second driving trajectory, or a portion of the driving trajectory corresponding to the initial stage (within a set time) of executing the subsequent task can be selected as the second driving trajectory, and then fine repositioning can be performed based on the second driving trajectory.

[0169] It should be noted that when a mobile device travels to the target location, it can obtain a first driving trajectory. Based on this first driving trajectory, coarse repositioning can be performed to determine the initial pose of the mobile device in the map coordinate system and give a general orientation. Then, based on the coarse repositioning, the initial pose can be obtained. The mobile device's odometer can start to execute subsequent tasks based on this general orientation. A part of the trajectory path of the subsequent tasks is used as the second driving trajectory. The second driving trajectory is used to calibrate the orientation of the coarse repositioning, and then calibrate the starting point of the odometer and the navigation information determined based on the starting point of the odometer. The repositioning is fast and efficient.

[0170] Specifically, based on the first driving trajectory, the initial pose of the self-moving device in the map coordinate system is determined. The starting point and ending point of the first driving trajectory can be determined first. The azimuth angle between the two points is calculated based on the starting point and ending point to obtain the initial pose corresponding to the first driving trajectory. When calculating the initial pose, the coordinates of the starting point and the ending point correspond to the same coordinate system.

[0171] In actual implementation, after controlling the self-moving device to travel a first distance and forming the corresponding first driving trajectory, the coordinates of each position in the body coordinate system and the map coordinate system during the driving process can be aligned according to the timestamp. The second transformation matrix T1' from the body coordinate system to the map coordinate system is solved using the least squares method. After determining the trajectory endpoint of the first driving trajectory, the RTK positioning coordinates of the trajectory endpoint can be determined. Combined with the RTK coordinate system origin saved after mapping, the RTK coordinates of the trajectory endpoint in the RTK coordinate system are recalculated. Then, based on the first transformation matrix T from the RTK coordinate system to the body coordinate system saved after mapping, the RTK coordinates in the RTK coordinate system are transformed to the body coordinate system to obtain the mileage coordinates of the trajectory endpoint in the body coordinate system. Finally, based on the second transformation matrix T1' from the body coordinate system to the map coordinate system, the mileage coordinates of the trajectory endpoint in the body coordinate system are transformed to the map coordinate system to obtain the initial coordinates of the trajectory endpoint in the map coordinate system.

[0172] The obtained initial coordinates and initial pose are used as the initial pose obtained by coarse repositioning based on the first driving trajectory. Subsequent tasks are then executed starting from this initial pose. At the initial node of the subsequent task, a second distance is traveled, and fine repositioning is achieved based on the second distance.

[0173] In the embodiments of this specification, coarse repositioning can be performed based on the first driving trajectory before the target positioning point to obtain the initial attitude. Then, the self-moving device can be directly controlled to start executing subsequent tasks with the initial attitude. A part of the trajectory path of the subsequent tasks is used as the second driving trajectory. The orientation of the coarse repositioning is then calibrated using the second driving trajectory to perform fine repositioning. Repositioning is achieved efficiently by traveling a shorter distance, reducing the driving distance for repositioning and improving the efficiency of repositioning.

[0174] Of course, in actual implementation, the driving trajectory after the target positioning point may not be integrated into the process of executing subsequent tasks. Instead, the positioning of the two trajectories may be completed first, and then the subsequent tasks may be executed. This specification does not limit this.

[0175] Step 104: Determine the target coordinates of the end point of the driving trajectory in the map coordinate system.

[0176] It should be noted that, for a single driving trajectory, the endpoint of the trajectory is the endpoint of the set driving distance; for at least two driving trajectories, the endpoint of the trajectory is the endpoint of the last driving trajectory. For example, if a first driving trajectory is obtained by driving a certain distance to a target location, and then a second driving trajectory is obtained by continuing from the target location, the endpoint of the second driving trajectory is the endpoint of the second driving trajectory after driving a certain distance.

[0177] In actual implementation, after controlling the self-moving device to travel a set distance and forming the corresponding driving trajectory, the coordinates of each position in the body coordinate system and the map coordinate system during the driving process can be aligned according to the timestamp. The second transformation matrix T' from the body coordinate system to the map coordinate system is solved by the least squares method. Subsequently, the mileage coordinates of the self-moving device in the body coordinate system can be transformed by the second transformation matrix T' and then output, so that the mileage coordinates in the body coordinate system can be repositioned to the map coordinate system.

[0178] In one optional implementation, if a target positioning point is configured at a set distance, after controlling the self-moving device to travel to the target positioning point and forming the corresponding first driving trajectory, the coordinates of each position in the body coordinate system and the map coordinate system during the driving process can be aligned according to the timestamp. The second transformation matrix T1' from the body coordinate system to the map coordinate system is solved using the least squares method. Due to the small driving distance, the error of this second transformation matrix is ​​relatively large, but it can quickly reposition the self-moving device to the map coordinate system. Then, the self-moving device continues to travel from the target positioning point and forms the corresponding second driving trajectory. The coordinates of each position in the body coordinate system and the map coordinate system during the driving process can be aligned according to the timestamp. The second transformation matrix T2' from the body coordinate system to the map coordinate system is solved using the least squares method. As the driving distance of the self-moving device increases, the second transformation matrix T2' from the body coordinate system to the map coordinate system is solved again. Subsequently, each mileage coordinate in the body coordinate system can be repositioned to the map coordinate system through this second transformation matrix T2', which can improve the repositioning accuracy.

[0179] In practical applications, the RTK coordinates of the endpoint of the driving trajectory can be determined. Combined with the RTK coordinate system origin saved after mapping, the RTK coordinates of the endpoint in the RTK coordinate system are recalculated. Then, based on the first transformation matrix T from the RTK coordinate system to the body coordinate system saved after mapping, the RTK coordinates in the RTK coordinate system are transformed to the body coordinate system, obtaining the mileage coordinates of the endpoint in the body coordinate system. Then, based on the second transformation matrix from the body coordinate system to the map coordinate system (if a certain distance has been traveled, it is the second transformation matrix T'; if the first and second distances have been traveled, it is the second transformation matrix T2'), the mileage coordinates of the endpoint in the body coordinate system are transformed to the map coordinate system, obtaining the target coordinates of the endpoint in the map coordinate system.

[0180] It should be noted that the RTK coordinates of the end point of the driving trajectory in the RTK coordinate system are obtained based on RTK positioning. The RTK coordinates are then transformed to the body coordinate system to obtain the mileage coordinates. The mileage coordinates are then transformed to the map coordinate system to obtain the target coordinates of the end point of the driving trajectory in the map coordinate system. These target coordinates are the coordinates for repositioning to the map, thus realizing the repositioning of the self-moving device in the map coordinate system.

[0181] Step 106: Determine the target pose of the self-moving device based on the driving trajectory, and use the target coordinates and target pose as the repositioning pose of the self-moving device in the map coordinate system.

[0182] It should be noted that the repositioning pose in the map coordinate system can include coordinates and attitude. Based on RTK positioning and coordinate transformation of the end position of the driving trajectory, the target coordinates of the repositioning can be obtained. The target attitude of the self-moving device can be determined according to the driving trajectory, thus completing the repositioning of the self-moving device.

[0183] In one optional implementation of this embodiment, determining the target attitude of the self-moving device based on the driving trajectory includes:

[0184] The target attitude of the self-moving device is determined based on the first driving trajectory and / or the second driving trajectory.

[0185] It should be noted that if the self-moving device is controlled to travel a set distance of one segment, the target attitude of the self-moving device can be calculated based on that segment of the travel trajectory. If the self-moving device is controlled to travel a set distance of two or more segments, that is, if a target positioning point is configured at the set distance, the target attitude of the self-moving device can be calculated by combining the travel trajectories corresponding to the multiple travel segments. For example, if a target positioning point is configured at the set distance, the target attitude of the self-moving device can be determined by combining the first travel trajectory before the target positioning point and / or the second travel trajectory after the target positioning point.

[0186] In the embodiments described in this specification, the target posture of the self-moving device can be gradually corrected through multiple segments of driving, avoiding the safety problem of hitting obstacles due to driving a long distance at once, and also avoiding the problem of inaccurate repositioning due to driving a short distance. It can improve the accuracy of repositioning while ensuring safe driving.

[0187] In one optional implementation of this embodiment, determining the target attitude of the self-moving device based on the first driving trajectory and / or the second driving trajectory includes:

[0188] Determine the starting position of the first driving trajectory and the ending position of the second driving trajectory;

[0189] The target posture of the self-moving device is determined based on the starting position of the first driving trajectory and the ending position of the second driving trajectory.

[0190] It should be noted that if the self-moving device is controlled to travel a set distance and a corresponding travel trajectory is obtained, the target attitude of the self-moving device can be calculated based on the starting and ending positions of the travel trajectory. If a target positioning point is configured at the set distance and a first travel trajectory before the target positioning point and a second travel trajectory after the target positioning point are obtained, the starting position of the first travel trajectory and the ending position of the second travel trajectory can be determined. Then, the target attitude of the self-moving device can be determined based on the starting position of the first travel trajectory and the ending position of the second travel trajectory.

[0191] In actual implementation, the starting coordinates of the starting point of the first driving trajectory and the ending coordinates of the ending point of the second driving trajectory can be determined. The starting coordinates and the ending coordinates correspond to the same coordinate system, which can be the RTK coordinate system, the body coordinate system, or the map coordinate system. If they correspond to different coordinate systems, the starting coordinates and the ending coordinates can be transformed to the same coordinate system. The azimuth angle between the two points is calculated based on the starting coordinates and the ending coordinates, and the azimuth angle is used as the target attitude of the self-moving device.

[0192] For example, considering the starting point of the first driving trajectory and the ending point of the second driving trajectory, the azimuth angle can be calculated using the latitude and longitude in the RTK coordinate system. Assume the starting point of the first driving trajectory is P1, with latitude and longitude of (lat1, lon1) in the RTK coordinate system, and the ending point of the second driving trajectory is P2, with latitude and longitude of (lat2, lon2) in the RTK coordinate system. The azimuth angle can then be calculated using the following formula (1) to obtain the target attitude of the self-moving device.

[0193] Δφ=lat2-lat1

[0194] Δλ=lon2-lon1

[0195] y = sin(Δλ)·cos(lat2)

[0196] x=cos(lat1)·sin(lat2)-sin(lat1)·cos(lat2)·cos(Δλ)

[0197] θ = arctan 2(y, x) (1)

[0198] Wherein, θ is the azimuth angle calculated based on the starting point RTK coordinates P1(lat1, lon1) and the ending point RTK coordinates P2(lat2, lon2), which is the target attitude of the self-moving device. This θ is calculated clockwise with east as the positive direction as an example. In actual implementation, other directions can be defined as the positive direction.

[0199] In the embodiments of this specification, no vision or radar assistance is required. The repositioning of the automatic lawnmower is achieved through RTK. When repositioning the position and orientation of the automatic lawnmower, the automatic lawnmower can be controlled to move a small distance to obtain a first travel trajectory in the event of a positioning error. Then, the automatic mobile device is controlled to move a longer distance to obtain a second travel trajectory. The repositioning orientation of the automatic mobile device is calibrated by using the end point of the second travel trajectory and the starting point of the first travel trajectory, so as to achieve rapid repositioning while ensuring repositioning accuracy.

[0200] In addition to determining the target attitude of the self-moving device based on the starting position of the first driving trajectory and the ending position of the second driving trajectory, other methods can be used to determine the target attitude of the self-moving device by combining the first and second driving trajectories. For example, an attitude can be determined based on the first driving trajectory alone, and another attitude can be determined based on the second driving trajectory. The two attitudes are then compared, and the average attitude is taken. Alternatively, the target attitude of the self-moving device can be determined based on either the first or second driving trajectory alone. For example, the corresponding attitude can be calculated for each segment of the driving trajectory, and the attitude can be corrected segment by segment. For instance, an attitude can be calculated based on the first driving trajectory, and another attitude can be calculated based on the second driving trajectory. This second attitude is then replaced with the attitude calculated based on the first driving trajectory, and the calculated attitude is continuously corrected.

[0201] In one optional embodiment of this invention, the self-moving device is equipped with an odometer sensor, which is used to record parameters of the self-moving device during its travel; determining the target attitude of the self-moving device based on the travel trajectory includes:

[0202] The target attitude of the self-moving device is determined based on the driving trajectory and parameters recorded by the mileage sensor.

[0203] An odometer is a device used to measure the displacement and orientation changes of a self-moving device relative to its starting position. It estimates the linear displacement and angular changes of the self-moving device by tracking the rotation of wheels or the movements of other moving parts. Odometry sensors may include wheel encoders, inertial measurement units (IMUs), visual odometers (VOs), and lidar odometers. An inertial measurement unit (IMU) may include a three-axis accelerometer, a three-axis gyroscope, and a three-axis magnetometer.

[0204] It should be noted that the self-moving device can be equipped with an odometer sensor, which can record parameters of the self-moving device's driving process, such as the rotation angle or number of wheel rotations, linear acceleration and angular velocity information, and other sensor data.

[0205] In practical implementation, the target attitude of the repositioned mobile device can be calculated by combining the parameters of the driving trajectory and the odometer. Specifically, the first attitude of the mobile device can be determined based on the parameters of its odometer, such as obtaining the first attitude based on the three-axis gyroscope detection in the inertial measurement unit (IMU). Furthermore, the second attitude of the mobile device can be determined based on the driving trajectory, such as calculating the azimuth angle based on the start and end points of the trajectory. Then, the target attitude of the mobile device is calculated by combining the first and second attitudes.

[0206] As an example, if the angle difference between the first attitude and the second attitude is within the angle threshold, the first attitude determined by the parameters recorded by the odometer of the self-moving device is used as the final target attitude; if it is not within the angle threshold, it means that the attitudes are significantly different, and the second attitude determined by the driving trajectory can be used as the final target attitude, or repositioning can be performed again.

[0207] Of course, in actual implementation, other combinations can also be used to obtain the target attitude of the self-moving device by combining the first attitude determined by the parameters recorded by the odometer of the self-moving device and the second attitude determined by the driving trajectory, which can be used as the orientation obtained by repositioning. The embodiments in this specification do not limit this.

[0208] In the embodiments of this specification, the target attitude of the self-moving device can be determined by combining the driving trajectory and the parameters recorded by the odometer. In addition to the driving trajectory, the parameters recorded by the odometer of the self-moving device can also be introduced to further improve the accuracy of the attitude during the repositioning process.

[0209] In an optional implementation of this embodiment, after using the target coordinates and target pose as the repositioning pose of the self-moving device in the map coordinate system, the method further includes:

[0210] Based on the repositioning pose and the pre-built map, determine whether the self-moving device is located in the map area;

[0211] If not, then issue an out-of-bounds warning.

[0212] In practice, when relocating a self-moving device, the device can be controlled to travel a set distance. Relocation in the map coordinate system is achieved based on the travel trajectory. If the self-moving device encounters an obstacle or is identified by AI as being in a non-working area during the travel of the set distance, the relocation is considered to have failed. If no relocation success signal is received after traveling the set distance, the relocation is considered to have failed. Alternatively, if no relocation success signal is received within a set time period, the relocation is also considered to have failed. This set time period can be configured based on the duration required for relocation and is often configured to be a short time, such as 10 seconds, 30 seconds, or 1 minute.

[0213] In practice, if the self-moving device fails to relocate, it will stop moving and issue an alarm, prompting the user to check or repair it. If the self-moving device successfully relocates, it can determine whether the self-moving device is within the map area based on the relocated pose and the pre-built map, that is, whether the self-moving device is still within its working area. If so, it will continue to perform its work tasks; if not, it will issue an out-of-bounds alarm, reminding the user that the self-moving device is outside the map and cannot work, and instructing the user to check it.

[0214] It should be noted that after the self-moving device is successfully relocated, it can also determine whether the self-moving device is within the map based on the correct location. If it is within the map, the work task continues to be executed; otherwise, an alarm is triggered to terminate the task due to out-of-bounds movement. This avoids the self-moving device being damaged if it is relocated outside the map and the work task is executed. This ensures the safety of the self-moving device when executing work tasks after relocation.

[0215] This specification provides a method for repositioning a self-moving device. If the self-moving device loses its location on a map, it can be controlled to travel a set distance from its current position to locate the target coordinates of the endpoint of its travel trajectory in the map coordinate system. Furthermore, based on the travel trajectory after the set distance, the target posture of the self-moving device can be determined. The target coordinates indicate the self-moving device's position on the map, and the target posture indicates its orientation. This allows for the repositioning of the self-moving device on the map without needing to return to the base station to re-trigger the task or re-match visual or radar map points. The repositioning of the self-moving device's position and orientation on the map can be achieved using its travel trajectory, without manual intervention, thus improving repositioning efficiency and accuracy.

[0216] Referring to Figure 4, which shows a flowchart of a second relocation method for a self-moving device according to an embodiment of this specification, applied to the control unit of the self-moving device, specifically including the following steps.

[0217] Step 402: In response to the relocation event, control the self-moving device to travel a set distance from the current position to form a corresponding travel trajectory. The relocation event includes at least one of the following: the self-moving device is moved or the self-moving device is restarted.

[0218] It should be noted that, in response to a relocation event triggered by the self-moving device, the control unit can control the self-moving device to travel a set distance from its current position to form a corresponding travel trajectory, and then relocate the self-moving device based on the travel trajectory.

[0219] The relocation event is an event triggered when the location of the self-moving device is lost in the map coordinate system. The relocation event includes at least one of the following: the self-moving device is moved, or the self-moving device is restarted. Moving the self-moving device can include moving it after it has been turned off and then turned on again, or dragging it to another location during a task pause. Restarting the self-moving device can include restarting the self-moving device after it crashes, restarting in response to a power off / on operation, or turning it on outside the base station.

[0220] In practical implementation, the self-moving device can be equipped with a movement detection unit, which can be a gravity sensor. When the self-moving device is placed on the ground, its gravity sensor can detect a first gravity value. When the self-moving device is lifted, the gravity value detected by the gravity sensor changes, becoming a second gravity value. That is, if the control unit detects that the gravity value detected by the gravity sensor changes from the first gravity value to the second gravity value, it can determine that the self-moving device has been moved. Alternatively, the movement detection unit can also be a mechanical structure. For example, when the self-moving device is placed on the ground, this mechanical structure protrudes; when the self-moving device is lifted, the mechanical structure retracts, triggering a movement electrical signal fed back to the control unit. When the control unit receives this electrical signal, it can determine that the self-moving device has been moved. When the self-moving device is moved, it may lose its position in the map coordinate system, triggering a relocation event.

[0221] Of course, in practice, other methods can also be used to detect whether the self-moving device has been moved. No specific limitations are made here. For example, a three-axis accelerometer in an IMU can be used to monitor the linear acceleration change of the self-moving device. When the self-moving device is stationary on the ground, the acceleration along the Z-axis should be close to the acceleration due to gravity (9.8 m / s²). 2 If the self-moving device is lifted, the Z-axis acceleration will deviate significantly from this value; alternatively, a three-axis gyroscope in the IMU can be used to monitor changes in angular velocity. When the self-moving device is lifted, there is usually a large change in angle, which will cause the gyroscope to output a non-zero angular velocity value.

[0222] Specifically, the power-on location of the self-moving device can be determined based on RTK technology. If the power-on location is compared with the base station location, and they are inconsistent, it means that the self-moving device was powered on outside the base station and may lose its position in the map coordinate system, triggering a relocation event.

[0223] In addition, the self-device may lose its position in the map coordinate system after crashing and restarting. Therefore, the control unit can also monitor the power on and off status of the self-device. If a crash and restart are detected, a relocation event will be triggered.

[0224] Furthermore, if the self-moving device is dragged to another location during the task pause period, the control unit will not know where the user dragged the self-moving device, resulting in the loss of the self-moving device's position in the map coordinate system, which can trigger a relocation event. Specifically, during the task pause period of the self-moving device, it can be detected whether the self-moving device has been moved, and the specific detection method can be the same as described above. If so, a relocation event is triggered.

[0225] It should be noted that a relocation event can be triggered based on at least one scenario, such as whether the self-moving device has been moved or restarted. The relocation event can be triggered in a variety of scenarios, which can adapt to various scenarios where the location in the map is lost, ensuring that the relocation coverage scenarios are more comprehensive.

[0226] Step 404: Determine the target coordinates of the end point of the driving trajectory in the map coordinate system.

[0227] Step 406: Determine the target pose of the self-moving device based on the driving trajectory, and use the target coordinates and target pose as the repositioning pose of the self-moving device in the map coordinate system.

[0228] It should be noted that the specific implementation process of "controlling the self-moving device to travel a set distance from the current position to form a corresponding driving trajectory" in step 402 above is similar to the specific implementation process of step 102 above. The specific implementation processes of steps 404-406 are similar to the specific implementation processes of steps 104-106 above. For details, please refer to the above description. This specification does not limit the embodiments in this way.

[0229] This specification provides a relocation method for a self-moving device. Responding to relocation events triggered by at least one of the following scenarios: the self-moving device is moved, the self-moving device is powered on outside a base station, the self-moving device restarts, or the self-moving device is dragged to another location during a task pause, the method utilizes the self-moving device's trajectory to relocate its position and orientation on a map. The relocation event triggering scenarios are diverse, adaptable to various scenarios where the device's position on the map is lost, ensuring more comprehensive relocation coverage. Furthermore, it eliminates the need to move the device back to the base station to re-trigger the task, re-match visual map points or radar map points, and requires no manual intervention, thus improving relocation efficiency and accuracy.

[0230] Referring to Figure 5, which illustrates a flowchart of a third relocation method for a self-moving device according to an embodiment of this specification, the self-moving device is equipped with a visual sensor, a positioning device, and a control unit. The visual sensor is positioned at the front of the self-moving device along its normal travel direction and is used to identify environmental information in the area in front of the self-moving device. The positioning device includes a positioning tag for communicating with a satellite and at least one positioning beacon located outside the self-moving device. The position of the self-moving device is obtained based on the differential information between the at least one positioning beacon at a known location and the positioning tag. This method is applied to the control unit of the self-moving device and specifically includes the following steps.

[0231] Step 502: In response to the self-moving device being moved and / or the self-moving device being powered on again after being powered off, a relocation event is triggered.

[0232] It should be noted that in one user scenario, taking a lawnmower as an example of a self-moving device, after the user completes the mapping using the lawnmower, the user can see the completed map on the display device. Users want to start mowing with a lawnmower. To avoid accidents, they first turn off the lawnmower, then move it to the desired area and turn it on. At this point, the lawnmower's positioning device begins to locate itself, and the display shows the lawnmower's position on the map. However, the odometer (such as an IMU unit) cannot obtain the lawnmower's attitude at this time. The display uses data saved by the odometer before the lawnmower was turned off to show the lawnmower's attitude. Since the lawnmower's attitude changes after being moved, if the lawnmower starts its subsequent work immediately, the user can see through the display that the position change and orientation displayed do not match. Alternatively, during the lawnmower's movement after starting its work, its orientation gradually changes (the degree of gradualness depends on the refresh rate of the positioning device) in the direction of the position change, making it impossible to accurately display the lawnmower's position and attitude on the display. This not only degrades the user experience but also leads to incorrect navigation path planning when the lawnmower starts its subsequent work.

[0233] In actual implementation, in order to solve the problem of loss of posture when the self-moving device is moved or / or restarted after being turned off, the self-moving device will trigger a relocation event after being moved or / or restarted after being turned off, and re-position itself to obtain the posture of the self-moving device.

[0234] Step 504: In response to the relocation event, determine the trust status of the area in front of the self-moving device through the vision sensor, control the self-moving device to travel a set distance to the trusted area in front, and form a corresponding driving trajectory according to the positioning device.

[0235] Specifically, the vision sensor is positioned at the front of the self-moving device along its normal travel direction. The vision sensor is used to identify environmental information such as obstacles, grassy areas, and non-grassy areas in front of the self-moving device. Trust status refers to the safety of the area in front of the self-moving device, such as the presence of obstacles, whether it is a dangerous area (e.g., an edge), or an impassable area (e.g., a wall, fence). A trusted front area means that the self-moving device can travel in this area without causing a safety accident, such as hitting a wall or falling.

[0236] It should be noted that the self-moving device first uses a visual sensor (or LiDAR or vision + TOF, etc.) to determine the trust status of the area in front of the self-moving device, travels a set distance in front of the trusted area, and forms a corresponding driving trajectory based on the positioning device; determines the target coordinates of the end position of the driving trajectory in the map coordinate system; determines the target posture of the lawnmower based on the driving trajectory, and uses the target coordinates and target posture as the repositioning pose of the lawnmower in the map coordinate system.

[0237] In one optional implementation of this embodiment, the self-moving device is further equipped with an odometer sensor; controlling the self-moving device to travel a set distance towards a trusted area ahead, and forming a corresponding travel trajectory based on the positioning device, includes:

[0238] Control the mobile device to travel from its current location to a trusted area ahead to the target location point, and form a corresponding first driving trajectory based on the positioning device;

[0239] The initial attitude of the self-moving device is determined based on the first driving trajectory. The initial attitude is used as the orientation reference of the mileage sensor to control the self-moving device to continue driving from the target positioning point, forming the corresponding second driving trajectory.

[0240] It should be noted that the self-moving device first travels a first segment of the path to the target location. Based on the first travel trajectory of this first segment, an initial attitude (i.e., a rough orientation) is obtained, quickly providing a general orientation. The self-moving device then uses this rough orientation as the orientation reference for the odometer. However, since the rough orientation is only approximate, to obtain more accurate orientation information, the self-moving device continues to travel from the target location to obtain a second travel trajectory. The initial attitude (i.e., the rough orientation) of the self-moving device is further calibrated using the second travel trajectory after the target location and the entire trajectory of the first travel trajectory, resulting in a precise target attitude. This precise target attitude is then used as the orientation reference for the odometer, completing the fine positioning.

[0241] Step 506: Determine the target coordinates of the end point of the driving trajectory in the map coordinate system, and determine the target attitude of the self-moving device based on the driving trajectory. Use the target coordinates and target attitude as the repositioning pose of the self-moving device in the map coordinate system, where the repositioning pose is the starting point of the subsequent navigation path.

[0242] In one optional implementation of this embodiment, determining the target attitude of the self-moving device based on the driving trajectory includes:

[0243] The target attitude of the self-moving device is determined based on the first and second driving trajectories. The orientation of the odometer sensor is updated based on the target attitude, and subsequent tasks are executed under control.

[0244] It should be noted that the initial attitude (i.e., rough orientation) of the self-moving device is further calibrated by using the entire driving trajectory of the second segment of the path after the target positioning point and the first segment of the path before the target positioning point, so as to obtain the accurate target attitude. At the same time, the accurate target attitude is used as the orientation reference of the odometer to complete the fine positioning. The target attitude obtained by the fine positioning is used to control the execution of subsequent tasks.

[0245] In an optional embodiment of this invention, the working system of the self-moving device further includes a display device; the method further includes:

[0246] In response to the self-mobile device being moved and / or being powered on again after being powered off, the first pose of the self-mobile device is displayed on a pre-built map via a display device;

[0247] During the relocalization process of the self-moving device, the self-moving device's trajectory from the first pose is displayed on the map, and the relocalized pose obtained after relocalization of the trajectory is also displayed. After relocalization of the trajectory, the pose in the first pose changes to the target pose in the relocalized pose.

[0248] Specifically, the display device can be installed on the self-moving device or on the control terminal of the self-moving device, such as mobile phones, computers, smartwatches, etc.

[0249] It should be noted that in response to the self-moving device being moved and / or restarted after being powered off, the device's initial pose can be displayed on a pre-built map via a display device. During the self-moving device's repositioning process, the trajectory of the self-moving device from its initial pose is displayed on the map. Users can see on the display device that after the self-moving device moves along this trajectory, the pose of the self-moving device displayed on the display device will change significantly. Subsequently, the self-moving device uses the repositioned target pose as the starting point for the subsequent navigation path, greatly reducing the possibility of navigation path planning errors and enabling the lawnmower's accurate pose to be displayed quickly and accurately on the display device, thus improving the user experience.

[0250] In an optional embodiment of this invention, the operating system of the self-moving device further includes a display device; after determining the initial posture of the self-moving device based on the first driving trajectory, it further includes:

[0251] The initial position of the self-moving device on the map is displayed through the display device;

[0252] After determining the target attitude of the self-moving device based on the first and second driving trajectories, the process also includes:

[0253] The initial posture of the self-moving device in the map displayed by the display device is updated to the target posture. If the error between the target posture and the initial posture is greater than a set threshold, the posture update jump amplitude of the self-moving device in the map is the first amplitude; if the error between the target posture and the initial posture is not greater than the set threshold, the posture update jump amplitude of the self-moving device in the map is the second amplitude, and the first amplitude is greater than the second amplitude.

[0254] It should be noted that the mobile device first travels a short distance to the target location. Based on the initial trajectory of this first travel segment, it obtains an initial attitude (i.e., a rough orientation). This provides a general orientation quickly, and the user can observe the repositioning process through the map interface. When the mobile device completes coarse positioning, its approximate position and orientation (i.e., initial attitude) are displayed on the map. Subsequently, the mobile device uses this approximate orientation (initial attitude) as a reference for the odometer sensor to control its continued travel from the target location, obtaining a second travel trajectory. The initial attitude (i.e., the rough orientation) is then further calibrated using the second travel segment after the target location and the entire trajectory of the first travel segment, resulting in a precise target attitude. After fine positioning, the user can see the updated position of the mobile device on the map displayed on the device. If the attitude error between coarse and fine positioning is large, the updated attitude will show significant fluctuations; conversely, if the error is small, the updated attitude will show minimal fluctuations.

[0255] In the embodiments described in this specification, the user can see through the display device that after the self-moving device moves along the driving trajectory, the posture of the self-moving device displayed on the display device will directly and significantly change. Subsequently, the self-moving device uses the repositioned target posture as the starting point of the subsequent navigation path, which greatly reduces the occurrence of navigation path planning errors and can quickly and accurately display the accurate posture of the self-moving device on the display device, thus improving the user experience.

[0256] Referring to Figure 6, which shows a flowchart of a fourth relocation method for a self-moving device according to an embodiment of this specification, the self-moving device is equipped with a visual sensor, a positioning device, and a control unit; the visual sensor is located at the front of the self-moving device along its normal driving direction and is used to identify environmental information in the area in front of the self-moving device; the positioning device includes a positioning tag for communicating with a satellite and at least one positioning beacon located outside the self-moving device, and the position of the self-moving device is obtained based on at least one positioning beacon at a known location and differential information between the positioning tags. The method is applied to the control unit and includes:

[0257] Step 602: In response to the self-moving device being moved to the positioning shadow area, a relocation event is triggered, wherein the positioning shadow area is an area with weak positioning signal.

[0258] It should be noted that the self-moving device pre-builds a map based on the working area, which includes areas with strong and weak positioning signals. Areas with strong positioning signals refer to areas where a clear and powerful positioning service signal can be received. In these areas, the self-moving device can accurately determine its location, thereby effectively planning its path, avoiding obstacles, and avoiding repeatedly covering already trimmed areas. Areas with strong positioning signals are characterized by stable signals, no obstructions, and visibility from multiple satellites. Self-moving devices can operate efficiently in these areas, achieving accurate navigation and boundary recognition, reducing the risk of misoperation. Common examples include open lawns, courtyards without tall trees or buildings obstructing the view, and large green areas in rural or suburban areas.

[0259] Areas with weak positioning signals refer to places where the received positioning signal is weak or unstable due to physical obstacles (such as tall trees, metal structures, and high-rise buildings) or natural terrain (such as valleys and dense forests). In such areas, mobile devices may encounter navigation difficulties, such as being unable to accurately locate their own position, losing their sense of direction, or failing to respond correctly to preset boundary conditions. Areas with weak positioning signals suffer from severe signal attenuation, multipath effects, and a limited number of visible satellites, which may reduce the efficiency of mobile devices, require more intervention, and increase the risk of collisions or deviation from the predetermined path. Common examples include shaded areas near large buildings or trees, grassy areas above underground parking garages, and garden sections in canyons or deep valleys.

[0260] Step 604: In response to the relocation event, determine the trust status of the area in front of the self-moving device through the vision sensor, control the self-moving device to travel a set distance to the trusted area in front, and form a corresponding driving trajectory according to the positioning device.

[0261] In an optional embodiment of this invention, the self-moving device further includes a mileage sensor; controlling the self-moving device to travel a set distance towards a trusted area ahead, and forming a corresponding travel trajectory based on the positioning device, includes:

[0262] Control the self-moving device to travel from its current location to the target location point within the positioning shadow area, and form a corresponding first driving trajectory based on the positioning device;

[0263] Based on the first driving trajectory, the initial pose of the self-moving device in the map coordinate system is determined, wherein the initial pose includes the initial coordinates and the initial attitude.

[0264] Using the initial coordinates as the starting point of the positioning device and the initial attitude as the orientation reference of the odometer, the self-moving device is controlled to continue driving from the target positioning point, execute subsequent tasks, and form a corresponding second driving trajectory. The trajectory path for executing subsequent tasks includes at least a portion of the second driving trajectory.

[0265] Step 606: Determine the target coordinates of the end point of the driving trajectory in the map coordinate system, and determine the target attitude of the self-moving device based on the driving trajectory. Use the target coordinates and target attitude as the repositioning pose of the self-moving device in the map coordinate system, where the repositioning pose is the starting point of the subsequent navigation path.

[0266] In one optional implementation of this embodiment, determining the target attitude of the self-moving device based on the driving trajectory includes:

[0267] The target attitude of the self-moving device is determined based on the first and second driving trajectories. The orientation of the odometer sensor is updated based on the target attitude, and the device is controlled to continue executing subsequent tasks.

[0268] In one optional embodiment of this invention, the working system of the self-moving device further includes a display device; the method further includes:

[0269] In response to the mobile device being moved to the location shadow area, the location of the mobile device is displayed on a pre-built map via a display device, and the number of location jumps is less than or equal to the number of relocation calculations;

[0270] During the relocalization process of the self-moving device, the self-moving trajectory of the self-moving device is displayed on the map, and the relocalized pose obtained after relocalization of the moving trajectory is displayed. The pose of the self-moving device on the map changes after the relocalization of the moving trajectory, and the pose remains stable after the change.

[0271] It should be noted that when the mobile device is moved into the positioning shadow area, the positioning signal strength in the positioning shadow area is weak, causing the position displayed on the display device to fluctuate continuously due to the weak positioning signal. The user cannot see a stable positioning position on the display device. When the self-moving device triggers a relocation event in a location shadow area, it will still travel a set distance forward to a trusted area and form a corresponding driving trajectory based on the positioning device in the area with weak positioning signal. The endpoint of this driving trajectory will be determined in the target coordinates of the map coordinate system. Based on the driving trajectory, the target posture of the lawnmower will be determined, and the target coordinates and target posture will be used as the relocation pose of the lawnmower in the map coordinate system. At this time, the user can see through the display device that after the self-moving device moves along this driving trajectory, the posture of the self-moving device displayed on the display device will undergo a significant jump, and the number of jumps will be less than or equal to the number of relocation calculations. For example, if coarse and fine positioning relocation methods are used, and two relocations are performed, the posture of the self-moving device displayed on the display device will jump twice. Furthermore, the posture displayed on the display device after this jump (after the self-moving device completes relocation) is stable and will not fluctuate continuously, providing a better user experience.

[0272] In an optional embodiment of this invention, the operating system of the self-moving device further includes a display device; after determining the initial posture of the self-moving device based on the first driving trajectory, it further includes:

[0273] The initial position of the self-moving device on the map is displayed through the display device;

[0274] After determining the target attitude of the self-moving device based on the first and second driving trajectories, the process also includes:

[0275] The initial posture of the self-moving device in the map displayed by the display device is updated to the target posture. If the error between the target posture and the initial posture is greater than a set threshold, the posture update jump amplitude of the self-moving device in the map is the first amplitude; if the error between the target posture and the initial posture is not greater than the set threshold, the posture update jump amplitude of the self-moving device in the map is the second amplitude, and the first amplitude is greater than the second amplitude.

[0276] It should be noted that when the mobile device is in an area with weak positioning signal, it first travels a first segment of the path to the target positioning point. Based on the first travel trajectory of the first segment of the path, it obtains an initial attitude (i.e., a rough orientation). It quickly provides a general attitude and direction. The user can see the repositioning process of the mobile device through the map interface that interacts with the user. When the mobile device completes the coarse positioning, the map will display the approximate position and orientation of the mobile device. Subsequently, the mobile device uses this approximate orientation as the orientation reference of the odometer and as the starting point for subsequent navigation path planning.

[0277] Since the rough orientation is only a general direction, to obtain more accurate orientation information for the self-moving device, the device continues to travel from the target location point to obtain a second travel trajectory. The initial attitude (i.e., rough orientation) of the self-moving device is then further calibrated using the second travel trajectory after the target location point and the entire trajectory of the first travel trajectory, resulting in a precise target attitude. This precise target attitude is then used as the orientation reference for the odometer. After fine positioning is completed, the user will notice an update in the self-moving device's location on the display. If the attitude error between the coarse and fine positioning is large, the updated attitude will show a large fluctuation; if the attitude error is small, the updated attitude will show a small fluctuation.

[0278] In the embodiments described in this specification, when the self-moving device is moved to the positioning shadow area, the positioning signal strength in the positioning shadow area is weak, causing the position displayed on the display device to continuously fluctuate due to the weak positioning signal. The user cannot see a stable positioning position on the display device. After repositioning, the pose of the self-moving device displayed on the map is stable and will not fluctuate continuously, which can provide the user with a better user experience.

[0279] Referring to Figure 7, which shows a flowchart of a fifth relocation method for a self-moving device according to an embodiment of this specification, applied to the control unit of the self-moving device, specifically including the following steps.

[0280] Step 702: Control the self-moving device to travel a set distance from the current position to form a corresponding driving trajectory.

[0281] Step 704: Determine the target coordinates of the end point of the driving trajectory in the map coordinate system.

[0282] Step 706: Determine the target pose of the self-moving device based on the driving trajectory, and use the target coordinates and target pose as the repositioning pose of the self-moving device in the map coordinate system.

[0283] It should be noted that the specific implementation process of steps 702-706 above is similar to that of steps 102-106 above. For details, please refer to the above description. This specification does not limit the implementation process in this way.

[0284] Step 708: Determine the corresponding task execution strategy based on the state parameters of the self-moving device, and control the self-moving device according to the repositioning pose and the task execution strategy.

[0285] It should be noted that the state parameters of a self-moving device refer to parameters reflecting its state in the operating environment, including but not limited to position, velocity, attitude, and task progress. In actual implementation, after obtaining the repositioned pose through relocalization, the corresponding task execution strategy can be determined based on the state parameters of the self-moving device. Then, based on the repositioned pose and according to the task execution strategy, the self-moving device can be controlled. Different state parameters can correspond to different task execution strategies.

[0286] In one optional implementation of this embodiment, the status parameters include task status, original location distance, and base station distance. The task status includes whether there are unexecuted tasks or not. Based on the status parameters of the self-moving device, a corresponding task execution strategy is determined, including:

[0287] If the task status is that there are unexecuted tasks, then the corresponding task execution strategy is determined based on the task type, original location distance, and base station distance of the unexecuted tasks.

[0288] If the task status is "no unexecuted tasks", then the corresponding task execution strategy is determined based on the distance to the base station.

[0289] In one optional implementation, the state parameters include task state, original location distance, and base station distance. The task state includes whether there is an unexecuted task or not. The original location distance refers to the distance between the target coordinates in the repositioned pose obtained by repositioning and the coordinates of the original location. The base station distance refers to the distance between the target coordinates in the repositioned pose obtained by repositioning and the coordinates of the base station.

[0290] In practice, if the task status is "there are unexecuted tasks", it means that before relocation, there were tasks that the self-mobile device had not completed. Therefore, after relocation, the corresponding task execution strategy can be determined by combining the task type of the unexecuted task, the original location distance, and the base station distance. If the task status is "there are no unexecuted tasks", it means that before relocation, all tasks of the self-mobile device were completed and there is no need to continue executing the previous tasks. In this case, the corresponding task execution strategy can be determined based on the base station distance.

[0291] In the embodiments of this specification, for cases where there are unexecuted tasks, the system can combine the task type of the unexecuted task, the original location distance, and the base station distance to determine whether to continue executing the task, and which task to continue executing. For cases where there are no unexecuted tasks, the system can determine whether to create and execute a new task based on the base station distance. Thus, by employing different task execution strategies after relocation for cases with and without unexecuted tasks, the system controls the self-moving device, providing greater control flexibility, more closely reflecting the user's true intentions, and improving the user experience.

[0292] In one optional implementation of this embodiment, a corresponding task execution strategy is determined based on the task type of the unexecuted task, the original location distance, and the base station distance, including:

[0293] If the task type is "in progress" and the original location distance does not exceed the distance threshold, the task execution strategy is to continue executing the unexecuted task; or,

[0294] If the task type is "in execution" and the original location distance exceeds a distance threshold, determine whether the base station distance exceeds the distance threshold. If it does, determine the task execution strategy as follows: determine and execute the target task from the pending tasks based on the repositioned pose. If it does not exceed the threshold, determine the task execution strategy as follows: stop task execution and return to the base station; or...

[0295] When the task type is pending execution, determine whether the distance to the base station exceeds the distance threshold. If it does, determine the task execution strategy as determining and executing the target task from the pending tasks based on the repositioning pose. If it does not exceed the threshold, determine the task execution strategy as stopping the task execution and returning to the base station.

[0296] The distance threshold is a configured value used to determine the distance to the original location or base station.

[0297] In one implementation, if the task type is "in execution" and the distance to the original location does not exceed the distance threshold, it indicates that the location in the map was lost during the execution of the task, the task being executed was interrupted, and the distance to the original location does not exceed the distance threshold. This means that the interval between the target coordinates and the coordinates of the original location in the repositioned pose obtained by repositioning is small, that is, the repositioned location is close to the original location before repositioning. The user is likely to want to continue executing the previously interrupted task. At this time, it can be determined that the task execution strategy is to continue executing the unexecuted task. The self-moving device can be controlled to return to the previous original location from the repositioned location in the map based on the repositioned pose and continue executing the interrupted task.

[0298] In another implementation, if the task type is "in execution" and the distance from the original location exceeds a distance threshold, it indicates that although the previously executed task was interrupted, the distance between the target coordinates in the repositioned pose and the coordinates of the original location is large. In other words, the repositioned location is far from the original location before repositioning, and the user likely does not want to continue executing the previously interrupted task. At this time, it can be further determined whether the base station distance exceeds the distance threshold. If the base station distance exceeds the distance threshold, it indicates that the distance between the target coordinates in the repositioned pose and the coordinates of the base station is large. In other words, the repositioned location is also far from the base station location, and the user likely does not want to control the mobile device to return to the base station. At this time, if there are tasks to be executed in the task list of the mobile device, the target task can be determined and executed from the tasks to be executed based on the repositioned pose. The target task is the task closest to the repositioned pose, and the mobile device is controlled to execute the target task based on the repositioned pose. If there are no tasks to be executed in the task list of the mobile device, a new task can be created based on the repositioned pose, and the mobile device is controlled to execute the new task based on the repositioned pose. If the distance to the base station does not exceed the distance threshold, it means that the repositioning location is close to the base station location. The user will most likely want to control the mobile device to automatically return to the base station. At this time, the mobile device can be controlled to stop performing tasks and return to the base station location based on the repositioning pose.

[0299] In another implementation, if the task type is pending execution, that is, there is no task interruption, and the location is lost after the previous task is completed, but there are pending tasks in the task list of the self-mobile device, it can be directly determined whether the distance to the base station exceeds the distance threshold. If it exceeds the threshold, it means that the distance to the base station is too far. At this time, the nearest target task can be determined from the pending tasks based on the relocation pose. If it does not exceed the threshold, it means that the distance to the base station is too close. The self-mobile device is controlled to stop executing the task and return to the base station.

[0300] In the embodiments described in this specification, if task execution is interrupted and the relocated position is close to the position before the interruption, the interrupted task continues to be executed; if task execution is interrupted and the relocated position is far from the position before the interruption, if it is close to the base station, it returns to the base station; if it is far from the base station, it selects a task close to the relocated position from the candidate tasks to be executed; if there is no interrupted task but there is a task to be executed, it can be directly determined whether it is close to the base station. If it is close, it returns to the base station; if it is far, it selects a task close to the relocated position to be executed. After relocation, different task execution strategies are adopted based on the different task types of the tasks to be executed to control the self-moving device, which improves flexibility, is closer to the user's true intention, and improves the user experience.

[0301] In one optional implementation of this embodiment, the state parameters include the original location distance and the base station distance; based on the state parameters of the self-moving device, a corresponding task execution strategy is determined, including:

[0302] If the distance to the original location does not exceed the distance threshold, the task execution strategy is determined to return to the original location;

[0303] If the distance to the original location exceeds the distance threshold, determine whether the distance to the base station exceeds the distance threshold. If it does not exceed the distance threshold, determine the task execution strategy as returning to the base station; if it exceeds the distance threshold, determine the task execution strategy as creating and executing a new task.

[0304] In practice, the state parameters can include the original location distance and the base station distance. If the original location distance does not exceed the distance threshold, it means that the repositioned location is closer to the original location. In this case, the task execution strategy can be determined as returning to the original location, that is, controlling the mobile device to return to the original location based on the repositioned pose and continue executing the previous task. If the original location distance exceeds the distance threshold, it means that the repositioned location is farther from the original location. If it is closer to the base station, the task execution strategy is determined as returning to the base station, controlling the mobile device to return to the base station based on the repositioned pose. If it is farther from the base station, the task execution strategy is determined as creating and executing a new task.

[0305] It should be noted that the operation after relocation can be determined solely based on the original location distance and base station distance. The control logic after relocation is simple, which improves the operation efficiency of the self-moving device after relocation and thus ensures the user experience.

[0306] Of course, in specific implementations, the task execution strategy can be further determined by combining the task status, and the embodiments in this specification do not impose any limitations on this. In addition, the above-mentioned task execution strategies are only examples of various methods. In actual implementations, other control of the self-moving device can also be achieved based on other state parameters of the self-moving device and in combination with the relocation pose, and the embodiments in this specification do not impose any limitations on this.

[0307] This specification provides a relocation method for a self-moving device. It utilizes the self-moving device's trajectory to relocate its position and orientation on a map. This eliminates the need to return to the base station to re-trigger the task, re-match visual or radar map points, and requires no manual intervention, thus improving relocation efficiency and accuracy. Furthermore, different task execution strategies are employed after relocation to control the self-moving device based on its various state parameters, providing greater control flexibility and better reflecting the user's true intentions, thereby enhancing the user experience.

[0308] The following description, in conjunction with Figure 8, uses the application of the self-moving device repositioning method provided in this specification in an automatic lawnmower as an example to further illustrate the self-moving device repositioning method. Figure 8 shows a flowchart of the processing procedure of a self-moving device repositioning method according to an embodiment of this specification. As shown in Figure 8, when the lawnmower task begins, the RTK coordinates of the map coordinate system origin saved after mapping are obtained. The initial RTK coordinates of the current position obtained based on RTK positioning technology are then obtained. The RTK positioning coordinates of the current position are then recalculated based on the RTK coordinates of the map coordinate system origin. The first transformation matrix T from the RTK coordinate system to the machine coordinate system saved after mapping is obtained. Based on this first transformation matrix T, the RTK positioning coordinates of the current position are transformed to the machine coordinate system, and then positioned back to the map coordinate system. Based on the position and orientation of the odometer sensor on the automatic lawnmower, the automatic lawnmower is controlled to perform the lawnmower task.

[0309] When a relocation event is detected, such as the automatic lawnmower being moved, the automatic lawnmower being turned on outside the base station, the automatic lawnmower being restarted, or the automatic lawnmower being dragged to another location during the lawnmower task pause, the automatic lawnmower responds to the relocation event and triggers relocation. The automatic lawnmower starts to drive to the target location point and obtains the first driving trajectory S1. Based on the first driving trajectory, a coarse relocation is performed.

[0310] The rough relocation process is as follows (not shown in the figure):

[0311] Determine the RTK coordinates of the endpoint of the first driving trajectory. Combined with the RTK coordinate system origin saved after mapping, recalculate the RTK coordinates of the endpoint in the RTK coordinate system. Then, based on the first transformation matrix T from the RTK coordinate system to the machine coordinate system saved after mapping, transform the RTK coordinates in the RTK coordinate system to the machine coordinate system to obtain the mileage coordinates of the endpoint in the machine coordinate system. Next, based on the second transformation matrix T1' from the machine coordinate system to the map coordinate system, transform the mileage coordinates of the endpoint in the machine coordinate system to the map coordinate system to obtain the initial coordinates of the endpoint in the map coordinate system. Calculate the azimuth angle based on the starting and ending positions of the first driving trajectory, which will be used as the initial orientation determined after the automatic lawnmower reaches the target positioning point. This completes the coarse repositioning.

[0312] After successful coarse repositioning, the autonomous lawnmower uses the repositioned attitude as its current attitude and continues mowing. The coarse repositioning pose information is displayed on the map used for user interaction, quickly informing the user of the lawnmower's location and direction. At the beginning of the mowing task, the autonomous lawnmower continues from the target positioning point, obtaining a second travel trajectory S2 (the path length of S2 is greater than or equal to the path length of S1). Based on this second trajectory, the autonomous lawnmower performs fine repositioning, thus calibrating the previous coarse repositioning attitude information. Once precise repositioning is complete, the user can detect subtle shifts in the lawnmower's position on the user-interacting map, indicating accurate repositioning.

[0313] If no relocation success signal is received, it indicates that the coarse relocation has failed, a positioning failure alarm will be issued, and the lawn mowing task will be stopped.

[0314] The fine repositioning process is as follows (not shown in the figure):

[0315] Determine the RTK coordinates of the endpoint of the second driving trajectory. Combined with the RTK coordinate system origin saved after mapping, recalculate the RTK coordinates of the endpoint of the second driving trajectory in the RTK coordinate system. Then, based on the first transformation matrix T from the RTK coordinate system to the body coordinate system saved after mapping, transform the RTK coordinates in the RTK coordinate system to the body coordinate system to obtain the mileage coordinates of the endpoint of the second driving trajectory in the body coordinate system. Next, based on the second transformation matrix T2' from the body coordinate system to the map coordinate system, transform the mileage coordinates of the endpoint of the second driving trajectory in the body coordinate system to the map coordinate system to obtain the target coordinates of the endpoint of the second driving trajectory in the map coordinate system. Calculate the azimuth angle based on the starting position of the first driving trajectory and the ending position of the second driving trajectory as the target orientation of the automatic lawnmower. Complete the fine repositioning.

[0316] After successful repositioning, the repositioning pose is output to determine whether the automatic lawnmower is within the map area. If it is, the lawnmower continues to perform the mowing task based on the position and orientation collected by the automatic lawnmower's odometer sensor; otherwise, an off-map alarm is triggered.

[0317] If no relocation success signal is received, it indicates that the fine relocation has failed, a positioning failure alarm will be issued, and the lawn mowing task will be stopped.

[0318] This specification provides a relocation method for an automated mobile device. Relocation events are triggered in response to at least one of the following scenarios: the automated lawnmower is moved, the automated lawnmower is powered on outside a base station, the automated lawnmower restarts, or the automated lawnmower is dragged to another location during a task pause. The method utilizes two segments of the automated lawnmower's trajectory to relocate its position and orientation on a map. The relocation event triggering scenarios are diverse, adaptable to various scenarios where the lawnmower's position is lost on the map, ensuring more comprehensive relocation coverage. Furthermore, it eliminates the need to move the lawnmower back to the base station to re-trigger the task, nor to re-match visual or radar map points, requiring no manual intervention and improving relocation efficiency and accuracy. After successful relocation, it can also determine whether the lawnmower is within the map area. If it is, the mowing task continues; otherwise, an alarm sounds indicating it has gone out of bounds and the task ends. This prevents damage to the automated lawnmower if it relocates outside the map and continues mowing, ensuring the safety of the lawnmower after relocation.

[0319] Corresponding to the above method embodiments, this specification also provides a first embodiment of a control unit for a self-moving device. Figure 9 shows a schematic diagram of the structure of a control unit for a first self-moving device provided in one embodiment of this specification. As shown in Figure 9, the control unit includes:

[0320] The first control module 902 is configured to control the self-moving device to travel a set distance from its current position to form a corresponding travel trajectory;

[0321] The first determining module 904 is configured to determine the target coordinates of the end point of the driving trajectory in the map coordinate system;

[0322] The second determining module 906 is configured to determine the target attitude of the self-moving device based on the driving trajectory, and use the target coordinates and target attitude as the repositioning pose of the self-moving device in the map coordinate system.

[0323] Optionally, a target positioning point is configured with a set distance; the first control module 902 is further configured to:

[0324] Control the mobile device to travel from its current location to the target location, forming a corresponding first driving trajectory;

[0325] Control the self-moving device to continue moving from the target positioning point, forming a corresponding second driving trajectory;

[0326] Accordingly, the second determining module 906 is further configured as follows:

[0327] The target attitude of the self-moving device is determined based on the first driving trajectory and / or the second driving trajectory.

[0328] Optionally, the device further includes a third determining module configured to:

[0329] The initial attitude of the self-moving device is determined based on the first driving trajectory;

[0330] Accordingly, the first control module 902 is further configured as follows:

[0331] Based on the initial attitude, the self-moving device is controlled to continue moving from the target positioning point, forming a corresponding second driving trajectory.

[0332] Optionally, the first control module 902 is further configured as follows:

[0333] Control the self-moving device to travel from its current position along a straight line in its original posture to the target positioning point, where the original posture is the posture of the self-moving device before repositioning;

[0334] Control the self-moving device to continue traveling from the target positioning point in its original posture and along a straight line, forming a corresponding second driving trajectory.

[0335] Optionally, the control unit further includes a fourth determining module, configured to:

[0336] Based on the first driving trajectory, the initial pose of the self-moving device in the map coordinate system is determined, wherein the initial pose includes the initial coordinates and the initial attitude.

[0337] Accordingly, the first control module 902 is further configured as follows:

[0338] Based on the initial pose, the self-moving device is controlled to continue moving from the target positioning point, perform subsequent tasks, and form a corresponding second driving trajectory.

[0339] Optionally, the trajectory path for performing subsequent tasks includes at least a portion of the second driving trajectory.

[0340] Optionally, a target positioning point is configured with a set distance; the first control module 902 is further configured to:

[0341] Control the self-moving device to travel from the current location to the target location point, forming a corresponding first driving trajectory; control the self-moving device to continue traveling from the target location point, forming corresponding N driving trajectories, where N is greater than or equal to two;

[0342] The step of determining the target posture of the self-moving device based on the driving trajectory includes: determining the target posture of the self-moving device based on the first driving trajectory and / or the N segments of driving trajectory.

[0343] Optionally, the second determining module 906 is further configured to:

[0344] Determine the starting position of the first driving trajectory and the ending position of the second driving trajectory;

[0345] The target posture of the self-moving device is determined based on the starting position of the first driving trajectory and the ending position of the second driving trajectory.

[0346] Optionally, the path length of the second driving trajectory is greater than or equal to the path length of the first driving trajectory.

[0347] Optionally, the self-moving device is equipped with an odometer sensor for recording parameters during the self-moving device's travel; the second determining module 906 is further configured to:

[0348] The target attitude of the self-moving device is determined based on the driving trajectory and parameters recorded by the mileage sensor.

[0349] Optionally, the control unit also includes a prompting model, configured to:

[0350] Based on the repositioning pose and the pre-built map, determine whether the self-moving device is located in the map area;

[0351] If not, then issue an out-of-bounds warning.

[0352] This specification provides a repositioning device for a self-moving device. If the self-moving device loses its location on a map, it can control the device to travel a set distance from its current position to locate the target coordinates of the endpoint of its travel trajectory in the map coordinate system. Furthermore, based on the travel trajectory after the set distance, the target attitude of the self-moving device can be determined. The target coordinates indicate the self-moving device's position on the map, and the target attitude indicates its orientation. This allows for the repositioning of the self-moving device on the map, achieving repositioning without needing to return to the base station to re-trigger the task or re-match visual or radar map points. The device's travel trajectory is sufficient for repositioning its location and orientation on the map, eliminating the need for manual intervention and improving repositioning efficiency and accuracy.

[0353] Corresponding to the above method embodiments, this specification also provides a second embodiment of a control unit for a self-moving device. Figure 10 shows a schematic diagram of the structure of a control unit for a second self-moving device provided in one embodiment of this specification. As shown in Figure 10, the control unit includes:

[0354] The second control module 1002 is configured to respond to a relocation event and control the self-moving device to travel a set distance from its current position to form a corresponding travel trajectory. The relocation event includes at least one of the following: the self-moving device is moved or the self-moving device is restarted.

[0355] The fifth determining module 1004 is configured to determine the target coordinates of the end point of the driving trajectory in the map coordinate system;

[0356] The sixth determining module 1006 is configured to determine the target attitude of the self-moving device based on the driving trajectory, and use the target coordinates and target attitude as the repositioning pose of the self-moving device in the map coordinate system.

[0357] This specification provides a relocation device for a self-moving device. Responding to relocation events triggered by at least one of the following scenarios: the self-moving device is moved, the self-moving device is powered on outside a base station, the self-moving device restarts, or the self-moving device is dragged to another location during a task pause, the device utilizes the self-moving device's trajectory to relocate its position and orientation on a map. The relocation event triggering scenarios are diverse, adaptable to various scenarios where the device's position on the map is lost, ensuring more comprehensive relocation coverage. Furthermore, it eliminates the need to move the device back to the base station to re-trigger the task, re-match visual map points or radar map points, and requires no manual intervention, thus improving relocation efficiency and accuracy.

[0358] Corresponding to the above method embodiments, this specification also provides a third embodiment of a control unit for a self-moving device. Figure 11 shows a schematic diagram of the structure of a control unit for a third self-moving device according to an embodiment of this specification. The self-moving device is equipped with a vision sensor, a positioning device, and a control unit. The vision sensor is located on the front side of the self-moving device along its normal driving direction and is used to identify environmental information in the area in front of the self-moving device. The positioning device includes a positioning tag for communicating with a satellite and at least one positioning beacon located outside the self-moving device. The position of the self-moving device is obtained based on the at least one positioning beacon with a known location and differential information between the positioning tags. As shown in Figure 11, the control unit includes:

[0359] The first triggering module 1102 is configured to trigger a relocation event in response to the self-moving device being moved and / or the self-moving device being powered on after being powered off.

[0360] The third control module 1104 is configured to respond to a relocation event, determine the trust status of the area in front of the self-moving device through a vision sensor, control the self-moving device to travel a set distance to the trusted area in front, and form a corresponding driving trajectory based on the positioning device.

[0361] The seventh determining module 1106 is configured to determine the target coordinates of the end point of the driving trajectory in the map coordinate system, and determine the target attitude of the self-moving device based on the driving trajectory. The target coordinates and target attitude are used as the repositioning pose of the self-moving device in the map coordinate system, wherein the repositioning pose is the starting point of the subsequent navigation path.

[0362] Optionally, the operating system of the self-moving device further includes a display device; the control unit also includes a first display module configured to:

[0363] In response to the self-mobile device being moved and / or being powered on again after being powered off, the first pose of the self-mobile device is displayed on a pre-built map via a display device;

[0364] During the relocalization process of the self-moving device, the self-moving device's trajectory from the first pose is displayed on the map, and the relocalized pose obtained after relocalization of the trajectory is also displayed. After relocalization of the trajectory, the pose in the first pose changes to the target pose in the relocalized pose.

[0365] Optionally, the self-moving device is also equipped with an odometer sensor; the third control module 1104 is further configured to:

[0366] Control the mobile device to travel from its current location to a trusted area ahead to the target location point, and form a corresponding first driving trajectory based on the positioning device;

[0367] The initial attitude of the self-moving device is determined based on the first driving trajectory. The initial attitude is used as the orientation reference of the odometer sensor to control the self-moving device to continue driving from the target positioning point, forming the corresponding second driving trajectory.

[0368] Accordingly, the seventh determining module 1106 is further configured as follows:

[0369] The target attitude of the self-moving device is determined based on the first and second driving trajectories. The orientation of the odometer sensor is updated based on the target attitude, and subsequent tasks are executed under control.

[0370] Optionally, the operating system of the self-moving device further includes a display device; the control unit also includes a second display module configured to:

[0371] The initial position of the self-moving device on the map is displayed through the display device;

[0372] The initial posture of the self-moving device in the map displayed by the display device is updated to the target posture. If the error between the target posture and the initial posture is greater than a set threshold, the posture update jump amplitude of the self-moving device in the map is the first amplitude; if the error between the target posture and the initial posture is not greater than the set threshold, the posture update jump amplitude of the self-moving device in the map is the second amplitude, and the first amplitude is greater than the second amplitude.

[0373] Corresponding to the above method embodiments, this specification also provides a fourth embodiment of a control unit for a self-moving device. Figure 12 shows a schematic diagram of the structure of a control unit for a fourth self-moving device provided in one embodiment of this specification. The self-moving device is equipped with a vision sensor, a positioning device, and a control unit. The vision sensor is located on the front side of the self-moving device along its normal driving direction and is used to identify environmental information in the area in front of the self-moving device. The positioning device includes a positioning tag for communicating with a satellite and at least one positioning beacon located outside the self-moving device. The position of the self-moving device is obtained based on at least one positioning beacon with a known location and differential information between the positioning tags. As shown in Figure 12, the control unit includes:

[0374] The second trigger module 1202 is configured to trigger a relocation event in response to the self-moving device being moved to the positioning shadow area, wherein the positioning shadow area is an area with weak positioning signal;

[0375] The fourth control module 1204 is configured to respond to a relocation event, determine the trust status of the area in front of the self-moving device through a vision sensor, control the self-moving device to travel a set distance to the trusted area in front, and form a corresponding driving trajectory based on the positioning device.

[0376] The eighth determining module 1206 is configured to determine the target coordinates of the end point of the driving trajectory in the map coordinate system, and determine the target attitude of the self-moving device according to the driving trajectory. The target coordinates and target attitude are used as the repositioning pose of the self-moving device in the map coordinate system, wherein the repositioning pose is the starting point of the subsequent navigation path.

[0377] Optionally, the operating system of the self-moving device also includes a display device; the control unit further includes a third display module configured to:

[0378] In response to the mobile device being moved to the location shadow area, the location of the mobile device is displayed on a pre-built map via a display device, and the number of location jumps is less than or equal to the number of relocation calculations;

[0379] During the relocalization process of the self-moving device, the self-moving trajectory of the self-moving device is displayed on the map, and the relocalized pose obtained after relocalization of the moving trajectory is displayed. The pose of the self-moving device on the map changes after the relocalization of the moving trajectory, and the pose remains stable after the change.

[0380] Optionally, the self-moving device also includes an odometer sensor; the fourth control module 1204 is further configured to:

[0381] Control the self-moving device to travel from its current location to the target location point within the positioning shadow area, and form a corresponding first driving trajectory based on the positioning device;

[0382] Based on the first driving trajectory, the initial pose of the self-moving device in the map coordinate system is determined, wherein the initial pose includes the initial coordinates and the initial attitude.

[0383] The initial coordinates are used as the starting position of the positioning device, and the initial attitude is used as the orientation reference of the odometer sensor. The self-moving device is controlled to continue driving from the target positioning point, execute subsequent tasks, and form a corresponding second driving trajectory. The trajectory path for executing subsequent tasks includes at least part of the second driving trajectory.

[0384] Accordingly, the eighth determining module 1206 is further configured as follows:

[0385] The target attitude of the self-moving device is determined based on the first and second driving trajectories. The orientation of the odometer sensor is updated based on the target attitude, and the device is controlled to continue executing subsequent tasks.

[0386] Corresponding to the above method embodiments, this specification also provides a fifth embodiment of a control unit for a self-moving device. Figure 13 shows a schematic diagram of the structure of a control unit for a fifth self-moving device provided in one embodiment of this specification. As shown in Figure 13, the control unit includes:

[0387] The fifth control module 1302 is configured to control the self-moving device to travel a set distance from its current position, forming a corresponding travel trajectory;

[0388] The ninth determining module 1304 is configured to determine the target coordinates of the end point of the driving trajectory in the map coordinate system;

[0389] The tenth determining module 1306 is configured to determine the target attitude of the self-moving device based on the driving trajectory, and use the target coordinates and target attitude as the repositioning pose of the self-moving device in the map coordinate system.

[0390] The sixth control module 1308 is configured to determine the corresponding task execution strategy based on the state parameters of the self-moving device, and control the self-moving device according to the repositioning pose and the task execution strategy.

[0391] Optionally, the status parameters include task status, original location distance, and base station distance; the task status includes whether there are unexecuted tasks or not. The sixth control module 1308 is further configured to:

[0392] If the task status is that there are unexecuted tasks, then the corresponding task execution strategy is determined based on the task type, original location distance, and base station distance of the unexecuted tasks.

[0393] If the task status is "no unexecuted tasks", then the corresponding task execution strategy is determined based on the distance to the base station.

[0394] Optionally, the sixth control module 1308 is further configured as follows:

[0395] If the task type is "in progress" and the original location distance does not exceed the distance threshold, the task execution strategy is to continue executing the unexecuted task; or,

[0396] If the task type is "in execution" and the original location distance exceeds a distance threshold, determine whether the base station distance exceeds the distance threshold. If it does, determine the task execution strategy as follows: determine and execute the target task from the pending tasks based on the repositioned pose. If it does not exceed the threshold, determine the task execution strategy as follows: stop task execution and return to the base station; or...

[0397] When the task type is pending execution, determine whether the distance to the base station exceeds the distance threshold. If it does, determine the task execution strategy as determining and executing the target task from the pending tasks based on the repositioning pose. If it does not exceed the threshold, determine the task execution strategy as stopping the task execution and returning to the base station.

[0398] Optionally, the status parameters include the original location distance and the base station distance; the sixth control module 1308 is further configured to:

[0399] If the distance to the original location does not exceed the distance threshold, the task execution strategy is determined to return to the original location;

[0400] If the distance to the original location exceeds the distance threshold, determine whether the distance to the base station exceeds the distance threshold. If it does not exceed the distance threshold, determine the task execution strategy as returning to the base station; if it exceeds the distance threshold, determine the task execution strategy as creating and executing a new task.

[0401] This specification provides a relocation device for a self-moving device. It utilizes the self-moving device's trajectory to relocate its position and orientation on a map. This eliminates the need to return to the base station to re-trigger the task, re-match visual or radar map points, and requires no manual intervention, thus improving relocation efficiency and accuracy. Furthermore, different task execution strategies are employed after relocation to control the self-moving device based on its various state parameters, providing greater control flexibility and better reflecting the user's true intentions, thereby enhancing the user experience.

[0402] The above is a schematic scheme of a relocation device for a self-moving device according to this embodiment. It should be noted that the technical solution of this relocation device for a self-moving device belongs to the same concept as the technical solution of the relocation method for a self-moving device described above. For details not described in detail in the technical solution of the relocation device for a self-moving device, please refer to the description of the technical solution of the relocation method for a self-moving device described above.

[0403] Figure 14 shows a structural block diagram of a self-moving device according to an embodiment of this specification. The components of this self-moving device include, but are not limited to:

[0404] Ontology 1402,

[0405] The drive module 1404 is located on the main body 1402 and is used to drive the main body 1402 to move.

[0406] Execution module 1406, located in body 1402, is used to execute work tasks;

[0407] Memory 1408 and processor 1410;

[0408] The memory 1408 is used to store computer-executable instructions, and the processor 1410 is used to execute the computer-executable instructions. When the computer-executable instructions are executed by the processor 1410, they implement the steps of the relocation method of the self-moving device described above.

[0409] The above is an illustrative scheme of a self-moving device according to this embodiment. It should be noted that the technical solution of this self-moving device and the technical solution of the self-moving device relocation method described above belong to the same concept. For details not described in detail in the technical solution of the self-moving device, please refer to the description of the technical solution of the self-moving device relocation method described above.

[0410] Figure 15 shows a structural block diagram of a working system for a self-moving device according to an embodiment of this specification, including a self-moving device and a display device. The display device is used to display a map of the working area of ​​the self-moving device. As shown in Figure 15, the working system for the self-moving device includes:

[0411] The detection module 1502 is installed on the self-moving device and is used to detect whether a moving event has occurred on the self-moving device.

[0412] The positioning device 1504 includes one or more positioning tags, which are disposed on the self-moving device and configured to receive positioning signals from one or more positioning beacons, wherein there are areas with strong positioning signals and areas with weak positioning signals in the working area.

[0413] At least one processor 1506 is configured as follows:

[0414] In response to the occurrence of the transport event, the self-moving device is controlled to travel a preset distance, and the coordinates of the destination of the preset distance of the mobile device are determined based on the pre-stored information of one or more positioning beacons.

[0415] The target pose of the self-moving device is determined based on the trajectory of the preset mileage, and the target coordinates and target pose of the endpoint of the preset mileage are used as the repositioning pose in the coordinate system of the map.

[0416] The preset mileage is located in an area where the positioning signal is weak.

[0417] This specification also provides an embodiment of another self-moving device operating system, including a self-moving device, a base station, and a display device, wherein the display device is used to display a map of the working area of ​​the self-moving device, and the self-moving device operating system includes:

[0418] The detection module is used to detect whether the self-moving device has engaged with the base station.

[0419] A positioning device includes one or more positioning tags disposed on the self-moving device and configured to receive positioning signals from one or more positioning beacons;

[0420] At least one processor is configured as follows:

[0421] In response to the activation of the self-moving device and the absence of the docking event, the self-moving device is controlled to travel a preset distance, and the coordinates of the endpoint of the preset distance of the mobile device are determined based on the pre-stored information of one or more positioning beacons.

[0422] The target posture of the self-moving device is determined based on the trajectory of the preset mileage, and the target coordinates and target posture of the endpoint of the preset mileage are used as the repositioning posture in the coordinate system of the map.

[0423] The above is an illustrative scheme of a working system for a self-moving device according to this embodiment. It should be noted that the technical solution of this self-moving device working system and the technical solution of the self-moving device relocation method described above belong to the same concept. For details not described in detail in the technical solution of the self-moving device working system, please refer to the description of the technical solution of the self-moving device relocation method described above.

[0424] An embodiment of this specification also provides a computer-readable storage medium storing computer-executable instructions that, when executed by a processor, implement the steps of the relocation method for the self-moving device described above.

[0425] The above is an illustrative scheme of a computer-readable storage medium according to this embodiment. It should be noted that the technical solution of this storage medium belongs to the same concept as the technical solution of the self-moving device relocation method described above. For details not described in detail in the technical solution of the storage medium, please refer to the description of the technical solution of the self-moving device relocation method described above.

[0426] An embodiment of this specification also provides a computer program, wherein when the computer program is executed in a computer, it causes the computer to perform the steps of the relocation method of the self-moving device described above.

[0427] The above is an illustrative example of a computer program according to this embodiment. It should be noted that the technical solution of this computer program and the technical solution of the aforementioned relocation method for self-moving devices belong to the same concept. Details not described in detail in the computer program's technical solution can be found in the description of the technical solution of the aforementioned relocation method for self-moving devices.

[0428] The foregoing has described specific embodiments of this specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in a different order than that shown in the embodiments and may still achieve the desired result. Furthermore, the processes depicted in the drawings do not necessarily require the specific or sequential order shown to achieve the desired result. In some embodiments, multitasking and parallel processing are possible or may be advantageous.

[0429] Computer instructions include computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. Computer-readable media can include: any entity or device capable of carrying computer program code, recording media, USB flash drives, portable hard drives, magnetic disks, optical disks, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signals, telecommunication signals, and software distribution media, etc. It should be noted that the content included in computer-readable media can be appropriately added or removed according to the requirements of patent practice. For example, in some regions, according to patent practice, computer-readable media do not include electrical carrier signals and telecommunication signals.

[0430] It should be noted that, for the sake of simplicity, the foregoing method embodiments are all described as a series of actions. However, those skilled in the art should understand that the embodiments of this specification are not limited to the described order of actions, because according to the embodiments of this specification, some steps can be performed in other orders or simultaneously. Furthermore, those skilled in the art should also understand that the embodiments described in the specification are all optional embodiments, and the actions and modules involved are not necessarily essential to the embodiments of this specification.

[0431] In the above embodiments, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions in other embodiments.

[0432] The optional embodiments disclosed above are merely illustrative of this specification. These optional embodiments do not exhaustively describe all details, nor do they limit the invention to the specific implementations described. Clearly, many modifications and variations can be made based on the embodiments described in this specification. These embodiments are selected and specifically described in this specification to better explain the principles and practical applications of the embodiments, thereby enabling those skilled in the art to better understand and utilize this specification. This specification is limited only by the claims and their full scope and equivalents.

Claims

1. A relocation method for a self-moving device, characterized in that, include: Control the mobile device to travel a set distance from its current location, forming a corresponding travel trajectory; Determine the target coordinates of the endpoint of the driving trajectory in the map coordinate system; The target posture of the self-moving device is determined based on the driving trajectory, and the target coordinates and the target posture are used as the repositioning posture of the self-moving device in the map coordinate system.

2. The relocation method for a self-moving device according to claim 1, characterized in that, The set distance is configured with a target positioning point; The control of the self-moving device to travel a set distance from its current position to form a corresponding travel trajectory includes: Control the self-moving device to travel from the current location to the target location, forming a corresponding first driving trajectory; control the self-moving device to continue traveling from the target location, forming a corresponding second driving trajectory; The step of determining the target posture of the self-moving device based on the driving trajectory includes: determining the target posture of the self-moving device based on the first driving trajectory and / or the second driving trajectory.

3. The relocation method for a self-moving device according to claim 2, characterized in that, After controlling the self-moving device to travel from the current location to the target positioning point and forming a corresponding first driving trajectory, the method further includes: The initial posture of the self-moving device is determined based on the first driving trajectory; Accordingly, controlling the self-moving device to continue traveling from the target positioning point to form a corresponding second driving trajectory includes: Based on the initial posture, the self-moving device is controlled to continue traveling from the target positioning point, forming a corresponding second driving trajectory.

4. The relocation method for a self-moving device according to claim 2, characterized in that, The step of controlling the self-moving device to travel from the current location to the target positioning point, forming a corresponding first driving trajectory, includes: Control the self-moving device to travel from its current position along a straight line in its original posture to the target positioning point, wherein the original posture is the posture of the self-moving device before repositioning; Accordingly, controlling the self-moving device to continue traveling from the target positioning point to form a corresponding second driving trajectory includes: The self-moving device is controlled to continue traveling from the target positioning point in the original posture and along the straight line direction, forming a corresponding second driving trajectory.

5. The relocation method for a self-moving device according to claim 2, characterized in that, After controlling the self-moving device to travel from the current location to the target positioning point and forming a corresponding first driving trajectory, the method further includes: Based on the first driving trajectory, the initial pose of the self-moving device in the map coordinate system is determined, wherein the initial pose includes initial coordinates and initial attitude; Accordingly, controlling the self-moving device to continue traveling from the target positioning point to form a corresponding second driving trajectory includes: Based on the initial pose, the self-moving device is controlled to continue driving from the target positioning point, perform subsequent tasks, and form a corresponding second driving trajectory.

6. The relocation method for a self-moving device according to claim 5, characterized in that, The trajectory path for performing subsequent tasks includes at least a portion of the second driving trajectory.

7. The relocation method for a self-moving device according to any one of claims 2-6, characterized in that, Determining the target posture of the self-moving device based on the first driving trajectory and / or the second driving trajectory includes: Determine the starting position of the first driving trajectory and the ending position of the second driving trajectory; The target posture of the self-moving device is determined based on the starting position of the first driving trajectory and the ending position of the second driving trajectory.

8. The relocation method for a self-moving device according to any one of claims 2-6, characterized in that, The path length of the second driving trajectory is greater than or equal to the path length of the first driving trajectory.

9. The relocation method for a self-moving device according to claim 1, characterized in that, The set distance is configured with a target positioning point; The control of the self-moving device to travel a set distance from its current position to form a corresponding travel trajectory includes: Control the self-moving device to travel from the current location to the target location point, forming a corresponding first driving trajectory; control the self-moving device to continue traveling from the target location point, forming corresponding N driving trajectories, where N is greater than or equal to two; The step of determining the target posture of the self-moving device based on the driving trajectory includes: determining the target posture of the self-moving device based on the first driving trajectory and / or the N segments of driving trajectory.

10. A relocation method for a self-moving device, characterized in that, include: In response to a relocation event, the self-moving device is controlled to travel a set distance from its current position to form a corresponding travel trajectory. The relocation event includes at least one of the following: the self-moving device is moved or the self-moving device is restarted. Determine the target coordinates of the endpoint of the driving trajectory in the map coordinate system; The target posture of the self-moving device is determined based on the driving trajectory, and the target coordinates and the target posture are used as the repositioning posture of the self-moving device in the map coordinate system.

11. A working system for a self-moving device, comprising a self-moving device and a display device, wherein the display device is used to display a map of the working area of ​​the self-moving device, characterized in that, The operating system of the self-moving device includes: A detection module, installed on the self-moving device, is used to detect whether a moving event has occurred on the self-moving device. A positioning device includes one or more positioning tags disposed on the self-moving device and configured to receive positioning signals from one or more positioning beacons, wherein the working area has areas with strong positioning signals and areas with weak positioning signals. At least one processor is configured as follows: In response to the occurrence of the transport event, the self-moving device is controlled to travel a preset distance, and the coordinates of the destination of the preset distance of the mobile device are determined based on the pre-stored information of one or more positioning beacons. The target pose of the self-moving device is determined based on the trajectory of the preset mileage, and the target coordinates and target pose of the endpoint of the preset mileage are used as the repositioning pose in the coordinate system of the map. The preset mileage is located in an area where the positioning signal is weak.

12. A working system for a self-moving device, comprising a self-moving device, a base station, and a display device, wherein the display device is used to display a map of the working area of ​​the self-moving device, characterized in that, The operating system of the self-moving device includes: The detection module is used to detect whether the self-moving device has engaged with the base station. A positioning device includes one or more positioning tags disposed on the self-moving device and configured to receive positioning signals from one or more positioning beacons; At least one processor is configured as follows: In response to the activation of the self-moving device and the absence of the docking event, the self-moving device is controlled to travel a preset distance, and the coordinates of the endpoint of the preset distance of the mobile device are determined based on the pre-stored information of one or more positioning beacons. The target posture of the self-moving device is determined based on the trajectory of the preset mileage, and the target coordinates and target posture of the endpoint of the preset mileage are used as the repositioning posture in the coordinate system of the map.

13. A self-moving device, characterized in that, It includes: ontology, A drive module, located on the main body, is used to drive the main body to move; An execution module, located in the main body, is used to perform work tasks; Memory and processor; The memory is used to store computer-executable instructions, and the processor is used to execute the computer-executable instructions, which, when executed by the processor, implement the steps of the relocation method of the self-moving device according to any one of claims 1-10.

14. A computer-readable storage medium, characterized in that, It stores computer-executable instructions that, when executed by a processor, implement the steps of the relocation method of the self-moving device according to any one of claims 1-10.

15. A computer program product, characterized in that, Includes a computer program / instructions that, when executed by a processor, implement the steps of the relocation method for the self-moving device according to any one of claims 1-10.