CN106793016B - Wireless fidelity Wi-Fi connection method and mobile terminal - Google Patents

Wireless fidelity Wi-Fi connection method and mobile terminal Download PDF

Info

Publication number
CN106793016B
CN106793016B CN201710090773.7A CN201710090773A CN106793016B CN 106793016 B CN106793016 B CN 106793016B CN 201710090773 A CN201710090773 A CN 201710090773A CN 106793016 B CN106793016 B CN 106793016B
Authority
CN
China
Prior art keywords
connection
access point
mobile terminal
records
connection records
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.)
Expired - Fee Related
Application number
CN201710090773.7A
Other languages
Chinese (zh)
Other versions
CN106793016A (en
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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp 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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201710090773.7A priority Critical patent/CN106793016B/en
Publication of CN106793016A publication Critical patent/CN106793016A/en
Application granted granted Critical
Publication of CN106793016B publication Critical patent/CN106793016B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W48/00Access restriction; Network selection; Access point selection
    • H04W48/16Discovering, processing access restriction or access information
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W48/00Access restriction; Network selection; Access point selection
    • H04W48/20Selecting an access point
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)
  • Telephone Function (AREA)

Abstract

The embodiment of the invention provides a wireless fidelity Wi-Fi connection method and a mobile terminal, wherein the method comprises the following steps: acquiring the current position of the mobile terminal; determining N Wi-Fi connection records from historical Wi-Fi connection data according to the current position, wherein the historical Wi-Fi connection data comprises M Wi-Fi connection records, each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point which is not successfully connected, M is a positive integer, and N is a positive integer smaller than or equal to M; and generating a Wi-Fi list according to the N Wi-Fi connection records. The embodiment of the invention can realize automatic searching of the hidden AP.

Description

Wireless fidelity Wi-Fi connection method and mobile terminal
Technical Field
The invention relates to the technical field of communication, in particular to a wireless fidelity Wi-Fi connection method and a mobile terminal.
Background
With the rapid development of information technology, mobile terminals (such as mobile phones, tablet computers, and the like) are increasingly used, and users have higher requirements on the mobile terminals, so that not only is higher processing speed required, but also the dependence on wireless fidelity (Wi-Fi) is stronger.
In the prior art, in order to improve the security of an Access Point (AP), a user may hide the AP. However, in performing Wi-Fi scanning, the following problems are encountered: taking an AP to which the mobile terminal has not been connected as an example, before the AP is not hidden, the mobile terminal may scan the AP and further display the AP on the screen of the mobile terminal when performing Wi-Fi scanning, but after the AP is hidden, the mobile terminal may not scan the AP.
Disclosure of Invention
The embodiment of the invention provides a wireless fidelity Wi-Fi connection method and a mobile terminal, which can realize automatic searching of a hidden AP.
The first aspect of the embodiments of the present invention provides a wireless fidelity Wi-Fi connection method, including:
acquiring the current position of the mobile terminal;
determining N Wi-Fi connection records from historical Wi-Fi connection data according to the current position, wherein the historical Wi-Fi connection data comprises M Wi-Fi connection records, each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point which is not successfully connected, M is a positive integer, and N is a positive integer smaller than or equal to M;
and generating a Wi-Fi list according to the N Wi-Fi connection records.
A second aspect of an embodiment of the present invention provides a mobile terminal, including:
the mobile terminal comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring the current position of the mobile terminal;
a determining unit, configured to determine N Wi-Fi connection records from historical Wi-Fi connection data according to the current location, where the historical Wi-Fi connection data includes M Wi-Fi connection records, each of the N Wi-Fi connection records includes an access point that has not been successfully connected, M is a positive integer, and N is a positive integer less than or equal to M;
and the generating unit is used for generating a Wi-Fi list according to the N Wi-Fi connection records.
A third aspect of the embodiments of the present invention provides a mobile terminal, including:
a processor and a memory; wherein the processor performs some or all of the steps of the method described in the first aspect by calling code or instructions in the memory.
The embodiment of the invention has the following beneficial effects:
it can be seen that, according to the embodiment of the invention, the current position of the mobile terminal is obtained, N Wi-Fi connection records are determined from historical Wi-Fi connection data according to the current position, the historical Wi-Fi connection data comprises M Wi-Fi connection records, each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point which is not successfully connected, M is a positive integer, N is a positive integer smaller than or equal to M, and a Wi-Fi list is generated according to the N Wi-Fi connection records. Therefore, the unsuccessfully connected access point can be searched from the historical Wi-Fi connection data, and therefore, when the unsuccessfully connected access point is changed from the non-hidden state to the hidden state, the hidden access point can be automatically searched.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a flowchart illustrating a first embodiment of a Wi-Fi connection method according to an embodiment of the present invention;
fig. 2 is a flowchart illustrating a Wi-Fi connection method according to a second embodiment of the present invention;
fig. 3a is a schematic structural diagram of a mobile terminal according to a first embodiment of the present invention;
fig. 3b is a schematic structural diagram of a determining unit of the mobile terminal depicted in fig. 3a according to an embodiment of the present invention;
fig. 3c is a schematic structural diagram of a generating unit of the mobile terminal depicted in fig. 3a according to an embodiment of the present invention;
fig. 3d is a schematic diagram of another structure of the mobile terminal depicted in fig. 3a according to an embodiment of the present invention;
fig. 4 is a schematic structural diagram of a mobile terminal according to a second embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The terms "first," "second," "third," and "fourth," etc. in the description and claims of the invention and in the accompanying drawings are used for distinguishing between different objects and not for describing a particular order. Furthermore, the terms "include" and "have," as well as any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or elements is not limited to only those steps or elements listed, but may alternatively include other steps or elements not listed, or inherent to such process, method, article, or apparatus.
Reference herein to "an embodiment" means that a particular feature, structure, or characteristic described in connection with the embodiment can be included in at least one embodiment of the invention. The appearances of the phrase in various places in the specification are not necessarily all referring to the same embodiment, nor are separate or alternative embodiments mutually exclusive of other embodiments. It is explicitly and implicitly understood by one skilled in the art that the embodiments described herein can be combined with other embodiments.
The mobile terminal described in the embodiment of the present invention may include a smart Phone (such as an Android Phone, an iOS Phone, a Windows Phone, etc.), a tablet computer, a palm computer, a notebook computer, a mobile internet device (MID, mobile internet Devices), or a wearable device, which are merely examples, but not exhaustive, and include but are not limited to the mobile terminal.
In general, when a designated Access Point (AP) is not manually added, the AP cannot be displayed, so after the mobile terminal performs Wi-Fi scanning, an unsaved hidden AP cannot be displayed in a Wi-Fi list, and thus, a user cannot select such a designated access point and cannot connect to the designated access point. Moreover, manual addition of the AP is complicated, the SSID needs to be completely matched to be displayed, and if the SSID has special characters (e.g., length, etc.) or (e.g.,/, @) symbols, it is easy to input an error, so that the user needs to input the specified access point many times.
Optionally, the historical Wi-Fi connection data in the embodiment of the present invention may include a plurality of Wi-Fi connection records, each of which may include access point information of one access point, and of course, the historical Wi-Fi connection data may also include location information (e.g., longitude and latitude, location name, location time, etc.) of the access point. The access point information of the access point may include, but is not limited to: SSID, BSSID, encryption scheme, hidden (hidden state or non-hidden state). In the embodiment of the present invention, the access point that has not successfully connected means that the mobile terminal does not perform Wi-Fi connection on the access point, or that the access point that has performed Wi-Fi connection but failed in connection on the access point. A successfully connected access point means an access point to which the mobile terminal has connected and which is successfully connected. It should be noted that when a certain access point is in a hidden state, Wi-Fi scanning needs to be performed according to the SSID or BSSID of the access point, so that the access point may be searched. In practical application, after a mobile terminal successfully connects to an AP each time, the SSID, BSSID, encryption mode, whether to hide, and other attributes of the AP, as well as location information during connection, may be recorded and stored in the mobile terminal, so that historical Wi-Fi connection data may be obtained. Of course, in each Wi-Fi scanning process, although only one access point may be accessed by the mobile terminal, a plurality of access points may be obtained by scanning, and an access point that is not accessed may also be stored in the historical Wi-Fi connection data, that is, the historical Wi-Fi connection data may include not only an access point that is not successfully connected, but also an access point that is successfully connected.
Further optionally, since a location may contain a large number of access points, after a Wi-Fi scan at the location, a plurality of Wi-Fi connection records may be obtained, each of which may contain an access point, whether the access point is a successfully connected access point or an unsuccessfully connected access point. When a user arrives at the position for multiple times, a large number of Wi-Fi connection records containing the same access point can be obtained, and therefore historical Wi-Fi connection data possibly occupy more memory resources, so that deduplication processing can be performed in the historical Wi-Fi connection data, only at least one of the Wi-Fi connection records containing the same access point is reserved, and further the historical Wi-Fi connection data is optimized.
Fig. 1 is a flowchart illustrating a Wi-Fi connection method according to a first embodiment of the present invention. The Wi-Fi connection method described in this embodiment includes the following steps:
101. and acquiring the current position of the mobile terminal.
The mobile terminal may determine the current location of the mobile terminal through a Global Positioning System (GPS), or the mobile terminal may determine the current location of the mobile terminal through a Wi-Fi Positioning technology. The current location of the mobile terminal may be expressed in terms of latitude and longitude, for example, the current location may be expressed as 113 ° 46 'east longitude and 22 ° 27' north latitude. Of course, if the Wi-Fi positioning technology is used to determine the current location of the mobile terminal, the location of an AP scanned by the current Wi-Fi is used as the location of the mobile terminal, and the location of the AP may be a point (a point representing the location of the mobile terminal) if marked on an indoor map.
102. And determining N Wi-Fi connection records from historical Wi-Fi connection data according to the current position, wherein the historical Wi-Fi connection data comprises M Wi-Fi connection records, each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point which is not successfully connected, M is a positive integer, and N is a positive integer less than or equal to M.
The historical Wi-Fi connection data may include a large number of Wi-Fi connection records, and each Wi-Fi connection record only includes one access point, because the mobile terminal can only access one access point at a time in a normal case. The historical Wi-Fi connection data may be stored in a memory (e.g., a RAM memory or a ROM memory) such that after one access point is accessed, another access point may not be accessed, and thus, although one access point is accessed at a certain location, there may be access points that have not been successfully connected at the certain location, and therefore, N Wi-Fi connection records may be determined from the historical Wi-Fi connection data according to the current location, where each Wi-Fi connection record includes one access point that has not been successfully connected.
Optionally, in the step 102, determining N Wi-Fi connection records from the historical Wi-Fi connection data according to the current location may include the following steps:
B1) determining Q Wi-Fi connection records from the historical Wi-Fi connection data, wherein each Wi-Fi connection record in the Q Wi-Fi connection records comprises an access point which is not successfully connected, and Q is a positive integer;
B2) acquiring the Q positions from the Q Wi-Fi connection records;
B3) determining the distance between the current position and the Q positions to obtain Q distance values;
B4) and selecting N distance values smaller than a preset threshold value in the Q distance values, and acquiring the N Wi-Fi connection records corresponding to the N distance values.
The historical Wi-Fi connection data can comprise M Wi-Fi connection records, and the M Wi-Fi connection records can comprise Wi-Fi connection records of access points which are successfully connected or Wi-Fi connection records of access points which are not successfully connected. Thus, Q Wi-Fi connection records can be determined from the M Wi-Fi connection records, wherein each Wi-Fi connection record in the Q Wi-Fi connection records comprises an access point which is not successfully connected. Since one location may be included in each Wi-Fi connection record, Q locations may be obtained, and thus, the distance between the current location and each of the Q locations may be determined, and thus, Q distance values may be obtained. The preset threshold value can be set by the user or the default of the system. N distance values smaller than a preset threshold may be selected from the Q distance values. Of course, the N distance values correspond to N Wi-Fi connection records, so that the N Wi-Fi connection records can be obtained.
In step B2, the Q positions and the current position are mapped on the indoor map, and then the distance between each of the Q positions and the current position is calculated, so that Q distance values are obtained.
103. And generating a Wi-Fi list according to the N Wi-Fi connection records.
Optionally, there may be Wi-Fi connection records including the same access point in the N Wi-Fi connection records, for example, if the Wi-Fi connection record a includes SSID1 and the Wi-Fi connection record B includes SSID1, the two may be regarded as Wi-Fi connection records of the same access point. In practical applications, it cannot be excluded that the mobile terminal accesses the same access point for multiple times, for example, when the user is at home, the user connects to the router at home for multiple times, and then multiple identical Wi-Fi connection records can be obtained.
Optionally, in step 103, generating a Wi-Fi list according to the N Wi-Fi connection records may include the following steps:
31) extracting access point information of P access points from the N Wi-Fi records, wherein P is an integer less than or equal to N;
32) and generating a Wi-Fi list according to the access point information of the P access points, and displaying the Wi-Fi list on a screen of the mobile terminal.
Each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point, but different Wi-Fi connection records may comprise the same access point, and the N Wi-Fi connections correspond to the N access points, so that P different access points are necessarily selected from the N Wi-Fi connection records, specifically, the N access points can be deduplicated to obtain P access points, a Wi-Fi list can be generated according to the P access points, and the Wi-Fi list can be displayed on a screen of the mobile terminal. Each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point, but different Wi-Fi connection records may comprise the same access point, and the N Wi-Fi connections correspond to the N access points, so that P different access points are necessarily selected from the N Wi-Fi connection records, specifically, the N access points can be deduplicated to obtain P access points, a Wi-Fi list can be generated according to the P access points, and the Wi-Fi list can be displayed on a screen of the mobile terminal. The above-mentioned deduplication for N access points can be implemented in two ways: 1. the duplication can be removed according to the SSID, and the SSID of each access point in the P access points is different; 2. the de-duplication can be performed according to the BSSID, and the obtained BSSID of each of the P access points is different.
Optionally, in step 31, the extracting of the access point information of P access points from the N Wi-Fi records may be implemented as follows:
and selecting access point information of P access points with static passwords from the N Wi-Fi records.
When the password of a certain access point is a static password, the user can conveniently access the access point only by knowing the password of the access point. Thus, only hidden APs with passwords that are static may be displayed in the Wi-Fi list.
The embodiments of the present invention described above can be applied to a scenario, for example, in practical applications, a hidden AP may exist in the current environment (in general, the hidden AP is set to prevent other users from accessing the AP). A hidden AP in the current environment may be a non-hidden AP before and set as a hidden AP later. Taking the example of hiding the AP1, before the AP1 is not hidden, the mobile terminal may scan the AP1, after the AP1 is hidden, the mobile terminal may not scan the AP1, but before the AP1 is not hidden, if the mobile terminal scans the AP1, the access point information of the AP1 may be saved as a Wi-Fi connection record in the historical Wi-Fi connection data. After the AP1 is hidden, if the user is present in the current environment, a Wi-Fi list may be generated according to the AP1 according to the above-described embodiment of the present invention, so that the AP1 may be displayed on the display screen of the mobile terminal, and then the user may select the AP1 and further access the AP 1. Certainly, in practical application, more hidden access points can appear, and the hidden access points can be displayed on the screen of the mobile terminal according to the mode described in the embodiment of the invention so that the user can select the hidden access points, thus not only improving the security of the access points, but also preventing other users from stealing broadband resources.
It can be seen that, according to the embodiment of the invention, the current position of the mobile terminal is obtained, N Wi-Fi connection records are determined from historical Wi-Fi connection data according to the current position, the historical Wi-Fi connection data comprises M Wi-Fi connection records, each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point which is not successfully connected, M is a positive integer, N is a positive integer smaller than or equal to M, and a Wi-Fi list is generated according to the N Wi-Fi connection records. Therefore, access points which are not successfully connected can be searched from historical Wi-Fi connection data, so that not only can the hidden AP be automatically searched, but also more access points can be provided for a user to select, and the Wi-Fi connection efficiency can be improved.
In accordance with the above, please refer to fig. 2, which is a flowchart illustrating a Wi-Fi connection method according to a second embodiment of the present invention. The Wi-Fi connection method described in this embodiment includes the following steps:
201. and acquiring the current position of the mobile terminal.
202. And determining N Wi-Fi connection records from historical Wi-Fi connection data according to the current position, wherein the historical Wi-Fi connection data comprises M Wi-Fi connection records, each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point which is not successfully connected, M is a positive integer, and N is a positive integer less than or equal to M.
Optionally, the detailed description of the steps 201 to 202 may refer to the corresponding steps 101 to 102 of the wifi connection method described in fig. 1, and are not repeated herein.
203. And extracting access point information of P access points from the N Wi-Fi records, wherein P is an integer less than or equal to N.
Each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point, but different Wi-Fi connection records may comprise the same access point, and the N Wi-Fi connections correspond to the N access points, so that P different access points are necessarily selected from the N Wi-Fi connection records, specifically, the N access points can be deduplicated to obtain P access points, a Wi-Fi list can be generated according to the P access points, and the Wi-Fi list can be displayed on a screen of the mobile terminal.
204. And generating a Wi-Fi list according to the access point information of the P access points, and displaying the Wi-Fi list on a screen of the mobile terminal.
205. At least one access point is selected from the Wi-Fi list.
Optionally, in step 205, a Wi-Fi list may be displayed on the screen of the mobile terminal, and at least one access point with the best signal strength in the Wi-Fi list may be selected, or at least one access point closest to the current location in the Wi-Fi list may be selected.
206. And Wi-Fi scanning is carried out according to the SSID or BSSID of each access point in the at least one access point.
In step 206, the mobile terminal may perform Wi-Fi scanning according to the SSID of the at least one access point, or the mobile terminal may perform Wi-Fi scanning according to the BSSID of the at least one access point, or the mobile terminal may perform Wi-Fi scanning according to the SSID and the BSSID of the at least one access point. Of course, when the SSID is used for Wi-Fi scanning, there may be a case where the SSID is changed, for example, the SSID of a certain original access point is "cathay 000", and the SSID is changed to "cathay 007" later, and if Wi-Fi scanning is performed according to the SSID "cathay 000", the access point cannot be scanned. Of course, this would not be the case if Wi-Fi scanning were performed based on the BSSID, which is not modifiable. Of course, Wi-Fi scanning can also be performed based on SSID and BSSID.
Optionally, in step 205, a selection instruction input by the user may be received, and the access point indicated by the selection instruction may be selected from the Wi-Fi list, and in step 206, Wi-Fi scanning may be performed according to the SSID or BSSID of the access point.
It can be seen that, through the embodiment of the invention, the current position of the mobile terminal is obtained, N Wi-Fi connection records are determined from historical Wi-Fi connection data according to the current position, the historical Wi-Fi connection data comprises M Wi-Fi connection records, each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point which is not successfully connected, M is a positive integer, N is a positive integer less than or equal to M, access point information of P access points is extracted from the N Wi-Fi records, P is an integer less than or equal to N, generating a Wi-Fi list according to the access point information of the P access points, displaying the Wi-Fi list on a screen of the mobile terminal, selecting at least one access point from the Wi-Fi list, Wi-Fi scanning is performed according to the SSID or BSSID of each of the at least one access point. Therefore, access points which are not successfully connected can be searched from historical Wi-Fi connection data, so that not only can the hidden AP be automatically searched, but also more access points can be provided for a user to select, and the Wi-Fi connection efficiency can be improved.
In accordance with the foregoing, an apparatus for implementing the Wi-Fi connectivity method described above is as follows:
please refer to fig. 3a, which is a schematic structural diagram of a mobile terminal according to a first embodiment of the present invention. The mobile terminal described in this embodiment includes: the acquiring unit 301, the determining unit 302 and the generating unit 303 are specifically as follows:
an obtaining unit 301, configured to obtain a current location of the mobile terminal;
a determining unit 302, configured to determine N Wi-Fi connection records from historical Wi-Fi connection data according to the current location, where the historical Wi-Fi connection data includes M Wi-Fi connection records, each of the N Wi-Fi connection records includes an access point that has not been successfully connected, M is a positive integer, and N is a positive integer smaller than or equal to M;
a generating unit 303, configured to generate a Wi-Fi list according to the N Wi-Fi connection records.
Optionally, as shown in fig. 3b, fig. 3b is a detailed structure of the determining unit 302 of the mobile terminal depicted in fig. 3a, and the determining unit 302 may include: the first determining module 3021, the obtaining module 3022, the second determining module 3023, and the selecting module 3024 are specifically as follows:
a first determining module 3021, configured to determine Q Wi-Fi connection records from the historical Wi-Fi connection data, where each Wi-Fi connection record in the Q Wi-Fi connection records includes an access point that has not been successfully connected, and Q is a positive integer;
an obtaining module 3022, configured to obtain the Q positions from the Q Wi-Fi connection records;
a second determining module 3023, configured to determine distances between the current position and the Q positions, to obtain Q distance values;
a selecting module 3024, configured to select N distance values smaller than a preset threshold among the Q distance values, and obtain the N Wi-Fi connection records corresponding to the N distance values.
Optionally, as shown in fig. 3c, fig. 3c is a detailed structure of the generating unit 303 of the mobile terminal depicted in fig. 3a, where the generating unit 303 includes: the extraction module 3031 and the generation module 3032 are specifically as follows:
an extracting module 3031, configured to extract access point information of P access points from the N Wi-Fi records, where P is an integer smaller than or equal to N;
a generating module 3032, configured to generate a Wi-Fi list according to the access point information of the P access points, and display the Wi-Fi list on a screen of the mobile terminal.
Alternatively, as shown in fig. 3d, fig. 3d is a modified structure of the mobile terminal depicted in fig. 3a, and fig. 3d may further include, compared with fig. 3 a: the selecting unit 304 and the scanning unit 305 are as follows:
a selecting unit 304, configured to select at least one access point from the Wi-Fi list after the generating module displays the Wi-Fi list on the screen of the mobile terminal;
a scanning unit 305, configured to perform Wi-Fi scanning according to the access point information of the at least one access point.
Further, the scanning unit 305 is specifically configured to:
and Wi-Fi scanning is carried out according to the SSID or BSSID of each access point in the at least one access point.
It can be seen that, according to the embodiment of the invention, the current position of the mobile terminal is obtained, N Wi-Fi connection records are determined from historical Wi-Fi connection data according to the current position, the historical Wi-Fi connection data comprises M Wi-Fi connection records, each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point which is not successfully connected, N is a positive integer less than or equal to M, and a Wi-Fi list is generated according to the N Wi-Fi connection records. Therefore, access points which are not connected can be searched from historical Wi-Fi connection data, so that not only can the hidden AP be automatically searched, but also more access points can be provided for a user to select, and the Wi-Fi connection efficiency can be improved.
In accordance with the above, please refer to fig. 4, which is a schematic structural diagram of a mobile terminal according to a second embodiment of the present invention. The mobile terminal described in this embodiment includes: at least one input device 1000; at least one output device 2000; at least one processor 3000, e.g., a CPU; and a memory 4000, the input device 1000, the output device 2000, the processor 3000, and the memory 4000 being connected by a bus 5000.
The input device 1000 may be a touch panel, a physical button, or a mouse.
The output device 2000 may be a display screen.
The memory 4000 may be a high-speed RAM memory or a non-volatile memory (e.g., a magnetic disk memory). The memory 4000 is used for storing a set of program codes, and the input device 1000, the output device 2000 and the processor 3000 are used for calling the program codes stored in the memory 4000 to execute the following operations:
the processor 3000 is configured to:
acquiring the current position of the mobile terminal;
determining N Wi-Fi connection records from historical Wi-Fi connection data according to the current position, wherein the historical Wi-Fi connection data comprises M Wi-Fi connection records, each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point which is not successfully connected, M is a positive integer, and N is a positive integer smaller than or equal to M;
and generating a Wi-Fi list according to the N Wi-Fi connection records.
Optionally, the determining, by the processor 3000, N Wi-Fi connection records from historical Wi-Fi connection data according to the current location includes:
determining Q Wi-Fi connection records from the historical Wi-Fi connection data, wherein each Wi-Fi connection record in the Q Wi-Fi connection records comprises an access point which is not successfully connected, and Q is a positive integer;
obtaining the Q positions from the Q Wi-Fi connection records;
determining the distance between the current position and the Q positions to obtain Q distance values;
and selecting N distance values smaller than a preset threshold value in the Q distance values, and acquiring the N Wi-Fi connection records corresponding to the N distance values.
Optionally, the processor 3000 generates a Wi-Fi list according to the N Wi-Fi connection records, including:
extracting access point information of P access points from the N Wi-Fi records, wherein P is an integer less than or equal to N;
and generating a Wi-Fi list according to the access point information of the P access points, and displaying the Wi-Fi list on a screen of the mobile terminal.
Further optionally, after the processor 3000 displays the Wi-Fi list on the screen of the mobile terminal, the method further includes:
selecting at least one access point from the Wi-Fi list;
and carrying out Wi-Fi scanning according to the access point information of the at least one access point.
Optionally, the Wi-Fi scanning may be performed according to the access point information of the at least one access point, including:
and Wi-Fi scanning is carried out according to the SSID or BSSID of each access point in the at least one access point.
An embodiment of the present invention further provides a computer storage medium, where the computer storage medium may store a program, and the program includes some or all of the steps of any one of the wireless fidelity Wi-Fi connection methods described in the above method embodiments when executed.
While the invention has been described in connection with various embodiments, other variations to the disclosed embodiments can be understood and effected by those skilled in the art in practicing the claimed invention, from a review of the drawings, the disclosure, and the appended claims. In the claims, the word "comprising" does not exclude other elements or steps, and the word "a" or "an" does not exclude a plurality. A single processor or other unit may fulfill the functions of several items recited in the claims. The mere fact that certain measures are recited in mutually different dependent claims does not indicate that a combination of these measures cannot be used to advantage.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, apparatus (device), or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein. A computer program stored/distributed on a suitable medium supplied together with or as part of other hardware, may also take other distributed forms, such as via the Internet or other wired or wireless telecommunication systems.
The present invention has been described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (devices) and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While the invention has been described in conjunction with specific features and embodiments thereof, it will be evident that various modifications and combinations can be made thereto without departing from the spirit and scope of the invention. Accordingly, the specification and figures are merely exemplary of the invention as defined in the appended claims and are intended to cover any and all modifications, variations, combinations, or equivalents within the scope of the invention. It will be apparent to those skilled in the art that various changes and modifications may be made in the present invention without departing from the spirit and scope of the invention. Thus, if such modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include such modifications and variations.

Claims (9)

1. A wireless fidelity (Wi-Fi) connection method, comprising:
acquiring the current position of the mobile terminal;
determining N Wi-Fi connection records from historical Wi-Fi connection data according to the current position, wherein the historical Wi-Fi connection data comprises M Wi-Fi connection records, each Wi-Fi connection record in the N Wi-Fi connection records comprises an access point which is not successfully connected, M is a positive integer, and N is a positive integer smaller than or equal to M;
generating a Wi-Fi list according to the N Wi-Fi connection records;
wherein the generating a Wi-Fi list according to the N Wi-Fi connection records comprises:
extracting access point information of P access points from the N Wi-Fi records, wherein P is an integer less than or equal to N;
and generating a Wi-Fi list according to the access point information of the P access points, and displaying the Wi-Fi list on a screen of the mobile terminal, wherein the information of the access points comprises SSID (service set identifier), BSSID (base station service set identifier) and/or hidden state information.
2. The method of claim 1, wherein determining N Wi-Fi connection records from historical Wi-Fi connection data based on the current location comprises:
determining Q Wi-Fi connection records from the historical Wi-Fi connection data, wherein each Wi-Fi connection record in the Q Wi-Fi connection records comprises an access point which is not successfully connected, and Q is a positive integer;
obtaining the Q positions from the Q Wi-Fi connection records;
determining the distance between the current position and the Q positions to obtain Q distance values;
and selecting N distance values smaller than a preset threshold value in the Q distance values, and acquiring the N Wi-Fi connection records corresponding to the N distance values.
3. The method according to claim 1, wherein after the screen of the mobile terminal presents the Wi-Fi list, the method further comprises:
selecting at least one access point from the Wi-Fi list;
and carrying out Wi-Fi scanning according to the access point information of the at least one access point.
4. The method of claim 3, wherein the Wi-Fi scanning based on the access point information for the at least one access point comprises:
and Wi-Fi scanning is carried out according to the SSID or BSSID of each access point in the at least one access point.
5. A mobile terminal, comprising:
the mobile terminal comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring the current position of the mobile terminal;
a determining unit, configured to determine N Wi-Fi connection records from historical Wi-Fi connection data according to the current location, where the historical Wi-Fi connection data includes M Wi-Fi connection records, each of the N Wi-Fi connection records includes an access point that has not been successfully connected, M is a positive integer, and N is a positive integer less than or equal to M;
the generating unit is used for generating a Wi-Fi list according to the N Wi-Fi connection records;
wherein the generating unit includes:
an extraction module, configured to extract access point information of P access points from the N Wi-Fi records, where P is an integer less than or equal to N;
and the generating module is used for generating a Wi-Fi list according to the access point information of the P access points and displaying the Wi-Fi list on a screen of the mobile terminal, wherein the information of the access points comprises SSID (service set identifier), BSSID (base station service set identifier) and/or hidden state information.
6. The mobile terminal according to claim 5, wherein the determining unit comprises:
a first determining module, configured to determine Q Wi-Fi connection records from the historical Wi-Fi connection data, where each Wi-Fi connection record in the Q Wi-Fi connection records includes an access point that has not been successfully connected, and Q is a positive integer;
the acquisition module is used for acquiring the Q positions from the Q Wi-Fi connection records;
a second determining module, configured to determine distances between the current position and the Q positions to obtain Q distance values;
and the selecting module is used for selecting N distance values smaller than a preset threshold value in the Q distance values and acquiring the N Wi-Fi connection records corresponding to the N distance values.
7. The mobile terminal of claim 5, wherein the mobile terminal further comprises:
the selecting unit is used for selecting at least one access point from the Wi-Fi list after the Wi-Fi list is displayed on the screen of the mobile terminal by the generating module;
and the scanning unit is used for carrying out Wi-Fi scanning according to the access point information of the at least one access point.
8. The mobile terminal of claim 7, wherein the scanning unit is specifically configured to:
and Wi-Fi scanning is carried out according to the SSID or BSSID of each access point in the at least one access point.
9. A mobile terminal, comprising:
a processor and a memory; wherein the processor performs the method of any one of claims 1 to 4 by calling code or instructions in the memory.
CN201710090773.7A 2017-02-20 2017-02-20 Wireless fidelity Wi-Fi connection method and mobile terminal Expired - Fee Related CN106793016B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710090773.7A CN106793016B (en) 2017-02-20 2017-02-20 Wireless fidelity Wi-Fi connection method and mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710090773.7A CN106793016B (en) 2017-02-20 2017-02-20 Wireless fidelity Wi-Fi connection method and mobile terminal

Publications (2)

Publication Number Publication Date
CN106793016A CN106793016A (en) 2017-05-31
CN106793016B true CN106793016B (en) 2020-01-14

Family

ID=58957803

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710090773.7A Expired - Fee Related CN106793016B (en) 2017-02-20 2017-02-20 Wireless fidelity Wi-Fi connection method and mobile terminal

Country Status (1)

Country Link
CN (1) CN106793016B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11197236B2 (en) 2017-07-04 2021-12-07 Huawei Technologies Co., Ltd. Hotspot scanning method and electronic device
US11419044B2 (en) * 2019-08-05 2022-08-16 Veniam, Inc. Adaptive and dynamic Wi-Fi® scanning policies in a network of moving things including, for example, autonomous vehicles

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP5185081B2 (en) * 2008-11-17 2013-04-17 株式会社東芝 Wireless terminal device, communication method, and communication program
WO2014006949A1 (en) * 2012-07-04 2014-01-09 ソフトバンクモバイル株式会社 Terminal and connection method for same
CN103475996B (en) * 2013-08-19 2017-06-16 小米科技有限责任公司 Method for connecting network, network share method and device
CN103874018B (en) * 2014-02-21 2018-03-20 小米科技有限责任公司 Access-in point information sharing method and device
CN104837215A (en) * 2015-04-14 2015-08-12 广东欧珀移动通信有限公司 Wireless access point connecting method and device
CN105530643A (en) * 2015-12-31 2016-04-27 集怡嘉数码科技(深圳)有限公司 WIFI network access method, WIFI network access device and terminal

Also Published As

Publication number Publication date
CN106793016A (en) 2017-05-31

Similar Documents

Publication Publication Date Title
US10299197B2 (en) Wireless fidelity connection method, mobile terminal and storage medium
US10873900B2 (en) Method for wireless fidelity connection and related products
EP3277027B1 (en) Wi-fi connection method, mobile terminal and storage medium
US10469488B2 (en) Security verification method, apparatus, and system
CN106686587B (en) Wireless fidelity Wi-Fi connection method, mobile terminal and medium
CN104660549A (en) Identity verification method and device
US11070529B2 (en) Method for wireless fidelity connection and related products
WO2018103402A1 (en) Wireless fidelity (wifi) scan method and related product
CN105574948A (en) Checking-in method and equipment
CN106793016B (en) Wireless fidelity Wi-Fi connection method and mobile terminal
US11044766B2 (en) Method for Wi-Fi connection and related products
US11323873B2 (en) Method for wireless fidelity connection and related products
WO2018103403A1 (en) Wireless fidelity (wi-fi) scanning method and related product
CN113383314A (en) User similarity calculation method and device, server and storage medium

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
CB02 Change of applicant information

Address after: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Applicant after: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

Address before: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Applicant before: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

CB02 Change of applicant information
GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20200114

CF01 Termination of patent right due to non-payment of annual fee