Disclosure of Invention
In view of this, the present invention aims to provide an intelligent terminal positioning system and method and an electronic device, in which a plurality of intelligent terminals share electric quantity information in a cluster manner, so as to improve the quantity and accuracy of geographical location information acquired by the intelligent terminals.
In a first aspect, an embodiment of the present invention provides an intelligent terminal positioning system, where the system includes: the system comprises a plurality of intelligent terminals and a server; each intelligent terminal is communicated with the server, and is provided with a sensor;
the intelligent terminals are used for establishing near field communication when monitoring preset time drive so that each intelligent terminal can share electric quantity information through the near field communication; determining a target intelligent terminal corresponding to the maximum electric quantity according to the electric quantity information so that the target intelligent terminal collects self geographical position information through the set sensor and sends the self geographical position information and relative position information of the other intelligent terminals to the server;
and the server is used for obtaining the position information of the intelligent terminals according to the self geographical position information and the relative position information of the target intelligent terminal.
With reference to the first aspect, an embodiment of the present invention provides a first possible implementation manner of the first aspect, where the step of establishing near field communication when the driving of the preset time is monitored includes:
the plurality of intelligent terminals are further used for generating near field communication information when any intelligent terminal reaches the preset time, and sending the near field communication information to the rest of intelligent terminals, so that the rest of intelligent terminals generate reply information according to the near field communication information to establish the near field communication.
With reference to the first possible implementation manner of the first aspect, an embodiment of the present invention provides a second possible implementation manner of the first aspect, where the step of determining, by the multiple intelligent terminals according to the electric quantity information, a target intelligent terminal corresponding to the maximum value of the electric quantity includes:
and the plurality of intelligent terminals are further used for comparing the electric quantity information of the rest intelligent terminals with the electric quantity information of the intelligent terminals after the electric quantity information is shared through the near field communication, and determining a target intelligent terminal corresponding to the maximum electric quantity according to a comparison result.
With reference to the second possible implementation manner of the first aspect, an embodiment of the present invention provides a third possible implementation manner of the first aspect, where each of the intelligent terminals compares the electric quantity information of the other intelligent terminals with the electric quantity information of the intelligent terminal, and determines, according to a comparison result, a target intelligent terminal corresponding to the maximum electric quantity value, further includes:
and each intelligent terminal compares the electric quantity information of the rest intelligent terminals with the self electric quantity information, and if the electric quantity information of the rest intelligent terminals is smaller than the self electric quantity information of the current intelligent terminal, the current intelligent terminal is the target intelligent terminal.
With reference to the first aspect, an embodiment of the present invention provides a fourth possible implementation manner of the first aspect, where the step of the server, configured to obtain location information of a plurality of intelligent terminals according to the own geographic location information and the relative location information of the target intelligent terminal, further includes:
and the server is used for obtaining the position information of a plurality of intelligent terminals according to the self geographical position information of the target intelligent terminal, the relative position information of the rest intelligent terminals and the target intelligent terminal, and the identification information of each rest intelligent terminal.
With reference to the fourth possible implementation manner of the first aspect, an embodiment of the present invention provides a fifth possible implementation manner of the first aspect, where the self geographic location information includes one or more of the following information: longitude information, latitude information, and altitude information.
With reference to the fourth possible implementation manner of the first aspect, an embodiment of the present invention provides a sixth possible implementation manner of the first aspect, where the relative location information includes relative distances and relative angles between the other intelligent terminals and the target intelligent terminal.
In a second aspect, an embodiment of the present invention further provides an intelligent terminal positioning method, where the method is applied to the intelligent terminal positioning system in the first aspect, and the method includes:
when monitoring the preset time drive, a plurality of intelligent terminals establish near field communication so that each intelligent terminal shares electric quantity information through the near field communication; determining a target intelligent terminal corresponding to the maximum electric quantity according to the electric quantity information so that the target intelligent terminal collects self geographical position information through a set sensor and sends the self geographical position information and relative position information of the other intelligent terminals to a server;
and the server obtains the position information of the intelligent terminals according to the geographical position information and the relative position information of the target intelligent terminal.
In a third aspect, an embodiment of the present invention further provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor implements the steps of the intelligent terminal positioning method according to the second aspect when executing the computer program.
In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the steps of the intelligent terminal positioning method according to the second aspect are executed.
The embodiment of the invention has the following beneficial effects:
the embodiment of the invention provides an intelligent terminal positioning system and method and electronic equipment, wherein the intelligent terminal positioning system comprises the following steps: the system comprises a plurality of intelligent terminals and a server; each intelligent terminal is communicated with the server, and is provided with a sensor; the intelligent terminals are used for establishing near field communication when the preset time drive is monitored, so that each intelligent terminal can share electric quantity information through the near field communication; determining a target intelligent terminal corresponding to the maximum electric quantity according to the electric quantity information so that the target intelligent terminal acquires geographical position information of the target intelligent terminal through a set sensor and sends the geographical position information of the target intelligent terminal and relative position information of the target intelligent terminal and other intelligent terminals to a server; and the server is used for obtaining the position information of the intelligent terminals according to the self geographical position information and the relative position information of the target intelligent terminal. In the application, a plurality of intelligent terminals share electric quantity information in a cluster mode, and the quantity and the precision of the geographical position information acquired by the intelligent terminals are improved.
Additional features and advantages of the invention will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice of the invention. The objectives and other advantages of the invention will be realized and attained by the structure particularly pointed out in the written description and drawings.
In order to make the aforementioned and other objects, features and advantages of the present invention comprehensible, preferred embodiments accompanied with figures are described in detail below.
Detailed Description
To make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some, but not all embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Aiming at the problem that the quantity and the precision of the geographic position information acquired by the existing intelligent terminal are not ideal, the embodiment of the invention provides an intelligent terminal positioning system, an intelligent terminal positioning method and electronic equipment.
To facilitate understanding of the embodiment, first, a detailed description is given below of an intelligent terminal positioning system provided in the embodiment of the present invention.
The first embodiment is as follows:
an embodiment of the present invention provides an intelligent terminal positioning system, and fig. 1 is a schematic diagram of an intelligent terminal positioning system provided in an embodiment of the present invention. As shown in fig. 1, the system includes: a plurality of intelligent terminals 10 and a server 20; wherein, every intelligent terminal all communicates with the server, and, every intelligent terminal is provided with the sensor.
The intelligent terminals are used for establishing near field communication when monitoring preset time drive so that each intelligent terminal can share electric quantity information through the near field communication; and determining a target intelligent terminal corresponding to the maximum value of the electric quantity according to the electric quantity information so that the target intelligent terminal collects the geographical position information of the target intelligent terminal through a set sensor and sends the geographical position information of the target intelligent terminal and the relative position information of the target intelligent terminal and the rest intelligent terminals to a server.
Specifically, for a plurality of intelligent terminals, when any intelligent terminal reaches a preset time, near field communication information is generated, and the near field communication information is sent to the other intelligent terminals, so that the other intelligent terminals generate reply information according to the near field communication information to establish near field communication. The preset time of each intelligent terminal can be the same or different, when a certain intelligent terminal reaches the preset time, the intelligent terminal generates near field communication information and sends the near field communication information to other intelligent terminals, and at the moment, the other intelligent terminals generate reply information according to the near field communication information, so that near field communication is established between the intelligent terminal and the other intelligent terminals. In addition, for a cluster formed by a plurality of intelligent terminals, when any intelligent terminal in the cluster reaches a preset time, near field communication information can be generated so as to establish near field communication in the cluster, and for the rest intelligent terminals in the cluster receiving the near field communication information, if a certain intelligent terminal is in the near field communication process, at the moment, the intelligent terminal does not generate reply information after finishing the near field communication, namely does not participate in the near field communication establishment at the moment.
At this moment, after the near field communication is established by the plurality of intelligent terminals in the cluster, the electric quantity information is shared through the near field communication, at this moment, each intelligent terminal can obtain the electric quantity information of the intelligent terminal and the electric quantity information of the other intelligent terminals, the electric quantity information of the intelligent terminal is compared with the electric quantity information of the other intelligent terminals, and the target intelligent terminal corresponding to the maximum electric quantity value is determined according to the comparison result. Specifically, if the electric quantity information of the rest intelligent terminals is smaller than the self electric quantity information of the current intelligent terminal, the current intelligent terminal is the target intelligent terminal.
After the target intelligent terminal is determined, the target intelligent terminal starts to acquire self geographical position information through the set sensor, and determines the relative position information of the target intelligent terminal and other intelligent terminals according to the signal intensity of near field communication with other intelligent terminals; the self geographical position information comprises one or more of the following information: longitude information, latitude information, and altitude information; the relative position information comprises relative distances and relative angles between the other intelligent terminals and the target intelligent terminal; the relative distance between the other intelligent terminals and the target intelligent terminal is roughly determined according to the signal intensity of near field communication, meanwhile, the included angle between any one of the other intelligent terminals and the target intelligent terminal can be obtained through the measurement of the deviation angle of the signal, the calculation is carried out through polar coordinates, the relative position information between any one of the other intelligent terminals and the target intelligent terminal is obtained, similarly, the relative position information between each intelligent terminal and the target intelligent terminal in the other intelligent terminals can be obtained, and finally, the target intelligent terminal sends the geographical position information of the target intelligent terminal and the relative position information between the target intelligent terminal and the other intelligent terminals to the server.
At this time, the server is used for obtaining the position information of the intelligent terminals according to the self geographical position information and the relative position information of the target intelligent terminal.
Specifically, the server obtains the position information of the plurality of intelligent terminals according to the geographical position information of the target intelligent terminal, the relative position information of the other intelligent terminals and the target intelligent terminal, and the identification information of each other intelligent terminal.
Specifically, each intelligent terminal is also provided with unique identification information, and after the server receives the self geographical position information of the target intelligent terminal and the relative position information of the other intelligent terminals and the target intelligent terminal, the server also receives the self geographical position information of the target intelligent terminal and the relative position information of the other intelligent terminals and the target intelligent terminal according to the self geographical position information of the target intelligent terminal and the self geographical position information of the target intelligent terminalThe relative position information between a certain intelligent terminal and the target intelligent terminal in the rest intelligent terminals and the identification information of the intelligent terminal obtain the position information of the intelligent terminal, for example: if a cluster comprises an intelligent terminal A, an intelligent terminal B and an intelligent terminal C, in addition, the intelligent terminal A, the intelligent terminal B and the intelligent terminal C are in near field communication, in addition, the intelligent terminal A is a target intelligent terminal, the intelligent terminal A acquires self position information (x, y) through a sensor arranged by the intelligent terminal A, and phase position information (x, y) of the intelligent terminal B and the intelligent terminal A is acquired through the near field communicationab,yab) And phase position information (x) of the intelligent terminal C and the intelligent terminal Aac,yac) And (x, y), (x)ab,yab) And (x)ac,yac) Sending to the server, wherein the server is according to (x, y), (x)ab,yab) And (x)ac,yac) And the identification information of the intelligent terminal B and the identification information of the intelligent terminal C are obtained, and the position information of the intelligent terminal B and the position information of the intelligent terminal C are obtained.
Similarly, the server can obtain the position information of all the intelligent terminals in the rest of the intelligent terminals, and the position information of the target intelligent terminal is combined, so that the final server can obtain the position information of the intelligent terminals in the cluster, and the position information of the intelligent terminals is sent to all the intelligent terminals in the cluster, so that each intelligent terminal in the cluster finally obtains the position information of the intelligent terminal and the position information of the rest of the intelligent terminals, namely the intelligent terminals in the cluster share the acquired geographical position information, and the quantity and the precision of the geographical position information acquired by the intelligent terminals are improved under the consumption of the same electric quantity.
The intelligent terminal positioning system provided by the embodiment of the invention comprises: the system comprises a plurality of intelligent terminals and a server; each intelligent terminal is communicated with the server, and is provided with a sensor; the intelligent terminals are used for establishing near field communication when the preset time drive is monitored, so that each intelligent terminal can share electric quantity information through the near field communication; determining a target intelligent terminal corresponding to the maximum electric quantity according to the electric quantity information so that the target intelligent terminal acquires geographical position information of the target intelligent terminal through a set sensor and sends the geographical position information of the target intelligent terminal and relative position information of the target intelligent terminal and other intelligent terminals to a server; and the server is used for obtaining the position information of the intelligent terminals according to the self geographical position information and the relative position information of the target intelligent terminal. In the application, a plurality of intelligent terminals share electric quantity information in a cluster mode, and the quantity and the precision of the geographical position information acquired by the intelligent terminals are improved.
This is illustrated here for ease of understanding. As shown in fig. 2, in the existing method, an intelligent terminal a and an intelligent terminal B may respectively acquire 10 pieces of geographic position information, the acquired positioning accuracy is 30m, and the power consumption is X, and the acquired geographic position information is sent to a client, so that a user can obtain, through the client, 10 pieces of geographic position information, the accuracy of which is 30m, from the intelligent terminal a and the intelligent terminal B. When the intelligent terminal positioning system provided by the embodiment of the invention is adopted, as shown in fig. 3, an intelligent terminal a and an intelligent terminal B form a cluster, and the cluster is communicated in a near field communication mode, at this time, the power consumption of the intelligent terminal a and the intelligent terminal B is still X, and when the intelligent terminal a is a target intelligent terminal, the intelligent terminal a can obtain 7 pieces of acquired self geographical position information and the relative geographical position information of the 7 pieces of intelligent terminal B relative to the intelligent terminal a through a sensor arranged by the intelligent terminal a, and send the information to a server, so that the server can obtain the position information of the 7 pieces of intelligent terminal B according to the 7 pieces of self geographical position information and the relative geographical position information of the 7 pieces of intelligent terminal B relative to the intelligent terminal a, send the position information of the 7 pieces of intelligent terminal B to the intelligent terminal a, and send the position information of the 7 pieces of intelligent terminal a to the intelligent terminal B, at this moment, the user can see that the intelligent terminal A and the intelligent terminal B respectively have 14 pieces of geographical position information with the precision of 15m, so that the quantity and the precision of the geographical position information collected by the intelligent terminal A and the intelligent terminal B are improved under the condition that the intelligent terminal A and the intelligent terminal B consume the same electric quantity.
On the basis of the above embodiments, the embodiments of the present invention provide an intelligent terminal positioning method, which is applied to the above intelligent terminal positioning system. Fig. 4 is a flowchart of an intelligent terminal positioning method according to an embodiment of the present invention, and as shown in fig. 4, the method includes the following steps:
step S102, when a plurality of intelligent terminals monitor the preset time drive, establishing near field communication so that each intelligent terminal shares electric quantity information through the near field communication; determining a target intelligent terminal corresponding to the maximum electric quantity according to the electric quantity information so that the target intelligent terminal acquires geographical position information of the target intelligent terminal through a set sensor and sends the geographical position information of the target intelligent terminal and relative position information of the target intelligent terminal and other intelligent terminals to a server;
and step S104, the server obtains the position information of the intelligent terminals according to the geographical position information and the relative position information of the target intelligent terminal.
The intelligent terminal positioning method provided by the embodiment of the invention is applied to an intelligent terminal positioning system and comprises the following steps: the system comprises a plurality of intelligent terminals and a server; each intelligent terminal is communicated with the server, and is provided with a sensor; the intelligent terminals are used for establishing near field communication when the preset time drive is monitored, so that each intelligent terminal can share electric quantity information through the near field communication; determining a target intelligent terminal corresponding to the maximum electric quantity according to the electric quantity information so that the target intelligent terminal acquires geographical position information of the target intelligent terminal through a set sensor and sends the geographical position information of the target intelligent terminal and relative position information of the target intelligent terminal and other intelligent terminals to a server; and the server is used for obtaining the position information of the intelligent terminals according to the self geographical position information and the relative position information of the target intelligent terminal. In the application, a plurality of intelligent terminals share electric quantity information in a cluster mode, and the quantity and the precision of the geographical position information acquired by the intelligent terminals are improved.
The embodiment of the present invention further provides an electronic device, which includes a memory, a processor, and a computer program stored in the memory and capable of running on the processor, and when the processor executes the computer program, the steps of the intelligent terminal positioning method provided in the above embodiment are implemented.
The embodiment of the invention also provides a computer-readable storage medium, wherein a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the steps of the intelligent terminal positioning method of the embodiment are executed.
The computer program product provided in the embodiment of the present invention includes a computer-readable storage medium storing a program code, where instructions included in the program code may be used to execute the method described in the foregoing method embodiment, and specific implementation may refer to the method embodiment, which is not described herein again.
It can be clearly understood by those skilled in the art that, for convenience and brevity of description, the specific working process of the system described above may refer to the corresponding process in the foregoing method embodiment, and is not described herein again.
In addition, in the description of the embodiments of the present invention, unless otherwise explicitly specified or limited, the terms "mounted," "connected," and "connected" are to be construed broadly, e.g., as meaning either a fixed connection, a removable connection, or an integral connection; can be mechanically or electrically connected; they may be connected directly or indirectly through intervening media, or they may be interconnected between two elements. The specific meanings of the above terms in the present invention can be understood in specific cases to those skilled in the art.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a non-volatile computer-readable storage medium executable by a processor. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
In the description of the present invention, it should be noted that the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer", etc., indicate orientations or positional relationships based on the orientations or positional relationships shown in the drawings, and are only for convenience of description and simplicity of description, but do not indicate or imply that the device or element being referred to must have a particular orientation, be constructed and operated in a particular orientation, and thus, should not be construed as limiting the present invention. Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance.
Finally, it should be noted that: the above-mentioned embodiments are only specific embodiments of the present invention, which are used for illustrating the technical solutions of the present invention and not for limiting the same, and the protection scope of the present invention is not limited thereto, although the present invention is described in detail with reference to the foregoing embodiments, those skilled in the art should understand that: any person skilled in the art can modify or easily conceive the technical solutions described in the foregoing embodiments or equivalent substitutes for some technical features within the technical scope of the present disclosure; such modifications, changes or substitutions do not depart from the spirit and scope of the embodiments of the present invention, and they should be construed as being included therein. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.