CN106792698A - A kind of Wireless Fidelity Wi Fi connection methods and mobile terminal - Google Patents

A kind of Wireless Fidelity Wi Fi connection methods and mobile terminal Download PDF

Info

Publication number
CN106792698A
CN106792698A CN201710091096.0A CN201710091096A CN106792698A CN 106792698 A CN106792698 A CN 106792698A CN 201710091096 A CN201710091096 A CN 201710091096A CN 106792698 A CN106792698 A CN 106792698A
Authority
CN
China
Prior art keywords
access point
mobile terminal
bssid
password
hash table
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
CN201710091096.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.)
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 CN201710091096.0A priority Critical patent/CN106792698A/en
Publication of CN106792698A publication Critical patent/CN106792698A/en
Pending legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/06Authentication
    • 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/24Reselection being triggered by specific parameters
    • H04W36/32Reselection being triggered by specific parameters by location or mobility data, e.g. speed data

Landscapes

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

Abstract

A kind of Wireless Fidelity Wi Fi connection methods and mobile terminal are the embodiment of the invention provides, methods described includes:When mobile terminal reaches roaming conditions with a distance from the first access point, the target BSSID of the second access point is obtained, wherein, the SSID and cipher mode all same of first access point and second access point;With the presence or absence of the corresponding first passwords of the target BSSID in the Hash table that detection is prestored, recorded comprising K bars in the Hash table, a BSSID and the corresponding passwords of the BSSID are included in each record, the K is positive integer;When there is the corresponding first passwords of the target BSSID in the Hash table, second access point is accessed according to the first password.In the case of can realizing that there is multiple in the environment has the access point that SSID is identical with cipher mode but password is different by the embodiment of the present invention, fast access into network.

Description

A kind of Wireless Fidelity Wi-Fi connection method and mobile terminal
Technical field
The present invention relates to communication technical field, and in particular to a kind of Wireless Fidelity Wi-Fi connection method and mobile terminal.
Background technology
With the fast development of information technology, mobile terminal (such as mobile phone, panel computer) is used using increasingly popularizing Requirement of the family to mobile terminal also more and more higher, not only needs processing speed higher, and to Wireless Fidelity (Wireless Fidelity, Wi-Fi) dependence it is also more and more stronger.With the popularization of mobile terminal and Wi-Fi, connect by mobile terminal Enter Wi-Fi network also more and more frequent.
In the prior art, it may appear that following situation, for example, when mobile terminal roaming is to certain region, its surrounding environment May there is multiple identicals service set (Service Set Identifier, SSID), cipher mode, different passwords Access point, for example, after Wi-Fi scannings are carried out, if identical in the presence of two SSID, but the identical password of cipher mode is different Access point, mobile terminal can only be identified as an access point, such as:One of password is input to be attached, it is understood that there may be because Password mismatches the problem that cannot be connected, and how to solve having identical SSID and cipher mode in the presence of multiple in the environment, but close In the case of the different access point of code, realize that the problems demand of fast access into network is solved.
The content of the invention
A kind of Wireless Fidelity Wi-Fi connection method and mobile terminal are the embodiment of the invention provides, to realize in environment In the case that middle presence multiple has identical SSID and cipher mode, but the different access point of password, fast access into network.
Embodiment of the present invention first aspect provides a kind of Wireless Fidelity Wi-Fi connection method, including:
When mobile terminal reaches roaming conditions with a distance from the first access point, the target BSSID of the second access point is obtained, Wherein, the SSID and cipher mode all same of first access point and second access point;
With the presence or absence of the corresponding first passwords of the target BSSID in the Hash table that detection is prestored, the Hash table In comprising K bars record, each record in include a BSSID and the corresponding passwords of the BSSID, the K be positive integer;
When there is the corresponding first passwords of the target BSSID in the Hash table, institute is accessed according to the first password State the second access point.
Embodiment of the present invention second aspect provides a kind of mobile terminal, including:
Acquiring unit, accesses for when mobile terminal reaches roaming conditions with a distance from the first access point, obtaining second The target BSSID of point, wherein, the SSID and cipher mode all same of first access point and second access point;
First detection unit, for detecting in the Hash table that prestores with the presence or absence of the target BSSID corresponding the One password, is recorded in the Hash table comprising K bars, and a BSSID and the corresponding passwords of the BSSID are included in each record, The K is positive integer;
Access unit, for existing in the Hash table during the corresponding first passwords of the target BSSID, according to this One password accesses second access point.
The embodiment of the present invention third aspect provides a kind of mobile terminal, including:
Processor and memory;Wherein, the processor is by calling code in the memory or instruction to perform The some or all of step of the method described by first aspect.
Implement the embodiment of the present invention, have the advantages that:
By the embodiment of the present invention, when mobile terminal reaches roaming conditions with a distance from the first access point, second is obtained The target BSSID of access point, wherein, the SSID and cipher mode all same of the first access point and the second access point, detection are advance Whether there is the corresponding passwords of target BSSID in the Hash table of storage, recorded comprising K bars in the Hash table, in each record Comprising a BSSID and the corresponding first passwords of the BSSID, K is positive integer, there is target BSSID in Hash table corresponding During first password, the second access point is accessed according to the first password.So as to, can exist in the environment it is multiple have identical SSID and In the case of cipher mode, but the different access point of password, fast access into network is realized.
Brief description of the drawings
Technical scheme in order to illustrate more clearly the embodiments of the present invention, below will be to that will make needed for embodiment description Accompanying drawing is briefly described, it should be apparent that, drawings in the following description are some embodiments of the present invention, for ability For the those of ordinary skill of domain, on the premise of not paying creative work, can also obtain other attached according to these accompanying drawings Figure.
Fig. 1 is that a kind of first embodiment flow of Wireless Fidelity Wi-Fi connection method provided in an embodiment of the present invention is illustrated Figure;
Fig. 2 is that a kind of second embodiment flow of Wireless Fidelity Wi-Fi connection method provided in an embodiment of the present invention is illustrated Figure;
Fig. 3 is that a kind of 3rd embodiment flow of Wireless Fidelity Wi-Fi connection method provided in an embodiment of the present invention is illustrated Figure;
Fig. 4 is that a kind of fourth embodiment flow of Wireless Fidelity Wi-Fi connection method provided in an embodiment of the present invention is illustrated Figure;
Fig. 5 a are a kind of first embodiment structural representations of mobile terminal provided in an embodiment of the present invention;
Fig. 5 b are the another structural representations of the mobile terminal described by Fig. 5 a provided in an embodiment of the present invention;
Fig. 5 c are the structural representations of the second detection unit of the mobile terminal described by Fig. 5 b provided in an embodiment of the present invention Figure;
Fig. 5 d are the another structural representations of the mobile terminal described by Fig. 5 a provided in an embodiment of the present invention;
Fig. 5 e are the another structural representations of the mobile terminal described by Fig. 5 a provided in an embodiment of the present invention;
Fig. 6 is a kind of second embodiment structural representation of mobile terminal provided in an embodiment of the present invention.
Specific embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete Site preparation is described, it is clear that described embodiment is a part of embodiment of the invention, rather than whole embodiments.Based on this hair Embodiment in bright, the every other implementation that those of ordinary skill in the art are obtained under the premise of creative work is not made Example, belongs to the scope of protection of the invention.
Term " first ", " second ", " the 3rd " in description and claims of this specification and the accompanying drawing and " Four " it is etc. for distinguishing different objects, rather than for describing particular order.Additionally, term " comprising " and " having " and it Any deformation, it is intended that covering non-exclusive is included.For example contain the process of series of steps or unit, method, be System, product or equipment are not limited to the step of having listed or unit, but alternatively also include the step of not listing or list Unit, or alternatively also include for these processes, method, product or other intrinsic steps of equipment or unit.
Referenced herein " embodiment " is it is meant that the special characteristic, structure or the characteristic that describe can be wrapped in conjunction with the embodiments Containing at least one embodiment of the present invention.It is identical that each position in the description shows that the phrase might not each mean Embodiment, nor the independent or alternative embodiment with other embodiments mutual exclusion.Those skilled in the art explicitly and Implicitly understand, embodiment described herein can be combined with other embodiments.
Mobile terminal described by the embodiment of the present invention can include smart mobile phone (such as Android phone, iOS mobile phones, Windows Phone mobile phones etc.), panel computer, palm PC, notebook computer, mobile internet device (MID, Mobile Internet Devices) or Wearable etc., above-mentioned is only citing, and non exhaustive, including but not limited to above-mentioned mobile whole End.
It should be noted that having in the presence of two or more during surrounding environment is primarily adapted for use in the embodiment of the present invention There are identical SSID and cipher mode, but the different access point of password.After Wi-Fi scannings are carried out, if having in the presence of two Identical SSID and cipher mode, but the different access point of password, mobile terminal can be identified as an access point, such as input wherein Individual password connection, may there is a problem of being connected because password is mismatched.For example, access point A and access point B, wherein, connect The SSID of access point A is:Cathay000, cipher mode is:WAP_PSK, password:12345678, the SSID of access point B are: Cathay000, cipher mode is:WAP_PSK, password is:88888888.If mobile terminal only uses SSID removal search access points A and access point B, then can only search in access point A or access point B, if mobile terminal to search is to access point A, May go to connect access point A according to the password of access point B, thus, cause connection access point A to fail, similarly, if mobile terminal Access point B is searched, then may go to connect access point B according to the password of access point A, thus, cause connection access point B to lose Lose.
It should be noted that the Hash table in the embodiment of the present invention includes a plurality of record, one is included in each record BSSID and password corresponding with the BSSID.For example, after mobile terminal connects the AP that succeeded, can record the AP's SSID, cipher mode, BSSID and password, and BSSID, password are stored in Hash table (HASH) as key-value pair, Hash table In can include a plurality of record, each record form can be as follows:By taking AP1 as an example, its BSSID:BSSID1, its password:Password 1, It is (BSSID1, password 1) that can record.Present invention below embodiment only with mobile terminal local environment exist two SSID and add The situation of close mode identical access point is illustrated, in practical application, in mobile terminal local environment may comprising two with Upper SSID and cipher mode identical access point, its realization principle are similar with the embodiment of the present invention.
Fig. 1 is referred to, is a kind of first embodiment stream of Wireless Fidelity Wi-Fi connection method provided in an embodiment of the present invention Journey schematic diagram.Wireless Fidelity Wi-Fi connection method described in the present embodiment, comprises the following steps:
101st, when mobile terminal reaches roaming conditions with a distance from the first access point, the target of the second access point is obtained BSSID, wherein, the SSID and cipher mode all same of first access point and second access point.
Wherein, the SSID of above-mentioned first access point and the second access point is identical with cipher mode, but, the first access point and The password of the second access point is differed.The coverage of above-mentioned first access point has certain with the coverage of the second access point Intersection region, certainly, the coverage of the first access point can not also have intersection region with the coverage of the second access point.Move Dynamic terminal after the first access point is connected to, if it leaves first access point and reaches certain distance, what it was detected The signal intensity of the first access point can be more and more weaker, it is thus possible to roaming conditions are triggered, so that accessing other access points. The mobile terminal roaming can then obtain the target BSSID of second access point in the coverage of the second access point.It is above-mentioned to obtain The target BSSID for taking the second access point can carry out Wi-Fi scannings by mobile terminal, so that, obtain the BSSID of the second access point. Certainly, the target BSSID of the second access point can be prestored in mobile terminal, so that, target BSSID can be directly read.
102nd, with the presence or absence of the corresponding first passwords of the target BSSID, the Kazakhstan in the Hash table that detection is prestored Comprising K bars record in uncommon table, a BSSID and the corresponding passwords of the BSSID are included in each record, the K is positive integer.
Wherein, from the foregoing, a plurality of record that is stored with the Hash table for prestoring, it is assumed that K bars are recorded, wherein, K is Positive integer, each record includes a BSSID and password corresponding with the BSSID.Thus, obtaining the second access point After target BSSID, then can be searched in Hash table according to target BSSID, if in the presence of target BSSID, can Find corresponding password.If not existing password corresponding with target BSSID in Hash table, user input can be pointed out to be somebody's turn to do The corresponding passwords of target BSSID, and according to the access point of password login second.
When the 103rd, there is the corresponding first passwords of the target BSSID in the Hash table, connect according to the first password Enter second access point.
Wherein, when there is first password corresponding with target BSSID in Hash table, then can be accessed according to the first password Second access point, specifically, can carry out Wi-Fi scannings according to target BSSID, after scanning to the second access point, then may be used Second access point is accessed according to the password.
For example, mobile terminal is in Wi-Fi scanning processes are carried out, then it is possible that two have identical SSID and encryption The access point of mode but different passwords, for example:AP1 and AP2.In implementing, if connect certain AP manually, can record should The SSID of AP, cipher mode, BSSID, password, and its BSSID, password are stored in Hash table as key-value pair, such as connect AP1, then be recorded as (BSSID1, password 1), when mobile terminal disconnects AP1, when re-starting Wi-Fi connection, and can be according to choosing BSSID password is selected from Hash table, such as choose password, then be attached according to the password, such as do not choose password, Then prompting user re-enters new password and is attached.Connection AP2, then can re-enter the connection of AP2 passwords, successful connection Afterwards, the BSSID of AP2 and password can be stored in Hash table, such as (BSSID2, password 2), again from after AP2 disconnections, be reconnected When, then password connection AP1, AP2 may be selected, if for example, AP1 and AP2 have intersection region, in the region, if connection AP1 is not Success, then can connect AP2.
Again for example, having two in the surrounding environment of mobile terminal has identical SSID and cipher mode but different passwords Access point, for example:AP1 and AP2.In implementing, if connect certain AP manually, SSID, the encryption side of the AP are can record Formula, BSSID, password, and its BSSID, password are stored in Hash table as key-value pair, such as connection AP1 is then recorded as (BSSID1, password 1), in mobile terminal away from AP1 and when reaching roaming conditions, may be selected AP2, first the basis from Hash table The BSSID2 of AP2 reads corresponding password 2, and more new password carries out roaming switch if existing, as pointed out user defeated in the absence of if Enter new password, then after re-entering password connection, the BSSID of AP2 and password are stored in Hash table, such as (BSSID2, password 2) When roaming AP1 from AP2 again, the BSSID1 according to AP1 reads password and carries out roaming switch, you can reaches intelligent selection password and enters Row roaming.
As can be seen that by the embodiment of the present invention, when mobile terminal reaches roaming conditions with a distance from the first access point, The target BSSID of the second access point is obtained, wherein, the SSID and cipher mode all same of the first access point and the second access point, With the presence or absence of the corresponding first passwords of target BSSID in the Hash table that detection is prestored, recorded comprising K bars in the Hash table, A BSSID and the corresponding passwords of the BSSID are included in each record, K is positive integer, there is target in Hash table During the corresponding first passwords of BSSID, the second access point is accessed according to the first password.So as to can in the environment there are multiple tools In the case of having identical SSID and cipher mode, but the different access point of password, fast access into network is realized.
Consistent with the abovely, Fig. 2 is referred to, is a kind of Wireless Fidelity Wi-Fi connection method provided in an embodiment of the present invention Second embodiment schematic flow sheet.Wireless Fidelity Wi-Fi connection method described in the present embodiment, comprises the following steps:
201st, when mobile terminal reaches roaming conditions with a distance from the first access point, the target of the second access point is obtained BSSID, wherein, the SSID and cipher mode all same of first access point and second access point.
202nd, with the presence or absence of the corresponding first passwords of the target BSSID, the Kazakhstan in the Hash table that detection is prestored Comprising K bars record in uncommon table, a BSSID and the corresponding passwords of the BSSID are included in each record, the K is positive integer.
When the 203rd, there is the corresponding first passwords of the target BSSID in the Hash table, connect according to the first password Enter second access point.
Wherein, the specific descriptions of above-mentioned steps 201- steps 203 can refer to the right of the Wi-Fi connection method described by Fig. 1 Answer step 101- steps 103.
204th, in the Hash table during first password corresponding in the absence of the target BSSID, input is obtained Second password.
Wherein, in Hash table during first password corresponding in the absence of target BSSID, then may connect mobile terminal first time The second access point is connect, thus, the second password of the second access point can be input into by user oneself.
205th, second access point is accessed according to second password.
Wherein, mobile terminal can verify to second password, and then, in the successful situation of the second password authentification Under, access the second access point.
206th, when second password is successfully accessed second access point, by the target BSSID and described second Password is stored in the Hash table as a record.
Wherein, when the second password is successfully accessed the second access point, can be using target BSSID and the second password as one Record is stored in Hash table, for example, (target BSSID, the second password).
As can be seen that by the embodiment of the present invention, when mobile terminal reaches roaming conditions with a distance from the first access point, The target BSSID of the second access point is obtained, wherein, the SSID and cipher mode all same of the first access point and the second access point, With the presence or absence of the corresponding first passwords of target BSSID in the Hash table that detection is prestored, recorded comprising K bars in the Hash table, A BSSID and the corresponding passwords of the BSSID are included in each record, K is positive integer, there is target in Hash table During the corresponding first passwords of BSSID, the second access point is accessed according to the first password, do not exist target BSSID in Hash table During corresponding first password, second password of user can be obtained, and the second access point is accessed according to second password.So that, can In the case of there are multiple access points different with cipher mode but password with identical SSID in the environment, realization quickly connects Enter network.
Consistent with the abovely, Fig. 3 is referred to, is a kind of Wireless Fidelity Wi-Fi connection method provided in an embodiment of the present invention 3rd embodiment schematic flow sheet.Wireless Fidelity Wi-Fi connection method described in the present embodiment, comprises the following steps:
301st, when mobile terminal reaches roaming conditions with a distance from the first access point, detect whether the mobile terminal overflows Swim over to the coverage of second access point.
Wherein, when mobile terminal reaches roaming conditions with a distance from the first access point, this can as follows be detected Whether mobile terminal roams into the coverage of the second access point.
Alternatively, in above-mentioned steps 301, detect whether the mobile terminal roams into the covering model of second access point Enclose, including:
31) current location of the mobile terminal, is determined;
32) the distance between the current location and the position of second access point value, is determined;
33), judge whether the distance value is less than predetermined threshold value, when the distance value is less than the predetermined threshold value, really Recognize the mobile terminal roaming to the coverage of second access point.
Wherein, mobile terminal can determine to move by global positioning system (Global Positioning System, GPS) The current location of dynamic terminal, or, mobile terminal can determine the current location of mobile terminal by Wi-Fi location technologies.It is above-mentioned The current location of mobile terminal can be indicated with longitude and latitude, for example, current location is represented by 113 ° of 46' of east longitude, 22 ° of north latitude 27'.Certainly, if determining the current location of mobile terminal using Wi-Fi location technologies, then, current Wi-Fi is scanned The position of a certain AP as the mobile terminal position, if be marked in indoor map can be used as being a point for the position of the AP (point for expression mobile terminal locations).Wherein, if being positioned using Wi-Fi location technologies, the position of the second access point It is a known quantity to put, and it can be marked in indoor map.Thus, it may be determined that the position of current location and the second access point The distance between value, whether can determine whether the distance value less than predetermined threshold value, when distance value is less than predetermined threshold value, confirm it is mobile eventually End roams into the coverage of the second access point, when distance value is more than or equal to predetermined threshold value, then confirms that mobile terminal does not overflow Swim over to the coverage of the second access point.
302nd, in coverage of the mobile terminal roaming to second access point, the mesh of the second access point is obtained Mark BSSID, wherein, the SSID and cipher mode all same of first access point and second access point.
303rd, with the presence or absence of the corresponding first passwords of the target BSSID, the Kazakhstan in the Hash table that detection is prestored Comprising K bars record in uncommon table, a BSSID and the corresponding passwords of the BSSID are included in each record, the K is positive integer.
When the 304th, there is the corresponding first passwords of the target BSSID in the Hash table, connect according to the first password Enter second access point.
Wherein, the specific descriptions of above-mentioned steps 302- steps 304 can refer to the right of the Wi-Fi connection method described by Fig. 1 Answer step 101- steps 103.
As can be seen that by the embodiment of the present invention, when mobile terminal reaches roaming conditions with a distance from the first access point, The target BSSID of the second access point is obtained, wherein, the SSID and cipher mode all same of the first access point and the second access point, With the presence or absence of the corresponding first passwords of target BSSID in the Hash table that detection is prestored, recorded comprising K bars in the Hash table, A BSSID and the corresponding passwords of the BSSID are included in each record, K is positive integer, there is target in Hash table During the corresponding first passwords of BSSID, the second access point is accessed according to the first password.So as to can in the environment there are multiple tools In the case of having the access point that SSID is identical with cipher mode but password is different, fast access into network is realized.
Consistent with the abovely, Fig. 4 is referred to, is a kind of Wireless Fidelity Wi-Fi connection method provided in an embodiment of the present invention Fourth embodiment schematic flow sheet.Wireless Fidelity Wi-Fi connection method described in the present embodiment, comprises the following steps:
401st, when mobile terminal reaches roaming conditions with a distance from the first access point, detect whether the mobile terminal connects Receive the beacon frames sent by second access point.
Wherein, the second access point can according to certain frequency to surrounding broadcast beacon frames, thus, if mobile terminal is second In the coverage of access point, then the beacon frames broadcasted by the second access point may be received.Therefore, if mobile terminal connects The beacon frames sent by the second access point are received, then illustrates that mobile terminal can be according to the target BSSID of second access point Scan second access point.
402nd, when the mobile terminal receives the beacon frames sent by second access point, obtain second and access The target BSSID of point, wherein, the SSID and cipher mode all same of first access point and second access point.
Wherein, when mobile terminal receives the beacon frames sent by the second access point, the second access point hair can be obtained During the beacon frames for sending, the target BSSID of the second access point is accessed,
403rd, with the presence or absence of the corresponding first passwords of the target BSSID, the Kazakhstan in the Hash table that detection is prestored Comprising K bars record in uncommon table, a BSSID and the corresponding passwords of the BSSID are included in each record, the K is positive integer.
When the 404th, there is the corresponding first passwords of the target BSSID in the Hash table, connect according to the first password Enter second access point.
Wherein, the specific descriptions of above-mentioned steps 402- steps 404 can refer to the right of the Wi-Fi connection method described by Fig. 1 Answer step 101- steps 103.
As can be seen that by the embodiment of the present invention, when mobile terminal reaches roaming conditions with a distance from the first access point, The target BSSID of the second access point is obtained, wherein, the SSID and cipher mode all same of the first access point and the second access point, With the presence or absence of the corresponding first passwords of target BSSID in the Hash table that detection is prestored, recorded comprising K bars in the Hash table, A BSSID and the corresponding passwords of the BSSID are included in each record, K is positive integer, there is target in Hash table During the corresponding first passwords of BSSID, the second access point is accessed according to the first password.So as to can in the environment there are multiple tools In the case of having the identical SSID access points different with cipher mode but password, fast access into network is realized.
Consistent with the abovely, it is below the device of the above-mentioned Wireless Fidelity Wi-Fi connection method of implementation, it is specific as follows:
Fig. 5 a are referred to, is a kind of first embodiment structural representation of mobile terminal provided in an embodiment of the present invention.This Mobile terminal described in embodiment, including:Acquiring unit 501, the first detection unit 502 and access unit 503, specifically such as Under:
Acquiring unit 501, connects for when mobile terminal reaches roaming conditions with a distance from the first access point, obtaining second The target BSSID of access point, wherein, the SSID and cipher mode all same of first access point and second access point;
First detection unit 502, it is corresponding with the presence or absence of the target BSSID in the Hash table prestored for detection First password, records in the Hash table comprising K bars, corresponding close comprising a BSSID and BSSID in each record Code, the K is positive integer;
Access unit 503, for existing in the Hash table during the corresponding first passwords of the target BSSID, according to The first password accesses second access point.
Alternatively, the another modification structures of the mobile terminal as described by Fig. 5 b, Fig. 5 b are Fig. 5 a, Fig. 5 b are compared with Fig. 5 a Compared with it may also include:Second detection unit 504, it is specific as follows:
Second detection unit 504, for detecting whether the mobile terminal roams into the covering model of second access point Enclose, be covering model of the mobile terminal roaming to second access point in the testing result of second detection unit 504 When enclosing, the target BSSID of the second access point of the acquisition is performed by the acquiring unit 501.
Alternatively, the specific refinement knot of the second detection unit 504 of the mobile terminal as described by Fig. 5 c, Fig. 5 c are Fig. 5 b Structure, second detection unit 504 may include:Determining module 5041 and judge module 5042, it is specific as follows:
Determining module 5041, the current location for determining the mobile terminal;
The determining module 5041, also particularly useful for:
Determine the distance between the current location and the position of second access point value;
Judge module 5042, for whether judging the distance value less than predetermined threshold value, in the judge module 5042 When judged result is that the distance value is less than the predetermined threshold value, the mobile terminal roaming to second access point is confirmed Coverage.
Alternatively, the another modification structures of the mobile terminal as described by Fig. 5 d, Fig. 5 d are Fig. 5 a, Fig. 5 d are compared with Fig. 5 a Compared with it may also include:3rd detection unit 505, it is specific as follows:
3rd detection unit 505, for detecting whether the mobile terminal receives what is sent by second access point Beacon frames, receive by second access point for the mobile terminal in the testing result of the 3rd detection unit 505 During the beacon frames of transmission, the target BSSID of the second access point of the acquisition is performed by the acquiring unit 501.
Alternatively, the another modification structures of the mobile terminal as described by Fig. 5 e, Fig. 5 e are Fig. 5 a, Fig. 5 e are compared with Fig. 5 a Compared with it may also include:Storage unit 506, it is specific as follows:
The acquiring unit 501 also particularly useful for:
In the Hash table during first password corresponding in the absence of the target BSSID, the second of input is obtained Password;
The access unit 503 also particularly useful for:
Second access point is accessed according to second password;
Storage unit 506, for when second password is successfully accessed second access point, by the target BSSID and second password are stored in the Hash table as a record.
As can be seen that by the embodiment of the present invention, when mobile terminal reaches roaming conditions with a distance from the first access point, The target BSSID of the second access point is obtained, wherein, the SSID and cipher mode all same of the first access point and the second access point, With the presence or absence of the corresponding first passwords of target BSSID in the Hash table that detection is prestored, recorded comprising K bars in the Hash table, A BSSID and the corresponding passwords of the BSSID are included in each record, K is positive integer, there is target in Hash table During the corresponding first passwords of BSSID, the second access point is accessed according to the first password.So as to can in the environment there are multiple tools In the case of having the identical SSID access points different with cipher mode but password, fast access into network is realized.
Consistent with the abovely, Fig. 6 is referred to, is a kind of second embodiment knot of mobile terminal provided in an embodiment of the present invention Structure schematic diagram.Mobile terminal described in the present embodiment, including:At least one input equipment 1000;At least one output sets Standby 2000;At least one processor 3000, such as CPU;With memory 4000, above-mentioned input equipment 1000, output equipment 2000, Processor 3000 and memory 4000 are connected by bus 5000.
Wherein, above-mentioned input equipment 1000 concretely contact panel, physical button or mouse.
The concretely display screen of above-mentioned output equipment 2000.
Above-mentioned memory 4000 can be high-speed RAM memory, or nonvolatile storage (non-volatile Memory), such as magnetic disk storage.Above-mentioned memory 4000 is used to store batch processing code, above-mentioned input equipment 1000, defeated Going out equipment 2000 and processor 3000 is used to call the program code stored in memory 4000, performs following operation:
Above-mentioned processor 3000, is used for:
When mobile terminal reaches roaming conditions with a distance from the first access point, the target BSSID of the second access point is obtained, Wherein, the SSID and cipher mode all same of first access point and second access point;
With the presence or absence of the corresponding first passwords of the target BSSID in the Hash table that detection is prestored, the Hash table In comprising K bars record, each record in include a BSSID and the corresponding passwords of the BSSID, the K be positive integer;
When there is the corresponding first passwords of the target BSSID in the Hash table, institute is accessed according to the first password State the second access point.
Alternatively, above-mentioned processor 3000, also particularly useful for:
Detect whether the mobile terminal roams into the coverage of second access point, in the mobile terminal roaming To second access point coverage when, perform it is described obtain the second access point target BSSID.
Alternatively, above-mentioned processor 3000 detects whether the mobile terminal roams into the covering model of second access point Enclose, including:
Determine the current location of the mobile terminal;
Determine the distance between the current location and the position of second access point value;
Judge that whether the distance value, less than predetermined threshold value, when the distance value is less than the predetermined threshold value, confirms institute State mobile terminal roaming to the coverage of second access point.
Alternatively, above-mentioned processor 3000, also particularly useful for:
Detect whether the mobile terminal receives the beacon frames sent by second access point, in the mobile terminal When receiving the beacon frames sent by second access point, the target BSSID for obtaining the second access point is performed.
Alternatively, above-mentioned processor 3000, also particularly useful for:
In the Hash table during first password corresponding in the absence of the target BSSID, the second of input is obtained Password;
Second access point is accessed according to second password;
When second password is successfully accessed second access point, by the target BSSID and second password It is stored in the Hash table as a record.
The embodiment of the present invention also provides a kind of computer-readable storage medium, wherein, the computer-readable storage medium can be stored with journey Sequence, the part including any Wireless Fidelity Wi-Fi connection method described in the above method embodiment when program is performed Or Overall Steps.
Although invention has been described to combine each embodiment herein, however, implementing the present invention for required protection During, those skilled in the art are by checking the accompanying drawing, disclosure and appended claims, it will be appreciated that and it is real Other changes of the existing open embodiment.In the claims, " including " (comprising) one word be not excluded for other composition Part or step, "a" or "an" are not excluded for the situation of multiple.Single processor or other units can realize claim In some functions enumerating.Mutually different has been recited in mutually different dependent some measures, it is not intended that these are arranged Apply to combine and produce good effect.
It will be understood by those skilled in the art that embodiments of the invention can be provided as method, device (equipment) or computer journey Sequence product.Therefore, in terms of the present invention can be using complete hardware embodiment, complete software embodiment or combination software and hardware The form of embodiment.And, the present invention can be used and wherein include the calculating of computer usable program code at one or more The computer program implemented in machine usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) The form of product.Computer program is stored/distributed in suitable medium, is provided together with other hardware or as the one of hardware Part, it would however also be possible to employ other distribution forms, such as passes through Internet or other wired or wireless telecommunication systems.
The present invention be with reference to the embodiment of the present invention method, device (equipment) and computer program product flow chart with/ Or block diagram is described.It should be understood that each flow during flow chart and/or block diagram can be realized by computer program instructions and/ Or the combination of the flow and/or square frame in square frame and flow chart and/or block diagram.These computer program instructions can be provided To the processor of all-purpose computer, special-purpose computer, Embedded Processor or other programmable data processing devices producing one Individual machine so that produced for realizing by the instruction of computer or the computing device of other programmable data processing devices The device of the function of being specified in one flow of flow chart or multiple one square frame of flow and/or block diagram or multiple square frames.
These computer program instructions may be alternatively stored in can guide computer or other programmable data processing devices with spy In determining the computer-readable memory that mode works so that instruction of the storage in the computer-readable memory is produced and include finger Make the manufacture of device, the command device realize in one flow of flow chart or multiple one square frame of flow and/or block diagram or The function of being specified in multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing devices so that in meter Series of operation steps is performed on calculation machine or other programmable devices to produce computer implemented treatment, so as in computer or The instruction performed on other programmable devices is provided for realizing in one flow of flow chart or multiple flows and/or block diagram one The step of function of being specified in individual square frame or multiple square frames.
Although with reference to specific features and embodiment, invention has been described, it is clear that, do not departing from this hair In the case of bright spirit and scope, various modifications and combinations can be carried out to it.Correspondingly, the specification and drawings are only institute The exemplary illustration of the invention that attached claim is defined, and be considered as covered in the scope of the invention any and all and repair Change, change, combining or equivalent.Obviously, those skilled in the art the present invention can be carried out it is various change and modification without Depart from the spirit and scope of the present invention.So, if it is of the invention these modification and modification belong to the claims in the present invention and its Within the scope of equivalent technologies, then the present invention is also intended to comprising these changes and modification.

Claims (11)

1. a kind of Wireless Fidelity Wi-Fi connection method, it is characterised in that including:
When mobile terminal reaches roaming conditions with a distance from the first access point, the target BSSID of the second access point is obtained, its In, the SSID and cipher mode all same of first access point and second access point;
With the presence or absence of the corresponding first passwords of the target BSSID in the Hash table that detection is prestored, wrapped in the Hash table Bar containing K is recorded, and a BSSID and the corresponding passwords of the BSSID are included in each record, and the K is positive integer;
When there is the corresponding first passwords of the target BSSID in the Hash table, described the is accessed according to the first password Two access points.
2. method according to claim 1, it is characterised in that methods described also includes:
Detect whether the mobile terminal roams into the coverage of second access point, in the mobile terminal roaming to institute When stating the coverage of the second access point, the target BSSID for obtaining the second access point is performed.
3. method according to claim 2, it is characterised in that whether the detection mobile terminal roams into described The coverage of two access points, including:
Determine the current location of the mobile terminal;
Determine the distance between the current location and the position of second access point value;
Judge that whether the distance value, less than predetermined threshold value, when the distance value is less than the predetermined threshold value, confirms the shifting Coverage of the dynamic terminal roaming to second access point.
4. method according to claim 1, it is characterised in that methods described also includes:
Detect whether the mobile terminal receives the beacon frames sent by second access point, received in the mobile terminal During to the beacon frames sent by second access point, the target BSSID for obtaining the second access point is performed.
5. the method according to any one of Claims 1-4, it is characterised in that methods described also includes:
In the Hash table during first password corresponding in the absence of the target BSSID, the second password of input is obtained;
Second access point is accessed according to second password;
When second password is successfully accessed second access point, using the target BSSID and second password as One record is stored in the Hash table.
6. a kind of mobile terminal, it is characterised in that including:
Acquiring unit, for when mobile terminal reaches roaming conditions with a distance from the first access point, obtaining the second access point Target BSSID, wherein, the SSID and cipher mode all same of first access point and second access point;
First detection unit, it is corresponding first close with the presence or absence of the target BSSID in the Hash table that prestores for detecting Code, is recorded in the Hash table comprising K bars, and a BSSID and the corresponding passwords of the BSSID, the K are included in each record It is positive integer;
Access unit, it is first close according to this for existing in the Hash table during the corresponding first passwords of the target BSSID Code accesses second access point.
7. mobile terminal according to claim 6, it is characterised in that the mobile terminal also includes:
Second detection unit, for detecting whether the mobile terminal roams into the coverage of second access point, in institute When the testing result for stating the second detection unit is the mobile terminal roaming to the coverage of second access point, by described Acquiring unit performs the target BSSID for obtaining the second access point.
8. mobile terminal according to claim 7, it is characterised in that second detection unit includes:
Determining module, the current location for determining the mobile terminal;
The determining module, also particularly useful for:
Determine the distance between the current location and the position of second access point value;
Judge module, for judging that whether the distance value, less than predetermined threshold value, is institute in the judged result of the judge module When stating distance value less than the predetermined threshold value, the mobile terminal roaming to the coverage of second access point is confirmed.
9. mobile terminal according to claim 6, it is characterised in that the mobile terminal also includes:
3rd detection unit, for detecting whether the mobile terminal receives the beacon frames sent by second access point, It is that the mobile terminal is received by the beacon of second access point transmission in the testing result of the 3rd detection unit During frame, the target BSSID for obtaining the second access point is performed by the acquiring unit.
10. the mobile terminal according to any one of claim 6 to 9, it is characterised in that the acquiring unit is also specifically used In:
In the Hash table during first password corresponding in the absence of the target BSSID, the second password of input is obtained;
The access unit also particularly useful for:
Second access point is accessed according to second password;
The mobile terminal also includes:
Storage unit, for when second password is successfully accessed second access point, by the target BSSID and described Second password is stored in the Hash table as a record.
A kind of 11. mobile terminals, it is characterised in that including:
Processor and memory;Wherein, the processor is by calling code in the memory or instruction to perform such as power Profit requires the method described in 1 to 5 any one.
CN201710091096.0A 2017-02-20 2017-02-20 A kind of Wireless Fidelity Wi Fi connection methods and mobile terminal Pending CN106792698A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710091096.0A CN106792698A (en) 2017-02-20 2017-02-20 A kind of Wireless Fidelity Wi Fi connection methods and mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710091096.0A CN106792698A (en) 2017-02-20 2017-02-20 A kind of Wireless Fidelity Wi Fi connection methods and mobile terminal

Publications (1)

Publication Number Publication Date
CN106792698A true CN106792698A (en) 2017-05-31

Family

ID=58958709

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710091096.0A Pending CN106792698A (en) 2017-02-20 2017-02-20 A kind of Wireless Fidelity Wi Fi connection methods and mobile terminal

Country Status (1)

Country Link
CN (1) CN106792698A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019075896A1 (en) * 2017-10-18 2019-04-25 广州视睿电子科技有限公司 Method and apparatus for interconnection between devices, system, device, and storage medium
CN110022561A (en) * 2019-03-29 2019-07-16 联想(北京)有限公司 Information processing method and information processing unit

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2004034205A2 (en) * 2002-10-08 2004-04-22 Koolspan Self-managed network access using localized access management
CN101977382A (en) * 2010-10-27 2011-02-16 福州星网视易信息***有限公司 Audio and video integrated control circuit and method for accessing access point
CN105323244A (en) * 2015-09-22 2016-02-10 小米科技有限责任公司 Method and device for network identification
CN105657706A (en) * 2015-10-30 2016-06-08 东莞酷派软件技术有限公司 Access method, related device and access apparatus
CN106162818A (en) * 2015-04-09 2016-11-23 厦门众联世纪科技有限公司 The method unlocking WIFI hot spot

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2004034205A2 (en) * 2002-10-08 2004-04-22 Koolspan Self-managed network access using localized access management
CN101977382A (en) * 2010-10-27 2011-02-16 福州星网视易信息***有限公司 Audio and video integrated control circuit and method for accessing access point
CN106162818A (en) * 2015-04-09 2016-11-23 厦门众联世纪科技有限公司 The method unlocking WIFI hot spot
CN105323244A (en) * 2015-09-22 2016-02-10 小米科技有限责任公司 Method and device for network identification
CN105657706A (en) * 2015-10-30 2016-06-08 东莞酷派软件技术有限公司 Access method, related device and access apparatus

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2019075896A1 (en) * 2017-10-18 2019-04-25 广州视睿电子科技有限公司 Method and apparatus for interconnection between devices, system, device, and storage medium
CN110022561A (en) * 2019-03-29 2019-07-16 联想(北京)有限公司 Information processing method and information processing unit

Similar Documents

Publication Publication Date Title
CN106973384B (en) A kind of Wireless Fidelity Wi-Fi connection method and mobile terminal
EP3364692B1 (en) Wireless fidelity connection method, mobile terminal and storage medium
EP3562257B1 (en) Wireless fidelity (wi-fi) connection method and related product
CN104994563B (en) A kind of method for network access and mobile communication terminal
CN106375465B (en) A kind of data migration method and server
CN104853410B (en) A kind of method for network access and mobile communication terminal
CN106604362A (en) Wireless fidelity (Wi-Fi) scanning method and mobile terminal
EP3565370A1 (en) Wireless fidelity (wi-fi) connection method and related product
CN107182098A (en) For realizing the method and apparatus that user equipment switches between WAP
CN106686587B (en) Wireless fidelity Wi-Fi connection method, mobile terminal and medium
CN106792698A (en) A kind of Wireless Fidelity Wi Fi connection methods and mobile terminal
CN103067909A (en) Method and device for achieving locking card
CN104968030B (en) A kind of method for network access and mobile communication terminal
CN106793015A (en) A kind of Wireless Fidelity Wi Fi connection methods and mobile terminal
CN106658670A (en) Wireless fidelity Wi-Fi scanning method and mobile terminal
CN106888496B (en) A kind of Wireless Fidelity Wi-Fi connection method and mobile terminal
CN106535102A (en) Mobile terminal positioning method and mobile terminal
CN106793016A (en) A kind of Wireless Fidelity Wi Fi connection methods and mobile terminal
CN110493246A (en) Wireless network connecting method, device, electronic equipment and medium
CN106686588A (en) Wireless fidelity Wi-Fi connecting method and mobile terminal
CN107529171A (en) Detection terminal accesses the method and Related product of pseudo-base station
CN106060804A (en) Wireless distance triangulation location method
CN116744391A (en) Base station selection method and device
CN106507446A (en) A kind of Wireless Fidelity Wi Fi methods of attachment and mobile terminal
KR20170130824A (en) Mobile communication terminal and method for generating list of wireless internet network

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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20170531