CN116264719A - Method, terminal and communication system for generating electronic fence - Google Patents

Method, terminal and communication system for generating electronic fence Download PDF

Info

Publication number
CN116264719A
CN116264719A CN202111529772.0A CN202111529772A CN116264719A CN 116264719 A CN116264719 A CN 116264719A CN 202111529772 A CN202111529772 A CN 202111529772A CN 116264719 A CN116264719 A CN 116264719A
Authority
CN
China
Prior art keywords
access point
area
terminal
calibrated
access points
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111529772.0A
Other languages
Chinese (zh)
Inventor
黄龙
陈志辉
江洪泽
范昊深
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Honor Device Co Ltd
Original Assignee
Honor Device Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Honor Device Co Ltd filed Critical Honor Device Co Ltd
Priority to CN202111529772.0A priority Critical patent/CN116264719A/en
Publication of CN116264719A publication Critical patent/CN116264719A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W36/00Hand-off or reselection arrangements
    • H04W36/0005Control or signalling for completing the hand-off
    • H04W36/0083Determination of parameters used for hand-off, e.g. generation or modification of neighbour cell lists
    • H04W36/0085Hand-off measurements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W36/00Hand-off or reselection arrangements
    • H04W36/24Reselection being triggered by specific parameters
    • H04W36/30Reselection being triggered by specific parameters by measured or perceived connection quality data
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W36/00Hand-off or reselection arrangements
    • H04W36/24Reselection being triggered by specific parameters
    • H04W36/32Reselection being triggered by specific parameters by location or mobility data, e.g. speed data
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W36/00Hand-off or reselection arrangements
    • H04W36/08Reselecting an access point
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W36/00Hand-off or reselection arrangements
    • H04W36/14Reselecting a network or an air interface
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/02Services making use of location information
    • H04W4/021Services related to particular areas, e.g. point of interest [POI] services, venue services or geofences
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Abstract

A method, a terminal and a communication system for generating an electronic fence. In this method, an electronic fence of a certain location (e.g. the location where an elevator hoistway or a device providing Wi-Fi network is located) may be calculated, and the terminal may trigger the execution of a certain function when the terminal enters or leaves the electronic fence of the location. For example, when the terminal determines that it enters an electronic fence of an elevator entrance, the connected Wi-Fi network may be switched to a cellular network.

Description

Method, terminal and communication system for generating electronic fence
Technical Field
The present application relates to the field of terminals and communications technologies, and in particular, to a method for generating an electronic fence, a terminal, and a communications system.
Background
The terminal may connect to an Access Point (AP) to access a wireless fidelity (wireless fidelity, wi-Fi) network corresponding to the AP, at which time the terminal may establish communications with other terminals through the Wi-Fi network. However, the coverage area of one Wi-Fi network is about 50-200 m, but in the coverage area, when an obstacle is encountered, part or all of the Wi-Fi network is shielded, so that the Wi-Fi signal strength is reduced, for example, when a user enters an elevator, the Wi-Fi network accessed by the terminal is shielded by the elevator, the signal quality is poor, the signal strength is reduced, the terminal cannot normally communicate, for example, cannot send a message, the playing video is stuck, and the user experience is poor.
Disclosure of Invention
A method, a terminal and a communication system for generating an electronic fence.
In some scenarios, when the terminal is disconnected from the Wi-Fi network of the access point to a certain extent, the terminal is connected to the cellular network, and normal communication is restored, and in this "post-remediation" mode, there is a situation that the terminal is stuck or cannot communicate for a period of time.
Compared with the mode of 'post-remediation', the mode of 'pre-prediction' can enable a user to have no sense on the reduction of network quality, and can inform the user electronic equipment that the network quality is predicted to be poor and is processed in advance, so that better user experience is obtained. The method includes the steps that an electronic fence of a blocking area (for example, an elevator hoistway area is a blocking area) is generated, a terminal of a user is matched with the electronic fence of the blocking area according to the detected characteristics of a signal of a wireless access point and the like after entering the blocking area again, if the characteristics of the signal of the wireless access point and the characteristics of the signal of the wireless access point are matched with the electronic fence of the blocking area, the terminal can be determined to enter the blocking area, and then the network of the terminal can be switched in advance before the network quality is about to be deteriorated (for example, the network quality is deteriorated when the terminal enters an elevator) (for example, the terminal is in the blocking area of the elevator hoistway area but does not enter the elevator).
In a first aspect, the present application provides a method for generating an electronic fence, which is applied to a communication system, where the communication system includes a terminal and a cloud server, and the method includes: the cloud server acquires a wireless network data set, wherein the wireless network data set comprises wireless network data sent by at least one terminal, and the wireless network data set comprises first wireless network data; the first wireless network data comprises a connected access point connected with a first terminal in an area to be calibrated, a WiFi list detected by the first terminal, and a cell identifier of a cell to which the area to be calibrated where the first terminal is located belongs; the first terminal is a terminal for transmitting the first wireless network data; the cloud server divides wireless network data which have the same cell identifier and have similar WiFi lists in the wireless network data set into a group to obtain two or more groups, wherein one group corresponds to one temporary area, and one temporary area comprises at least one piece of wireless network data; the cloud server determines the cell access point distance characteristics and the connected access point data corresponding to two or more temporary areas, wherein the cell access point distance characteristics and the connected access point data corresponding to a first temporary area are included; the intra-cell access point distance corresponding to the first temporary area is characterized by the corresponding relation between different access points and intra-cell distances in a WiFi list detected by the terminal in the first temporary area, wherein the intra-cell distances corresponding to the different access points are the relative distances between the access points and the first temporary area; the connected access point data corresponding to the first temporary area are connected access points included in each wireless network data in the first temporary area; the cloud server combines the access point distance features in the cells of the temporary areas with the same connected access point data to obtain at least one access point distance feature corresponding to the area to be calibrated, wherein the access point distance feature comprises a first access point distance feature corresponding to a first area to be calibrated, the first access point distance feature is the corresponding relation between different access points and area distances in a WiFi list detected by the terminal, and the area distances corresponding to the different access points are the relative distances between the access points and the first area to be calibrated; and the cloud server determines the access point distance characteristic corresponding to the first region to be calibrated as an electronic fence of the first region to be calibrated.
In some embodiments, the wireless network data set includes a large amount of wireless network data, and the cloud server calculates the electronic fence of different areas to be calibrated through the large amount of wireless network data, so that the calculation result is more accurate, the electronic fence of the area to be calibrated can be used for representing one area to be calibrated, and the area to be calibrated of the entity is dataized.
In combination with the content of the first aspect, in some embodiments, the cloud server merges the intra-cell access point distance features of the temporary area with the same connected access point data, and after obtaining the access point distance feature corresponding to the at least one to-be-calibrated area, the method further includes: the cloud server takes a connected access point corresponding to a temporary area involved in the electronic fence of the first area to be calibrated as connected access point data corresponding to the first area to be calibrated; and the cloud server identifies the electronic fence of the first region to be calibrated by utilizing the connected access point data corresponding to the first region to be calibrated.
In the above embodiment, the electronic fence of the first area to be calibrated may be identified by using the connected access point data, and the connected access point data may also be used as data in the electronic fence.
With reference to the first aspect, in some embodiments, the cloud server classifies wireless network data with the same cell identifier and similar WiFi list in the wireless network data set into a group, and specifically includes: the cloud server groups the wireless network data sets based on the cell identifiers to obtain two or more groups, wherein one group corresponds to one cell and comprises a first cell, and the first cell comprises at least one piece of wireless network data; for wireless network data included in the first cell, the cloud server groups wireless network data similar to a WiFi list into one group.
In the above embodiment, the cloud service first groups the wireless network data sets using the cell identities, and calculates for each group: and the similarity of the WiFi list is utilized to group a group of wireless network data again, and then calculation is carried out, so that the calculated amount can be reduced, and the calculation speed can be increased.
In combination with the content of the first aspect, in some embodiments, the cloud server determines that the two WiFi lists are similar in that: and in the two WiFi lists, the ratio of the same access points in the first WiFi list to the second WiFi list to all the access points in the first WiFi list reaches a first similar threshold.
In combination with the content of the first aspect, in some embodiments, the cloud server determines that the two WiFi lists are similar in that: and in the two WiFi lists, the first WiFi list and the second WiFi list are the same, and the ratio of the access points with the strength difference smaller than the preset strength value to all the access points in the first WiFi list reaches a second similar threshold.
In combination with the content of the first aspect, in some embodiments, before the cloud server determines the access point distance feature corresponding to the first to-be-calibrated area as the electronic fence of the first to-be-calibrated area, the method further includes: the cloud server acquires a connected access point intensity data set, wherein the connected access point intensity data set comprises connected access point intensity data sent by at least one terminal, the connected access point intensity data set comprises first connected access point intensity data, the first connected access point intensity data is the corresponding relation between the intensity of a connected access point and the connected access point, the connected access point intensity data set comprises first connected access points, and the first connected access points have the conditions corresponding to different intensities; the cloud server determines all intensities of the connected access points corresponding to the same connected access point in the connected access point intensity data set, and determines intensity thresholds corresponding to the same connected access point based on all the intensities to obtain intensity thresholds corresponding to different connected access points; the cloud server utilizes the different connected access points to match with the connected access point data corresponding to the first area to be calibrated, and determines all connected access points matched with the first area to be calibrated; the cloud server takes the corresponding relation between the intensity threshold values of all connected access points matched with the first region to be calibrated and the connected access points as the intensity characteristics of the connected access points corresponding to the first region to be calibrated; the cloud server determines the access point distance characteristic corresponding to the first region to be calibrated as an electronic fence of the first region to be calibrated, and specifically comprises the following steps: and the cloud server takes the access point distance characteristic corresponding to the first area to be calibrated and the strength characteristic of the connected access point as an electronic fence of the first area to be calibrated.
In combination with the content of the first aspect, in some embodiments, the cloud server determines an intra-cell access point distance feature and connected access point data corresponding to two or more temporary areas, where the intra-cell access point distance feature and the connected access point data corresponding to the first temporary area are included, and specifically includes: the cloud server determines all different connected access points in the wireless network data included in the first temporary area, and takes all different connected access points as connected access point data corresponding to the first temporary area; the cloud server calculates the distances of all access points included in all WiFi lists based on all WiFi lists in the wireless network data included in the first temporary area, wherein one distance corresponds to one access point, and the same access point has the conditions of corresponding to different distances; the cloud server determines all distances of the same access point based on the distances of all access points, and determines the average distance of the same access point based on the all distances to obtain the average distances of different access points; the cloud server takes the average distance of different access points as the intra-cell distance corresponding to the different access points, and obtains the corresponding relation between the different access points and the intra-cell distance; and the cloud server determines the intra-cell access distance characteristic corresponding to the first temporary area based on the corresponding relation between the different access points and the intra-cell distances.
In combination with the content of the first aspect, in some embodiments, the determining, by the cloud server, a intra-cell access point distance feature corresponding to the first temporary area based on a correspondence between the different access points and intra-cell distances specifically includes: and the cloud server takes the corresponding relation between the different access points and the intra-cell distances as the intra-cell access distance characteristic corresponding to the first temporary area.
In combination with the content of the first aspect, in some embodiments, the determining, by the cloud server, a intra-cell access point distance feature corresponding to the first temporary area based on a correspondence between the different access points and intra-cell distances specifically includes: and the cloud server determines all access points meeting the conditions in the different access points, and takes the corresponding relation between all access points meeting the conditions and the intra-cell distances as the intra-cell access point distance characteristic corresponding to the first temporary area, wherein the conditions are that the intra-cell distances corresponding to the access points are smaller than a first distance preset value.
With reference to the content of the first aspect, in some embodiments, the method further includes: the cloud server determines whether an electronic fence of the first area to be calibrated is available; in calculating all WiFi lists related to the electronic fence of the first area to be calibrated, when a qualified WiFi list reaches a first threshold value, the cloud server determines that the electronic fence of the first area to be calibrated is available, wherein all WiFi lists comprise a first WiFi list, and the condition that the first WiFi list is qualified is as follows: in the distances corresponding to all access points in the first WiFi list, the qualified distance is larger than a second threshold, all the access points in the first WiFi list comprise first access points, and the condition that the distance corresponding to the first access points is the qualified distance is as follows: the distance corresponding to the first access point is smaller than a distance preset difference value from the access point distance characteristic of the electronic fence of the first area to be calibrated; and when determining that all WiFi lists corresponding to the electronic fences of the first area to be calibrated are calculated, determining that the electronic fences of the first area to be calibrated are unavailable by the cloud server.
With reference to the content of the first aspect, in some embodiments, the method further includes: the cloud server determines a matching threshold parameter of the electronic fence of the first area to be calibrated, the matching threshold parameter is used for determining whether the WiFi list acquired by the terminal is matched with the electronic fence of the first area to be calibrated, the matching threshold parameter comprises a qualified access point number threshold and a qualified distance number threshold, the qualified access point number threshold is used for representing the minimum number of qualified access points in all access points included in the WiFi list acquired by the terminal, the qualified access point is an access point which is the same as a certain access point included in the access point distance characteristic of the electronic fence of the first area to be calibrated in all access points of the WiFi list acquired by the terminal, the qualified distance number threshold is used for representing the minimum number of qualified distances in all access points included in the WiFi list acquired by the terminal, and the distance corresponding to the qualified access point is the difference between the distance corresponding to the qualified access point and the distance corresponding to the qualified access point of the electronic fence of the first area to be calibrated and the preset distance is smaller than the difference between the distances corresponding to the qualified access points and the access points of the electronic fence of the first area to be calibrated.
With reference to the content of the first aspect, in some embodiments, the method further includes: after the terminal is connected with a second access point, the terminal acquires a first electronic fence corresponding to the second access point from the cloud server, wherein the connected access point data of the first electronic fence comprises the second access point; the terminal determines that the intensity of the second access point is matched with an intensity threshold corresponding to the second access point, wherein the intensity threshold is an intensity threshold corresponding to the second access point included in the access point intensity characteristic of the first electronic fence, then the terminal acquires a second WiFi list, and the terminal determines that the second WiFi list is matched with the first electronic fence based on a matching threshold parameter corresponding to the first electronic fence; and the terminal disconnects the second access point and switches to the cellular network.
In the above embodiment, the electronic fence for generating the area to be calibrated may determine whether the terminal enters the area to be calibrated, for example, the area to be calibrated may be an elevator hoistway, and after determining that the terminal reaches the elevator hoistway, the first access point may be disconnected and switched to the cellular network.
In a second aspect, the present application provides an electronic device, comprising: one or more processors and memory; the memory is coupled to the one or more processors, the memory for storing computer program code comprising computer instructions that the one or more processors call to cause the electronic device to perform the method as described in the first aspect or any implementation of the first aspect.
In the above embodiment, the wireless network data set includes a large amount of wireless network data, and the cloud server calculates the electronic fence of different areas to be calibrated through the large amount of wireless network data, so that the calculation result is more accurate, the electronic fence of the area to be calibrated can be used for representing one area to be calibrated, and the area to be calibrated of the entity is dataized.
In a third aspect, embodiments of the present application provide a chip system for application to an electronic device, the chip system comprising one or more processors configured to invoke computer instructions to cause the electronic device to perform a method as described in the first aspect or any implementation of the first aspect.
In the above embodiment, the wireless network data set includes a large amount of wireless network data, and the cloud server calculates the electronic fence of different areas to be calibrated through the large amount of wireless network data, so that the calculation result is more accurate, the electronic fence of the area to be calibrated can be used for representing one area to be calibrated, and the area to be calibrated of the entity is dataized.
In a fourth aspect, embodiments of the present application provide a computer program product comprising instructions which, when run on an electronic device, cause the electronic device to perform a method as described in the first aspect or any implementation of the first aspect.
In the above embodiment, the wireless network data set includes a large amount of wireless network data, and the cloud server calculates the electronic fence of different areas to be calibrated through the large amount of wireless network data, so that the calculation result is more accurate, the electronic fence of the area to be calibrated can be used for representing one area to be calibrated, and the area to be calibrated of the entity is dataized.
In a fifth aspect, embodiments of the present application provide a computer readable storage medium, which when executed on an electronic device, causes the electronic device to perform a method as described in the first aspect or any implementation of the first aspect.
In the above embodiment, the wireless network data set includes a large amount of wireless network data, and the cloud server calculates the electronic fence of different areas to be calibrated through the large amount of wireless network data, so that the calculation result is more accurate, the electronic fence of the area to be calibrated can be used for representing one area to be calibrated, and the area to be calibrated of the entity is dataized.
Drawings
1 a-1 c are a set of schematic diagrams of a terminal switching an accessed network from a WiFi network to a cellular network;
fig. 2a is a schematic diagram of a terminal switching an accessed network from a WiFi network to a cellular network in an embodiment of the present application;
fig. 3 shows a schematic diagram of the relationship between a region and a cell;
FIG. 4 illustrates an exemplary diagram of different terminals acquiring wireless network data in different areas;
FIG. 5 shows a schematic flow chart of a cloud server generating an electronic fence;
FIG. 6 shows a schematic flow chart of calculating in any cell an intra-cell access distance feature corresponding to any region;
FIG. 7 is a schematic flow chart diagram illustrating a terminal generating an electronic fence;
fig. 8 is a schematic structural diagram of a communication system according to an embodiment of the present application;
Fig. 9 is a schematic structural diagram of a terminal provided in an embodiment of the present application.
Detailed Description
In one scheme, when a terminal enters an elevator or is far away from a device (such as a router) for providing a Wi-Fi network, the signal strength of the accessed Wi-Fi network gradually decreases, and when the signal strength decreases to a certain degree, the terminal can switch the accessed network from the Wi-Fi network to a cellular network.
Fig. 1 a-1 c are a set of schematic diagrams illustrating a terminal switching an access network from a Wi-Fi network to a cellular network in one scenario.
The scenario depicted in fig. 1 a-1 c is: the user is in building 17, and terminal access is 17 building Wi-Fi network, then, user hand terminal takes the elevator from building 17 and falls the building down, and after the elevator door was closed, the signal quality of terminal access Wi-Fi network gradually drops, switches to the cellular network when dropping to only one check. In which the user indicates that the elevator door is not closed when the user is in solid line, and the user is seen from the elevator hoistway (the elevator entrance of a certain floor or the area near the elevator entrance is called an elevator hoistway, for example, the elevator entrance shown in fig. 1a may be an elevator hoistway), and the user indicates that the elevator door is closed when the user is in broken line, and the user is not seen from the elevator hoistway. In fig. 1 a-1 c, a signal strength indicator 101 is used to indicate the signal strength of a Wi-Fi network, where the signal strength indicator includes M arcs (M is a positive integer greater than 1, and is typically 4 or 5). The black color of the arc line can indicate that the signal strength of the Wi-Fi network reaches the value corresponding to the arc line, and the gray color indicates that the signal strength of the Wi-Fi network does not reach the value. The more black arcs, the stronger the signal representing the Wi-Fi network, the more black arcs are also referred to as signal grid numbers, the stronger the signal of the Wi-Fi network, the more Wi-Fi network, the network usage indicator 101A is further included in the signal indicator 101, the network usage indicator 101A indicates that the current terminal uses the Wi-Fi network for communication, and when the network usage indicator 101A and the signal strength indicator 102 are displayed together, the terminal is indicated to use the cellular network for communication. In fig. 1 a-1 c, the signal strength indicator 102 is used to indicate the signal strength of the cellular network, and the indication manner may refer to the description of the signal strength indicator 101, which is not repeated herein.
In another case, in the scenario shown in fig. 2a, the terminal switches to the cellular network without switching the accessed WiFi network, but after the elevator door is closed, the terminal detects that the strength of the connected access point has fallen to the strength preset value (the description of the first strength preset value in step S415 described below may be referred to here).
As shown in fig. 1a, the user enters the elevator from the elevator hoistway of floor 17, at which time the elevator door is not closed and the time displayed in the user interface 10 is 17:59 (this time is just an example), the number of signal cells in the signal strength indicator 101 is 3, and normally the terminal can communicate normally. The elevator door is then closed and during the descent of the elevator, the terminal can display a user interface 11 as described in fig. 1b at floor 16.
As shown in fig. 1b, at 16 floors, when the elevator door is closed and the Wi-Fi network is shielded by the elevator, the time displayed in the user interface 20 is 18:00, the number of signal cells in the signal strength indicator 101 is 2, at this time, the terminal cannot normally communicate with other terminals, and the terminal can display the prompt information 111, where the content of the prompt information 111 is: "network connection is not available, please retry later". Between 17:59 and 18:00, the other terminal sends a message (not shown, denoted as message 131) to the terminal, which message 131, if in the case of normal communication, should be received when the terminal displays 17:59, but which message 131 is currently not received because the terminal is currently in the elevator and cannot normally communicate, and which message 131 is received when the terminal replies to the communication, provided that the message 131 is received and displayed at 18:01, the user interface referred to below for user interface 13 at 18:01 is referred to below), but because the network connection is not available, the terminal cannot receive this message at 18:00, and in response to the user operating on the transmission control 112, the terminal attempts to transmit the message 113 to the other terminal. At this point the elevator continues to descend and at floor 14 the terminal can display a user interface 13 as described in fig. 1 c.
As shown in fig. 1c, at floor 14, when the elevator is turned off, the Wi-Fi network is shielded by the elevator, and floor 14 is farther from floor 17 (than floor 16), the signal strength of the Wi-Fi network is lower, in the user interface 13, the number of signal cells in the signal strength indicator 101 is only 1 cell, the terminal cannot normally communicate with other terminals at 18:00, the information 113 cannot be successfully transmitted, and in the user interface 12, the in-transmission prompt 120 can be displayed to inform the user that the information is being transmitted. At this time, the signal strength of the Wi-Fi network drops to a certain extent, and the terminal can be switched to the cellular network for communication.
In this way, after the terminal enters the elevator, the accessed Wi-Fi network may be shielded by the elevator, resulting in that the Wi-Fi network may deteriorate over a period of time but the Wi-Fi network is not disconnected, thereby affecting the communication.
It should be appreciated that other similar scenarios may also suffer from the above-described problems, e.g., as a terminal gets farther from a device providing a Wi-Fi network until it leaves the range covered by the Wi-Fi network, the Wi-Fi network that is accessed will also degrade over a period of time but the Wi-Fi network will not be disconnected, thereby affecting communications.
In the embodiment of the application, an electronic fence at a certain position (such as an elevator hoistway or a position where a device providing a Wi-Fi network is located) can be calculated, and when the terminal enters or leaves the electronic fence at the position, the terminal can trigger execution of a certain function. For example, when the terminal determines that it enters an electronic fence of an elevator entrance, the connected Wi-Fi network may be switched to a cellular network.
Fig. 2a is a set of schematic diagrams illustrating a terminal switching an access network from a Wi-Fi network to a cellular network in an embodiment of the present application.
The scenario depicted in fig. 2a is: the user is at floor 17, the terminal accesses the Wi-Fi network of floor 17, then, the user holds the terminal to take the elevator from floor 17, after the user enters the elevator, the Wi-Fi network accessed by the terminal is switched into the cellular network before the elevator is closed, and the terminal can communicate with other terminals through the cellular network in the elevator. For other descriptions of this scenario, for example descriptions of signal indicators, reference may be made to the previous descriptions of fig. 1 a-1 b, which are not repeated here.
After the user enters the elevator from the elevator hoistway of floor 17, the user interface displayed by the terminal can refer to the previous description of fig. 1a, and the illustration and description will not be repeated here. When the user is near the elevator hoistway, the terminal may determine that he entered the electronic fence of the hoistway, and then, after determining that the user entered the elevator, the terminal may switch the accessed Wi-Fi network to a cellular network.
As shown in fig. 2a, after entering the elevator, the terminal does not wait for the Wi-Fi network to drop to 1 grid before switching to the cellular network, and can switch to the cellular network when the Wi-Fi network drops to 3 grid (normally, communication with other terminals can be performed at this time), at this time, the terminal can display a signal strength indicator 202 including a network usage indicator, which indicates that the terminal is communicating using the cellular network at this time, and prompt information 202 is displayed in the user interface 20, and the prompt information includes prompt contents: the present network is switched to the mobile network (cellular network), and is used for prompting the user that the present network is switched, so that the terminal can still normally communicate without influencing the receiving and sending of information, the user interface displayed by the terminal can be the user interface 20, and the time displayed in the user interface 20 is 17:59. The user interface 20 is a user interface when the terminal edits the information 113, before the user touches the sending control 112, between 17:59-18:00, the terminal receives information 131 sent by other terminals to the local machine, after that, the user touches the sending control 112, detects an operation (for example, a clicking operation) of the user on the sending control 112, and the terminal sends the information 113 to other terminals through the cellular network.
As can be seen from comparing fig. 1b to fig. 1c related to the foregoing scenario, the user can successfully send the information at floor 16 without waiting for the floor 13 to switch to the cellular, and the display sequence corresponds to the sequence of the information sending.
In this way, after the terminal determines that it enters the electronic fence of the elevator gate, the terminal may be triggered to switch the connected network from the Wi-Fi network to the cellular network.
It should be appreciated that other similar scenarios, such as the terminal getting farther from the device providing the Wi-Fi network until it leaves the range covered by the Wi-Fi network, may also trigger a network switch to the cellular network to ensure successful communication when the terminal determines that it leaves the electronic fence of the location.
The embodiment of the application relates to a method for generating an electronic fence and a method for triggering functions. The method for generating the electronic fence can determine the electronic fence of a certain area, the method for triggering the function can determine that the terminal enters or leaves the electronic fence of a certain area and trigger the execution of a certain function, for example, in the scene described in fig. 2a, when the terminal enters the electronic fence of the elevator entrance, the connected WiFi network can be switched to the cellular network.
The method for generating the electronic fence in the embodiment of the application is described in detail below.
Electronic fence (guard) refers to creating a virtual geographic boundary around an area by using the characteristics of access points (detected access points and connected access points) around the area, and when a terminal enters or leaves the electronic fence, the terminal can trigger the execution of certain functions. The area may be the elevator hoistway described above, the area where the device providing the WiFi network is located, or another area.
The access points around a certain area include access points detected by a terminal around the area and access points connected to the access points, which means that the terminal is around the certain area, the terminal can detect and also can be connected to the access points, through the connected access points, the terminal can access a WiFi network corresponding to the access points, and through a device (such as a router) for providing the WiFi network, the terminal communicates with other terminals, and the connected access points can also be called connected access points. The detected access points refer to access points corresponding to WiFi networks that can be detected by the terminal around a certain area, including access points connected to.
For convenience of description, for an electronic fence of a certain area, the area may also be referred to as an area to be calibrated, and the electronic fence may be referred to as an electronic fence of the area to be calibrated.
In some embodiments, the characteristics of the access points involved in the electronic fence of the area to be calibrated may include an access point distance characteristic and/or a connected access point strength characteristic corresponding to the area to be calibrated, any electronic fence may be associated with one connected access point data, where the connected access point data is used to identify the electronic fence, and the electronic fence includes at least one access point, where the access point is an access point to which a terminal may be connected in the electronic fence, and any access point corresponds to the electronic fence. Wherein the connected access points included in the connected access point strength characteristics are the same as the connected access points included in the connected access point data, i.e. the number of access points and the BSSID are the same.
In other embodiments, the characteristics of the access points included in the electronic fence of the to-be-calibrated area may include other characteristics, such as a cell identifier corresponding to the access point, besides the strength characteristics of the connected access points and the distance characteristics of the access points corresponding to the to-be-calibrated area.
The strength characteristics of the connected access points corresponding to the area to be calibrated comprise the corresponding relation between the strength threshold value of the connected access points and the connected access points in the area to be calibrated, namely, the strength threshold value of any connected access point and the connected access points correspond. The strength threshold of any connected access point may be a range of strength corresponding to the connected access point in the electronic fence of the area to be calibrated when the terminal connects the access point, and the representation form of the strength threshold is different according to the type of the area to be calibrated, for example, may be represented as a range, for example, may be represented as a lowest strength-highest strength corresponding to the connected access point in the electronic fence of the area to be calibrated, may also be represented as a value, for example, may be represented as a lowest strength corresponding to the connected access point in the electronic fence of the area to be calibrated, and may also be represented as a highest strength corresponding to the connected access point in the electronic fence of the area to be calibrated.
The strength may be a received signal strength of the connected access point, which may be represented by a received signal strength indication (received signal strength indication, RSSI).
The access point distance characteristic corresponding to the area to be calibrated is included in the area to be calibrated, the relative distance between the access point (different access points included in the detected WiFi list) which can be detected by the terminal and the area to be calibrated (hereinafter, the relative distance is simply referred to as the area distance, which is the result that when the distance between the access point and the area to be calibrated is calculated, the energy of the electric wave is not absorbed by the barrier and reflected or scattered when the electric wave propagates in free space is assumed), and the access point distance characteristic can be expressed as the corresponding relation between any access point and the area distance of the access point relative to the area to be calibrated.
In this embodiment of the present application, the terminal may use basic service set identifier information (basic service set identifier, BSSID) of an access point, where the BSSID is a media access control (media access control, MAC) address of the access point, where the BSSID may be used to uniquely identify one access point, and the BSSIDs of different access points are different, and it should be understood that, in addition to the BSSID, the manner of identifying the access point may also have other expression manners, which is not limited in this embodiment of the present application.
Table 1 is a schematic representation of an electronic fence provided in an embodiment of the present application.
TABLE 1
Figure BDA0003411236310000081
Figure BDA0003411236310000091
As shown in table 1, the electronic fence includes a connected access point intensity feature and an access point distance feature corresponding to the region to be calibrated, where the connected access point intensity feature included in the electronic fence is: when the electronic fence leaves the area to be calibrated, the lowest intensity of the BSSID1 is-50 dBm, the highest intensity is-45 dBm, the lowest intensity of the BSSID2 is-49 dBm, and the highest intensity is-42 dBm. The access point distance of the electronic fence is characterized in that: in the area to be calibrated, the access points that the terminal can detect include BSSID1, BSSID2, BSSID3, and BSSID4, which have an area distance of 25.6m, 26.6m, 22.1m, and 27.6m with respect to the area to be calibrated. The electronic fence can be considered herein to be associated with all connected access points in the connected access point strength data.
After determining the electronic fence, one application mode of the electronic fence is as follows: and determining whether the terminal enters or leaves the electronic fence by using the electronic fence, thereby triggering the execution of a certain function.
For example, one way to determine that a terminal enters the electronic fence is: when a terminal is connected to an access point a, the connected access point data associated with the electronic fence can be matched through the access point a, if the BSSID of the access point a is the same as one of the connected access point data, the access point is considered to correspond to the electronic fence, then at time a the terminal can determine whether the strength B of the connected access point matches the strength characteristics of the connected access point, when the strength characteristics of the connected access point included in the electronic fence are the corresponding strength ranges (such as those shown in table 1) when the electronic fence leaves the electronic fence from the area to be calibrated, then when the strength B is within the strength range corresponding to the access point a, the terminal can determine that the strength B matches the strength of the access point a, and at this time, the terminal can be determined to enter the electronic fence.
It should be appreciated that one of the ways in which the above-mentioned determination of the entry of the terminal into the electronic fence is an exemplary description, and that other ways are possible, and reference may be made specifically to the following description of steps S401-S416.
In one possible manner, the electronic fence of the area to be calibrated can be calculated by the cloud server and then sent to the terminal. At least one terminal can access a certain access point around the area to be calibrated to acquire a plurality of connected access point intensity data and a plurality of wireless network data, then the access point intensity data and the wireless network data are uploaded to a cloud server, the cloud server can receive the connected access point intensity data and the wireless network data acquired by different terminals in different areas, then the connected access point intensity data and the wireless network data are processed to obtain electronic fences corresponding to different areas, and the different areas comprise the area to be identified. The method for any terminal to acquire any wireless network data is as follows: the terminal can determine that the terminal reaches the area to be calibrated (reaches the area to be calibrated from other areas) at the first moment by detecting the first event, can consider the first moment and a certain period of time after the first moment, the terminal is in the electronic fence of the area to be calibrated, and then acquire wireless network data corresponding to the first moment. The mode of any terminal for acquiring the strength data of any connected access point is as follows: at the second moment, the terminal can determine that the terminal leaves the area to be calibrated (leaves the area to be calibrated and leaves other areas from the area to be calibrated) at the second moment by detecting the second event, can consider the second moment and a certain period of time before the second moment, the terminal is in the electronic fence of the area to be calibrated, and then acquires the connected access point intensity data corresponding to the second time. The detailed process of calculating the electronic fence of the area to be calibrated by the cloud server can refer to the following description of step S101-step S112, which is not repeated herein.
In another possible manner, the electronic fence of the area to be calibrated may be calculated by the terminal, and the terminal may use the multiple pieces of connected access point intensity data and the multiple pieces of wireless network data acquired in different areas, and then process the multiple pieces of connected access point intensity data and the multiple pieces of wireless network data to obtain the electronic fence corresponding to the different areas, where the different areas include the area to be identified. The manner in which the terminal obtains any data (including the connected access point data and the wireless network data) may refer to the manner in which the terminal obtains the data, which is not described herein. The detailed process of calculating the electronic fence of the area to be calibrated by the cloud server can refer to the following description of step S301-step S310.
The first event is used for determining that the terminal arrives at the area to be calibrated or is located in the area to be calibrated (arrives at the area to be calibrated from other areas) at the first moment, when the terminal detects the first event, the terminal can be considered to be in the electronic fence of the area to be calibrated (around the area to be calibrated) at the first moment and a certain period of time after the first moment, and at the moment (at the first moment and a certain period of time after the first moment), the wireless network data acquired by the terminal can be used for calculating the electronic fence of the area to be calibrated.
The second event is used for determining that the terminal leaves the area to be calibrated (leaves the area to be calibrated and leaves other areas from the area to be calibrated) at the second moment, when the terminal detects the second event, the second moment and a certain period of time before the second moment can be considered that the terminal is in the electronic fence of the area to be calibrated (around the area to be calibrated), and at the moment (the second moment and a certain period of time before the second moment), the strength data of the connected access point acquired by the terminal can be used for calculating the electronic fence of the area to be calibrated.
The first time is a time period after the first time, that is, the terminal is in the terminal fence of the area to be calibrated at the first time, the second time is a time period before the second time, and the second time can be the same as the first time or different from the first time. The first time is a time period between the third time and the first time, the terminal is located in the electronic fence of the area to be calibrated at the third time, namely, in the first time, after the terminal enters the fence from the outside of the electronic fence of the area to be calibrated at the first time, the terminal is always located in the electronic fence of the area to be calibrated, and the difference between the third time and the first time is a first preset value. The second time is a time period between the fourth time and the second time, the terminal is in the electronic fence of the area to be calibrated at the fourth time, namely, in the second time, the terminal is always in the electronic fence of the area to be calibrated before the terminal leaves the fence from the electronic fence of the area to be calibrated at the second time, and the difference between the fourth time and the second time is a second preset value.
For convenience of description, the wireless network data corresponding to the first time may be referred to as qualified wireless network data, and the connected access point strength data corresponding to the second time may be referred to as qualified connected access point strength data.
The strength data of the connected access point is the corresponding relation between the strength of the access point (connected access point) connected by the terminal and the connected access point, namely, any strength corresponds to one access point, wherein the connected access point is the access point (access point) connected by the terminal around the area to be calibrated. Through the access point, the terminal can be connected with a wireless fidelity (wireless fidelity, wiFi) network corresponding to the access point, then can communicate with equipment providing the WiFi network, and the equipment is connected with the Internet through the access point connected with the terminal, so that the terminal can communicate with other terminals. The device may be a router, or may be another device that may provide a wireless network, which is not limited in this embodiment of the present application. The WiFi network is a wireless network provided by the device, and may be associated with at least one access point of the device, i.e., one WiFi network may correspond to at least one access point. A device may have at least one access point, and different access points may be located on different channels or on the same channel, any access point may provide a bridging function of a terminal to the internet, when the terminal is connected to any access point of the device, that means that the terminal may access the WiFi network provided by the device through the access point, and use the channel on which the access point is located to communicate.
The wireless network data may include an access point (connected access point) to which the terminal is connected, a WiFi list, and/or a cell identifier of a cell (hereinafter referred to as a cell) to which a region to be calibrated where the terminal is located belongs, and may further include other information such as a timestamp. The description of the related description of the wireless network may be referred to below, and is not repeated here.
The WiFi list may include all or part of relevant information of WiFi networks that can be detected by the terminal around the area to be identified, where any relevant information of WiFi includes relevant information of all access points included in the device to which the WiFi belongs.
In some embodiments, the related information of any access point may include a correspondence between the strength of the access point and the access point, where the access point is an access point that can be detected by the terminal.
The time stamp is the time generated by the wireless network data of the terminal, and the time stamp is a certain moment in the first time.
The cell identity may be described by a combination of a location area code (location area code, LAC) and a cell number (cellid), or by other means, for example, a location area code (location area code, LAC), a cell number (cellid) and an operator to which the cell belongs (common operators include telecommunications, mobile and telecom).
The cell identity is used to uniquely identify a cell, and the cell identity may be described by a combination of a location area code (location area code, LAC) and a cell number (cellid), or may be described by other means, for example, by a location area code (location area code, LAC), a cell number (cellid), and an operator to which the cell belongs (common operators include telecommunications, mobile, and telecom).
Wherein any cell is the range of signal coverage of one base station. In either cell, a terminal may communicate with the base station using a cellular network. Different operators (such as telecommunications, connectivity and mobility) may all arrange base stations in the same area (the area is larger, for example, some areas have coverage radius up to 500 meters, which may include a plurality of areas to be calibrated referred to herein), so that the same area may correspond to at least one cell identifier, any cell identifier may be LAC and cellid of a cell covered by a base station arranged by one of the three operators, namely telecommunications, connectivity and mobility, and different operators may be the same or different. When the electronic fence is generated, different wireless network data can be divided into different cells according to the cell identification, and then subsequent processing is carried out.
It should be understood that, when one to-be-calibrated area corresponds to a plurality of cell identifiers, a cell corresponding to a cell identifier in radio network data acquired by the to-be-calibrated area by the terminal may be a range covered by a base station that communicates with a main subscriber identity module (subscriber identity module, SIM) card used by the terminal, or may be a range covered by a base station that communicates with a SIM card with the strongest signal strength in the terminal, or may have other defining manners, which are not limited in this embodiment of the present application.
It should be understood that, when an area corresponds to a plurality of cell identities, a cell corresponding to a cell identity in the wireless network data acquired by the terminal in the area may be a range covered by a base station that communicates with a main subscriber identity module (subscriber identity module, SIM) card used by the terminal, or may be a range covered by a base station that communicates with a SIM card with the strongest signal strength in the terminal, or may have other defining manners, which are not limited in this embodiment of the present application.
In summary, in the case where a piece of wireless network data may include a connected access point, a Wi-Fi list, and a cell identifier, the piece of wireless network data may be expressed as:
data1=[(bssid 1 ,rssi 1 =-50dBm),(bssid 2 ,rssi 2 =-35dBm),(bssid 3 ,rssi 3 =-50dBm),connectBssid=bssid 1 ,LAC,cellid]
Wherein data1 represents wireless network data, (bssid 1 ,rssi 1 =-50dBm),(bssid 2 ,rssi 2 =-35dBm),(bssid 3 ,rssi 3 = -50 dBm) represents Wi-Fi list, connectbssite=bssid 1 Representing a connected access point as a bssid 1 LAC and cellid are used to identify the cell. As shown in fig. 3, the elevator hoistway is located in an area to be calibrated, icons 401 (all gray dots are icons 401) are some positions in the area to be calibrated, icons 402 (all light dots are icons 402) are other positions in the area to be calibrated, and icons 403 (all black dots are icons 403) are other positions in the area to be calibrated. Here, it is assumed that, outside the area to be calibrated, the terminal cannot detect the first event, and the terminal cannot acquire the wireless network data, if the terminal is located at the position where the icon 401 is located, the access point connected to the terminal is access 1, if the terminal can acquire the wireless network data, if the connected access point in the wireless network data is access 1, if the terminal is located at the position where the icon 402 is located, the connected access point is access 2, if the terminal can acquire the wireless network data, if the connected access point in the wireless network data is access 2, if the terminal is located at the position where the icon 402 is locatedThe access point connected when the icon 403 is located is access 3, and the terminal cannot collect wireless network data.
In this embodiment of the present application, the area to be calibrated may be an elevator hoistway, or an area where equipment providing a WiFi network is located, for example, a living room where a router is placed, or other areas, for example, an area without a WiFi network.
The electronic fence of any area is generated by using the characteristics (such as the distance characteristics of the access points, the strength characteristics of the connected access points and the like) of the access points (the detected access points and the connected access points) around the area, when the electronic fence of any area is calculated, the characteristics of the access points of the area can be calculated by the data (such as the connected access point data, the wireless network data and the like) related to the access points acquired around the area, and according to the related content, the terminal can be determined to be around the area to be calibrated by detecting the first event and the second event, and the terminal is triggered to acquire the data related to the access points.
By using the different first events and second events, the terminal can obtain data (including connected access point data, wireless network data and the like) related to access points around different types of areas to be calibrated (for example, an elevator port is of one type, an area where equipment for providing a WiFi network is located is of another type), so that characteristics of the access points of the different areas to be calibrated can be calculated, and generation of the electronic fence is realized. The method includes that if the areas to be calibrated are different, the terminal determines that the terminal is located around the areas to be calibrated, namely, the first event and the second event are different, and the area where the areas to be calibrated are the elevator hoistway and the equipment for providing the WiFi network are located is taken as an example for explanation.
When the area to be calibrated is an elevator hoistway, the first event can be set as a terminal elevator, and the second event can be set as a terminal elevator.
One way for the terminal to determine that the terminal is out of the elevator may be: the acceleration of the terminal is detected to be changed from a vertical acceleration in a certain direction (vertically upward or vertically downward) to a horizontal acceleration within a first preset time, wherein in the case that the terminal detects that the acceleration of the terminal is 5 ° clockwise in the vertical direction to 5 ° counterclockwise in the vertical direction, the terminal can determine that the acceleration at this time is the vertical acceleration, and in the case that the terminal detects that the acceleration of the terminal is 5 ° clockwise in the horizontal direction to 5 ° counterclockwise in the horizontal direction, the terminal can determine that the acceleration at this time is the horizontal acceleration. Correspondingly, one way for the terminal to determine that the terminal is entering the elevator may be: the method for determining that the acceleration of the terminal is the horizontal acceleration and the vertical acceleration by detecting that the acceleration of the terminal is changed from the horizontal acceleration to the vertical acceleration within the second preset time can refer to the foregoing description, and will not be repeated herein. The first preset time and the second preset time can be the same or different in length and can be adjusted according to actual needs, for example, the first preset time can be set to be 1s-3s, and the second preset time can be set to be 2s-5s.
The terminal can also determine a mode that the terminal goes out of the elevator as follows: and after detecting that the altitude of the area where the terminal is located continuously becomes high, the altitude of the area is not continuously increased within a third preset time. Correspondingly, one way for the terminal to determine that the terminal enters the elevator may also be: the altitude of the area where the terminal is detected continuously becomes low in a fourth preset time, wherein the lengths of the third preset time and the fourth preset time can be the same or different, the first preset time and the second preset time can be adjusted according to actual needs, for example, the first preset time can be set to be 0.5s-1s, and the second preset time can be set to be 1s-2s.
The terminal can determine whether the terminal enters (exits) the elevator or not by other modes, for example, by combining voice detection and motion detection, after the terminal is detected to stop moving, voice such as 'descending of the elevator' is detected within a fifth preset time, the terminal can be determined to enter the elevator, and after voice such as 'opening an elevator door' is detected, the terminal is determined to exit the elevator after the motion is detected within a sixth preset time.
It should be understood that, in the embodiment of the present application, whether the terminal enters the elevator/exits the elevator may be determined by other manners, which are not repeated herein, and the foregoing 5 °, 1s-3s, 2s-5s, 0.5s-1s and 1s-2s are illustrative, and may be adjusted according to practical situations, for example, 10 ° or the like, which is not limited in the embodiment of the present application.
When the area to be calibrated is an area where a device providing a WiFi network is located, for example, a living room of a router is placed.
In some cases, when the terminal enters the area where the device for providing the WiFi network is located from another place, the access point corresponding to the WiFi network is connected, and then the first event may be set to be the access point on which the terminal is connected, and when the terminal leaves the area where the device for providing the WiFi network is located, the access point corresponding to the WiFi network is disconnected, and then the second event is set to be the access point on which the terminal is disconnected.
In other cases, when the terminal enters the area where the device for providing the WiFi network is located from another place, the access point corresponding to the WiFi network is connected, and there is usually a process from a motion state to stopping motion, for example, when the area where the device for providing the WiFi network is located is a living room where a router is located, a user usually has a process of opening a door before entering a door, which can cause the terminal to stop motion from the motion state to the stopping motion, and then the first event may be set that the terminal is in the motion state, and after the access point is connected, the terminal stops motion within a seventh preset period. When the terminal leaves the area where the device providing the WiFi network is located, there is usually a process in a motion state, and the second event may be set as an access point where the terminal is disconnected and is in a motion state.
It should be understood that the above arrangements of the first event and the second event are merely illustrative, and are not limited to the embodiments of the present application, and in other cases, other arrangements may be used, which is not limited to the present application.
In the embodiment of the application, the electronic fences in different areas can be calculated by the cloud server or the terminal.
The detailed process of generating an electronic fence by the cloud server is described below.
Here, the electronic fence includes the access point distance feature and the connected access point intensity feature corresponding to the area to be calibrated, and other cases, for example, the electronic fence includes only the access point distance feature or the connected access point intensity feature, may refer to the following description.
In some embodiments, the cloud server may receive N pieces of wireless network data and Z pieces of connected access point strength data sent by different terminals, and then calculate an electronic fence of the area to be calibrated based on these data. These data (N pieces of wireless network data, and Z pieces of connected access point strength data) may be acquired by different terminals when connecting different access points in different areas, in which way the wireless network data includes the connected access points, wiFi list, and cell identity.
Fig. 4 shows another exemplary schematic diagram of different terminals acquiring wireless network data in different areas to be calibrated.
In fig. 4, an icon 301 indicates that the terminal is connected to an Access Point (AP). As shown in fig. 4, it is assumed that the area to be calibrated is an elevator hoistway including each elevator hoistway of different floors in different buildings, for example, elevator hoistway 1 in floor 1, elevator hoistway 2 in floor 2, and other elevator hoistway in other floors in building 1 shown in the drawing, and it is also assumed that the main SIM card used by terminal 1 and terminal 2 is a SIM card provided by operator a, the range of signal coverage of the base station arranged by operator a is cell 1 (cell-1), the main SIM card used by terminal 3 and terminal 4 is a SIM card provided by operator B, and the range of signal coverage of the base station arranged by operator B is cell 2 (cell-2). It should be understood that the N pieces of wireless network data acquired by different terminals are acquired by different terminals around different elevator hatches of different buildings. The building 1 is located in both the cell 1 and the cell 2, and the cell identifier included in the wireless network data uploaded by the terminal located in the building 1 may be the cell identifier of the cell 1 or the cell identifier of the cell 2. The APs around elevator hoistway 1 include AP1 of device 1 and AP2 of device 2, the AP of elevator hoistway 2 includes AP3 and AP4 of device 3, AP1 corresponds to WiFi1 (WiFi 1 is provided by device 1 and not shown in the figure), AP2 corresponds to WiFi2 (WiFi 2 is provided by device 2 and not shown in the figure), AP3 and AP4 correspond to WiFi3 (WiFi 3 is provided by device 3 and not shown in the figure). The terminal 1 may acquire the wireless network data 1 after detecting the first event, and upload the wireless network data 1 to the cloud server, where the wireless network data 1 may include: BSSID of AP1, wiFi list 1, cell identity 1 (cell identity of cell 1), wherein WiFi list 1 may include relevant information in all or part of the relevant information of WiFi networks (e.g., wiFi1 and/or WiFi 2) that terminal 1 may detect at elevator hoistway 1. The terminal 3 may acquire the wireless network data 2 after detecting the first event, and upload the wireless network data 2 to the cloud server, where the wireless network data 2 may include: BSSID of AP3, wiFi list 2, cell identity 2 (cell identity of cell 2), wherein WiFi list 2 may include relevant information in all or part of the WiFi networks that terminal 1 can detect at elevator hoistway 1 (e.g., wiFi3 and/or WiFi1 and/or WiFi 2). The terminal 1 and the terminal 3 may detect the first event at least once within a period of time, acquire at least one qualified wireless network data, and transmit the data to the terminal, for example, the terminal 1 may acquire 20 qualified wireless network data within 14 days and upload the data to the cloud server, and the process of acquiring the wireless network data by other terminals and uploading the data to the cloud server will not be described herein. It should be understood that the same terminal may acquire wireless network data in different areas and upload the wireless network data to the cloud server.
Therefore, it can be understood that the N pieces of wireless network data acquired by the cloud server are the results of acquiring the wireless network data in different areas by different terminals and uploading the wireless network data to the cloud server in a period of time.
The above description is given by taking the process of acquiring N pieces of wireless network data by the cloud server as an example, and the process of acquiring the intensity data of the Z pieces of connected access points is similar to the process, but only after the second event is detected, the different terminals acquire the qualified intensity data of the connected access points and upload the acquired intensity data to the cloud server, which is not described herein again.
When the electronic fence of the area to be calibrated comprises the access point distance characteristic corresponding to the area to be calibrated and the connected access point strength characteristic, the cloud server calculates the access point distance characteristic corresponding to the area to be calibrated by the following steps: the cloud server may obtain M pieces of wireless network data included in different cells based on the N pieces of wireless network data, where the M pieces of wireless network data are wireless network data obtained by the terminal in different areas of the cell, and obtain X pieces of wireless network data included in different areas of the cell based on similarity of WiFi lists in wireless network data in the same area of the M pieces of wireless network data. And obtaining the connected access point data associated with any region and the intra-cell access point distance characteristic corresponding to the region in the cell by utilizing the X pieces of wireless network data included in any region in any cell. And combining the intra-cell access point distance characteristics corresponding to the areas with the same connected access point data in different cells to obtain the access point distance characteristics corresponding to H different areas, wherein any area is associated with different connected access point data.
In any cell, the intra-cell access point distance feature corresponding to any area (temporary area) includes a correspondence between the temporary area and the intra-cell distances of the access points detected by the terminal (different access points included in the detected WiFi list), where the intra-cell distances corresponding to the different access points are relative distances between the access point and the first temporary area.
The process for calculating the strength characteristics of the connected access points corresponding to the area to be calibrated is as follows: the cloud server groups connected access points in the Z pieces of connected access point intensity data based on the connected access points, so that different connected access points correspond to one intensity data set, the intensity threshold of any connected access point is calculated, the corresponding relation between the intensity threshold of all connected access points and the connected access point is obtained, namely the intensity threshold of the connected access point corresponds to the connected access point, then all connected access points are matched with the connected access point data corresponding to any area, all connected access points matched with the connected access point data corresponding to any area are determined, and the corresponding relation between the intensity threshold of all connected access points matched with any area and the connected access point is used as the intensity characteristic of the connected access point corresponding to the area.
Thus, the distance characteristic of the access point corresponding to any area and the strength characteristic of the connected access point can be obtained, and the electronic fence of the area is obtained.
Fig. 5 shows a schematic flow chart of cloud server generation of an electronic fence.
The cloud server may refer to the following description of step S101-step S112 for a detailed process of generating the electronic fence:
it should be understood that, enough wireless network data can make calculating the access point distance feature corresponding to any area more accurate, so that the cloud server needs to acquire multiple pieces of wireless network data around the area when calculating the access point distance feature corresponding to any area, where the wireless network data can be acquired by the terminal and other terminals at different time and different areas, and then uploaded to the cloud server.
In a possible case, the cloud server may set to utilize wireless network data sent by different terminals to calculate the distance characteristics of the access point within a period of time, where the period of time may be 10 days to 14 days, or may be other time, and may also be adjusted according to a specific data acquisition situation of the terminal.
In another possible scenario, the cloud service may set that the access point distance feature calculation may be performed when a certain number of wireless network data is acquired.
The detailed process of the cloud server to obtain one piece of wireless network data sent by the terminal and other terminals may refer to the following steps S101-S102:
s101, detecting a first event, and acquiring wireless network data by a terminal and uploading the wireless network data to a cloud server;
the wireless network data may include access points to which the terminal is connected (connected access points), and WiFi lists. When the terminal detects a first event at a first time, wireless network data corresponding to the first time can be acquired. The first event and the first time setting may be different in different areas to be calibrated, and the detailed description of the first event and the first time may refer to the related description and will not be repeated here.
Wherein the first event is used for determining that the terminal reaches the region to be calibrated (reaches the region to be calibrated from other regions) at the first moment. The first time is a time period after the first time, and can be considered as the time from the first time to the 15s after the terminal enters the fence from outside the fence of the area to be calibrated, for example, the terminal is always in the fence of the area to be calibrated. It should be understood that this 15s is illustrative, and other times, such as 10s or 20s, may be provided, and the embodiments of the present application are not limited thereto.
The method for setting the first time is exemplified by taking the area to be calibrated as the elevator entrance, and because the first time is a time period after the first time, the terminal can acquire wireless network data at the first time, the length of the first time can determine the size of the electronic fence of the elevator entrance, the longer the first time is, the more the terminal can acquire the wireless network data of the area farther from the elevator entrance, the larger the electronic fence of the elevator entrance is calculated, the shorter the first time is, the opposite is, the smaller the electronic fence of the elevator entrance is calculated at the moment, and the first time is specifically set to 15s, 10s and 20s or other times according to actual needs. When the area to be calibrated is other area, reference may be made to the description related to the elevator hoistway, and details are not repeated here.
In the first time, the terminal can acquire a WiFi list detected at the first time in the first time, determine an access point connected at the second time in the first time as a connected access point, and determine a cell identifier of a cell where the terminal is located at the third time in the first time. The first time in the first time, the second time in the first time, and the third time in the first time may be the same or different, for example, the first time in the first time is the time when the WiFi list is detected within 15s after the first time, the second time in the first time is the time when the terminal is connected to the access point within 15s after the first time, the third time in the first time may be preset, any second in the first time may be set by the terminal to be the third time in the first time, for example, the 5 th s or the 10 th s after the first time is set, which is not limited in the embodiment of the present application.
In some embodiments, the first time in the first time may be preset, the terminal may set any second in the first time as the first time in the first time, for example, set the 5s or 10s after the first time as the first time in the first time, and the terminal may trigger to detect the WiFi list once at the first time in the first time to obtain the WiFi list detected at the first time in the first time, which is called active detection.
In other embodiments, the first time in the first time may not be preset, and the terminal may acquire the detected WiFi list and the time of detecting the WiFi list in the first time after the first event is detected, and if the time of detecting the WiFi list is within 15s after the first time, that is, in the first time, take the detected WiFi list as the WiFi list detected in the first time. In this embodiment, the detected WiFi list is acquired by an application or service in the terminal when the WLAN network needs to be used, and this process is called passive scanning, and the terminal can detect the WiFi list any time the WLAN network is scanned (the process of detecting the WiFi list may be called passive detection here), and at the same time, the time when the WiFi list is detected is recorded. It should be understood that the passive scanning needs to be implemented under the condition that the terminal sets the WLAN scanning function to be turned on, and after the terminal sets the WLAN scanning function to be turned on, an application or service in the terminal can scan the WLAN network at any time when the WLAN network needs to be used, and the WiFi list can be detected any time the WLAN network is scanned, and the time when the WiFi list is detected is recorded. In some cases, after detecting the first event, the terminal may set up to perform an active detection within a first time in case the terminal turns off the WLAN scanning function.
It should be understood that after detecting the first event, the terminal may be configured to acquire wireless network data multiple times in the first time, obtain multiple pieces of qualified wireless network data, and upload the pieces of qualified wireless network data to the cloud server. Or after the first event is detected, acquiring a qualified wireless network, and then not acquiring the wireless network, waiting until the first event is detected next time, and uploading the wireless network to the cloud server.
S102, detecting a first event, and acquiring wireless network data by other terminals and uploading the wireless network data to a cloud server;
the process involved in this step S102 is the same as that involved in the aforementioned step S101, and reference is made to the aforementioned description of step S102.
It should be understood that the time of execution of the step S102 and the step S101 is not sequentially divided, and other terminals may be in the same area to be calibrated with the terminal, or may not be in the same area to be calibrated.
The steps S101 and S102 may be repeatedly performed within a period of time, and the terminal and other terminals may perform acquiring the wireless network data and upload the wireless network data to the cloud server as long as the first event is detected.
Referring to the foregoing, the cloud server may receive N pieces of wireless network data sent by different terminals, and then calculate the access point distance features corresponding to different areas using the N pieces of wireless network data, which may refer to the following description of step S103-step S107.
S103, grouping by the cloud server based on cell identifiers in the N pieces of wireless network data to obtain a plurality of different groups, wherein any group corresponds to one different cell, any cell comprises M pieces of wireless network data, the values corresponding to M in different cells are possibly different and possibly the same, and the N pieces of wireless network data come from different areas;
in some embodiments, the cell identity may be described by a combination of a location area code (location area code, LAC) and a cell number (cellid). When the cloud server determines that LAC and cellid in two wireless network data are the same, it may be determined that the two wireless network data may be divided into one group. When the cloud server determines that LAC or celid in the two wireless network data are not the same, it may be determined that the two wireless network data may not be divided into one group.
In other embodiments, the cell identity may be described by a combination of location area code (location area code, LAC), cell number (cellid), and the operator to which the cell belongs (common operators include telecommunications, mobile, and telecom). When the cloud server determines that LAC, cellid, and operator in the two wireless network data are the same, it may be determined that the two wireless network data may be divided into one group. When the cloud server determines that at least one of LAC, cellid, and operator in the two wireless network data is different from each other, it may be determined that the two wireless network data may not be divided into one group.
The cell identifier is used to group N pieces of wireless network data acquired by different terminals in different areas according to cells, and a detailed description of the cell identifier may refer to a related description thereof, for example, the related description of fig. 3.
The cloud server groups the wireless network data with the same cell identifier in the same group through the cell identifier in the N pieces of wireless network data, any group corresponds to a different cell, any cell can comprise M pieces of wireless network data, the M pieces of wireless network data are acquired by different terminals in one or more areas in the cell, and the M pieces of wireless network data comprise data related to access points in one or more areas in the cell and can be used for calculating the access point distance characteristics of one or more areas in the cell.
It should be understood that the values corresponding to M may be different or the same for different cells.
S104, for M pieces of wireless network data in any cell, the cloud server groups the M pieces of wireless network data to obtain a plurality of different groups, wherein any group corresponds to different areas in any cell, any area comprises X pieces of wireless network data, and the values corresponding to X in different areas are possibly different and possibly the same;
It should be understood that one area in a different cell may be referred to as a temporary area.
Referring to fig. 4, it can be seen that the same cell may include a plurality of different areas, for example, when the area to be calibrated is an elevator hoistway, the cell 1 shown in fig. 4 includes an elevator hoistway 1, an elevator hoistway 2, and other elevator trunks, and the M pieces of wireless network data corresponding to the cell 1 include wireless network data of the elevator hoistway 1, the elevator hoistway 2, and other elevator trunks.
In the cell, the wireless network data of the same area are similar, and the wireless network data of different areas are dissimilar, so that the cloud server can group the wireless network data corresponding to different areas in the cell based on the similarity of the M wireless network data.
In one possible scenario, it is considered that in the same cell, two pieces of wireless network data are similarly: the connected access points in the two pieces of wireless network data are the same, or the WiFi lists in the two pieces of wireless network data are similar. As can be seen from the foregoing, any WiFi list may include a correspondence between the strength of one or more access points and the access point, where the one or more access points are all access points that can be detected by the terminal in the to-be-calibrated area, and detailed description of the WiFi list may refer to the related description and is not repeated herein.
The manner of determining that the two WiFi lists are similar is as follows: the ratio of the same access point in the first WiFi list to the same access point in the second WiFi list to all access points in the first WiFi list reaches a first similar threshold (e.g., 90%), or the ratio of the same access point in the first WiFi list to the same access point in the second WiFi list and having a difference in strength less than a preset strength value (e.g., 1dBm-5 dBm) to all access points in the first WiFi list reaches a second similar threshold (e.g., 90%).
It should be understood that the same access point refers to the same BSSID of the access point, and the foregoing 90% and 1dBm-5dBm are merely illustrative, and may be specifically adjusted according to practical situations, and should not be construed as limiting the embodiments of the present application. The manner of determining that two pieces of wireless network data are similar may be other manners besides the foregoing manner, which is not limited in this embodiment of the present application.
S105, for any area in any cell, the cloud server determines all connected access points corresponding to any area in any cell based on connected access points in X pieces of wireless network data included in the area, and sets all connected access points as connected access point data corresponding to the area;
The connected access point data corresponding to any region are used for identifying the electronic fence of the region, the connected access point data corresponding to different electronic fences are different, the connected access point data comprise at least one access point, the access point is an access point to which a terminal can be connected in the electronic fence of the region, and any access point corresponds to the electronic fence of the region. For a detailed description of the connected access point data, reference may be made to the description of the foregoing related content, and no further description is given here.
Referring to fig. 4, it can be seen that, around any area in any cell, a terminal or other terminals may be connected to different access points, and the corresponding connected access point data of the area may include at least one connected access point, for example, when the area to be calibrated is an elevator hoistway, the access points to which the terminal or other terminals may be connected around the elevator hoistway 1 include AP1 and AP2, and the corresponding connected access point data of the elevator hoistway 1 may include AP1 and AP2.
For X pieces of wireless network data included in any area in any cell, the cloud server may determine all different connected access points based on connected access points in the X pieces of wireless network data, and use a set of all different connected access points as connected access point data corresponding to the area. For example, if 100 pieces of wireless network data are included in any area, in which the connected access point in 50 pieces of wireless network data is AP1 and the connected access point in the other 50 pieces of wireless network data is AP2, the connected access point data corresponding to the area includes AP1 and AP2.
S106, for any cell, the cloud server calculates the intra-cell access distance characteristic corresponding to any region in any cell based on X WiFi lists in X pieces of wireless network data included in any region;
the intra-cell access point distance feature corresponding to any area (to-be-calibrated area) in any cell is the relative distance between all access points which can be detected by a terminal and the to-be-calibrated area (hereinafter, the relative distance is simply referred to as the intra-cell distance) in the to-be-calibrated area in the cell, when the distance between the access point and the temporary area is calculated in any cell, the energy of the electric wave is not absorbed by an obstacle or reflected or scattered when the electric wave propagates in free space, and the access point distance feature corresponding to any area (to-be-calibrated area) in any cell can be expressed as the corresponding relationship between any access point and the intra-cell distance of the intra-cell access point.
Referring to fig. 4, it can be seen that, for two different areas in any cell, a terminal or other terminals may detect different access points, where the differences are represented by: the BSSID of the detectable access point, or the same access point, but different intensities, the calculated distances are different, for example, when the area to be calibrated is a hoistway, the access points detectable by the terminal or other terminals are AP1, AP2, AP3, AP4, etc. around the hoistway 1, the access points detectable by the terminal or other terminals are AP1, AP2, AP3, AP4, AP5, etc. around the hoistway 2, and the same terminal detects the access points around the hoistway 1 and around the hoistway 2, which are different in that: the BSSIDs of the access points that can be detected are different and the same access point, e.g., AP1, is different in intensity in different areas (not shown).
In summary, the function of identifying the area in any cell can be achieved by using the intra-cell access distance feature corresponding to any area.
Fig. 6 shows a schematic flow chart of calculating in any cell the intra-cell access distance characteristics corresponding to any region.
The process of calculating the intra-cell access distance feature corresponding to any area in any cell by the cloud server may refer to the following description of step S201-step S203:
s201, the cloud server calculates the relative distances (distance values) between all access points in the X WiFi lists and the area to be calibrated based on X WiFi lists in X wireless network data included in any area, and the same access point can have a plurality of distance values;
the cloud server converts the intensities corresponding to all the access points in the X WiFi lists into the relative distance (hereinafter referred to as distance value) between the access point and the area to be calibrated, the same access point can have a plurality of distance values, and because the X WiFi lists correspond to the same area, the same access point can appear for a plurality of times in the X WiFi lists, and the intensities of the plurality of access points can correspond to the same access point.
One possible way to determine the distance value of any access point is to calculate the intensity corresponding to the access point by a signal attenuation company to obtain the relative distance between the access point and the area to be calibrated.
S202, the cloud server calculates the intra-cell distances corresponding to all access points, and any one access point uniquely corresponds to one intra-cell distance;
the cloud server calculates an average distance of any access point based on all the distances corresponding to the access points, wherein the average distance corresponds to one average distance, and the average distance is used for uniquely representing the intra-cell distance of the access point relative to the area to be calibrated in one electronic fence.
One possible implementation manner is that the cloud server counts the number of times K of occurrence of any access point 1 Calculating K corresponding to the access point 1 Sum of distance values sum 1 The average distance is sum 1 /K 1 The average distance is taken as the intra-cell distance of the access point.
Another possible implementation manner is that, in a case where a certain access point corresponds to a plurality of distance values, a distance value with a distance value greater than a second distance preset value may not participate in calculation, and K corresponding to the access point is counted 1 Number K of distance values smaller than the second distance value 2 Calculate the K 2 Sum of distance values sum 2 The average distance of the access points is sum 2 /K 2 The average distance is taken as the intra-cell distance of the access point.
It should be understood that, the intra-cell distance corresponding to any access point is calculated as the relative distance between the access point and the area to be calibrated in a certain cell, and the manner of calculating the intra-cell distance may be other than the above-mentioned manner, which is not limited in this embodiment of the present application.
S203, the cloud server takes the intra-cell distance between any access point with the intra-cell distance smaller than the first distance preset value and the corresponding access point in all the access points as the access point distance characteristic of the area.
Step S203 is optional, and may consider that when the intra-cell distance of the access point is greater than the first distance preset value, the access point is not in the electronic fence of the area to be calibrated, that is, the intra-cell distance corresponding to the access point is considered to cause a larger error, and then the cloud server may use the corresponding relationship between any one of the access points whose intra-cell distances are smaller than the first distance preset value and the intra-cell distance of the access point as the intra-cell, and the intra-cell access point distance corresponding to the area is characterized.
S107, the cloud server combines the intra-cell access point distance characteristics corresponding to the areas with the same connected access point data in different cells to obtain the access point distance characteristics corresponding to different areas, and any area is associated with different connected access point data;
the distance characteristics of the access points corresponding to any area (around the area to be calibrated) are the relative distances between all the access points that can be detected by the terminal and the area to be calibrated (hereinafter, the relative distances are simply referred to as the area distances, which are the distances between the access points and the area to be calibrated when the distance between the access points and the area to be calibrated is calculated, and if the electric waves propagate in free space, the energy of the electric waves is not absorbed by the obstacles and is not reflected or scattered), and the distance characteristics of the access points can be expressed as the corresponding relation between any access point and the area distance between the access point and the area to be calibrated, wherein one example can refer to the description in the table 1 and is not repeated herein.
In different cells, the areas with the same connected access point data refer to the areas with the same corresponding connected access point data, the two connected access point data are the same, that is, the number of access points in the connected access point data of the first area and the BSSID of each access point are the same as those of the second area, or the number of access points in the connected access point data of the first area is smaller than that of the second area, but the BSSID of each access point in the connected access point data of the first area can be found in the BSSID of each access point in the connected access point data of the second area to be the same as the BSSID.
For ease of description, areas having the same connected access point data may be referred to as the same area.
The cloud server can combine the intra-cell access point distance features corresponding to the same area in different cells based on the connected access point data in the cell corresponding to any area in the different cells to obtain the access point distance features corresponding to the area.
The method for combining the intra-cell access distance features corresponding to the same area in different cells is that for the intra-cell access distance features corresponding to the same area in different cells, a cloud server counts the occurrence times K of any access point 3 Calculating K corresponding to the access point 3 Sum of intra-cell distances sum 3 The average distance is sum 3 /K 3 The area distance of the access point is sum relative to the area to be calibrated 3 /K 3
If a certain area in a certain cell does not have the intra-cell access point distance characteristics corresponding to the same area in other cells, the intra-cell access point distance characteristics corresponding to the area are the access point distance characteristics corresponding to the area.
It should be understood that, as shown in fig. 4, since the same area may be located in different cells, for example, the elevator entrance 1 and the elevator entrance 2 are located in the cell 1 and also in the cell 2, all wireless network data acquired by different terminals in the same area may be divided into different cells in step S103, and the same area is obtained through steps S104-S106, and the access point distance features and the corresponding connected access point data in the corresponding cells in the different cells, and then the access point distance features corresponding to the different areas may be combined in step S107 to obtain one different connected access point data associated with any area.
The electronic fence of any area may further include a connected access point strength feature in addition to the access point distance feature, and the cloud server may refer to the following description of step S108-step S112 for calculating the connected access point strength feature corresponding to any area.
It should be understood that, only enough connected access point strength data can make the calculation of the strength characteristics of the connected access points corresponding to any area more accurate, and the related description related to the process may refer to the foregoing description of acquiring N pieces of wireless network data, which is not described herein for brevity.
The detailed process of the cloud server to obtain the strength data of one connected access point sent by the terminal and other terminals may refer to the following steps S108-S109:
s108, detecting a second event, and acquiring the strength data of the connected access point by the terminal and uploading the strength data to the cloud server;
the connected access point strength data is a correspondence between the strength of an access point (connected access point) to which the terminal is connected and the connected access point. And when the terminal detects a second event at the second moment, acquiring wireless network data corresponding to the second time. The areas to be calibrated are different, the second event and the second time may be set differently, and the detailed description of the second event and the second time may refer to the related description and will not be repeated here.
The second event is used to determine that the terminal leaves the area to be calibrated at the second time, (leaves the area to be calibrated and leaves other areas from the area to be calibrated), and the second time is the second time and a period of time before the second time, which can be considered as the second time, and the terminal is always in the electronic fence of the area to be calibrated before the terminal leaves the fence from the electronic fence of the area to be calibrated at the second time, for example, the time from the second time to the 10 th s after the second time. It should be understood that the 10s is an example, and may be set to other time, for example, 15s or 20s, which is not limited in this embodiment of the present application, and the second time setting mode may refer to the foregoing description of the first time setting mode, which is not repeated herein.
And in the second time, the terminal can determine the strength of the connected access point, and obtain the corresponding relation between the strength of the connected access point and the connected access point as a piece of connected access point strength data.
In one possible case, the terminal may acquire the strength of the connected access point detected within a period of time and the time when the strength is detected (hereinafter simply referred to as storage data), and store the strength, and after the second event is detected, the correspondence between the strength of the connected access point in the storage data and the connected access point, which meets a preset condition, is taken as the strength data of the connected access point, where the preset condition may be that the time when the strength is detected is within a second time, so that a plurality of pieces of strength data of the connected access point may be acquired, or the time when the strength is detected is within the second time and the time is the foremost, so that one piece of strength data of the connected access point may be acquired. The period of time is the latest period of time, and may be 5s-20s, for example, when the period of time is 10s, the terminal stores the strength of the connected access point obtained in the current 10s all the time, it should be understood that the foregoing 5s-20s is illustrative, and may be actually adjusted according to needs, which is not limited in the embodiment of the present application. In this embodiment, the process of the terminal acquiring the strength of the connected access point and the time when the strength is detected is: when a terminal is connected with a certain access point, the terminal can periodically detect the intensity of the access point to adjust parameters in network communication, and record the intensity detection time.
In another embodiment, the terminal may be configured to acquire the strength of the connected access point once and detect the strength within a period, for example, 30s, and after detecting the second event, the terminal may determine the strength of the connected access point in the second time when the strength is detected, and use the correspondence between the strength of the connected access point and the strength of the connected access point as the strength data of the connected access point.
It should be understood that after detecting the second event, the terminal may be configured to acquire the strength data of the connected access points multiple times in the first time, obtain multiple pieces of qualified strength data of the connected access points, and upload the pieces of strength data to the cloud server. And after the second event is detected, the method can also set that the second event is not acquired after the qualified connected access point intensity data is acquired, and the second event is acquired again after the second event is detected next time and is uploaded to the cloud server.
S109, detecting a second event, and acquiring the strength data of the connected access point by other terminals and uploading the strength data to a cloud server;
the process involved in this step S109 is the same as that involved in the aforementioned step S108, and reference is made to the aforementioned description of step S108.
It should be understood that the execution time of the step S109 and the aforementioned step S108, step S101, and step S102 is not sequentially divided, and other terminals may be in the same area to be calibrated with the terminal, or may not be in the same area to be calibrated any more.
The steps S108 and S109 may be repeated for a period of time, and the terminal and other terminals may perform to acquire the strength data of the connected access point and upload the data to the cloud server as long as the second event is detected.
Referring to the foregoing, the cloud server may receive Z pieces of connected access point intensity data sent by different terminals, and then calculate connected access point intensity data corresponding to different areas using the Z pieces of connected access point intensity data, which may refer to the following description of step S110 to step S112.
S110, the cloud server calculates the intensity threshold of any connected access point based on the intensity data of Z connected access points to obtain the corresponding relation between the intensity threshold of all connected access points and the connected access points;
the strength threshold of any connected access point may be the strength corresponding to the connected access point in the electronic fence of the area to be calibrated when the terminal connects the access point, where the strength may be indicated by a received signal strength indicator (received signal strength indication, RSSI), and the strength may be a range, may be the lowest strength-highest strength corresponding to the connected access point in the electronic fence of the area to be calibrated, or may be a value, for example, may be the lowest strength corresponding to the connected access point in the electronic fence of the area to be calibrated.
In one possible implementation manner, the cloud server groups connected access points based on the connected access points in the Z pieces of connected access point intensity data, uses the connected access point intensity data with the same connected access point as a group, that is, any group corresponds to a different connected access point, calculates the intensity threshold of the connected access point corresponding to the group by using the intensities of the connected access points in the intensity data of all connected access points in any group, and obtains the corresponding relation between the intensity threshold of all connected access points and the connected access point.
S111, the cloud server matches all connected access points with connected access point data corresponding to any area, determines all connected access points matched with the connected access point data corresponding to any area, and uses the corresponding relation between the intensity threshold values of all connected access points matched with any area and the connected access points as the connected access point intensity characteristics corresponding to the area to obtain the connected access point intensity characteristics corresponding to different areas;
the fact that the connected access point matches with the connected access point data corresponding to any area means that the BSSID of the connected access point is the same as the BSSID of a certain connected access point in the connected access point data.
The cloud server may match any one of the connected access points with the connected access point data corresponding to any one of the areas based on the corresponding relation between the intensity threshold values of all the connected access points and the connected access points obtained in the foregoing step S110, and if the matching is performed, determine all the connected access points matched with the area, and use the corresponding relation between the intensity threshold values of all the connected access points and the connected access points as the connected access point intensity feature corresponding to the area. In this way, the cloud server can obtain the strength characteristics of the connected access points corresponding to the H areas.
And S112, for any area, the cloud server uses the strength characteristics of the connected access points and the distance characteristics of the access points corresponding to the area as the electronic fence of the area so as to identify the area.
Based on the connected access point intensity characteristics corresponding to the different areas obtained in step S107 and the connected access point intensity characteristics corresponding to the different areas obtained in step S111, for any area, the cloud server uses the connected access point intensity characteristics and the access point distance characteristics corresponding to the area as the electronic fence of the area to identify the area, and the connected access point data corresponding to the area is used as the connected access point data corresponding to the electronic fence of the area to identify the electronic fence.
It should be understood that the processes described in the foregoing steps S101-S112 are applicable to the electronic fence of the area to be calibrated, where the electronic fence includes the access point distance feature and the connected access point strength feature corresponding to the area to be calibrated. When the electronic fence of the area to be calibrated includes different features, reference may be made to the foregoing description, which is not repeated herein, for example, when the electronic fence of the area to be calibrated includes only the access point distance features corresponding to the area to be calibrated, the terminal may determine the electronic fence of the different area by reference to the foregoing steps S101 to S107.
The detailed process of generating an electronic fence by the terminal is described below.
The process of generating the electronic fence by the terminal is similar to the process of generating the electronic fence by the cloud server, and is different in that sources of N pieces of wireless network data and Z pieces of connected access point intensity data related to the electronic fence used for calculating different areas are different, and in general, the terminal does not receive the wireless network data and the connected access point intensity data sent by other terminals, and then the N pieces of wireless network data and the Z pieces of connected access point intensity data are acquired by the terminal.
Fig. 7 is a schematic flow chart diagram illustrating terminal-generated electronic fence.
The process of generating the electronic fence by the terminal may refer to the following description of step S301 to step S310:
s301, a terminal acquires N pieces of wireless network data;
the wireless network data may include access points to which the terminal is connected (connected access points) and a WiFi list. When the terminal detects the first event at the first moment, the wireless network data corresponding to the first moment can be acquired, and the process involved in acquiring any wireless network data by the terminal is the same as the process of acquiring wireless network data by referring to the foregoing step S101, and the related description can be referred to, which is not repeated here.
In a possible case, the terminal may set to perform calculation of the access point distance feature by using a plurality of pieces of wireless network data acquired in a period of time, where the period of time may be 10 days to 14 days, or may be other time, and may also be adjusted according to a specific data acquisition situation of the terminal.
In another possible case, the terminal may be configured to perform the calculation of the electronic fence when the wireless network data and the strength data of the connected access points are acquired to a certain number.
S302, the terminal acquires Z pieces of connected access point intensity data;
The connected access point strength data is a correspondence between the strength of an access point (connected access point) to which the terminal is connected and the connected access point. When the terminal detects the second event at the second moment, wireless network data corresponding to the second time can be acquired, and the process involved in acquiring the strength data of any connected access point by the terminal is the same as the process of acquiring the strength data of the connected access point by referring to the foregoing step S108, and the related description will be referred to and will not be repeated here.
In a possible case, the terminal may set to perform calculation of the strength characteristic of the connected access point by using a plurality of pieces of strength data of the connected access point acquired in a period of time, where the period of time may be 10 days to 14 days, or may be other periods of time, and may be adjusted according to a specific data acquisition situation of the terminal.
In another possible scenario, the terminal may be configured to perform the calculation of the strength characteristics of the connected access points when the strength data of the connected access points is acquired up to a certain number.
It should be understood that this step S302 is performed just before step S308 described below.
S303, grouping the terminal based on the cell identifiers in the N pieces of wireless network data to obtain a plurality of different groupings, wherein any grouping corresponds to one different cell, any cell comprises M pieces of wireless network data, the values corresponding to M in different cells are different or the same, and the N pieces of wireless network data come from different areas;
The detailed process involved in this step S303 is similar to that of the previous step S103, and reference may be made to the previous description of the step S103, which is not repeated here.
S304, for M wireless network data in any cell, the terminal groups based on the M wireless network data to obtain a plurality of different groups, wherein any group corresponds to different areas in any cell, any area comprises X wireless network data, and the values corresponding to X in different areas are different or the same;
the detailed process involved in this step S304 is similar to that of the previous step S104, and reference may be made to the previous description of the step S104, which is not repeated here.
S305, for any area in any cell, the terminal determines all connected access points corresponding to any area in any cell based on connected access points in X pieces of wireless network data included in the area, and sets all connected access points as connected access point data corresponding to the area;
the detailed process involved in this step S305 is similar to that of the previous step S105, and reference may be made to the previous description of the step S105, which is not repeated here.
S306, for any cell, the terminal calculates the intra-cell access point distance characteristic corresponding to any region in any cell based on X WiFi lists in X pieces of wireless network data included in any region;
The detailed process involved in this step S306 is similar to that of the previous step S106, and reference may be made to the previous description of step S106, which is not repeated here.
S307, the terminal combines the intra-cell access point distance characteristics corresponding to the areas with the same connected access point data in different cells to obtain the access point distance characteristics corresponding to different areas, and any area is associated with different connected access point data;
the detailed process involved in this step S307 is similar to the previous step S107, and reference may be made to the previous description of step S107, which is not repeated here.
S308, calculating the intensity threshold of any connected access point based on the intensity data of Z connected access points to obtain the corresponding relation between the intensity threshold of all connected access points and the connected access points;
the detailed process involved in this step S308 is similar to that of the step S110, and reference may be made to the description of the step S110, which is not repeated here.
S309, the terminal matches all connected access points with connected access point data corresponding to any area, determines all connected access points matched with the connected access point data corresponding to any area, and uses the corresponding relation between the intensity threshold value of all connected access points matched with any area and the connected access points as the connected access point intensity characteristic corresponding to the area to obtain the connected access point intensity characteristic corresponding to different areas;
The detailed process involved in this step S309 is similar to that of the previous step S111, and reference may be made to the previous description of the step S111, which is not repeated here.
S310, for any area, the terminal uses the strength characteristics of the connected access points and the distance characteristics of the access points corresponding to the area as the electronic fence of the area so as to identify the area.
The detailed process involved in this step S310 is similar to that of the previous step S112, and reference may be made to the previous description of the step S112, which is not repeated here.
It should be understood that the processes described in the foregoing steps S301-S310 are applicable to the electronic fence of the area to be calibrated, where the electronic fence includes the access point distance feature and the connected access point strength feature corresponding to the area to be calibrated. When the electronic fence of the area to be calibrated includes different features, reference may be made to the foregoing description, and details are not repeated here.
It should be understood that the letters, such as N, Z, I, etc., referred to in steps S301-S310 for representing a plurality of data, while identical to those in the foregoing steps S101-S112, may actually be different, and are merely presented herein for convenience of description to use the same letters in similar steps.
In some embodiments, after determining the electronic fence of any area, the cloud server or the terminal may further verify whether the electronic fence of any area is available, if so, store the electronic fence of the area, and if not, not store the electronic fence of the area, and the process of determining whether the electronic fence of any area is available by the cloud server is described below, and the process of determining whether the electronic fence of any area is available by the terminal may be described below.
The manner in which the cloud server determines whether an electronic fence for any region is available is as follows:
in one possible implementation manner, the cloud server may verify whether the electronic fence is available based on all WiFi lists corresponding to the electronic fence in any area, where all WiFi lists corresponding to any electronic fence include any WiFi list used by calculating the electronic fence, and when the cloud server determines that the qualified WiFi list reaches the first threshold in all WiFi lists, it determines that the electronic fence is available, where a condition that any WiFi list is qualified in all WiFi lists is: among the distances corresponding to all the access points in any WiFi list, the qualified distance is larger than a second threshold, and the condition that the distance corresponding to any access point is the qualified distance is as follows: the distance corresponding to any access point is smaller than the distance preset difference value in the access point distance characteristic of the electronic fence of any area to be calibrated, wherein the first threshold value can be 80% of the distance related to the first threshold value, and the second threshold value can be 3 of the distance related to the second threshold value.
Specifically, it is assumed that Q total WiFi lists corresponding to any one of the electronic fences are provided, and one or more corresponding relations between the strength of the access point and the access point are included in any one of the WiFi lists, where it is assumed that Y is included in the i th WiFi list i The correspondence of the strength of a bar access point to that access point. For the ith WiFi list, Y is included i The corresponding relation between the intensity of the strip access point and the access point is Y i A plurality of access points, wherein any one access point corresponds to the intensity of the access point, and Y is the following i The intensity of each access point respectively will Y i The intensity of each access point is converted into the relative distance between the access point and the area to be calibrated, and Y is obtained i The cloud service can obtain Y based on the i-th WiFi list when the distance corresponding to the access point is the same as the distance corresponding to the access point i Access points and Y i A distance corresponding to one access point, and then the cloud server counts the Y i The number of eligible access points in the plurality of access points, the number of eligible access points being denoted as C i Wherein Y is i The judging condition that any one of the access points is a qualified access point may be: one access point is the same in all the access points included in the access point distance characteristics of the electronic fence (the access point distance characteristics are expressed as the corresponding relation between any access point and the area distance of the access point), and then the cloud server counts the C i C corresponding to each access point i A number of acceptable distances, expressed as D, among the distances i Wherein C i The judging condition that any one of the distances is a qualified distance may be: the difference between the distance and the area distance of the access point corresponding to the distance is smaller than a distance preset difference, for example, the distance preset difference may be 5 meters. Thus, for any electronic fence, the cloud server can obtain the number of qualified access points and the number of qualified distances corresponding to any WiFi list in the Q WiFi lists corresponding to the electronic fenceWherein the number of qualified access points corresponding to the ith WiFi list is C i The number of the qualified distances is D i . The electronic fence can be considered to be usable when the cloud server determines that the number of qualified distances corresponding to more than 80% of the WiFi lists is greater than 3 in the Q WiFi lists corresponding to any fence, the electronic fence can be considered to be unusable when the cloud server determines that the number of qualified distances corresponding to less than 80% of the WiFi lists is greater than 3 in the Q WiFi lists corresponding to any fence, and the electronic fence can be considered to be unusable when the cloud server determines that the number of qualified distances corresponding to 80% of the WiFi lists is greater than 3 in the Q WiFi lists corresponding to any fence. And the WiFi list with the qualified distance being more than 3 is the qualified WiFi list.
It should be understood that the manner in which the cloud server obtains all WiFi lists corresponding to the electronic fences in any area may be: in the process of calculating the electronic fence of any area, the cloud server can store all WiFi lists used for calculating the electronic fence to obtain all WiFi lists corresponding to the electronic fence.
It should also be understood that 80%, 3 meters and 5 meters are all exemplified in the foregoing description, and may be adjusted according to practical situations.
In some embodiments, after the cloud server calculates the electronic fences of each area to be calibrated, all the electronic fences are stored in the cloud server, and one connected access point data corresponding to any electronic fence can also correspond to one matching threshold parameter.
The matching threshold parameter corresponding to any electronic fence is used for determining whether a WiFi list (hereinafter referred to as a first WiFi list) acquired by the terminal is matched with the electronic fence, if so, it can be determined that the terminal enters the electronic fence, and if not, it can be determined that the terminal leaves the electronic fence.
The matching threshold parameter includes a threshold number of qualified access points and a threshold number of qualified distances, where the threshold number of qualified access points is used to represent a minimum number of qualified access points (access points that are the same as any access point included in the access point distance feature of the electronic fence) in all access points included in the first WiFi list, and the threshold number of qualified distances is used to represent a minimum number of qualified distances (a distance between the area distances of the access points corresponding to the distances is less than a preset difference value) in all access points included in the first WiFi list, where relevant descriptions about the qualified access points and the qualified distances may refer to relevant descriptions in the foregoing embodiments, and are not repeated herein.
And if the number of the qualified access points in all the access points included in the first WiFi list is determined to be larger than the threshold value of the number of the qualified access points, and/or the number of the qualified distances in the distances corresponding to the qualified access points is determined to be larger than the threshold value of the number of the qualified distances, the first WiFi list is determined to be matched with the electronic fence, and then the terminal can be determined to enter the electronic fence.
And if the number of qualified access points in all the access points included in the first WiFi list is smaller than the threshold value of the number of the qualified access points, or if the qualified distance is smaller than the threshold value of the number of the qualified distances in the distances corresponding to the qualified access points, determining that the first WiFi list is not matched with the electronic fence, and determining that the terminal leaves the electronic fence.
In the case that it is determined that the number of qualified access points in all access points included in the first WiFi list is equal to the threshold number of qualified access points, and/or that the number of qualified distances in the distances corresponding to the qualified access points is equal to the threshold number of qualified distances, if it is determined that the first WiFi list is not matched with the electronic fence, it may be determined that the terminal enters the electronic fence, or it may be determined that the terminal leaves the electronic fence.
One possible way for the cloud server to calculate the matching threshold parameters corresponding to any electronic fence is: the cloud server may calculate the matching threshold parameters for the electronic fence based on all WiFi lists for the electronic fence for any area, where all WiFi lists for any electronic fence include any WiFi list utilized to calculate the electronic fence.
Specifically, assuming that Q total WiFi lists corresponding to any electronic fence are provided, the cloud server may obtain the number of qualified access points and the number of qualified distances corresponding to any WiFi list in the Q WiFi lists corresponding to the electronic fence, where the number of qualified access points corresponding to the ith WiFi list is C i The number of the qualified distances is D i The number of Q qualified access points and the number of Q qualified distances can be obtained, and the process involved in this calculation is described in the foregoing embodiment correspondingly, which is not described herein. And then, the cloud server sorts the number of the Q qualified access points and the number of the Q qualified distances from small to large respectively, and for the sorted number of the Q qualified access points, selecting the 1% of the sorted number of the Q qualified access points as a qualified access point number threshold value, and for the sorted number of the Q qualified distances, selecting the 1% of the sorted number of the Q qualified access points as a qualified distance number threshold value.
It should be understood that 1% of the foregoing is a distance description, and may be set according to needs in practical applications, for example, 2%, 10%, etc., and should not be construed as limiting the embodiments of the present application.
It should be understood that, in some embodiments, after the terminal calculates the electronic fences in each area to be calibrated, all the electronic fences are stored in the terminal, one connected access point data corresponding to any electronic fence may also correspond to one matching threshold parameter, and a process of determining the matching threshold of any electronic fence by the terminal is similar to the process of determining the matching threshold of any electronic fence by the cloud server, which is not repeated herein.
In one possible embodiment, if the electronic fence is calculated on the cloud server, after the terminal is connected to an access point, the electronic fence corresponding to the access point may be obtained from the cloud server and then stored locally.
The manner of obtaining the electronic fence corresponding to the access point from the cloud server by the terminal may be: after a terminal connects to a certain access point, the access point is matched with the connected access point data corresponding to all the electronic fences stored in the cloud server, in the case that one connected access point is the same as the first access point in the connected access point data, it is determined that the electronic fence corresponding to the connected access point data is the electronic fence corresponding to the first access point, in some embodiments, the same is that the BSSID of the connected access point is the same as the BSSID of the first access point, for example, when the BSSID of the first access point is 6c:16:32:17:3c:95, that is, the BSSID1 in the connected access point data corresponding to the electronic fence shown in table 1 is the same, and when the first access point is 6c:16:32:17:3c:95, it is determined that the electronic fence shown in table 1 is the first electronic fence corresponding to the first connection point.
If the terminal does not acquire the electronic fence corresponding to the access point from the cloud server, the terminal can identify that the access point does not have the electronic fence corresponding to the access point, and when the terminal needs to acquire the electronic fence corresponding to the access point according to the access point, if the terminal determines that the access point does not have the electronic fence corresponding to the access point, the terminal can not acquire the electronic fence any more, and directly determines that the first access point does not have the electronic fence corresponding to the access point.
An exemplary communication system provided in an embodiment of the present application is described below.
Fig. 8 is a schematic structural diagram of a communication system according to an embodiment of the present application.
As shown in fig. 8, at least one terminal, such as terminal 101, terminal 102, terminal 103, and others, may be included in the communication system. A cloud server 104 is also included in the communication system.
The terminal may be a terminal device on which Android, iOS, microsoft or other operating systems are mounted, such as a mobile phone, a tablet computer, a notebook computer, a personal computer, or a desktop computer with a touch panel. For example, in the example shown in fig. 8, the terminals 101 and 102 are mobile phones, and the terminal 103 is a notebook computer.
Terminals, such as terminal 101 and terminal 102, may access a WiFi network corresponding to the access point through the connected access point, and may then communicate with a device (e.g., a router) that provides the WiFi network, where the router may route information sent by the terminal 101 and terminal 102 to other terminals, so that the terminal 101 and the terminal 102 may communicate with other terminals.
Terminals such as terminal 101 and terminal 102 may also acquire wireless network data and connected access point strength data that may be used by cloud server 104 to generate an electronic fence, and send the data to cloud server 104.
The cloud service 104 may calculate an electronic fence of the area to be calibrated based on the received wireless network data and the connected access point strength data, and the cloud server 104 may also send the calculated electronic fence to the terminal.
It should be understood that, the matching threshold parameters corresponding to the electronic fence and the connected access point data corresponding to the electronic fence in the embodiments of the present application may also be used as parameters in the electronic fence to describe the electronic fence, like the scannable access point feature and the connected access point feature, and besides these parameters, parameters such as a cell identifier to which the area to be calibrated belongs may also be included in the electronic fence.
An exemplary terminal provided in an embodiment of the present application is first described below.
Fig. 9 is a schematic structural diagram of a terminal provided in an embodiment of the present application.
The embodiments are specifically described below with reference to a terminal. It should be understood that the terminal may have more or less components than those shown in the figures, may combine two or more components, or may have different configurations of components. The various components shown in the figures may be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and/or application specific integrated circuits.
The terminal may include: processor 110, external memory interface 120, internal memory 121, universal serial bus (universal serial bus, USB) interface 130, charge management module 140, power management module 141, battery 142, antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, audio module 170, speaker 170A, receiver 170B, microphone 170C, headset interface 170D, sensor module 180, keys 190, motor 191, indicator 192, camera 193, display 194, and subscriber identity module (subscriber identification module, SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyro sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, and the like.
It should be understood that the structure illustrated in the embodiments of the present invention does not constitute a specific limitation on the terminal. In other embodiments of the present application, the terminal may include more or less components than illustrated, or certain components may be combined, or certain components may be split, or different arrangements of components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
The processor 110 may include one or more processing units, such as: the processor 110 may include an application processor (access point plication processor, access point), a modem processor, a graphics processor (gr access point hics processing unit, GPU), an image signal processor (image signal processor, ISP), a controller, a memory, a video codec, a digital signal processor (digital signal processor, DSP), a baseband processor, and/or a neural network processor (neural-network processing unit, NPU), etc. Wherein the different processing units may be separate devices or may be integrated in one or more processors.
In some embodiments, the processor 110 may include one or more interfaces. The interfaces may include an integrated circuit (inter-integrated circuit, I2C) interface, an integrated circuit built-in audio (inter-integrated circuit sound, I2S) interface, a pulse code modulation (pulse code modulation, PCM) interface, and the like.
It should be understood that the connection relationship between the modules illustrated in the embodiment of the present invention is only illustrative, and does not limit the structure of the terminal. In other embodiments of the present application, the terminal may also use different interfacing manners in the foregoing embodiments, or a combination of multiple interfacing manners.
The charge management module 140 is configured to receive a charge input from a charger.
The power management module 141 is used for connecting the battery 142, and the charge management module 140 and the processor 110.
The wireless communication function of the terminal can be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, a modem processor, a baseband processor, and the like.
The antennas 1 and 2 are used for transmitting and receiving electromagnetic wave signals.
The mobile communication module 150 may provide a solution for wireless communication including 2G/3G/4G/5G or the like applied on the terminal. The mobile communication module 150 may include at least one filter, switch, power amplifier, low noise amplifier (low noise amplifier, LNA), etc.
The modem processor may include a modulator and a demodulator. The modulator is used for modulating the low-frequency baseband signal to be transmitted into a medium-high frequency signal.
The wireless communication module 160 may provide solutions for wireless communication including wireless local area network (wireless local area networks, WLAN) (e.g., wireless fidelity (wireless fidelity, wiFi) network), bluetooth (BT), global navigation satellite system (global navigation satellite system, GNSS), frequency modulation (frequency modulation, FM), near field wireless communication technology (near field communication, NFC), infrared technology (IR), etc. applied on the terminal. The wireless communication module 160 may be one or more devices that integrate at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, modulates the electromagnetic wave signals, filters the electromagnetic wave signals, and transmits the processed signals to the processor 110. The wireless communication module 160 may also receive a signal to be transmitted from the processor 110, frequency modulate it, amplify it, and convert it to electromagnetic waves for radiation via the antenna 2.
The pressure sensor 180A is used to sense a pressure signal, and may convert the pressure signal into an electrical signal.
The gyro sensor 180B may be used to determine a motion gesture of the terminal. In some embodiments, the angular velocity of the terminal about three axes (i.e., x, y, and z axes) may be determined by the gyro sensor 180B. The gyro sensor 180B may be used for photographing anti-shake. Illustratively, when the shutter is pressed, the gyro sensor 180B detects the angle of the terminal shake, calculates the distance to be compensated by the lens module according to the angle, and makes the lens counteract the shake of the terminal by the reverse motion, thereby realizing anti-shake. The gyro sensor 180B may also be used for navigating, somatosensory game scenes.
The air pressure sensor 180C is used to measure air pressure. In some embodiments, the terminal calculates altitude from barometric pressure values measured by barometric pressure sensor 180C, aiding in positioning and navigation.
The magnetic sensor 180D includes a hall sensor. The terminal can detect the opening and closing of the flip cover using the magnetic sensor 180D.
The acceleration sensor 180E may detect the magnitude of acceleration of the terminal in various directions (typically three axes). The magnitude and direction of gravity can be detected when the terminal is stationary. The method can also be used for identifying the gesture of the terminal, and is applied to the applications such as horizontal and vertical screen switching, pedometers and the like.
A distance sensor 180F for measuring a distance. The terminal may measure the distance by infrared or laser.
The proximity light sensor 180G may include, for example, a Light Emitting Diode (LED) and a light detector, such as a photodiode. The light emitting diode may be an infrared light emitting diode.
The ambient light sensor 180L is used to sense ambient light level. The terminal may adaptively adjust the brightness of the display 194 based on the perceived ambient light level. The ambient light sensor 180L may also be used to automatically adjust white balance when taking a photograph. The ambient light sensor 180L may also cooperate with the proximity light sensor 180G to detect if the terminal is in a pocket to prevent false touches.
The fingerprint sensor 180H is used to collect a fingerprint.
The temperature sensor 180J is for detecting temperature. In some embodiments, the terminal performs a temperature processing strategy using the temperature detected by temperature sensor 180J.
The touch sensor 180K, also referred to as a "touch panel". The touch sensor 180K may be disposed on the display screen 194, and the touch sensor 180K and the display screen 194 form a touch screen, which is also called a "touch screen".
In the embodiment of the present application, the processor 110 may invoke computer instructions stored in the internal memory 121, so that the terminal performs the method referred to in the embodiment of the present application.
The above embodiments are merely for illustrating the technical solution of the present application, and not for limiting the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present application.
As used in the above embodiments, the term "when …" may be interpreted to mean "if …" or "after …" or "in response to determination …" or "in response to detection …" depending on the context. Similarly, the phrase "at the time of determination …" or "if detected (a stated condition or event)" may be interpreted to mean "if determined …" or "in response to determination …" or "at the time of detection (a stated condition or event)" or "in response to detection (a stated condition or event)" depending on the context.
In the above embodiments, it may be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented in software, may be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When loaded and executed on a computer, produces a flow or function in accordance with embodiments of the present application, in whole or in part. The computer may be a general purpose computer, a special purpose computer, a computer network, or other programmable apparatus. The computer instructions may be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transmitted from one website, computer, server, or data center to another website, computer, server, or data center by a wired (e.g., coaxial cable, fiber optic, digital subscriber line), or wireless (e.g., infrared, wireless, microwave, etc.). The computer readable storage medium may be any available medium that can be accessed by a computer or a data storage device such as a server, data center, etc. that contains an integration of one or more available media. The usable medium may be a magnetic medium (e.g., floppy disk, hard disk, magnetic tape), an optical medium (e.g., DVD), or a semiconductor medium (e.g., solid state disk), etc.
Those of ordinary skill in the art will appreciate that implementing all or part of the above-described method embodiments may be accomplished by a computer program to instruct related hardware, the program may be stored in a computer readable storage medium, and the program may include the above-described method embodiments when executed. And the aforementioned storage medium includes: ROM or random access memory RAM, magnetic or optical disk, etc.

Claims (16)

1. A method for generating an electronic fence, which is applied to a communication system, wherein the communication system comprises a terminal and a cloud server, and the method comprises the following steps:
the cloud server acquires a wireless network data set, wherein the wireless network data set comprises wireless network data sent by at least one terminal, and the wireless network data set comprises first wireless network data; the first wireless network data comprises a connected access point connected with a first terminal in an area to be calibrated, a WiFi list detected by the first terminal, and a cell identifier of a cell to which the area to be calibrated where the first terminal is located belongs; the first terminal is a terminal for transmitting the first wireless network data;
The cloud server divides wireless network data which have the same cell identifier and have similar WiFi lists in the wireless network data set into a group to obtain two or more groups, wherein one group corresponds to one temporary area, and one temporary area comprises at least one piece of wireless network data;
the cloud server determines the cell access point distance characteristics and the connected access point data corresponding to two or more temporary areas, wherein the cell access point distance characteristics and the connected access point data corresponding to a first temporary area are included; the intra-cell access point distance corresponding to the first temporary area is characterized by the corresponding relation between different access points and intra-cell distances in a WiFi list detected by the terminal in the first temporary area, wherein the intra-cell distances corresponding to the different access points are the relative distances between the access points and the first temporary area; the connected access point data corresponding to the first temporary area are connected access points included in each wireless network data in the first temporary area;
the cloud server combines the access point distance features in the cells of the temporary areas with the same connected access point data to obtain at least one access point distance feature corresponding to the area to be calibrated, wherein the access point distance feature comprises a first access point distance feature corresponding to a first area to be calibrated, the first access point distance feature is the corresponding relation between different access points and area distances in a WiFi list detected by the terminal, and the area distances corresponding to the different access points are the relative distances between the access points and the first area to be calibrated;
And the cloud server determines the access point distance characteristic corresponding to the first region to be calibrated as an electronic fence of the first region to be calibrated.
2. The method of claim 1, wherein after the cloud server merges the intra-cell access point distance features of the temporary area having the same connected access point data to obtain the access point distance feature corresponding to the at least one to-be-calibrated area, the method further comprises:
the cloud server takes a connected access point corresponding to a temporary area involved in the electronic fence of the first area to be calibrated as connected access point data corresponding to the first area to be calibrated;
and the cloud server identifies the electronic fence of the first region to be calibrated by utilizing the connected access point data corresponding to the first region to be calibrated.
3. The method according to claim 1 or 2, wherein the cloud server classifies wireless network data having the same cell identity and similar WiFi list in the wireless network data set into one group, specifically comprising:
the cloud server groups the wireless network data sets based on the cell identifiers to obtain two or more groups, wherein one group corresponds to one cell and comprises a first cell, and the first cell comprises at least one piece of wireless network data;
For wireless network data included in the first cell, the cloud server groups wireless network data similar to a WiFi list into one group.
4. A method according to claim 3, characterized in that:
the cloud server determines that two WiFi lists are similar in manner: and in the two WiFi lists, the ratio of the same access points in the first WiFi list to the second WiFi list to all the access points in the first WiFi list reaches a first similar threshold.
5. A method according to claim 3, characterized in that:
the cloud server determines that two WiFi lists are similar in manner: and in the two WiFi lists, the first WiFi list and the second WiFi list are the same, and the ratio of the access points with the strength difference smaller than the preset strength value to all the access points in the first WiFi list reaches a second similar threshold.
6. The method of any one of claims 1-5, wherein before the cloud server determines the access point distance feature corresponding to the first region to be calibrated as the electronic fence of the first region to be calibrated, the method further comprises:
the cloud server acquires a connected access point intensity data set, wherein the connected access point intensity data set comprises connected access point intensity data sent by at least one terminal, the connected access point intensity data set comprises first connected access point intensity data, the first connected access point intensity data is the corresponding relation between the intensity of a connected access point and the connected access point, the connected access point intensity data set comprises first connected access points, and the first connected access points have the conditions corresponding to different intensities;
The cloud server determines all intensities of the connected access points corresponding to the same connected access point in the connected access point intensity data set, and determines intensity thresholds corresponding to the same connected access point based on all the intensities to obtain intensity thresholds corresponding to different connected access points;
the cloud server utilizes the different connected access points to match with the connected access point data corresponding to the first area to be calibrated, and determines all connected access points matched with the first area to be calibrated;
the cloud server takes the corresponding relation between the intensity threshold values of all connected access points matched with the first region to be calibrated and the connected access points as the intensity characteristics of the connected access points corresponding to the first region to be calibrated;
the cloud server determines the access point distance characteristic corresponding to the first region to be calibrated as an electronic fence of the first region to be calibrated, and specifically comprises the following steps:
and the cloud server takes the access point distance characteristic corresponding to the first area to be calibrated and the strength characteristic of the connected access point as an electronic fence of the first area to be calibrated.
7. The method according to any one of claims 1-6, wherein the cloud server determines the intra-cell access point distance feature and the connected access point data corresponding to two or more temporary areas, wherein the intra-cell access point distance feature and the connected access point data corresponding to the first temporary area are included, and specifically includes:
The cloud server determines all different connected access points in the wireless network data included in the first temporary area, and takes all different connected access points as connected access point data corresponding to the first temporary area;
the cloud server calculates the distances of all access points included in all WiFi lists based on all WiFi lists in the wireless network data included in the first temporary area, wherein one distance corresponds to one access point, and the same access point has the conditions of corresponding to different distances;
the cloud server determines all distances of the same access point based on the distances of all access points, and determines the average distance of the same access point based on the all distances to obtain the average distances of different access points;
the cloud server takes the average distance of different access points as the intra-cell distance corresponding to the different access points, and obtains the corresponding relation between the different access points and the intra-cell distance;
and the cloud server determines the intra-cell access distance characteristic corresponding to the first temporary area based on the corresponding relation between the different access points and the intra-cell distances.
8. The method of claim 7, wherein the determining, by the cloud server, the intra-cell access point distance feature corresponding to the first temporary area based on the correspondence between the different access points and the intra-cell distances, specifically comprises:
And the cloud server takes the corresponding relation between the different access points and the intra-cell distances as the intra-cell access distance characteristic corresponding to the first temporary area.
9. The method of claim 7, wherein the determining, by the cloud server, the intra-cell access point distance feature corresponding to the first temporary area based on the correspondence between the different access points and the intra-cell distances, specifically comprises:
and the cloud server determines all access points meeting the conditions in the different access points, and takes the corresponding relation between all access points meeting the conditions and the intra-cell distances as the intra-cell access point distance characteristic corresponding to the first temporary area, wherein the conditions are that the intra-cell distances corresponding to the access points are smaller than a first distance preset value.
10. The method according to any one of claims 1-9, further comprising:
the cloud server determines whether an electronic fence of the first area to be calibrated is available;
in calculating all WiFi lists related to the electronic fence of the first area to be calibrated, when a qualified WiFi list reaches a first threshold value, the cloud server determines that the electronic fence of the first area to be calibrated is available, wherein all WiFi lists comprise a first WiFi list, and the condition that the first WiFi list is qualified is as follows: in the distances corresponding to all access points in the first WiFi list, the qualified distance is larger than a second threshold, all the access points in the first WiFi list comprise first access points, and the condition that the distance corresponding to the first access points is the qualified distance is as follows: the distance corresponding to the first access point is smaller than a distance preset difference value from the access point distance characteristic of the electronic fence of the first area to be calibrated;
And when determining that all WiFi lists corresponding to the electronic fences of the first area to be calibrated are calculated, determining that the electronic fences of the first area to be calibrated are unavailable by the cloud server.
11. The method according to any one of claims 1-10, further comprising:
the cloud server determines a matching threshold parameter of the electronic fence of the first area to be calibrated, the matching threshold parameter is used for determining whether the WiFi list acquired by the terminal is matched with the electronic fence of the first area to be calibrated, the matching threshold parameter comprises a qualified access point number threshold and a qualified distance number threshold, the qualified access point number threshold is used for representing the minimum number of qualified access points in all access points included in the WiFi list acquired by the terminal, the qualified access point is an access point which is the same as a certain access point included in the access point distance characteristic of the electronic fence of the first area to be calibrated in all access points of the WiFi list acquired by the terminal, the qualified distance number threshold is used for representing the minimum number of qualified distances in all access points included in the WiFi list acquired by the terminal, and the distance corresponding to the qualified access point is the difference between the distance corresponding to the qualified access point and the distance corresponding to the qualified access point of the electronic fence of the first area to be calibrated and the preset distance is smaller than the difference between the distances corresponding to the qualified access points and the access points of the electronic fence of the first area to be calibrated.
12. The method of claim 11, wherein the method further comprises:
after the terminal is connected with a second access point, the terminal acquires a first electronic fence corresponding to the second access point from the cloud server, wherein the connected access point data of the first electronic fence comprises the second access point;
the terminal determines that the intensity of the second access point is matched with an intensity threshold corresponding to the second access point, wherein the intensity threshold is an intensity threshold corresponding to the second access point included in the access point intensity characteristic of the first electronic fence, then the terminal acquires a second WiFi list, and the terminal determines that the second WiFi list is matched with the first electronic fence based on a matching threshold parameter corresponding to the first electronic fence;
and the terminal disconnects the second access point and switches to the cellular network.
13. An electronic device, the electronic device comprising: one or more processors and memory; the memory is coupled with the one or more processors, the memory for storing computer program code comprising computer instructions that the one or more processors invoke to cause the electronic device to perform the method of any of claims 1-12.
14. A chip system for application to an electronic device, the chip system comprising one or more processors to invoke computer instructions to cause the electronic device to perform the method of any of claims 1-12.
15. A computer program product comprising instructions which, when run on an electronic device, cause the electronic device to perform the method of any of claims 1-12.
16. A computer readable storage medium comprising instructions which, when run on an electronic device, cause the electronic device to perform the method of any one of claims 1-12.
CN202111529772.0A 2021-12-14 2021-12-14 Method, terminal and communication system for generating electronic fence Pending CN116264719A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111529772.0A CN116264719A (en) 2021-12-14 2021-12-14 Method, terminal and communication system for generating electronic fence

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111529772.0A CN116264719A (en) 2021-12-14 2021-12-14 Method, terminal and communication system for generating electronic fence

Publications (1)

Publication Number Publication Date
CN116264719A true CN116264719A (en) 2023-06-16

Family

ID=86722336

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111529772.0A Pending CN116264719A (en) 2021-12-14 2021-12-14 Method, terminal and communication system for generating electronic fence

Country Status (1)

Country Link
CN (1) CN116264719A (en)

Similar Documents

Publication Publication Date Title
CN115002849B (en) Network switching method and terminal
US20140241182A1 (en) Access Point And Channel Selection In A Wireless Network For Reduced RF Interference
CN115065996B (en) Method, terminal and communication system for generating electronic fence
CN106358189B (en) Method and device for accessing wireless local area network
CN111263410B (en) Resource reservation method and equipment
EP4061084A1 (en) Random access method and device, terminal, and storage medium
US11910212B2 (en) Methods and apparatuses for MDT measurement
CN111836352A (en) Power control method and terminal for physical side link feedback channel
CN110521230A (en) Mutual interference indicating means, method of reseptance and device in equipment
CN111615177A (en) Cell search method and user equipment
US20230370920A1 (en) Communication method, terminal device, and storage medium
EP4192098A1 (en) Satellite communication method, apparatus, and storage medium
CN111095982B (en) Signal measurement method, device, communication equipment and storage medium
CN111149388B (en) Communication processing method, device and computer storage medium
CN112753266A (en) Method and device for assisting selection of UE (user Equipment) and storage medium
CN116264719A (en) Method, terminal and communication system for generating electronic fence
US11191017B2 (en) Method and apparatus for camping on cell, user equipment, and base station
CN109451837B (en) Cell reselection method, device and storage medium
CN110708742A (en) Method, device, electronic equipment and medium for selecting frequency points
EP4258701A1 (en) Method, apparatus and system for determining device position
CN111278114A (en) Power control method, terminal equipment and network side equipment
CN114915359B (en) Method, apparatus, electronic device and readable storage medium for selecting channel
CN115190495A (en) Wireless signal quality evaluation method and system and electronic equipment
CN114339698A (en) Method for establishing wireless connection through equipment touch, electronic equipment and chip
EP2773152B1 (en) Access point and channel selection in a wireless network for reduced RF interference

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination