CN108811045B - WiFi channel scanning method and device, mobile terminal and storage medium - Google Patents
WiFi channel scanning method and device, mobile terminal and storage medium Download PDFInfo
- Publication number
- CN108811045B CN108811045B CN201810604000.0A CN201810604000A CN108811045B CN 108811045 B CN108811045 B CN 108811045B CN 201810604000 A CN201810604000 A CN 201810604000A CN 108811045 B CN108811045 B CN 108811045B
- Authority
- CN
- China
- Prior art keywords
- wifi
- channel
- mobile terminal
- wifi channel
- channels
- 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
Links
Images
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W48/00—Access restriction; Network selection; Access point selection
- H04W48/16—Discovering, processing access restriction or access information
Landscapes
- Engineering & Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Telephone Function (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
The embodiment of the application discloses a WiFi channel scanning method, a WiFi channel scanning device, a mobile terminal and a storage medium, and relates to the technical field of communication. The method comprises the following steps: the method comprises the steps of obtaining the error vector amplitude of each WiFi channel in a plurality of WiFi channels supported by the mobile terminal, sequencing the WiFi channels based on the error vector amplitude of each WiFi channel to obtain current WiFi channel sequencing, and scanning the WiFi channels in sequence based on the current WiFi channel sequencing. The WiFi channel scanning method, the WiFi channel scanning device, the mobile terminal and the storage medium sort the WiFi channels through the error vector magnitude of the mobile terminal on each WiFi channel, and scan based on the sort, so that the WiFi scanning success rate is improved.
Description
Technical Field
The present application relates to the field of communications technologies, and in particular, to a WiFi channel scanning method, apparatus, mobile terminal, and storage medium.
Background
When the mobile terminal starts the wlan function, the mobile terminal scans a Wireless Fidelity (WiFi) hotspot of the surrounding environment. However, the current strategy of WiFi scanning is to scan WiFi channels in order from low to high, or scan previously connected Wireless Access Points (APs), so that the problem of poor communication quality and low connection power of WiFi connected to the mobile terminal is easily caused.
Disclosure of Invention
In view of the above problems, the present application provides a WiFi channel scanning method, apparatus, mobile terminal and storage medium, where WiFi channels are sorted by an error vector magnitude of each WiFi channel of the mobile terminal, and are scanned based on the sorting, so as to improve a WiFi scanning success rate.
In a first aspect, an embodiment of the present application provides a WiFi channel scanning method, where the method includes: acquiring the error vector magnitude of each WiFi channel in a plurality of WiFi channels supported by the mobile terminal; sequencing the plurality of WiFi channels based on the error vector magnitude of each WiFi channel to obtain the current WiFi channel sequencing; and sequentially scanning the plurality of WiFi channels based on the current WiFi channel sequence.
In a second aspect, an embodiment of the present application provides a WiFi channel scanning apparatus, where the apparatus includes: the error vector amplitude acquisition module is used for acquiring the error vector amplitude of each WiFi channel in the plurality of WiFi channels supported by the mobile terminal; the WiFi channel ordering module is used for ordering the plurality of WiFi channels based on the error vector magnitude of each WiFi channel to obtain the current WiFi channel ordering; and the WiFi channel scanning module is used for scanning the plurality of WiFi channels in sequence based on the current WiFi channel sequence.
In a third aspect, an embodiment of the present application provides a mobile terminal, including a display screen, a memory, and a processor, where the display screen and the memory are coupled to the processor, and the memory stores instructions, and when the instructions are executed by the processor, the processor performs the above method.
In a fourth aspect, the present application provides a computer readable storage medium having program code executable by a processor, the program code causing the processor to execute the above method.
The embodiment of the application provides a WiFi channel scanning method, a WiFi channel scanning device, a mobile terminal and a storage medium, wherein the error vector amplitude of each WiFi channel of a plurality of WiFi channels supported by the mobile terminal is obtained, the plurality of WiFi channels are sequenced based on the error vector amplitude of each WiFi channel, the current WiFi channel sequencing is obtained, the plurality of WiFi channels are sequentially scanned based on the current WiFi channel sequencing, therefore, the WiFi channels are sequenced through the error vector amplitude of each WiFi channel of the mobile terminal, and scanning is performed based on the sequencing, and the WiFi scanning success rate is improved.
These and other aspects of the present application will be more readily apparent from the following description of the embodiments.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, 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 only some embodiments of the present application, 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 WiFi channel scanning method provided in an embodiment of the present application;
fig. 2 is a flowchart illustrating a second WiFi channel scanning method provided in an embodiment of the present application;
fig. 3 is a flowchart illustrating a step S240 of a second WiFi channel scanning method provided in this embodiment of the application;
fig. 4 shows a block diagram of a first WiFi channel scanning apparatus provided in an embodiment of the present application;
fig. 5 shows a block diagram of a second WiFi channel scanning apparatus provided in an embodiment of the present application;
fig. 6 shows a schematic structural diagram of a mobile terminal provided in an embodiment of the present application;
fig. 7 shows a block diagram of a mobile terminal for performing a WiFi channel scanning method according to an embodiment of the application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. 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 application.
With the development of mobile terminals, the WiFi of the wireless local area network has become a standard configuration of various mobile terminals, and through the configuration, the mobile terminal can scan WiFi hotspots nearby the mobile terminal and surf the internet by using the WiFi hotspots. However, in the current WiFi scanning strategy, the WiFi channels are scanned in a sequence from low to high, or the channels where the previously connected APs are located are scanned first, which does not dynamically adjust the state of the mobile phone, and easily causes the problems of poor communication quality and low connection power of the WiFi connected to the mobile terminal. In view of the above problems, the inventor proposes a WiFi channel scanning method, apparatus, mobile terminal and storage medium provided in this embodiment of the present application, and sorts WiFi channels according to an error vector magnitude of each WiFi channel of the mobile terminal, and scans based on the sort, thereby improving a WiFi scanning success rate. The specific WiFi channel scanning method is described in detail in the following embodiments.
Examples
Referring to fig. 1, fig. 1 is a schematic flowchart illustrating a first WiFi channel scanning method according to an embodiment of the present disclosure. The WiFi channel scanning method is used for sequencing the WiFi channels through the error vector magnitude of the mobile terminal on each WiFi channel and scanning based on the sequencing, so that the WiFi scanning success rate is improved. In a specific embodiment, the WiFi channel scanning method is applied to the WiFi channel scanning apparatus 200 shown in fig. 4 and a mobile terminal configured with the WiFi channel scanning apparatus 200 (fig. 6). The following will describe a specific process of this embodiment by taking a mobile terminal as an example, and it is understood that the mobile terminal applied in this embodiment may be a smart phone, a tablet computer, a wearable electronic device, and the like, which is not limited specifically herein. As will be described in detail with respect to the flow shown in fig. 1, the WiFi channel scanning method may specifically include the following steps:
step S110: and acquiring the error vector magnitude of each WiFi channel in the plurality of supported WiFi channels of the mobile terminal.
An Error Vector Magnitude (EVM) is a Vector difference between an ideal Error-free reference signal and an actually transmitted signal at a given time, and is used for measuring an amplitude Error and a phase Error of a modulated signal, and the EVM specifically indicates a degree of proximity between an IQ component generated when a receiving terminal demodulates the signal and the ideal component, and is an index for considering the modulated signal. Furthermore, when different mobile phones leave the factory, EVM values are different, and meanwhile, the EVM value of the same mobile phone on different WiFi channels also has some deviations, so that good EVM values can bring good internet experience, but when the EVM is poor, the EVM is matched with some routes with poor compatibility, and WiFi experience deviations can occur. The EVM is a negative value, and the smaller the EVM is, the better the communication quality of the WiFi channel is.
Further, when scanning all WiFi access points within the network coverage, the mobile terminal scans one by one according to the plurality of WiFi channels supported by the mobile terminal to obtain a WiFi access point on each WiFi channel in the plurality of scanned WiFi channels, and selects one WiFi access point for connection. As one manner, before performing WiFi channel scanning, an error vector magnitude of each WiFi channel in a plurality of WiFi channels supported by a mobile terminal is obtained, where the WiFi channels supported by the mobile terminal may include one or more of channels 1 to 13, for example, if the WiFi channels supported by the mobile terminal include all WiFi channels in channels 1 to 13, the error vector magnitudes of the mobile terminal on the 13 WiFi channels are respectively obtained, for example, the error vector magnitude of the mobile terminal on the channel 1 is-27, the error vector magnitude on the channel 2 is-30, and the like, which is not limited herein.
Step S120: and sequencing the plurality of WiFi channels based on the error vector magnitude of each WiFi channel to obtain the current WiFi channel sequencing.
After error vector amplitudes of a plurality of WiFi channels supported by the mobile terminal are obtained, the plurality of WiFi channels are sequenced based on the error vector amplitudes so as to obtain current WiFi channel sequencing. It can be understood that the error vector magnitude is a negative value, and the smaller the error vector is, the better the communication quality of the mobile terminal in the WiFi channel is characterized, therefore, the WiFi channels may be sorted based on the magnitude of the error vector magnitude of the WiFi channels, specifically, by comparing the magnitude of the error vector magnitude of each WiFi channel, the WiFi channels are sorted according to the comparison result.
As one way, as shown in table 1, the WiFi channels may be sorted from small to large according to the error vector magnitude of each WiFi channel, and as can be seen from table 1, the smaller the EVM value is, the earlier the corresponding WiFi channel is sorted, and the larger the EVM value is, the later the corresponding WiFi channel is sorted.
TABLE 1
EVM value | Sorting |
-30 | 1 |
-20 | 2 |
-10 | 3 |
-5 | 4 |
Step S130: and sequentially scanning the plurality of WiFi channels based on the current WiFi channel sequence.
In this embodiment, the WiFi channels are sequentially scanned based on the current WiFi channel sequence, and it can be understood that the scanning sequence is sequentially scanning from the WiFi channel with the highest sequence to the WiFi channel with the lowest sequence, where if a connectable WiFi access point is scanned in the WiFi channel with the highest sequence, the scanning is not continued, so as to improve the success rate of accessing the WiFi channel with better communication quality by the mobile terminal, and reduce the power consumption of the mobile terminal due to multiple scanning.
In this embodiment, the scanning of the WiFi channels may be active scanning or passive scanning. In the active scanning mode, the mobile terminal actively sends out a Probe Request frame on a WiFi channel with the highest rank, waits for an incoming frame indication (indicating an incoming frame) or waits for a scanning time to be overtime, and can scan a WiFi access point if a frame is received on the channel, specifically, the frame includes an identifier of the WiFi access point.
Under passive scanning, the mobile terminal waits to receive a Beacon (Beacon) frame on the highest-ranked WiFi channel, including the identification of the WiFi access point in the Beacon, so if the Beacon frame is received, the WiFi access point on the WiFi channel can be determined, and of course, if the Beacon frame is not received within a certain time, no connectable WiFi access point on the WiFi channel is characterized.
The first WiFi channel scanning method provided by the embodiment of the application obtains the error vector amplitude of each WiFi channel in a plurality of WiFi channels supported by a mobile terminal, sequences the WiFi channels based on the error vector amplitude of each WiFi channel to obtain the current WiFi channel sequencing, sequentially scans the WiFi channels based on the current WiFi channel sequencing, sequences the WiFi channels through the error vector amplitude of the mobile terminal on each WiFi channel, and scans based on the sequencing to improve the WiFi scanning success rate.
Referring to fig. 2, fig. 2 is a flowchart illustrating a second WiFi channel scanning method according to an embodiment of the present application. As will be explained in detail with respect to the flow shown in fig. 2, the method may specifically include the following steps:
step S210: detecting an error vector magnitude for the mobile terminal at each of the plurality of supported WiFi channels.
The error vector magnitude of the mobile terminal on the supported WiFi channel may be obtained during use, or may be obtained by testing before the mobile terminal leaves a factory. Specifically, when the error vector magnitude of the mobile terminal on the supported WiFi channel is obtained by a pre-factory test, then before the mobile terminal leaves the factory, a test environment may be pre-established, for example, other influence factors, except the error vector magnitude, which influence the communication quality of the mobile terminal on the WiFi channel are fixed and unchanged, and then the error vector magnitude of each WiFi channel supported by the mobile terminal is tested, so as to obtain the error vector magnitude of each WiFi channel supported by the mobile terminal.
Step S220: and storing the error vector magnitude of each WiFi channel to the mobile terminal.
It can be understood that, by the above method, the error vector magnitude of the mobile terminal on each WiFi channel can be obtained, and the error vector magnitude of each WiFi channel is stored in the mobile terminal, so that when the mobile terminal is used after leaving a factory, the error vector magnitude of each WiFi channel can be directly obtained locally, and the obtaining speed of the error vector magnitude is accelerated.
Step S230: and acquiring the error vector magnitude of each WiFi channel in the plurality of supported WiFi channels of the mobile terminal.
Step S240: and sequencing the plurality of WiFi channels from small to large according to the error vector magnitude of each WiFi channel to obtain the current WiFi channel sequencing.
Further, in this embodiment, since the mobile terminal stores the error vector magnitude of each WiFi channel, when the mobile terminal is in use, the error vector magnitude of each WiFi channel may be directly obtained locally, and the WiFi channels are sorted from high to low according to the order of the error vector magnitude of each WiFi channel from small to large.
As a way, when the error vector magnitudes of some WiFi channels in a plurality of WiFi channels are equal, respectively detecting the historical data of the some WiFi channels, where the historical data may include the historical signal strengths, the historical transmission rates, the historical congestion indexes, etc. of the some WiFi channels, and then scoring the WiFi channels based on the obtained historical data of each WiFi channel, it can be understood that the WiFi channels with high scores are ranked before the WiFi channels with low scores, and specifically, the WiFi channels with high historical signal strengths are ranked before the WiFi channels with low historical signal strengths; the WiFi channels with high historical transmission rate are sequenced before the WiFi channels with low historical transmission rate; the WiFi channels with low historical congestion indexes are ranked before the WiFi channels with high historical congestion indexes, the current part of WiFi channels can be obtained through the mode, and then the current WiFi channel ranks of all WiFi channels supported by the mobile terminal are obtained by integrating the rankings of other WiFi channels.
As a specific mode, when the error vector magnitudes of some WiFi channels in the multiple WiFi channels are equal, the historical data of the some WiFi channels are detected respectively, and it is determined whether there is WiFi that has established connection with the mobile terminal in the some WiFi channels, and the WiFi channels where the WiFi that has established connection with the mobile terminal is located are sorted before the WiFi channels where the WiFi that has not established connection with the mobile terminal is located.
Referring to fig. 3, fig. 3 is a flowchart illustrating step S240 of a second WiFi channel scanning method according to an embodiment of the present application. As will be explained in detail with respect to the flow shown in fig. 3, the method may specifically include the following steps:
step S241: and scoring the communication quality of each WiFi channel based on the error vector magnitude of each WiFi channel to obtain the communication quality score value of each WiFi channel.
As an implementable manner, after the error vector magnitude of each WiFi channel is obtained, the communication quality of each WiFi channel is scored to obtain the communication quality score value of each WiFi channel, and it can be understood that the error vector magnitude is a negative value, and the smaller the error vector magnitude is, the better the communication quality of the WiFi channel is, and therefore, the higher the corresponding communication quality score value is; conversely, the larger the error vector magnitude, the worse the WiFi channel communication quality, and therefore, the lower its corresponding communication quality score value, e.g., 90 when the error vector magnitude is-30; when the magnitude of the error vector is-20, the communication quality score value is 80, and the like, which is not limited herein.
Step S242: and sequencing the plurality of WiFi channels according to the communication quality score values of each WiFi channel from high to low to obtain the current WiFi channel sequencing.
As one way, as shown in table 2, the plurality of WiFi channels may be ranked from high to low in communication quality score value, and as can be seen from table 2, the higher the communication quality score value is, the earlier the corresponding ranking is, and the lower the communication quality score value is, the later the corresponding ranking is.
TABLE 2
EVM value | Communication quality score value | Sorting |
-30 | 90 | 1 |
-20 | 80 | 2 |
-10 | 70 | 3 |
-5 | 60 | 4 |
Step S250: and sequentially scanning the plurality of WiFi channels based on the current WiFi channel sequence.
Step S260: and acquiring a target WiFi channel, and establishing connection with WiFi in the target WiFi channel.
In this embodiment, the mobile terminal starts scanning from the WiFi channel with the highest rank, if there is no WiFi access point in the WiFi channel with the highest rank, the WiFi channel with the second rank is started scanning, and so on, in the scanning process, if a WiFi access point is found, the WiFi channel corresponding to the WiFi access point is determined as a target WiFi channel and a connection is established with WiFi in the target WiFi channel.
The second WiFi channel scanning method provided in this embodiment of the application detects an error vector magnitude of each WiFi channel in a plurality of WiFi channels supported by a mobile terminal, stores the error vector magnitude of each WiFi channel to the mobile terminal, obtains the error vector magnitude of each WiFi channel in the plurality of WiFi channels supported by the mobile terminal, sorts the plurality of WiFi channels from small to large according to the error vector magnitude of each WiFi channel, obtains a current WiFi channel sorting, scans the plurality of WiFi channels in sequence based on the current WiFi channel sorting, obtains a target channel, and establishes a WiFi connection with the target WiFi channel.
Referring to fig. 4, fig. 4 is a block diagram illustrating a first WiFi channel scanning apparatus 200 according to an embodiment of the present application. As will be explained below with respect to the block diagram shown in fig. 4, the WiFi channel scanning apparatus 200 includes: an error vector magnitude obtaining module 210, a WiFi channel ordering module 220, and a WiFi channel scanning module 230, wherein:
an error vector magnitude obtaining module 210, configured to obtain an error vector magnitude of each WiFi channel in the plurality of WiFi channels supported by the mobile terminal.
A WiFi channel ordering module 220, configured to order the WiFi channels based on the error vector magnitude of each WiFi channel, so as to obtain a current WiFi channel ordering.
A WiFi channel scanning module 230, configured to sequentially scan the WiFi channels based on the current WiFi channel ordering.
Referring to fig. 5, fig. 5 is a block diagram illustrating a second WiFi channel scanning apparatus 300 according to an embodiment of the present application. As will be explained below with respect to the block diagram shown in fig. 5, the WiFi channel scanning apparatus 300 includes: an error vector magnitude detection module 310, an error vector magnitude detection module 320, an error vector magnitude acquisition module 330, a WiFi channel ordering module 340, a WiFi channel scanning module 350, and an acquisition target WiFi channel 360, wherein:
an error vector magnitude detection module 310, configured to detect an error vector magnitude of the mobile terminal in each of the plurality of supported WiFi channels.
An error vector magnitude saving module 320, configured to save the error vector magnitude of each WiFi channel to the mobile terminal.
An error vector magnitude obtaining module 330, configured to obtain an error vector magnitude of each WiFi channel in the plurality of WiFi channels supported by the mobile terminal.
A WiFi channel ordering module 340, configured to order the WiFi channels based on the error vector magnitude of each WiFi channel, so as to obtain a current WiFi channel ordering. Further, the WiFi channel ordering module 340 includes: the device comprises a first channel sorting submodule, a historical data detection submodule, a scoring submodule, a second channel sorting submodule, a connection judgment submodule and a third channel sorting submodule, wherein:
and the first channel sequencing submodule is used for sequencing the plurality of WiFi channels from small to large according to the error vector magnitude of each WiFi channel to obtain the current WiFi channel sequencing. Further, the channel ordering sub-module comprises: a communication quality score value acquisition unit and a channel sorting unit, wherein:
and the communication quality score value acquisition unit is used for scoring the communication quality of each WiFi channel based on the error vector magnitude of each WiFi channel to obtain the communication quality score value of each WiFi channel.
And the channel sorting unit is used for sorting the plurality of WiFi channels according to the communication quality score values of the WiFi channels from high to low to obtain the current WiFi channel sorting.
And the historical data detection submodule is used for respectively detecting the historical data of partial WiFi channels when the error vector amplitudes of the partial WiFi channels in the plurality of WiFi channels are equal.
A scoring submodule configured to score the portion of the WiFi channels based on the historical data.
And the second channel sorting submodule is used for sorting the partial WiFi channels from high to low according to the scores to obtain the current partial WiFi channel sorting.
And the connection judgment submodule is used for judging whether WiFi which is connected with the mobile terminal exists in the part of WiFi channels.
And the third channel ordering submodule is used for ordering the WiFi channel corresponding to the WiFi which is connected with the mobile terminal before the WiFi channel corresponding to the WiFi which is not connected with the mobile terminal.
A WiFi channel scanning module 350, configured to sequentially scan the WiFi channels based on the current WiFi channel ordering.
And a target WiFi channel connection module 360, configured to acquire a target WiFi channel, and establish a connection with WiFi in the target WiFi channel.
To sum up, according to the WiFi channel scanning method, device, mobile terminal and storage medium provided in the embodiments of the present application, an error vector magnitude of each WiFi channel in a plurality of WiFi channels supported by the mobile terminal is obtained, the plurality of WiFi channels are sorted based on the error vector magnitude of each WiFi channel, a current WiFi channel sorting is obtained, the plurality of WiFi channels are sequentially scanned based on the current WiFi channel sorting, the WiFi channels are sorted by the error vector magnitude of each WiFi channel of the mobile terminal, and are scanned based on the sorting, so that a WiFi scanning success rate is improved.
It should be noted that, in the present specification, the embodiments are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments may be referred to each other. For the device-like embodiment, since it is basically similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment. For any processing manner described in the method embodiment, all the processing manners may be implemented by corresponding processing modules in the apparatus embodiment, and details in the apparatus embodiment are not described again.
Referring to fig. 6 again, based on the WiFi channel scanning method and apparatus, the embodiment of the present application further provides a mobile terminal 100, which includes an electronic body 10, where the electronic body 10 includes a housing 12 and a main display 120 disposed on the housing 12. The housing 12 may be made of metal, such as steel or aluminum alloy. In this embodiment, the main display 120 generally includes a display panel 111, and may also include a circuit or the like for responding to a touch operation performed on the display panel 111. The Display panel 111 may be a Liquid Crystal Display (LCD), and in some embodiments, the Display panel 111 is a Display screen 109.
Referring to fig. 7, in an actual application scenario, the mobile terminal 100 may be used as a smart phone terminal, in which case the electronic body 10 generally further includes one or more processors 102 (only one is shown in the figure), a memory 104, an RF (Radio Frequency) module 106, an audio circuit 110, a sensor 114, an input module 118, and a power module 122. It will be understood by those skilled in the art that the structure shown in fig. 7 is merely illustrative and is not intended to limit the structure of the electronic body 10. For example, the electronics body section 10 may also include more or fewer components than shown in FIG. 7, or have a different configuration than shown in FIG. 7.
Those skilled in the art will appreciate that all other components are peripheral devices with respect to the processor 102, and the processor 102 is coupled to the peripheral devices through a plurality of peripheral interfaces 124. The peripheral interface 124 may be implemented based on the following criteria: universal Asynchronous Receiver/Transmitter (UART), General Purpose Input/Output (GPIO), Serial Peripheral Interface (SPI), and Inter-Integrated Circuit (I2C), but the present invention is not limited to these standards. In some examples, the peripheral interface 124 may comprise only a bus; in other examples, the peripheral interface 124 may also include other elements, such as one or more controllers, for example, a display controller for interfacing with the display panel 111 or a memory controller for interfacing with a memory. These controllers may also be separate from the peripheral interface 124 and integrated within the processor 102 or a corresponding peripheral.
The memory 104 may be used to store software programs and modules, and the processor 102 executes various functional applications and data processing by executing the software programs and modules stored in the memory 104. For example, the memory 104 stores software programs and modules corresponding to the WiFi channel scanning method provided in the foregoing embodiment, and the processor 102 executes the WiFi channel scanning method provided in the foregoing embodiment when running the software programs and modules of the WiFi channel scanning method provided in the foregoing embodiment. The memory 104 may include high speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include memory located remotely from the processor 102, which may be connected to the electronic body portion 10 or the primary display 120 via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The RF module 106 is used for receiving and transmitting electromagnetic waves, and implementing interconversion between the electromagnetic waves and electrical signals, so as to communicate with a communication network or other devices. The RF module 106 may include various existing circuit elements for performing these functions, such as an antenna, a radio frequency transceiver, a digital signal processor, an encryption/decryption chip, a Subscriber Identity Module (SIM) card, memory, and so forth. The RF module 106 may communicate with various networks such as the internet, an intranet, a wireless network, or with other devices via a wireless network. The wireless network may comprise a cellular telephone network, a wireless local area network, or a metropolitan area network. The wireless network may use various Communication standards, protocols and technologies, including but not limited to Global System for Mobile Communication (GSM), Enhanced Data GSM Environment (EDGE), wideband Code division multiple Access (W-CDMA), Code Division Multiple Access (CDMA), Time Division Multiple Access (TDMA), Voice over internet protocol (VoIP), Global Microwave internet Access (Wi-Max), other protocols for mail, instant messaging and short messaging, and any other suitable Communication protocols, and may even include those protocols that have not yet been developed.
The WiFi module 125 is configured to transmit or receive a WiFi signal, and in particular, may establish a communication connection with a peripheral device through a Wireless Fidelity (WiFi) (e.g., IEEE 802.10A, IEEE802.11 b, IEEE802.11g, and/or IEEE802.11 n standards of the institute of electrical and electronics engineers), and the WiFi module 501 may include a power amplifier, a Wireless transceiver, a transceiver switch, a low noise amplifier, an antenna, and the like. When sending signals, the transceiver itself will directly output a low-Power weak rf signal, which is sent to a Power Amplifier (PA) for Power amplification, and then radiated to the space through an Antenna (Antenna) by a Transmit/Receive Switch (Transmit/Receive Switch). When receiving signals, the antenna senses electromagnetic signals in the space, and the electromagnetic signals are sent to a Low Noise Amplifier (LNA) for amplification after passing through the switcher, so that the amplified signals can be directly sent to the transceiver for processing and demodulation.
The audio circuitry 110, earpiece 101, sound jack 103, microphone 105 collectively provide an audio interface between a user and the electronic body portion 10 or the main display 120. Specifically, the audio circuit 110 receives sound data from the processor 102, converts the sound data into an electrical signal, and transmits the electrical signal to the earpiece 101. The earpiece 101 converts the electrical signal into sound waves that can be heard by the human ear. The audio circuitry 110 also receives electrical signals from the microphone 105, converts the electrical signals to sound data, and transmits the sound data to the processor 102 for further processing. Audio data may be retrieved from the memory 104 or through the RF module 106. In addition, audio data may also be stored in the memory 104 or transmitted through the RF module 106.
The sensor 114 is disposed in the electronic body portion 10 or the main display 120, examples of the sensor 114 include, but are not limited to: light sensors, operational sensors, pressure sensors, gravitational acceleration sensors, and other sensors.
Specifically, the sensors 114 may include a light sensor 114F and a pressure sensor 114G. Among them, the pressure sensor 114G may detect a pressure generated by pressing on the mobile terminal 100. That is, the pressure sensor 114G detects pressure generated by contact or pressing between the user and the mobile terminal, for example, contact or pressing between the user's ear and the mobile terminal. Accordingly, the pressure sensor 114G may be used to determine whether contact or pressing has occurred between the user and the mobile terminal 100, as well as the magnitude of the pressure.
The light sensor 114F and the pressure sensor 114G are disposed adjacent to the display panel 111. The light sensor 114F may turn off the display output when an object is near the main display 120, for example, when the electronic body portion 10 moves to the ear.
As one of the motion sensors, the gravity acceleration sensor can detect the magnitude of acceleration in various directions (generally three axes), detect the magnitude and direction of gravity when stationary, and can be used for applications (such as horizontal and vertical screen switching, related games, magnetometer attitude calibration), vibration recognition related functions (such as pedometer, tapping) and the like for recognizing the attitude of the mobile terminal 100. In addition, the electronic body 10 may also be configured with other sensors such as a gyroscope, a barometer, a hygrometer and a thermometer, which are not described herein,
in this embodiment, the input module 118 may include the display screen 109 disposed on the main display screen 120, and the display screen 109 may collect touch operations of the user (for example, operations of the user on or near the display screen 109 using any suitable object or accessory such as a finger, a stylus, etc.) and drive the corresponding connection device according to a preset program. Optionally, the display screen 109 may include a touch detection device and a touch controller. The touch detection device detects the touch direction of a user, detects a signal brought by touch operation and transmits the signal to the touch controller; the touch controller receives touch information from the touch detection device, converts the touch information into touch point coordinates, sends the touch point coordinates to the processor 102, and can receive and execute commands sent by the processor 102. In addition, various types such as resistive, capacitive, infrared, and surface acoustic wave can be used to implement the touch detection function of the display screen 109. In addition to the display 109, in other variations, the input module 118 may include other input devices, such as keys 107. The keys 107 may include, for example, character keys for inputting characters, and control keys for activating control functions. Examples of such control keys include a "back to home" key, a power on/off key, and the like.
The main display 120 is used to display information input by a user, information provided to the user, and various graphic user interfaces of the electronic main body part 10, which may be composed of graphics, text, icons, numbers, video, and any combination thereof, and in one example, the display 109 may be provided on the display panel 111 so as to be integrated with the display panel 111.
The power module 122 is used to provide power supply to the processor 102 and other components. Specifically, the power module 122 may include a power management system, one or more power sources (e.g., batteries or ac power), a charging circuit, a power failure detection circuit, an inverter, a power status indicator light, and any other components associated with the generation, management, and distribution of power within the electronic body portion 10 or the primary display 120.
The mobile terminal 100 further comprises a locator 119, the locator 119 being configured to determine an actual location of the mobile terminal 100. In this embodiment, the locator 119 implements the positioning of the mobile terminal 100 by using a positioning service, which is understood to be a technology or a service for obtaining the position information (e.g., longitude and latitude coordinates) of the mobile terminal 100 by using a specific positioning technology and marking the position of the positioned object on an electronic map.
It should be understood that the mobile terminal 100 described above is not limited to a smartphone terminal, but it should refer to a computer device that can be used in mobility. Specifically, the mobile terminal 100 refers to a mobile computer device equipped with an intelligent operating system, and the mobile terminal 100 includes, but is not limited to, a smart phone, a smart watch, a tablet computer, and the like.
In the description herein, reference to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the application. In this specification, the schematic representations of the terms used above are not necessarily intended to refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples. Furthermore, various embodiments or examples and features of different embodiments or examples described in this specification can be combined and combined by one skilled in the art without contradiction.
Furthermore, the terms "first", "second" and "first" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In the description of the present application, "plurality" means at least two, e.g., two, three, etc., unless specifically limited otherwise.
Any process or method descriptions in flow charts or otherwise described herein may be understood as representing modules, segments, or portions of code which include one or more executable instructions for implementing specific logical functions or steps of the process, and the scope of the preferred embodiments of the present application includes other implementations in which functions may be executed out of order from that shown or discussed, including substantially concurrently or in reverse order, depending on the functionality involved, as would be understood by those reasonably skilled in the art of the present application.
The logic and/or steps represented in the flowcharts or otherwise described herein, e.g., an ordered listing of executable instructions that can be considered to implement logical functions, can be embodied in any computer-readable medium for use by or in connection with an instruction execution system, apparatus, or device, such as a computer-based system, processor-containing system, or other system that can fetch the instructions from the instruction execution system, apparatus, or device and execute the instructions. For the purposes of this description, a "computer-readable medium" can be any means that can contain, store, communicate, propagate, or transport the program for use by or in connection with the instruction execution system, apparatus, or device. More specific examples (a non-exhaustive list) of the computer-readable medium would include the following: an electrical connection (mobile terminal) having one or more wires, a portable computer diskette (magnetic device), a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disc read-only memory (CDROM). Additionally, the computer-readable medium could even be paper or another suitable medium upon which the program is printed, as the program can be electronically captured, via for instance optical scanning of the paper or other medium, then compiled, interpreted or otherwise processed in a suitable manner if necessary, and then stored in a computer memory.
It should be understood that portions of the present application may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any one or combination of the following techniques, which are known in the art, may be used: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application specific integrated circuit having an appropriate combinational logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA), or the like.
It will be understood by those skilled in the art that all or part of the steps carried by the method for implementing the above embodiments may be implemented by hardware related to instructions of a program, which may be stored in a computer readable storage medium, and when the program is executed, the program includes one or a combination of the steps of the method embodiments. In addition, functional units in the embodiments of the present application may be integrated into one processing module, or each unit may exist alone physically, or two or more units are integrated into one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. The integrated module, if implemented in the form of a software functional module and sold or used as a stand-alone product, may also be stored in a computer readable storage medium.
The storage medium mentioned above may be a read-only memory, a magnetic or optical disk, etc. Although embodiments of the present application have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present application, and that variations, modifications, substitutions and alterations may be made to the above embodiments by those of ordinary skill in the art within the scope of the present application.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present application, and not to limit the same; although the present application has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; such modifications and substitutions do not necessarily depart from the spirit and scope of the corresponding technical solutions in the embodiments of the present application.
Claims (8)
1. A WiFi channel scanning method, the method comprising:
detecting an error vector magnitude of each of the plurality of supported WiFi channels by the mobile terminal before the mobile terminal leaves a factory;
storing the error vector magnitude of each WiFi channel to the local of the mobile terminal;
acquiring the error vector magnitude of each WiFi channel in a plurality of WiFi channels supported by the mobile terminal from the local of the mobile terminal;
when the error vector magnitudes of partial WiFi channels in the plurality of WiFi channels are equal, respectively detecting historical data of the partial WiFi channels, wherein the historical data comprises historical signal strength, historical transmission rate and historical congestion index;
scoring the partial WiFi channels based on the historical data;
sorting the partial WiFi channels from high to low according to the scores to obtain current partial WiFi channel sorting;
sorting the plurality of WiFi channels based on the current partial WiFi channel sorting and the error vector magnitude of each WiFi channel to obtain a current WiFi channel sorting;
and sequentially scanning the plurality of WiFi channels based on the current WiFi channel sequence.
2. The method of claim 1, wherein the sorting the WiFi channels based on the error vector magnitude of each WiFi channel to obtain a current WiFi channel ordering comprises:
and sequencing the plurality of WiFi channels from small to large according to the error vector magnitude of each WiFi channel to obtain the current WiFi channel sequencing.
3. The method of claim 2, wherein the sorting the WiFi channels by their error vector magnitude from small to large to obtain the current WiFi channel ordering comprises:
grading the communication quality of each WiFi channel based on the error vector magnitude of each WiFi channel to obtain a communication quality grading value of each WiFi channel;
and sequencing the plurality of WiFi channels according to the communication quality score values of each WiFi channel from high to low to obtain the current WiFi channel sequencing.
4. The method of claim 1, wherein after respectively detecting the historical data of the partial WiFi channels when the magnitudes of the error vectors of the partial WiFi channels in the plurality of WiFi channels are equal, further comprising:
judging whether WiFi which is connected with the mobile terminal is available in the part of WiFi channels;
and ordering the WiFi channels corresponding to the WiFi which is connected with the mobile terminal before the WiFi channels corresponding to the WiFi which is not connected with the mobile terminal.
5. The method of claim 1, wherein after scanning the plurality of WiFi channels based on the current WiFi channel ordering, further comprising:
and acquiring a target WiFi channel, and establishing connection with WiFi in the target WiFi channel.
6. An apparatus for WiFi channel scanning, the apparatus comprising:
an error vector magnitude detection module, configured to detect, before a mobile terminal leaves a factory, an error vector magnitude of each WiFi channel in the plurality of WiFi channels supported by the mobile terminal;
the error vector magnitude storage module is used for storing the error vector magnitude of each WiFi channel to the local of the mobile terminal;
an error vector magnitude obtaining module, configured to obtain, from a local area of the mobile terminal, an error vector magnitude of each WiFi channel in the plurality of WiFi channels supported by the mobile terminal;
a historical data detection submodule, configured to detect historical data of some WiFi channels in the multiple WiFi channels, when error vector magnitudes of the some WiFi channels are equal, respectively, where the historical data includes historical signal strength, historical transmission rate, and historical congestion index;
a scoring submodule for scoring the portion of the WiFi channels based on the historical data;
the second channel sorting submodule is used for sorting the partial WiFi channels from high to low according to the scores to obtain the current partial WiFi channel sorting;
a WiFi channel ordering module, configured to order the WiFi channels based on the current partial WiFi channel ordering and the error vector magnitude of each WiFi channel, to obtain a current WiFi channel ordering;
and the WiFi channel scanning module is used for scanning the plurality of WiFi channels in sequence based on the current WiFi channel sequence.
7. A mobile terminal comprising a display, a memory, and a processor, the display and the memory coupled to the processor, the memory storing instructions that, when executed by the processor, the processor performs the method of any of claims 1-5.
8. A computer-readable storage medium having program code executable by a processor, the program code causing the processor to perform the method of any one of claims 1-5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810604000.0A CN108811045B (en) | 2018-06-12 | 2018-06-12 | WiFi channel scanning method and device, mobile terminal and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810604000.0A CN108811045B (en) | 2018-06-12 | 2018-06-12 | WiFi channel scanning method and device, mobile terminal and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108811045A CN108811045A (en) | 2018-11-13 |
CN108811045B true CN108811045B (en) | 2021-03-02 |
Family
ID=64085299
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810604000.0A Expired - Fee Related CN108811045B (en) | 2018-06-12 | 2018-06-12 | WiFi channel scanning method and device, mobile terminal and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108811045B (en) |
Families Citing this family (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108924908B (en) * | 2018-06-12 | 2021-02-02 | Oppo广东移动通信有限公司 | WiFi scanning method and device and electronic device |
CN110225573A (en) * | 2019-06-03 | 2019-09-10 | Oppo广东移动通信有限公司 | WiFi channel scanning method and device, electronic equipment, computer readable storage medium |
CN113613310B (en) * | 2021-07-02 | 2023-10-13 | 深圳Tcl新技术有限公司 | WIFI connection method and device, storage medium and mobile terminal |
CN114302405B (en) * | 2021-12-29 | 2024-09-03 | 北京小米移动软件有限公司 | Network scanning method, device and storage medium |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101946543A (en) * | 2008-02-21 | 2011-01-12 | 日本电信电话株式会社 | Access point scan method, access point scan apparatus, and storage medium storing access point scan program |
CN102349334A (en) * | 2009-03-12 | 2012-02-08 | 高通股份有限公司 | Scanning channels while a device is out of service |
CN106063345A (en) * | 2014-03-27 | 2016-10-26 | 英特尔Ip公司 | Apparatus, system and method of selecting a wireless communication channel |
CN106792984A (en) * | 2016-11-29 | 2017-05-31 | 努比亚技术有限公司 | A kind of WIFI hot spot scanning connection control method and terminal |
CN106792993A (en) * | 2016-12-07 | 2017-05-31 | 广东欧珀移动通信有限公司 | Channel scanning method and mobile terminal |
Family Cites Families (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US9992766B2 (en) * | 2015-07-28 | 2018-06-05 | Arris Enterprises Llc | Utilizing active or passive buffered data metrics to mitigate streaming data interruption during dynamic channel change operations |
-
2018
- 2018-06-12 CN CN201810604000.0A patent/CN108811045B/en not_active Expired - Fee Related
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101946543A (en) * | 2008-02-21 | 2011-01-12 | 日本电信电话株式会社 | Access point scan method, access point scan apparatus, and storage medium storing access point scan program |
CN102349334A (en) * | 2009-03-12 | 2012-02-08 | 高通股份有限公司 | Scanning channels while a device is out of service |
CN106063345A (en) * | 2014-03-27 | 2016-10-26 | 英特尔Ip公司 | Apparatus, system and method of selecting a wireless communication channel |
CN106792984A (en) * | 2016-11-29 | 2017-05-31 | 努比亚技术有限公司 | A kind of WIFI hot spot scanning connection control method and terminal |
CN106792993A (en) * | 2016-12-07 | 2017-05-31 | 广东欧珀移动通信有限公司 | Channel scanning method and mobile terminal |
Also Published As
Publication number | Publication date |
---|---|
CN108811045A (en) | 2018-11-13 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10142845B2 (en) | Network connection method and apparatus, and computer storage medium | |
CN108811045B (en) | WiFi channel scanning method and device, mobile terminal and storage medium | |
CN108990105B (en) | Wireless communication transmission method, device, mobile terminal and computer readable storage medium | |
CN108513718B (en) | Network communication method and terminal | |
CN108668328B (en) | Network switching method and mobile terminal | |
CN108495349B (en) | Switching method of operator network and mobile terminal | |
CN108471622B (en) | WiFi connection adjustment method and device, mobile terminal and storage medium | |
CN113316206B (en) | Cell reselection method, device, terminal equipment and storage medium | |
CN108345422A (en) | Application control method, apparatus, mobile terminal and computer-readable medium | |
CN108924908B (en) | WiFi scanning method and device and electronic device | |
CN110740470B (en) | Measurement indication method, device and system | |
CN108770055B (en) | Transmission power adjusting method and device and electronic device | |
WO2018145477A1 (en) | Network access method and terminal | |
CN110324834B (en) | Indication method of measurement result, terminal and base station | |
CN108924868B (en) | WiFi disconnection adjusting method and device, mobile terminal and storage medium | |
CN108471630B (en) | Transmission rate adjustment method, device, mobile terminal, and computer-readable medium | |
CN110351702B (en) | System information area determining method, indicating method, terminal and network equipment | |
CN108848566B (en) | Wireless communication transmission method, device, mobile terminal and computer readable storage medium | |
CN108848557B (en) | Output power adjusting method, device, mobile terminal and computer readable medium | |
CN110602738B (en) | Network connection method and device and electronic device | |
CN108696917B (en) | Communication connection method, device, electronic device and computer readable medium | |
CN108965581B (en) | Transmission rate adjusting method, device, mobile terminal and storage medium | |
CN109040352B (en) | Antenna position adjusting method and device, mobile terminal and storage medium | |
CN108882335A (en) | Network connection method, device and electronic device | |
CN108668335B (en) | Communication connection method, device, mobile terminal and computer readable 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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20210302 |
|
CF01 | Termination of patent right due to non-payment of annual fee |