Device positioning method, device, robot and storage medium
By executing the positioning data acquisition program in the kernel of the terminal device, the problems of low positioning data acquisition efficiency and virtual positioning tampering in the existing technology are solved, and efficient and accurate positioning data acquisition and monitoring are achieved.
Patent Information
- Application Number
- CN202111659050.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-12-30
- Publication Date
- 2024-10-01
- Estimated Expiration
- 2041-12-30
AI Technical Summary
The existing technology has problems of low efficiency and virtual positioning tampering during the acquisition process of terminal device positioning data, resulting in inaccurate positioning data and affecting the effectiveness of location monitoring.
When the kernel of the terminal device is started, the startup script is executed to allocate computing resources, the positioning data acquisition program is directly run in the kernel, and the positioning data is obtained and sent to the server to avoid multi-layer collaborative work and virtual positioning tampering.
It improves the efficiency and accuracy of positioning data acquisition, ensures that the server obtains true and reliable positioning data, and enhances the effectiveness and reliability of terminal device location monitoring.
Smart Images

Figure CN114390064B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of positioning, and in particular to a device positioning method, device, robot and storage medium. Background Art
[0002] The positioning function is already one of the basic functions provided by terminal devices for users. In practice, different types of applications (Application, APP for short) installed on terminal devices can also provide users with a good user experience with the help of the positioning data collected by the terminal devices.
[0003] For example, a self-moving robot can collect its own position in real time, and then synchronize its position information to the terminal device used by the user through the server. At this time, the user can understand the task execution status of the self-moving robot in real time. Among them, the self-moving robot can be a service robot, such as a cleaning robot, a guide robot, etc. Another example is the instant messaging APP installed in the terminal device. After the terminal device used by the user collects its own position, it can also synchronize this position information to other users through the server, that is, the instant messaging APP provides the user with a location sending function. Summary of the invention
[0004] In view of this, an embodiment of the present invention provides a device positioning method, apparatus, robot and storage medium to improve the accuracy of positioning data.
[0005] In a first aspect, an embodiment of the present invention provides a device positioning method, including:
[0006] In response to the startup of the kernel of the terminal device, executing a startup script to allocate computing resources for acquiring positioning data;
[0007] In the kernel, executing a positioning data acquisition program using the allocated computing resources to obtain positioning data of the terminal device;
[0008] The positioning data is sent to a server so that the server can locate the terminal device.
[0009] In a second aspect, an embodiment of the present invention provides a device positioning apparatus, including:
[0010] A first execution module is used to execute a startup script in response to the startup of the terminal device kernel to allocate computing resources for obtaining positioning data;
[0011] A second execution module is used to execute a positioning data acquisition program in the kernel using the allocated computing resources to obtain the positioning data of the terminal device;
[0012] The sending module is used to send the positioning data to a server so that the server can locate the terminal device.
[0013] In a third aspect, an embodiment of the present invention provides a robot, comprising a processor and a memory, wherein the memory is used to store one or more computer instructions, wherein the one or more computer instructions, when executed by the processor, implement the device positioning method in the first aspect. The electronic device may also include a communication interface for communicating with other devices or a communication network.
[0014] In a fourth aspect, an embodiment of the present invention provides a non-transitory machine-readable storage medium having executable code stored thereon. When the executable code is executed by a processor of an electronic device, the processor can at least implement the device positioning method as described in the first aspect.
[0015] The device positioning method provided by the embodiment of the present invention executes a startup script in response to the startup of the terminal device kernel to allocate the computing resources of the terminal device, that is, to divide part of the computing resources to obtain positioning data. Then, the kernel continues to use the allocated computing resources to execute the positioning data acquisition program installed in the terminal device to obtain the positioning data of the terminal device. Finally, the positioning data of the terminal device is sent to the server so that the server obtains the positioning data to monitor the location of the terminal device. In the above method, the terminal device directly runs the positioning data acquisition program in the kernel to obtain the positioning data, and the method of obtaining the positioning data is simple and convenient. At the same time, there is no excessive processing logic for the acquired positioning data, and the acquisition efficiency of the positioning data is high. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0017] Figure 1 A flow chart of a device positioning method provided by an embodiment of the present invention;
[0018] Figure 2 A system architecture diagram of an Android system provided by an embodiment of the present invention;
[0019] Figure 3 A flowchart of another device positioning method provided by an embodiment of the present invention;
[0020] Figure 4A schematic diagram of the structure of a device positioning apparatus provided by an embodiment of the present invention;
[0021] Figure 5 For Figure 4 A schematic structural diagram of a robot corresponding to the equipment positioning device provided in the illustrated embodiment. DETAILED DESCRIPTION
[0022] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0023] The terms used in the embodiments of the present invention are only for the purpose of describing specific embodiments, and are not intended to limit the present invention. The singular forms "a", "said" and "the" used in the embodiments of the present invention and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings, and "multiple" generally includes at least two, but does not exclude the situation of including at least one.
[0024] It should be understood that the term "and / or" used in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.
[0025] As used herein, the words "if" and "if" may be interpreted as "at the time of" or "when" or "in response to determining" or "in response to identifying", depending on the context. Similarly, the phrases "if it is determined" or "if (stated condition or event) is identified" may be interpreted as "when determining" or "in response to determining" or "when identifying (stated condition or event)" or "in response to identifying (stated condition or event)", depending on the context.
[0026] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a product or system including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such a product or system. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the product or system including the elements.
[0027] Some embodiments of the present invention are described in detail below in conjunction with the accompanying drawings. In the case where there is no conflict between the embodiments, the following embodiments and the features in the embodiments can be combined with each other. In addition, the step sequence in the following method embodiments is only an example and not a strict limitation.
[0028] Figure 1 The flowchart of a device positioning method provided by an embodiment of the present invention is a flowchart of a device positioning method provided by an embodiment of the present invention. The device positioning method provided by an embodiment of the present invention can be executed by a positioning device. It can be understood that the positioning device can be implemented as software, or a combination of software and hardware. In practice, the positioning device can be a terminal device. Figure 1 As shown, the method comprises the following steps:
[0029] 101. In response to the startup of the kernel of the terminal device, execute a startup script to allocate computing resources for acquiring positioning data.
[0030] For terminal devices supporting the Android system, optionally, it can be a self-moving service robot, such as the guide robot, commercial cleaning robot, household cleaning robot, etc. mentioned in the background technology. In response to the startup of the Android system, the kernel of the Android system will also be further started. Then the terminal device can further execute the startup script in response to the startup of the kernel. Optionally, the startup script can be an init.rc file. By executing the startup script to realize the allocation of computing resources, that is, by executing the startup script, the terminal device can divide a part of its own computing resources, which is specifically used to obtain the positioning data of the terminal device itself.
[0031] 102. In the kernel, use the allocated computing resources to execute a positioning data acquisition program to obtain the positioning data of the terminal device.
[0032] Then, the terminal device can use the allocated computing resources in the kernel to execute a positioning data acquisition program, thereby obtaining the positioning data of the terminal device itself.
[0033] Regarding the process of obtaining positioning data by executing a program, optionally, the terminal device can drive a positioning module configured in the terminal device by executing a positioning data acquisition program, so as to use the positioning module to collect the positioning data of the terminal device itself.
[0034] Optionally, the positioning module may be a global positioning system (GPS) module or a WiFi positioning module, etc. And at least one positioning module may be installed in the terminal device.
[0035] Among them, using the GPS positioning module, the terminal device can obtain its own positioning data by satellite positioning, base station positioning or Assisted Global Positioning System (AGPS). To simplify the description, the Assisted Global Positioning System can be referred to as Assisted Positioning. Using the WiFi positioning module, the terminal device can obtain its own positioning data by WiFi positioning. And the above-mentioned positioning methods are all common positioning methods in practice, and the specific positioning process will not be repeated here.
[0036] For the generation of the positioning data acquisition program, optionally, the developer can independently write a compilation script and a source file of the positioning data acquisition program, and compile the source file using the compilation script on a development device that also runs an Android system, thereby obtaining an executable file, namely, the positioning data acquisition program. Optionally, the development device can install the compiled positioning data acquisition program on the terminal device.
[0037] 103. Send the positioning data to the server so that the server can locate the terminal device.
[0038] Finally, the terminal device can send the positioning data to the server, and the server obtains the location of the terminal device, which means that the location of the terminal device is monitored.
[0039] For the positioning data obtained by executing the program, the terminal device can optionally store the positioning data in the form of a positioning file locally so that the user can search for the positioning data. Optionally, the terminal device can also send the positioning data in the form of a file to the server.
[0040] In this embodiment, in response to the startup of the kernel, the terminal device executes the startup script to allocate the computing resources of the terminal device itself, that is, to divide part of the computing resources to obtain positioning data. Then, the kernel continues to use the allocated computing resources to execute the positioning data acquisition program installed by the terminal device to obtain the positioning data of the terminal device. Finally, the positioning data of the terminal device is sent to the server so that the server obtains the positioning data and realizes the monitoring of the location of the terminal device. In the above method, the terminal device directly runs the data acquisition program in the kernel to obtain the positioning data. The method of obtaining positioning data is simple and convenient, and the data acquisition efficiency is high.
[0041] In practice, since the server can obtain reliable and authentic terminal device positioning data, when the terminal device is lost, the server can also accurately locate the terminal device, thereby increasing the possibility of recovering the terminal device.
[0042] It should be noted that according to the method provided in the above embodiment, the server can monitor the position of the terminal device used by the user. In practice, the terminal device can also be a home or commercial self-propelled robot with a positioning function. According to the method in the above embodiment, the position of the self-propelled robot can also be monitored. At the same time, the server can also synchronize the obtained positioning data of the robot to other terminal devices used by the user, such as a mobile phone, so that the user can also monitor the position of the self-propelled robot and understand the movement of the self-propelled robot in a timely manner.
[0043] Optionally, the system architecture of the Android system supported by the terminal device can be shown as 2. Based on this system architecture, the process of device positioning can also be described as: in response to the startup of the APP installed in the terminal device, such as the takeaway APP or instant messaging APP mentioned in the background technology, the APP in the application layer of the system architecture can obtain the relevant functions encapsulated in the hardware layer through the architecture layer. Then, by executing the relevant functions encapsulated in the hardware layer, the positioning module in the kernel layer is driven to collect the positioning data of the terminal device, and finally the positioning data is reversely transmitted back to the application layer through the kernel layer, hardware layer, and architecture layer in the system architecture, so that the APP obtains the positioning data. At the same time, the positioning data can also be further forwarded to the server so that the server can realize the location monitoring of the terminal device.
[0044] In the above method, the acquisition of positioning data requires the application layer, architecture layer, hardware layer and kernel layer in the system architecture to work together, and the acquisition of positioning data can only be achieved when the APP is running. Therefore, the above positioning data acquisition process is cumbersome, and the time period for terminal device location monitoring is also limited, that is, monitoring can only be performed during the APP startup period.
[0045] And use Figure 1 In the device positioning method shown, the terminal device directly executes the positioning data acquisition program in the kernel, that is, even if the APP installed in the terminal device is in a closed state, the server can still monitor the location of the terminal device. Figure 1 The device positioning method shown does not rely on the startup of a certain APP in the terminal device, but relies on the startup of the terminal device. The server can monitor the location of the terminal device at any time after the Android system kernel is started, that is, there is no limit on the period of monitoring the location of the terminal device. Figure 1 In the device positioning method shown, the terminal device does not need to go through the architecture layer and hardware layer in the system architecture of the Android system. All processing is performed in the kernel layer in the system architecture, thereby ensuring the convenience of obtaining positioning data.
[0046] In addition, in practice, a virtual positioning program can also be installed in the terminal device. When the APP and the virtual positioning program in the terminal device are running at the same time, the virtual positioning program can tamper with the positioning data collected by the positioning module with the help of the architecture layer in the system architecture, and transmit the tampered positioning data back to the APP and the server. At this time, the positioning data obtained by the server is false, which directly leads to the server's actual invalidity of monitoring the location of the terminal device.
[0047] Since virtual positioning software can only be embedded in the architecture layer of the system architecture and cannot be embedded in the kernel layer, Figure 1 In the device positioning method shown, the virtual positioning program cannot tamper with the positioning data obtained by executing the program in the kernel, which can avoid the situation where the above-mentioned virtual positioning program tampers with the positioning data, so that the server can obtain real and reliable positioning data, ensuring the effectiveness of terminal device location monitoring.
[0048] According to the above analysis, compared with obtaining positioning data through the multi-layer collaborative work in the system architecture, using Figure 1 The device positioning method shown has the above advantages. And when the device positioning method provided by the following embodiments of the present invention is used for positioning, the above advantages are also obtained. The specific reasons can be found in the above content.
[0049] It is easy to understand that the positioning data acquisition program can be composed of functions, such as a positioning data acquisition function, i.e., a callback function. And in order to ensure the normal operation of the program, when the positioning data acquisition program is first run, it is necessary to initialize the function first, i.e., initialize the data acquisition function. After initialization, the data acquisition function can be called using the computing resources allocated to the positioning data acquisition program to obtain positioning data.
[0050] and Figure 1 In the embodiment shown, the specific process of executing the positioning data acquisition program to obtain positioning data may be: executing the positioning data acquisition program to drive the positioning module of the terminal device to collect positioning data. In combination with the function calling process described above, the positioning data acquisition process is specifically: using the computing resources allocated to the positioning data acquisition program to call the data acquisition function in the program to drive the positioning module of the terminal device to collect positioning data.
[0051] Optionally, the positioning data acquisition program may also include a format setting function and a filtering function. Similar to the data acquisition function, these two functions also need to be initialized before the positioning data acquisition program is first run. After initialization, the positioning data acquisition program can be run according to the following procedures: Figure 3 The method provided by the illustrated embodiment realizes the positioning of the terminal device.
[0052] Figure 3 FIG. 1 is a flow chart of another device positioning method provided by an embodiment of the present invention. Figure 3 As shown, the method may include the following steps:
[0053] 201 , in response to the startup of the kernel of the terminal device, executing a startup script to allocate computing resources for acquiring positioning data.
[0054] The execution process of step 201 is similar to the corresponding steps of the above-mentioned embodiment, and can be seen in FIG. Figure 1 The relevant description in the illustrated embodiment will not be repeated here.
[0055] 202. Using the allocated computing resources, call a data acquisition function to acquire positioning data obtained by the terminal device through different positioning methods.
[0056] After the terminal device allocates computing resources for acquiring positioning data, it can use the allocated computing resources to call a data acquisition function to obtain positioning data obtained by the terminal device through different positioning methods.
[0057] Optionally, as Figure 1 The positioning methods mentioned in the illustrated embodiments may include base station positioning, WiFi positioning, satellite positioning, auxiliary positioning, etc. The GPS positioning module configured in the terminal device can be used to obtain positioning data collected by base station positioning, satellite positioning, auxiliary satellite positioning, etc.; the WiFi module configured in the terminal device can be used to obtain positioning data collected by WiFi positioning.
[0058] And the positioning data obtained by different positioning methods often have different data formats. For example, the positioning data obtained by satellite positioning may include longitude, latitude, satellite speed, direction and other information. The positioning data obtained by WiFi positioning may include the Mac address, longitude, latitude and other information of the terminal device.
[0059] 203, calling a format setting function to obtain a preset format of the positioning data, where the preset format corresponds to the positioning method.
[0060] 204 , calling a filtering function to determine positioning data having a preset format from positioning data obtained through different positioning methods.
[0061] After obtaining positioning data of different formats by calling the data acquisition function, the target format of the positioning data can also be obtained by calling the format setting function. The target format can correspond to one or several positioning methods. Among them, the target format can be manually set according to the requirements for positioning accuracy.
[0062] Optionally, in practice, the positioning data obtained by using the GPS positioning module in a satellite positioning mode is usually the most accurate, so the target format is the data format of the positioning data obtained by setting the satellite positioning mode. Based on the set target format, the filtering function in the positioning data acquisition program can be called to filter out the positioning data that does not have the target format from all the acquired positioning data.
[0063] 205 , sending the positioning data to the server so that the server can locate the terminal device.
[0064] The execution process of step 205 is similar to the corresponding steps of the above-mentioned embodiment, and can be seen in FIG. Figure 1 The relevant description in the illustrated embodiment will not be repeated here.
[0065] In this embodiment, the terminal device's own positioning data is finally obtained by calling different functions in the positioning data acquisition program. When the terminal device is configured with different positioning modules to obtain positioning data collected in different ways and in different formats, the actual application scenario can also be considered to select the positioning data with the target format, that is, the server uses the positioning data with the target format to monitor the location of the terminal device to ensure the accuracy of the monitoring.
[0066] On the basis of the above embodiments, the device positioning methods provided by the above embodiments may be described below in conjunction with a scenario of positioning a self-moving robot.
[0067] For a self-moving robot that supports the Android system, in response to the startup of the self-moving robot, its system kernel will also start, and further execute the startup script to allocate certain computing resources for the acquisition of positioning data. Afterwards, in the kernel of the Android system, the positioning data acquisition program is executed using the allocated computing resources to obtain the positioning data of the self-moving robot. And the positioning data can also be sent to the server maintained by the developer of the self-moving robot and the terminal devices such as mobile phones and computers used by the user, so that the terminal device and the server can monitor the position of the self-moving robot. Optionally, the terminal device used by the user can be installed with an APP that matches the self-moving robot, and the positioning data of the self-moving robot can be displayed on the display interface provided by the APP installed on the terminal device.
[0068] The process of executing the data acquisition program to obtain positioning data can be as follows: when the data acquisition program is run for the first time, the data acquisition function, format setting function and filter function included in the program are initialized. After initialization, the kernel calls the data acquisition function to drive the GPS positioning module and WiFi positioning module configured in the mobile robot so that different positioning modules can collect positioning data in different formats. Then, the kernel calls the format setting function to determine the target format set in advance. Then call the filter function to filter out the positioning data with the target format from the positioning data of different formats collected by different positioning modules. Among them, the target format corresponds to a positioning method, and the setting of the target format is related to the positioning accuracy.
[0069] If the application layer, framework layer, hardware layer, and kernel layer in the Android system work together to obtain positioning data, the virtual positioning software installed in the self-moving robot can tamper with the positioning data of the self-moving robot at the framework layer. For example, the position of the self-moving robot can be tampered with from the working area to the charging area. At this time, the user and the developer of the self-moving robot will mistakenly believe that the self-moving robot has completed the corresponding task and is resting in the charging area, but in fact the self-moving robot has not completed the task.
[0070] The device positioning method provided by each embodiment of the present invention is that the terminal device directly executes the program in the kernel to obtain the positioning data. The positioning data is obtained in a simple manner and at a fast speed. In addition, the virtual positioning program cannot tamper with the positioning data obtained in the kernel, which ensures that the server and the terminal device used by the user obtain real and reliable positioning data, avoiding the above situation.
[0071] The following will describe in detail the device positioning apparatus of one or more embodiments of the present invention. Those skilled in the art will appreciate that these device positioning apparatuses can be configured using commercially available hardware components through the steps taught in this solution.
[0072] Figure 4 A schematic diagram of the structure of a device positioning apparatus provided by an embodiment of the present invention is shown in FIG. Figure 4 As shown, the device comprises:
[0073] The first execution module 11 is used for executing a startup script in response to the startup of the kernel of the terminal device to allocate computing resources for acquiring positioning data.
[0074] The second execution module 12 is used to execute a positioning data acquisition program in the kernel using the allocated computing resources to obtain the positioning data of the terminal device.
[0075] The sending module 13 is used to send the positioning data to a server so that the server can locate the terminal device.
[0076] Optionally, the second execution module 12 is specifically used to: use the allocated computing resources to execute the positioning data acquisition program to drive the positioning module in the terminal device to obtain the positioning data collected by the positioning module.
[0077] Optionally, the device further comprises: an initialization module 14, configured to initialize a data acquisition function in the positioning data acquisition program in response to the first running of the positioning data acquisition program.
[0078] The second execution module 12 is specifically used to call the data acquisition function using the allocated computing resources to obtain the positioning data.
[0079] Optionally, the initialization module 14 is further used to initialize a format setting function and a filtering function in the positioning data acquisition program.
[0080] The second execution module 12 is specifically used to: use the allocated computing resources to call the data acquisition function to acquire the positioning data obtained by the terminal device through different positioning methods;
[0081] Calling the format setting function to obtain the target format of the positioning data, wherein the target format corresponds to the positioning mode;
[0082] The filtering function is called to determine the positioning data having the target format from the positioning data obtained by the different positioning methods.
[0083] Among them, positioning methods include satellite positioning, base station positioning, and WiFi positioning.
[0084] Optionally, the apparatus further comprises: an installation module 15, configured to install the positioning data acquisition program provided by the development device, wherein the positioning data acquisition program is an executable file obtained by compiling a source file using a compilation script.
[0085] Optionally, the sending module 13 is specifically used to: generate a positioning file containing the positioning data;
[0086] The positioning file is sent to the server for the server to parse and obtain positioning data.
[0087] Figure 4 The device shown can perform Figures 1 to 3 For the method of the embodiment shown in the figure, the part not described in detail in this embodiment can be referred to Figures 1 to 3 The implementation process and technical effects of this technical solution refer to Figures 1 to 3 The description in the illustrated embodiment will not be repeated here.
[0088] The above describes the internal functions and structure of the equipment positioning device. In a possible design, the structure of the positioning device can be implemented as a robot, such as Figure 5 As shown, the robot may include: a processor 21 and a memory 22. The memory 22 is used to store the electronic device to perform the above Figures 1 to 3 The program of the device positioning method provided in the illustrated embodiment, the processor 31 is configured to execute the program stored in the memory 22 .
[0089] The program includes one or more computer instructions, wherein the one or more computer instructions can implement the following steps when executed by the processor 21:
[0090] In response to the startup of the kernel of the terminal device, executing a startup script to allocate computing resources for acquiring positioning data;
[0091] In the kernel, executing a positioning data acquisition program using the allocated computing resources to obtain positioning data of the terminal device;
[0092] The positioning data is sent to a server so that the server can locate the terminal device.
[0093] Optionally, the processor 31 is further configured to execute the aforementioned Figures 1 to 3 All or part of the steps in the illustrated embodiments.
[0094] The structure of the electronic device may further include a communication interface 23 for the electronic device to communicate with other devices or a communication network.
[0095] In addition, an embodiment of the present invention provides a computer storage medium for storing computer software instructions used by the above electronic device, which includes instructions for executing the above Figures 1 to 3 The procedures involved in the device positioning method in the method embodiment shown.
[0096] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A device positioning method, characterized in that: Applied to terminal equipment, including: In response to the startup of the kernel of the terminal device, executing a startup script to allocate computing resources for acquiring positioning data; In the kernel, the positioning data acquisition program is executed using the allocated computing resources to obtain the positioning data of the terminal device, wherein the development device running the Android system compiles the source file of the positioning data acquisition program using a compilation script to obtain the positioning data acquisition program installed on the terminal device; The positioning data is sent to a server so that the server can locate the terminal device.
2. The method according to claim 1, characterized in that The step of using the allocated computing resources to execute a positioning data acquisition program to obtain the positioning data of the terminal device includes: The positioning data acquisition program is executed using the allocated computing resources to drive the positioning module in the terminal device to obtain the positioning data collected by the positioning module.
3. The method according to claim 1, characterized in that The method further comprises: In response to the first running of the positioning data acquisition program, initializing a data acquisition function in the positioning data acquisition program; The step of using the allocated computing resources to execute a positioning data acquisition program to obtain the positioning data of the terminal device includes: The data acquisition function is called using the allocated computing resources to obtain the positioning data.
4. The method according to claim 3, characterized in that The method further comprises: Initializing the format setting function and the filtering function in the positioning data acquisition program; The step of using the allocated computing resources to execute a positioning data acquisition program to obtain the positioning data of the terminal device includes: Using the allocated computing resources to call the data acquisition function, the positioning data obtained by the terminal device through different positioning methods are acquired; Calling the format setting function to obtain a preset format of the positioning data, wherein the preset format corresponds to the positioning method; The filtering function is called to determine the positioning data having the preset format from the positioning data obtained by the different positioning methods.
5. The method according to claim 4, characterized in that Positioning methods include satellite positioning, base station positioning, and WiFi positioning.
6. The method according to claim 1, characterized in that The sending the positioning data to the server comprises: generating a positioning file containing the positioning data; The positioning file is sent to the server for the server to parse and obtain positioning data.
7. A device positioning device, characterized in that: include: A first execution module is used to execute a startup script in response to the startup of the terminal device kernel to allocate computing resources for obtaining positioning data; A second execution module is used to execute a positioning data acquisition program in the kernel using the allocated computing resources to obtain the positioning data of the terminal device, wherein the development device running the Android system compiles the source file of the positioning data acquisition program using a compilation script to obtain the positioning data acquisition program installed on the terminal device; The sending module is used to send the positioning data to a server so that the server can locate the terminal device.
8. A robot, characterized in that: include: A memory and a processor; wherein the memory stores executable code, and when the executable code is executed by the processor, the processor executes the device positioning method according to any one of claims 1 to 6.
9. A non-transitory machine-readable storage medium, characterized in that: The non-transitory machine-readable storage medium stores executable code, and when the executable code is executed by a processor of an electronic device, the processor is caused to execute the device positioning method according to any one of claims 1 to 6.
