Signal processing method, electronic equipment, storage medium and signal processing module
By obtaining multiple channels of multiple channels in one Wi-Fi channel scan, frequency shift processing and filtering processing are performed, and target channel signals are identified, which solves the problem of low efficiency of electronic devices during Wi-Fi channel scanning, and realizes efficient channel scanning and low power consumption.
Patent Information
- Application Number
- CN202311056213.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-08-21
- Publication Date
- 2025-02-28
AI Technical Summary
When electronic devices perform Wi-Fi channel scanning, single-channel scanning efficiency is low, resulting in long scanning time and large power consumption.
Multi-channel signals of multiple channels are obtained in one Wi-Fi channel scan, and frequency shift processing is performed, single-channel signals of each channel are filtered out and target channel signals are identified.
It improves the efficiency of Wi-Fi channel scanning, reduces the delay time of network communication, improves the user experience, and saves the power consumption of channel scanning.
Smart Images

Figure CN119545476A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of communication technology, and in particular, to a signal processing method, an electronic device, a storage medium, and a signal processing module. Background Art
[0002] As a wireless network transmission technology, Wi-Fi is widely used in electronic devices such as mobile phones, tablet computers and laptops. Electronic devices can connect to the wireless network by accessing a nearby Wi-Fi access point (AP) to achieve wireless network communication and provide convenience for users to surf the Internet.
[0003] In order to achieve wireless network communication, electronic devices will perform Wi-Fi channel scanning to obtain signals transmitted through Wi-Fi channels. When performing channel scanning, electronic devices usually scan multiple channels separately and determine the required single channel signal from the signals transmitted by the multiple channels.
[0004] However, since the Wi-Fi channel scanning of electronic devices is usually a single-channel scanning, such as scanning one channel at a time, when the electronic device needs to scan multiple channels separately, the scanning times are relatively large, which will result in a longer scanning time and higher power consumption of the electronic device. Summary of the invention
[0005] The embodiments of the present application provide a signal processing method, an electronic device, a storage medium, and a signal processing module, which are used to improve the efficiency of Wi-Fi channel scanning of an electronic device and save power consumption of Wi-Fi channel scanning.
[0006] To achieve the above objectives, the embodiments of the present application adopt the following technical solutions:
[0007] In a first aspect, a signal processing method is provided. In a Wi-Fi channel scan, a multi-channel signal of n channels is obtained. The multi-channel signal is obtained by receiving a multi-channel signal through an antenna, where n is an integer greater than 1. Then, frequency shift processing is performed on the multi-channel signal to obtain a multi-channel signal after frequency shift processing. A single-channel signal corresponding to each channel in the n channels is filtered out from the multi-channel signal after frequency shift processing, and a target channel signal is identified in the single-channel signal corresponding to each channel in the n channels.
[0008] Through the above signal processing method, multiple channels can be scanned at one time, and the target channel signal can be identified in the multi-channel signal. The target channel signal includes a signal of the target protocol type. For example, the target channel signal includes a signal of the 802.11b protocol type. In this way, the efficiency of Wi-Fi channel scanning can be improved, the delay time of Wi-Fi network communication can be reduced, and the user experience can be improved.
[0009] In a possible implementation of the first aspect, the frequency-shifted multi-channel signals are respectively input into n sub-filtering units for filtering to obtain a single-channel signal output by each sub-filtering unit. Different sub-filtering units output single-channel signals corresponding to different channels.
[0010] In this implementation, each sub-filtering unit of the filtering unit filters out a single-channel signal, thereby implementing channel division processing of the multi-channel signal and filtering out the single-channel signal corresponding to each channel in the multi-channel signal.
[0011] In another possible implementation manner of the first aspect, resampling processing may be performed on the single-channel signal corresponding to each channel, and the sampling frequency of the single-channel signal may be resampled from a first sampling frequency to a second sampling frequency.
[0012] In this implementation, the sampling frequency of the single-channel signal can be changed through resampling processing, so that the sampling frequency of the single-channel signal meets the requirements of baseband processing or back-end processing.
[0013] In another possible implementation of the first aspect, a single-channel signal of the first sampling frequency corresponding to each channel can also be input into a corresponding sub-sampling unit among the n sub-sampling units for resampling processing to obtain a single-channel signal of the second sampling frequency output by each sub-sampling unit.
[0014] In this implementation, through the resampling process of each subsampling unit, the sampling frequency of the single-channel signal corresponding to each channel can be changed so that the sampling frequency of the single-channel signal meets the requirements of baseband processing or back-end processing.
[0015] In another possible implementation of the first aspect, after resampling the single-channel signal corresponding to each channel and resampling the sampling frequency of the single-channel signal from a first sampling frequency to a second sampling frequency, a received signal strength indication of the single-channel signal corresponding to each channel in n channels is obtained.
[0016] In this implementation, the received signal strength indication RSSI can be used to indicate the signal strength of the received signal. If the RSSI value of a single-channel signal is larger, it means that the signal strength of the single-channel signal is larger. If the RSSI value of a single-channel signal is smaller, it means that the signal strength of the single-channel signal is smaller. By obtaining the RSSI of the single-channel signal corresponding to each channel, the signal strength of the single-channel signal corresponding to each channel can be reflected.
[0017] In another possible implementation manner of the first aspect, after filtering out the single-channel signal corresponding to each of the n channels from the multi-channel signal after frequency shift processing, a received signal strength indication of the single-channel signal corresponding to each of the n channels may be obtained.
[0018] In this implementation, since the single-channel signal before resampling is more accurate than the single-channel signal after resampling, the received signal strength indicator of each single-channel signal calculated according to the single-channel signal output by each sub-filtering unit has better accuracy.
[0019] In another possible implementation of the first aspect, performing frequency shift processing on the multi-channel signal to obtain the multi-channel signal after the frequency shift processing includes: inputting the multi-channel signal into each frequency shift subunit of n frequency shift subunits respectively, performing frequency shift processing on the multi-channel signal by each frequency shift subunit, and obtaining the multi-channel signal after the frequency shift processing by each frequency shift subunit. The frequency shift frequencies of the frequency shift processing performed by different frequency shift subunits are different.
[0020] In this implementation, frequency shift processing with different frequency shift frequencies can be performed on multi-channel signals respectively through n frequency shift sub-units. The multi-channel signals after frequency shift processing obtained by different frequency shift sub-units have different frequency band ranges. In this way, the multi-channel signals after frequency shift processing obtained by different frequency shift sub-units can pass through sub-filter units with the same configuration, and single-channel signals of corresponding channels can be obtained through each sub-filter unit. In this way, the configuration of the sub-filter units can be simplified, and the signal processing flow can be simplified.
[0021] In another possible implementation manner of the first aspect, identifying a target channel signal in a single channel signal corresponding to each of the n channels includes: identifying the target channel signal in the single channel signal corresponding to each of the n channels according to a Barker code corresponding to the target protocol type.
[0022] In this implementation, the target channel signal can be identified by the Barker code corresponding to the target protocol type. The Barker code corresponding to the target protocol type can be a synchronization code corresponding to the 802.11b protocol, which can be used to distinguish signals of the target protocol type from signals of other protocol types. In this way, the target channel signal can be quickly identified in the single channel signals of each channel to achieve Wi-Fi network communication.
[0023] In another possible implementation of the first aspect, the method further includes: obtaining a received signal strength indicator of a target channel signal. According to the received signal strength indicator of the target channel signal, adjusting the gain of the radio frequency signal of the n channels. The radio frequency signal is converted into a multi-channel signal of the n channels after analog-to-digital conversion.
[0024] In this implementation, by adjusting the gain of the radio frequency signal, the signal strength of the target channel signal can be made within an appropriate signal strength range, thereby facilitating subsequent processing of the target channel signal.
[0025] In another possible implementation of the first aspect, obtaining a multi-channel signal of n channels includes: receiving radio frequency signals of n channels through an antenna, performing frequency mixing and analog-to-digital conversion on the radio frequency signals, and obtaining the multi-channel signal of n channels.
[0026] In this implementation, the RF signal received by the antenna can be processed in the RF domain through mixing processing and analog-to-digital conversion, and the RF signal can be processed into a multi-channel signal suitable for processing by the baseband module.
[0027] In another possible implementation manner of the first aspect, after performing mixing processing and analog-to-digital conversion on the RF signal to obtain a multi-channel signal of n channels, the method further includes: filtering out a DC signal in the multi-channel signal.
[0028] In this implementation, by filtering out the DC signal in the multi-channel signal, the influence of the DC signal on the multi-channel signal can be reduced, thereby improving the signal quality of the multi-channel signal.
[0029] In another possible implementation manner of the first aspect, n is equal to any one of 2, 3, 4, and 5.
[0030] In this implementation, in one Wi-Fi channel scan, multi-channel signals of 2, 3, 4 or 5 channels can be obtained at one time, and then the multi-channel signals are processed to complete the scanning of 2, 3, 4 or 5 channels at one time. In this way, the efficiency of Wi-Fi channel scanning can be greatly improved.
[0031] In another possible implementation manner of the first aspect, the target protocol type is the 802.11b protocol.
[0032] In this implementation, the 802.11b protocol is a protocol type for Wi-Fi network communication, and the target channel signal may include a signal of the 802.11b protocol type. The electronic device may implement Wi-Fi network communication through the target channel signal of the 802.11b protocol.
[0033] In a second aspect, the present application provides an electronic device, the electronic device comprising: an antenna, a memory and one or more processors. The antenna and the memory are respectively coupled to the processor. The antenna is used to receive single-channel or multi-channel signals.
[0034] The memory is used to store computer program codes, and the computer program codes include computer instructions. When the processor executes the computer instructions, the electronic device performs the following steps:
[0035] In a Wi-Fi channel scan, a multi-channel signal of n channels is obtained, wherein the multi-channel signal is obtained by receiving a multi-channel signal through an antenna, and the channel is a Wi-Fi channel; n is an integer greater than 1; frequency shift processing is performed on the multi-channel signal to obtain the multi-channel signal after the frequency shift processing; a single-channel signal corresponding to each channel in the n channels is filtered out from the multi-channel signal after the frequency shift processing; a target channel signal is identified from the single-channel signal corresponding to each channel in the n channels, wherein the target channel signal includes a signal of a target protocol type.
[0036] In a possible implementation of the second aspect, the electronic device includes a filtering unit, and the filtering unit includes n sub-filtering units. When the above computer instructions are executed by the processor, the electronic device further performs the following steps: inputting the multi-channel signal after the frequency shift processing into the n sub-filtering units for filtering processing, and obtaining a single-channel signal output by each sub-filtering unit, wherein different sub-filtering units output single-channel signals corresponding to different channels.
[0037] In another possible implementation of the second aspect, when the above-mentioned computer instructions are executed by the processor, the electronic device further performs the following steps: resampling the single-channel signal corresponding to each channel, and resampling the sampling frequency of the single-channel signal from the first sampling frequency to the second sampling frequency.
[0038] In another possible implementation of the second aspect, the electronic device includes a resampling unit, and the resampling unit includes n subsampling units. When the above computer instructions are executed by the processor, the electronic device further performs the following steps: inputting a single-channel signal of a first sampling frequency corresponding to each channel into a corresponding subsampling unit among the n subsampling units for resampling processing, and obtaining a single-channel signal of a second sampling frequency output by each subsampling unit.
[0039] In another possible implementation of the second aspect, when the above-mentioned computer instructions are executed by the processor, the electronic device further performs the following steps: after resampling the single-channel signal corresponding to each channel and resampling the sampling frequency of the single-channel signal from the first sampling frequency to the second sampling frequency, obtaining a received signal strength indication of the single-channel signal corresponding to each channel in the n channels.
[0040] In another possible implementation of the second aspect, when the above-mentioned computer instructions are executed by the processor, the electronic device further performs the following steps: after filtering out the single-channel signal corresponding to each of the n channels in the multi-channel signal after frequency shift processing, obtaining the received signal strength indication of the single-channel signal corresponding to each of the n channels.
[0041] In another possible implementation of the second aspect, when the above-mentioned computer instructions are executed by the processor, the electronic device further performs the following steps: inputting the multi-channel signal into each frequency shifting subunit of n frequency shifting subunits respectively, performing frequency shifting processing on the multi-channel signal by each frequency shifting subunit, and obtaining the multi-channel signal after the frequency shifting processing by each frequency shifting subunit; wherein, the frequency shifting frequencies of different frequency shifting subunits performing frequency shifting processing are different.
[0042] In another possible implementation manner of the second aspect, when the above-mentioned computer instructions are executed by the processor, the electronic device further performs the following steps: identifying the target channel signal in the single channel signal corresponding to each channel in the n channels according to the Barker code corresponding to the target protocol type;
[0043] In another possible implementation manner of the second aspect, when the above-mentioned computer instructions are executed by the processor, the electronic device further performs the following steps: obtaining a received signal strength indication of the target channel signal; adjusting the gain of the radio frequency signal of n channels according to the received signal strength indication of the target channel signal; wherein the radio frequency signal is converted into a multi-channel signal of n channels after analog-to-digital conversion.
[0044] In another possible implementation of the second aspect, when the above-mentioned computer instructions are executed by the processor, the electronic device further performs the following steps: receiving radio frequency signals of n channels through an antenna; performing mixing processing and analog-to-digital conversion on the radio frequency signals to obtain multi-channel signals of n channels.
[0045] In another possible implementation of the second aspect, when the above-mentioned computer instructions are executed by the processor, the electronic device further performs the following steps: performing mixing processing and analog-to-digital conversion on the radio frequency signal, obtaining a multi-channel signal of n channels, and then filtering out the DC signal in the multi-channel signal.
[0046] In another possible implementation manner of the second aspect, n is equal to any one of 2, 3, 4, and 5.
[0047] In another possible implementation manner of the second aspect, the target protocol type is the 802.11b protocol.
[0048] In a third aspect, the present application provides a computer-readable storage medium, comprising computer instructions, which, when executed on an electronic device, enables the electronic device to execute the method described in the first aspect and any possible implementation thereof.
[0049] In a fourth aspect, the present application provides a signal processing module, which is applied to an electronic device, and the electronic device includes an antenna, and the antenna is used to receive single-channel or multi-channel signals. The signal processing module includes a controller and a memory, and the memory is coupled to the controller. The memory stores a computer program code, and the computer program code includes computer instructions. When the computer instructions are executed by the controller, the signal processing module executes the method described in the first aspect and any possible implementation thereof.
[0050] In a fifth aspect, the present application provides a computer program product including program instructions, which, when executed on a computer, enables the computer to execute the method described in the first aspect and any possible implementation thereof. For example, the computer may be the electronic device described above.
[0051] In a sixth aspect, the present application provides a chip system, which is applied to an electronic device. The electronic device includes an antenna, which is used to receive single-channel or multi-channel signals. The chip system includes an interface circuit and a processor. The interface circuit and the processor are interconnected by a line. The interface circuit is used to receive a signal from a memory and send a signal to the processor, the signal including a computer instruction stored in the memory. When the processor executes the computer instruction, the electronic device executes the method described in the first aspect and any possible implementation thereof. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] Figure 1 A schematic diagram of channels in the 2.4 GHz frequency band of Wi-Fi communication provided in an embodiment of the present application;
[0053] Figure 2 A schematic diagram of an electronic device performing 2.4G Wi-Fi channel scanning provided by an embodiment of the present application;
[0054] Figure 3 A schematic diagram of an example of an electronic device scanning five channels at a time provided by an embodiment of the present application;
[0055] Figure 4 A hardware structure block diagram of a mobile phone 100, an example of an electronic device provided in an embodiment of the present application;
[0056] Figure 5 A block diagram of a signal processing module provided in an embodiment of the present application;
[0057] Figure 6 A flowchart of an example of a signal processing method provided in an embodiment of the present application;
[0058] Figure 7 A block diagram of another signal processing module provided in an embodiment of the present application;
[0059] Figure 8 A structural block diagram of a frequency shift processing example provided in an embodiment of the present application;
[0060] Fig. 9 A schematic diagram of an example of frequency shift processing provided in an embodiment of the present application;
[0061] Fig.10 A schematic diagram of an example of filtering out a single-channel signal provided in an embodiment of the present application;
[0062] Fig.11 A schematic diagram of an example of a frequency shift unit and a filter unit provided in an embodiment of the present application;
[0063] Fig.12 A schematic diagram of another example of filtering out a single-channel signal provided in an embodiment of the present application;
[0064] Fig.13 A schematic diagram of a resampling processing example provided in an embodiment of the present application;
[0065] Fig.14 A schematic diagram of an example of target channel signal identification provided in an embodiment of the present application;
[0066] Fig.15 A schematic diagram of another example of module interaction for signal processing provided in an embodiment of the present application;
[0067] Fig.16 A schematic diagram of another example of module interaction for signal processing provided in an embodiment of the present application. DETAILED DESCRIPTION
[0068] At present, electronic devices usually have Wi-Fi communication functions, and Wi-Fi communication can be achieved through Wi-Fi networks. The frequency bands used for Wi-Fi communication may include 2.4 gigahertz (GHz) bands and 5 GHz bands. The frequency bands used for Wi-Fi communication are usually divided into multiple channels (or Wi-Fi channels). Different channels have different central frequencies. The bandwidths of different channels can be the same, and adjacent channels may overlap or not overlap at all.
[0069] Taking the 2.4 GHz frequency band as an example, the 2.4 GHz frequency band used for Wi-Fi communication ranges from 2.4 GHz to 2.497 GHz. Figure 1As shown in FIG. 1 , the 2.4 GHz frequency band can be divided into 14 channels. These 14 channels can be sorted from low to high according to the frequency band covered by the channel, and are represented as channel 1, channel 2, channel 3, ..., channel 14. Among them, channel 1 to channel 13 are commonly used 2.4 GHz Wi-Fi channels.
[0070] In such Figure 1 In the example shown, the center frequency of each channel is also shown. The center frequency of channel 1 is 2412 MHz, the center frequency of channel 2 is 2417 MHz, the center frequency of channel 3 is 2422 MHz, the center frequency of channel 4 is 2427 MHz, the center frequency of channel 5 is 2432 MHz, the center frequency of channel 6 is 2437 MHz, the center frequency of channel 7 is 2442 MHz, the center frequency of channel 8 is 2447 MHz, the center frequency of channel 9 is 2452 MHz, the center frequency of channel 10 is 2457 MHz, the center frequency of channel 11 is 2462 MHz, the center frequency of channel 12 is 2467 MHz, the center frequency of channel 13 is 2472 MHz, and the center frequency of channel 14 is 2484 MHz.
[0071] In channels 1 to 13, the bandwidth of each channel is 22MHz. The frequency spacing between two adjacent channels is 5MHz. For example, the coverage frequency band of channel 1 is 2401MHz to 2423MHz. The coverage frequency band of channel 2 is 2406MHz to 2428MHz. And so on. The coverage frequency bands of two or more adjacent channels may partially overlap. For example, the coverage frequency bands of channel 1, channel 2, channel 3, channel 4 and channel 5 all overlap.
[0072] The electronic device can obtain the signal transmitted by the Wi-Fi network through Wi-Fi channel scanning to achieve Wi-Fi network communication. The following is an example to introduce the process of the electronic device performing 2.4G Wi-Fi channel scanning.
[0073] Please refer to Figure 2 , the electronic device may have an antenna, a radio frequency module and a baseband module. The antenna of the electronic device may be used to receive signals in the working frequency band. The working frequency band of the antenna may cover the 2.4 GHz frequency band. The signal received by the antenna may be an analog signal. Furthermore, the antenna may transmit the received signal to the radio frequency module, and the radio frequency module may process the signal in the radio frequency domain. For example, the radio frequency module may perform radio frequency domain processing such as amplification, mixing, and filtering on the signal. The radio frequency module may also perform analog-to-digital conversion on the processed signal, convert the signal into a digital signal and transmit it to the baseband module. The baseband module may parse the signal to obtain the protocol type of the signal to determine whether the signal is a Wi-Fi signal of the target protocol type.
[0074] It is understandable that the signals received by the electronic device on different channels may correspond to different protocol types. For example, in wireless communications in the 2.4GHz frequency band, the protocol types of the signal may include 802.11a, 802.11b, 802.11g, 802.11n, 802.11ax, etc. The baseband module of the electronic device can determine whether the signal is of the target protocol type (such as 802.11b) by parsing the signal. If the signal of a channel is of the target protocol type, the electronic device can confirm that the signal of the channel is a signal transmitted through the Wi-Fi network, thereby realizing Wi-Fi network communication.
[0075] However, when scanning Wi-Fi channels, electronic devices need to parse the signals received on each channel to achieve Wi-Fi network communication. For example, electronic devices scan channels 1, 2, ..., and n in sequence to determine the Wi-Fi signal of the target protocol type from the signals received on each channel. This will result in more Wi-Fi channel scans by electronic devices, longer scanning time, and higher power consumption.
[0076] In view of this, an embodiment of the present application provides a signal processing method that can improve the efficiency of electronic devices scanning channels, improve the rate at which electronic devices communicate over Wi-Fi networks, and save power consumption of channel scanning. Specifically, the electronic device can obtain signals of multiple channels (which can be referred to as multi-channel signals) in a Wi-Fi channel scan. In this way, compared to obtaining the signal of a single channel in a Wi-Fi channel scan, the speed of Wi-Fi channel scanning can be improved. After the electronic device obtains the signals of multiple channels, the electronic device can perform frequency shift processing on the multi-channel signal to change the frequency band range where the multi-channel signal is located. Then, the electronic device filters out the single-channel signal corresponding to each channel in the n channels from the multi-channel signal after the frequency shift processing. The electronic device then obtains the single-channel signal of the target protocol type from the single-channel signal corresponding to each channel.
[0077] In this way, the electronic device can scan multiple channels at one time when performing Wi-Fi channel scanning, which can improve the efficiency of the electronic device's Wi-Fi channel scanning, reduce the delay time of the electronic device communicating through the Wi-Fi network, and improve the user experience.
[0078] Here, the electronic device scans signals of n channels at a time. n is an integer greater than 1. For example, n is equal to 2, 3, 4, or 5. The electronic device can obtain multi-channel signals of 2, 3, 4, or 5 channels at a time, and then perform signal processing on the multi-channel signals to complete the scanning of 2, 3, 4, or 5 channels at a time. In this way, the efficiency of Wi-Fi channel scanning can be greatly improved.
[0079] For example, an electronic device scans five channels in the 2.4 GHz frequency band at one time. Figure 3 As shown, the electronic device may first scan channels 1 to 5 to implement the first Wi-Fi channel scan. Then, the electronic device scans channels 5 to 9 to implement the second Wi-Fi channel scan. Finally, the electronic device scans channels 9 to 13 to implement the third Wi-Fi channel scan.
[0080] It can be seen that the electronic device only needs to perform 3 scans to scan all channels (scan 13 channels). If the electronic device only scans 1 channel in each Wi-Fi channel scan, then the electronic device needs to perform 13 scans to scan all channels, that is, scan from channel 1 to channel 13 in sequence. It can be seen that the electronic device can reduce the number of Wi-Fi channel scans and improve the efficiency of channel scanning by scanning multiple channels at a time.
[0081] It is understandable that the 2.4 GHz frequency band may include 14 channels. Among these 14 channels, the commonly used channels are channels 1 to 13. Channel 14 is generally not used. Therefore, when the electronic device scans channels via Wi-Fi, it only needs to scan channels 1 to 13.
[0082] When scanning a single channel, the scanning bandwidth of the electronic device can be 20MHz. As mentioned above, the bandwidth of a channel is 22MHz. The effective bandwidth carrying data in this 22MHz bandwidth is 20MHz. The remaining 2MHz bandwidth is the isolation band from other channels. That is, the frequency band corresponding to the 1MHz bandwidth at the beginning of a channel and the frequency band corresponding to the 1MHz bandwidth at the end are the isolation bandwidth of the channel. When scanning a single channel, only the effective bandwidth of 20MHz can be scanned.
[0083] Similarly, when scanning multiple channels, the scanning bandwidth of the electronic device may also start from the effective bandwidth of one channel and end at the effective bandwidth of another channel. For example, when the electronic device scans two channels at a time, the bandwidth corresponding to channel 1 to channel 2 is 27 MHz, and the scanning bandwidth of the electronic device during scanning may be 25 MHz, and the electronic device scans from the effective bandwidth of channel 1 to the effective bandwidth of channel 2.
[0084] In the embodiment of the present application, the electronic device can implement multi-channel scanning of different channel numbers by adjusting the scanning bandwidth and center frequency of the Wi-Fi channel scanning. During multi-channel scanning, the scanning bandwidth and center frequency of the electronic device can be determined according to the number of channels scanned at one time.
[0085] Take scanning 5 channels at a time as an example. Figure 3As shown, the scanning bandwidth of the electronic device for scanning 5 channels at a time is 40 MHz. The central frequency point of the electronic device for Wi-Fi channel scanning is first switched from 2422 MHz to 2442 MHz, and finally switched from 2442 MHz to 2462 MHz.
[0086] The corresponding relationship between the number of channels scanned by the electronic device at one time and the scanning bandwidth of the Wi-Fi channel scan is shown in Table 1. It can be seen that if the electronic device scans 5 channels at one time, the scanning bandwidth of the channel is 40MHz. If the electronic device scans 4 channels at one time, the scanning bandwidth of the channel is 35MHz. If the electronic device scans 3 channels at one time, the scanning bandwidth of the channel is 30MHz. If the electronic device scans 2 channels at one time, the scanning bandwidth of the channel is 25MHz. If the electronic device scans 1 channel at one time, the scanning bandwidth of the channel is 20MHz.
[0087] Table 1 Wi-Fi channel scanning conditions corresponding to different Wi-Fi channel scanning numbers
[0088]
[0089] In addition to recording the number of channels scanned once and the corresponding scanning bandwidth, Table 1 also records the channel and center frequency of the first Wi-Fi channel scan.
[0090] Specifically, if 5 channels are scanned at a time, the channels of the first Wi-Fi channel scan of the electronic device are channels 1 to channel 5, and the center frequency of the first Wi-Fi channel scan is 2422MHz. If 4 channels are scanned at a time, the channels of the first Wi-Fi channel scan of the electronic device are channels 1 to channel 4, and the center frequency of the first Wi-Fi channel scan is 2419.5MHz. If 3 channels are scanned at a time, the channels of the first Wi-Fi channel scan of the electronic device are channels 1 to channel 3, and the center frequency of the first Wi-Fi channel scan is 2417MHz. If 2 channels are scanned at a time, the channels of the first Wi-Fi channel scan of the electronic device are channels 1 to channel 2, and the center frequency of the first Wi-Fi channel scan is 2414.5MHz. If 1 channel is scanned at a time, the channel of the first Wi-Fi channel scan of the electronic device is channel 1, and the center frequency of the first Wi-Fi channel scan is 2412MHz.
[0091] The electronic device can obtain the center frequency point and the scanning bandwidth signal corresponding to the number of scanned channels in a Wi-Fi channel scan. The signal received by the electronic device through the antenna is a radio frequency signal, which is a high-frequency signal. In order to facilitate signal processing, the electronic device can further perform radio frequency domain processing on the signal received through the antenna, so that the signal received through the antenna is converted from a radio frequency signal to a baseband signal with a lower frequency band.
[0092] After the electronic device converts the received signal from the RF signal to the baseband signal, the center frequency of each channel corresponding to the signal is also changed. For example, when the electronic device scans channels 1 to 5 in a Wi-Fi channel scan, the center frequency of the signals of multiple channels obtained by the electronic device is converted from 2422 MHz to 0 MHz.
[0093] The frequency band of the signal received by the electronic device corresponds to multiple channels. After the signal is processed in the RF domain, the center frequency points of the multiple channels included in the frequency band of the signal also change. The above Table 1 also records the center frequency points of each channel corresponding to different channel scan numbers after the RF domain processing.
[0094] If the channels of the first channel scan are channels 1 to 5, after RF domain processing, the center frequency of channel 1 is converted from 2412 MHz to -10 MHz, the center frequency of channel 2 is converted from 2417 MHz to -5 MHz, the center frequency of channel 3 is converted from 2422 MHz to 0 MHz, the center frequency of channel 4 is converted from 2427 MHz to 5 MHz, and the center frequency of channel 5 is converted from 2432 MHz to 10 MHz.
[0095] If the channels of the first channel scan are channels 1 to 4, after RF domain processing, the center frequency of channel 1 is converted from 2412 MHz to -7.5 MHz, the center frequency of channel 2 is converted from 2417 MHz to -2.5 MHz, the center frequency of channel 3 is converted from 2422 MHz to 2.5 MHz, and the center frequency of channel 4 is converted from 2427 MHz to 7.5 MHz.
[0096] If the channels of the first channel scan are channel 1 to channel 3, after RF domain processing, the center frequency of channel 1 is converted from 2412 MHz to -5 MHz, the center frequency of channel 2 is converted from 2417 MHz to 0 MHz, and the center frequency of channel 3 is converted from 2422 MHz to 5 MHz.
[0097] If the channels of the first channel scan are channel 1 to channel 2, after RF domain processing, the center frequency of channel 1 is converted from 2412 MHz to -2.5 MHz, and the center frequency of channel 2 is converted from 2417 MHz to 2.5 MHz.
[0098] If the first channel scan is channel 1, after RF domain processing, the center frequency of channel 1 is converted from 2412 MHz to 0.
[0099] In some implementations, the electronic device can automatically adjust the number of channels scanned at one time to achieve adaptive adjustment of the number of channels, so that the channel processing solution of the embodiment of the present application is applicable to more application scenarios.
[0100] In an example of this implementation, the electronic device determines the number of channels to be scanned at one time according to the load condition of the electronic device. The load condition is determined according to the number of processes currently running on the electronic device. The larger the number of processes currently running, the greater the load, and the smaller the number of channels to be scanned at one time. Conversely, the smaller the number of processes currently running, the smaller the load, and the larger the number of channels to be scanned at one time.
[0101] For example, when an electronic device receives a user operation indicating a Wi-Fi connection, the upper-layer process used for Wi-Fi connection in the electronic device can obtain the load condition of the electronic device, such as obtaining the number of processes currently running in the electronic device. If the number of currently running processes is less than the preset number, it means that the current load of the electronic device is small and the operating system of the electronic device is relatively idle. In this case, the upper-layer process of the electronic device can issue a channel scanning instruction, which instructs the RF module and baseband module of the electronic device to scan 4 or 5 channels at a time. If the number of currently running processes is less than the preset number, it means that the current load of the electronic device is large and the system is busy. In this case, the upper-layer process of the electronic device can issue a channel scanning instruction, which instructs the RF module and baseband module of the electronic device to scan 2 or 3 channels at a time. In this way, the electronic device can adjust the number of channels scanned at a time according to the current load condition.
[0102] In another example of this implementation, the electronic device determines the number of channels for this Wi-Fi channel scan according to the counted historical times of each channel carrying the target channel signal.
[0103] For example, the electronic device can count the historical number of times each channel in all channels (such as channel 1 to channel 13) carries the target channel signal. If the historical number of times channel n in all channels carries the target channel signal is greater than the preset number, the electronic device can scan n channels at a time in this Wi-Fi channel scan. If the historical number of times channel 3 carries the target channel signal is greater than 10 times (an example of a preset number of times), it indicates that the electronic device often performs Wi-Fi communications through channel 3. In this case, the electronic device can scan 3 channels at a time in this Wi-Fi channel scan to quickly confirm whether channel 3 carries the target channel signal.
[0104] Alternatively, if the number of times that channel m and channel n carry the target channel signal among all channels is greater than the preset number, the electronic device can scan n channels at a time in this Wi-Fi channel scan. Wherein, m and n are both integers greater than 1, and m is less than n. If the number of times that channel 3 and channel 5 carry the target channel signal is greater than 10 times, it indicates that the electronic device often performs Wi-Fi communication through channel 3 and channel 5. In this case, the electronic device can scan 5 channels at a time in this Wi-Fi channel scan to quickly confirm whether channel 3 and channel 5 carry the target channel signal.
[0105] In this way, the electronic device can adjust the number of channels for this channel scan according to the actual situation of the current Wi-Fi channel scan, which can improve the efficiency and adaptability of the Wi-Fi channel scan of the electronic device.
[0106] Of course, the number of channels scanned by the electronic device at one time may also be preset, and this application does not impose any limitation on this.
[0107] For example, the electronic device described in the embodiments of the present application may be a mobile phone, a tablet computer, a desktop computer, a laptop computer, a handheld computer, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, a cellular phone, a personal digital assistant (PDA), an augmented reality (AR) / virtual reality (VR) device, a media player, a wearable device, etc. The embodiments of the present application do not impose any special restrictions on the specific form of the electronic device.
[0108] In the embodiment of the present application, the electronic device is a mobile phone 100 as an example, and the hardware structure of the electronic device is introduced through the mobile phone 100. Figure 4As shown, the mobile phone 100 may include: a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charging management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, etc.
[0109] Among them, the processor 110 may include one or more processing units, for example: the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), a controller, a memory, a video codec, a digital signal processor (digital signal processor, DSP), a baseband processor, and / or a neural network processor (neural-network processing unit, NPU), a driver processor, etc. Among them, different processing units can be independent devices or integrated in one or more processors. The processor 110 can be the nerve center and command center of the mobile phone 100. The processor 110 can generate an operation control signal according to the instruction opcode and the timing signal to complete the control of fetching and executing instructions.
[0110] The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may store instructions or data that the processor 110 has just used or cyclically used. If the processor 110 needs to use the instruction or data again, it may be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.
[0111] The charging management module 140 is used to receive charging input from a charger. The charger can be a wireless charger or a wired charger. While the charging management module 140 charges the battery 142, it can also power the mobile phone 100 through the power management module 141.
[0112] The power management module 141 is used to connect the battery 142, the charging management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and / or the charging management module 140, and supplies power to the processor 110, the internal memory 121, the external memory, the display screen 194, the camera 193, and the wireless communication module 160. In some embodiments, the power management module 141 and the charging management module 140 can also be set in the same device.
[0113] The wireless communication function of the mobile phone 100 can be implemented through the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modem processor and the baseband processor. In some embodiments, the antenna 1 of the mobile phone 100 is coupled with the mobile communication module 150, and the antenna 2 is coupled with the wireless communication module 160, so that the mobile phone 100 can communicate with the network and other devices through wireless communication technology.
[0114] Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in mobile phone 100 can be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve the utilization of antennas. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antenna can be used in combination with a tuning switch.
[0115] The mobile communication module 150 can provide solutions for wireless communications including 2G / 3G / 4G / 5G, etc., applied to the mobile phone 100. The mobile communication module 150 may include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves from the antenna 1, and filter, amplify, etc. the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation.
[0116] The wireless communication module 160 can provide wireless communication solutions for application in the mobile phone 100, including wireless local area networks (WLAN) (such as Wi-Fi networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication technology (NFC), infrared technology (IR), etc.
[0117] The wireless communication module 160 may be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, modulates the electromagnetic wave signal and performs filtering, and sends the processed signal to the processor 110. The wireless communication module 160 may also receive a signal to be sent from the processor 110, modulate the signal, amplify the signal, and convert it into an electromagnetic wave for radiation via the antenna 2.
[0118] In the embodiment of the present application, the mobile phone 100 can realize Wi-Fi network communication through the wireless communication module 160. The wireless communication module 160 can receive radio frequency signals of multiple channels through the antenna 2, and perform analog-to-digital conversion, filtering and other processing on the radio frequency signals to obtain a single channel signal of a single channel.
[0119] The mobile phone 100 can implement audio functions such as music playing and recording through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the earphone interface 170D, and the application processor.
[0120] The sensor module 180 may include sensors such as a pressure sensor, a gyro sensor, an air pressure sensor, a magnetic sensor, an acceleration sensor, a Hall sensor, a touch sensor, an ambient light sensor, and a bone conduction sensor. The mobile phone 100 may collect various data through the sensor module 180 .
[0121] It is understandable that the interface connection relationship between the modules illustrated in this embodiment is only a schematic illustration and does not constitute a structural limitation on the electronic device. In other embodiments, the electronic device may also include more or fewer modules than those provided in the above embodiments, and different interface connection methods in the above embodiments may be used between the modules, or a combination of multiple interface connection methods. The hardware structure of the electronic device provided in the embodiments of the present application can also refer to the hardware structure of the mobile phone 100 as shown in the figure. The methods in the following embodiments can all be implemented in an electronic device having the above hardware structure.
[0122] In order to better understand the method provided in the embodiment of the present application, the embodiment of the present application first combines Figure 4 The mobile phone 100 shown in the figure introduces the signal processing process. Figure 5 As shown, a schematic diagram of an example of module interaction of signal processing provided by an embodiment of the present application. In this example, the wireless communication module 160 of the mobile phone 100 may include a radio frequency module and a baseband module. The radio frequency module includes a radio frequency processing unit and an analog-to-digital conversion unit. The baseband module may include a DC filtering unit, a frequency shifting unit, a resampling unit, a filtering unit, a carrier sensing unit, a gain adjustment unit, and a digital gain unit. The functions of each unit are introduced below:
[0123] The RF processing unit can be used to receive RF signals and perform the following processing on the received RF signals: signal amplification, mixing processing, filtering and other processing, and transmit the processed RF signals to the analog-to-digital conversion unit.
[0124] The analog-to-digital conversion unit is used to perform analog-to-digital conversion processing on the radio frequency signal, and convert the analog radio frequency signal into a digital signal. The digital signal can be a multi-channel signal of multiple channels.
[0125] The DC filtering unit is used to filter out DC signals from multi-channel signals.
[0126] The frequency shift unit is used to perform frequency shift processing on the multi-channel signal to obtain the multi-channel signal after frequency shift processing. Among the multiple channels corresponding to the multi-channel signal after frequency shift processing, the center frequency point of one channel is the preset center frequency point.
[0127] The resampling unit is used to resample the multi-channel signal and convert the sampling frequency of the multi-channel signal from a first sampling frequency to a second sampling frequency. The second sampling frequency is the sampling frequency required by the baseband module, so that the baseband module resamples the multi-channel signal so that the sampling frequency of the multi-channel signal after the resampling process meets the requirements of the baseband module.
[0128] The filtering unit is used to filter out a plurality of single-channel signals from a multi-channel signal.
[0129] The carrier sensing unit is used to determine a target channel signal of a target protocol type among each single channel signal.
[0130] The digital gain unit is used to adjust the gain of the target channel signal so that the signal strength of the target channel signal remains within the first preset signal strength range, so as to facilitate the subsequent processing of the target channel signal by the mobile phone 100. For example, the mobile phone 100 processes, forwards or stores the data carried by the target channel signal.
[0131] The gain adjustment unit is used to adjust the gain of the radio frequency signal according to the multi-channel signal and / or the target channel signal so that the signal strength of the radio frequency signal is within a second preset signal strength range.
[0132] Here, the functions of each unit in the signal processing method provided by the embodiment of the present application are summarized by an example. The interaction process and specific implementation method of each unit will be described below and will not be repeated here.
[0133] It is to be understood that the above examples are only illustrative of the various units in the signal processing method provided in the embodiment of the present application. In some implementations, the various units in the RF module and the various units in the baseband module can be adaptively increased or decreased, and the order of the various units can also be changed. Each module or unit can be flexibly configured according to actual needs or application scenarios, and the embodiment of the present application does not limit this.
[0134] In some implementations, the baseband module of the mobile phone 100 may not include a DC filtering unit.
[0135] In some other implementations, the resampling unit in the baseband module of the mobile phone 100 may be placed before the frequency shifting unit.
[0136] In some other implementations, the positions of the resampling unit and the filtering unit in the baseband module of the mobile phone 100 may be interchanged.
[0137] In some other implementations, the analog-to-digital conversion unit may be disposed in a baseband module of the mobile phone 100 instead of in a radio frequency module.
[0138] In other implementations, the analog-to-digital conversion unit may be provided as an independent module between the radio frequency module and the baseband module of the mobile phone 100. The analog-to-digital conversion unit belongs neither to the radio frequency module nor to the baseband module.
[0139] The following describes the method provided by the embodiment of the present application through an embodiment. In this implementation, the wireless communication module in the mobile phone may include Figure 5 The structure of the wireless communication module can be found in Figure 7 In this implementation, the baseband module of the mobile phone obtains multi-channel signals of n channels of 2.4G Wi-Fi in one Wi-Fi channel scan. For example, if n is 5, the mobile phone scans 5 channels at a time. Figure 6 As shown, the method provided in the embodiment of the present application may include the following steps:
[0140] S601, the mobile phone receives a radio frequency signal through an antenna.
[0141] When the mobile phone is connected to a Wi-Fi network, it can first scan the channels of the Wi-Fi network. When the mobile phone performs a Wi-Fi channel scan, it can scan 5 channels at a time. As shown in Table 1, when the number of Wi-Fi channels to be scanned is 5, the channel scanning bandwidth is 40MHz. The mobile phone can perform a channel scan with a scanning bandwidth of 40MHz. When the mobile phone performs a channel scan with a scanning bandwidth of 40Hz, the RF module of the mobile phone can receive RF signals from 5 channels. For example, the mobile phone scans channels 1 to 5, and the RF module of the mobile phone receives RF signals from channels 1 to 5.
[0142] Here, the signals of multiple channels that the mobile phone can receive through the antenna are radio frequency signals. The radio frequency module of the mobile phone can receive radio frequency signals of 5 channels transmitted by the antenna.
[0143] It is understandable that the mobile phone scans 5 channels at a time, and can first scan channels 1 to 5 to achieve the first Wi-Fi channel scan. Then the mobile phone scans channels 5 to 9 to achieve the second Wi-Fi channel scan. Finally, the mobile phone scans channels 9 to 13 to achieve the third Wi-Fi channel scan. Through three scans, the mobile phone can scan all channels of 2.4G Wi-Fi.
[0144] During the Wi-Fi channel scanning process, the scanning bandwidth used by the mobile phone is 40MHz. At the same time, the center frequency of the mobile phone for Wi-Fi channel scanning can be switched from 2422MHz to 2442MHz, and then from 2442MHz to 2462MHz. The mobile phone can switch the center frequency of the Wi-Fi channel scan through the local oscillator of the radio frequency to achieve scanning of different frequency bands. In the embodiment of the present application, the method provided in the embodiment of the present application is introduced by taking the mobile phone performing a Wi-Fi channel scan as an example. The process of other channel scans is the same as the process of this channel scan, which will not be repeated here.
[0145] S602, the mobile phone performs mixing processing and analog-to-digital conversion on the radio frequency signal to obtain a multi-channel signal of a first sampling frequency from five channels.
[0146] After receiving the RF signal through the antenna, the RF module of the mobile phone further performs mixing processing and analog-to-digital conversion (ADC) on the RF signal to convert the RF signal into a multi-channel signal suitable for processing by the baseband module. The multi-channel signal sampling frequency is the first sampling frequency.
[0147] For example, Figure 7As shown, the RF processing unit of the RF module receives the RF signal transmitted by the antenna, and performs RF domain processing such as low-noise amplification, mixing and low-pass filtering on the RF signal to obtain a baseband signal. Among them, the mixing process is used to reduce the signal frequency, which can also be called down-conversion processing. In the process of performing RF domain processing on the RF signals of the five channels, the RF processing unit converts the RF signal into a baseband signal through mixing.
[0148] It is understandable that the RF signal is a high-frequency signal, and the frequency band range corresponding to the RF signal is the 2.4G frequency band range. For the baseband module, the signal usually processed is a baseband signal in a lower frequency band range (such as a frequency band range near 0MHz). The baseband signal is a signal with a frequency band range near zero frequency, which is suitable for the processing requirements of the baseband module. Through mixing processing, the RF processing unit can convert the RF signal in the 2.4G frequency band range into a baseband signal.
[0149] For example, the five channels scanned by the mobile phone are channel 1 to channel 5, and the frequency band corresponding to the RF signal is 2402 MHz to 2442 MHz. The RF processing unit performs mixing processing on the RF signal to obtain a baseband signal with a frequency band ranging from -20 MHz to 20 MHz.
[0150] The baseband signal obtained by the RF processing unit mixing the RF signal is an analog signal. Furthermore, the RF processing unit of the RF module transmits the baseband signal obtained after the mixing process to the analog-to-digital conversion unit, and the analog-to-digital conversion unit converts the analog baseband signal into a digital baseband signal. The digital baseband signal can be used as a multi-channel signal of 5 channels received by the baseband module.
[0151] During the analog-to-digital conversion process of the analog baseband signal, the analog baseband signal is sampled at a first sampling frequency to obtain a digital multi-channel signal. The sampling frequency of the multi-channel signal is the first sampling frequency. For example, the sampling frequency of the multi-channel signal is 80 MHz (an example of the first sampling frequency). After the analog-to-digital conversion unit of the mobile phone performs analog-to-digital conversion on the analog baseband signal to obtain a digital multi-channel signal, the obtained multi-channel signal can be transmitted to the baseband module for baseband processing.
[0152] In some implementations, in order to make the number of bits of the multi-channel signal received by the baseband module within an appropriate range of bits, the mobile phone may also adjust the gain of the RF signal according to the multi-channel signal obtained after analog-to-digital conversion.
[0153] For example, Figure 5As shown, the multi-channel signal output by the analog-to-digital conversion unit of the RF module can be input to the gain adjustment unit. The gain adjustment unit can obtain the number of bits of the multi-channel signal. If the number of bits of the multi-channel signal is greater than or equal to the first preset number of bits, the gain adjustment unit can reduce the gain of the RF signal to reduce the number of bits of the multi-channel signal of the next frame. If the number of bits of the multi-channel signal is less than or equal to the second preset number of bits, the gain adjustment unit can increase the gain of the RF signal to increase the number of bits of the multi-channel signal of the next frame. If the number of bits of the multi-channel signal is between the first preset number of bits and the second preset number of bits, the gain adjustment unit can maintain the gain of the RF signal to keep the number of bits of the multi-channel signal of the next frame within a suitable range of bits (such as the first preset number of bits to the second preset number of bits).
[0154] In this way, the multi-channel signal acquired by the baseband module of the mobile phone can be maintained at an appropriate number of bits, thereby facilitating the baseband module of the mobile phone to process the multi-channel signal.
[0155] It is understandable that the first preset number of bits and the second preset number of bits can be set according to actual application scenarios or requirements. For example, the first preset number of bits can be set to 10 bits, and the second preset number of bits can be set to 6 bits.
[0156] S603, the mobile phone performs frequency shift processing on the multi-channel signal of the first sampling frequency to obtain a multi-channel signal after frequency shift processing.
[0157] After acquiring the multi-channel signal of the first sampling frequency, the mobile phone can perform frequency shift processing on the multi-channel signal of the first sampling frequency, and transform the multi-channel signal of the first sampling frequency from the center frequency of at least one channel to a preset center frequency. The frequency shift processing can include digital down conversion (DDC) processing.
[0158] For example, Figure 7 As shown, in the baseband module of the mobile phone, the frequency shift unit is connected to the RF module. The frequency shift unit of the mobile phone can receive a multi-channel signal of 88MHz (an example of the first sampling frequency), and perform frequency shift processing on the multi-channel signal to obtain a multi-channel signal after frequency shift processing. Among the five channels corresponding to the multi-channel signal after frequency shift processing, the center frequency of one channel is the preset center frequency 0 (an example of the preset center frequency).
[0159] For example, Fig. 9As shown, before the frequency shift processing, the center frequencies of channels 1 to 5 in the multi-channel signal are -10MMHz, -5MMHz, 0MMHz, 5MMHz and 10MMHz respectively. The mobile phone performs a frequency shift processing on the multi-channel signal with a frequency shift frequency of -10MMHz through a frequency shift unit to obtain a multi-channel signal after the frequency shift processing. The frequency shift frequency is the change value of the frequency band in which the multi-channel signal is located before and after the frequency shift processing. The center frequencies of channels 1 to 5 in the multi-channel signal obtained after the frequency shift processing are -20MHz, -15MHz, -10MHz, -5MHz, and 0MHz respectively. Among them, the center frequency of channel 5 changes from 10MHz to 0MHz (an example of a preset center frequency).
[0160] Here, the preset center frequency can be set according to the actual application scenario or demand. For example, the preset center frequency can be 0MHz. Taking the 5 channels scanned by the mobile phone this time as channel 1 to channel 5, and the preset center frequency is 0MHz, the frequency band of the multi-channel signal obtained by the baseband module of the mobile phone is -20MMHz to 20MMHz. The center frequencies of channels 1 to 5 included in this frequency band are -10MMHz, -5MMHz, 0MMHz, 5MMHz and 10MMHz respectively. The frequency shifting unit of the baseband module performs frequency shifting processing on the multi-channel signal so that the center frequency of one channel (such as the center frequency of channel 1) in channels 1 to channel 5 corresponding to the multi-channel signal after the frequency shifting processing becomes 0.
[0161] Exemplarily, the frequency shift unit of the mobile phone may include multiple frequency shift subunits. Each frequency shift subunit is used to perform frequency shift processing on the multi-channel signal to obtain the multi-channel signal after the frequency shift processing. The frequency shift frequencies of the frequency shift processing performed by different frequency shift units are different. The frequency band ranges corresponding to the multi-channel signals after the frequency shift processing obtained by different frequency shift units are also different. Figure 8 As shown, the frequency shift unit of the mobile phone may include frequency shift subunit 1, frequency shift subunit 2, frequency shift subunit 3, frequency shift subunit 4 and frequency shift subunit 5.
[0162] The frequency shift subunit 1 is used to perform frequency shift processing on the multi-channel signal with a frequency shift frequency of 10MMHz to obtain a multi-channel signal after frequency shift processing (which can be represented as multi-channel signal 1). The center frequency points of channels 1 to 5 included in the frequency band of multi-channel signal 1 are changed to 0MHz, 5MHz, 10MHz, 15MHz, and 20MHz respectively. Among channels 1 to 5 corresponding to multi-channel signal 1, the center frequency point of channel 1 is changed from -10MMHz to the preset center frequency point 0MHz.
[0163] The frequency shift subunit 2 performs frequency shift processing on the multi-channel signal with a frequency shift frequency of 5MMHz to obtain a multi-channel signal after frequency shift processing (which can be expressed as multi-channel signal 2). The center frequency points of channels 1 to 5 included in the frequency band of multi-channel signal 2 are changed to -5MHz, 0MHz, 5MHz, 10MHz, and 15MHz respectively. Among channels 1 to 5 corresponding to multi-channel signal 2, the center frequency point of channel 2 is changed from -5MMHz to the preset center frequency point 0MHz.
[0164] The frequency shift subunit 3 is used to perform frequency shift processing on the multi-channel signal with a frequency shift frequency of 0MMHz, and obtain the multi-channel signal after the frequency shift processing (which can be expressed as multi-channel signal 3). Since the center frequency point 0MMHz of channel 3 is the same as the preset center frequency point 0MHz, the center frequency points of each channel corresponding to the multi-channel signal after the frequency shift processing obtained by the frequency shift subunit 3 (which can be expressed as multi-channel signal 3) remain unchanged. The center frequency points of channels 1 to 5 included in the frequency band of multi-channel signal 3 are changed to -10MHz, -5MHz, 0MHz, 5MHz, and 10MHz respectively.
[0165] The frequency shift subunit 4 is used to perform frequency shift processing on the multi-channel signal with a frequency shift frequency of -5MMHz, and obtain a multi-channel signal after frequency shift processing (which can be expressed as multi-channel signal 4). The center frequency points of channels 1 to 5 included in the frequency band of the multi-channel signal 4 are changed to -15MHz, -10MHz, -5MHz, 0MHz, and 5MHz respectively. Among channels 1 to 5 corresponding to the multi-channel signal 4, the center frequency point of channel 4 is changed from 5MMHz to the preset center frequency point 0MHz.
[0166] The frequency shift subunit 5 is used to perform frequency shift processing on the multi-channel signal with a frequency shift frequency of -15MMHz, and obtain a multi-channel signal after frequency shift processing (which can be expressed as multi-channel signal 5). The center frequency points of channels 1 to 5 included in the frequency band of the multi-channel signal 5 are changed to -20MHz, -15MHz, -10MHz, -5MHz, and 0MHz respectively. Among channels 1 to 5 corresponding to the multi-channel signal 5, the center frequency point of channel 5 is changed from 10MMHz to the preset center frequency point 0MHz.
[0167] It is understandable that the frequency shift unit of the mobile phone performs frequency shift processing on the multi-channel signal, which can cause the frequency band where the multi-channel signal is located to change by a certain moving step length, and at the same time, the center frequency points of the multiple channels corresponding to the multi-channel signal also change by the same moving step length. Among the multiple channels corresponding to the multi-channel signal after the frequency shift processing obtained by each frequency shift unit, the center frequency point of one channel changes to a preset center frequency point. In this way, the mobile phone can perform the same subsequent processing on the multi-channel signals obtained in different frequency bands through the same module or unit, thereby simplifying the signal processing process and improving the efficiency of channel scanning.
[0168] In other examples, since the center frequency of channel 3 among channels 1 to 5 corresponding to the multi-channel signal before frequency shift processing is the same as the preset center frequency 0 MHz, the frequency shift subunit 3 may not be set in the frequency shift unit of the mobile phone.
[0169] In other examples, the preset center frequency may correspond to the center frequency of the passband of the filter unit, so that the filter unit can filter out the single-channel signal corresponding to the channel whose center frequency is the preset center frequency from the multi-channel signal.
[0170] For example, the passing frequency band corresponding to the sub-filter unit 1 in the filtering unit is -15MHz to 5MHz, and the center frequency of the passing frequency band is -5MHz. Then the frequency shifting unit can perform a 5MHz frequency shifting process on the multi-channel signal to obtain a multi-channel signal 1 after the frequency shifting process. In channels 1 to 5 corresponding to the multi-channel signal 1, the center frequency of channel 1 changes from -10MHz to the preset center frequency -5MHz. Furthermore, the filtering unit of the mobile phone filters out the multi-channel signal 1 through the sub-filter unit 1, and can filter out the single-channel signal 1 corresponding to channel 1 with a center frequency of -5MHz and a bandwidth of 20MHz.
[0171] For another example, the pass frequency band corresponding to the sub-filter unit 2 in the filter unit is -10MHz to 10MHz, and the center frequency of the pass frequency band is 0MHz. Then the frequency shift unit can perform a 10MHz frequency shift process on the multi-channel signal to obtain a multi-channel signal 2 after the frequency shift process. In channels 1 to 5 corresponding to the multi-channel signal 1, the center frequency of channel 2 changes from -10MHz to the preset center frequency 0MHz. Furthermore, the filter unit of the mobile phone filters out the multi-channel signal 2 through the sub-filter unit 2, and can filter out the single-channel signal 2 corresponding to channel 2 with a center frequency of 0MHz and a bandwidth of 20MHz.
[0172] S604, the mobile phone inputs the multi-channel signal after the frequency shift processing into the filtering unit for filtering processing, and obtains a single-channel signal of the first sampling frequency corresponding to each channel in the five channels.
[0173] After frequency shifting the multi-channel signal, the mobile phone can divide the single-channel signal corresponding to each channel from the multi-channel signal. The filter unit in the baseband module of the mobile phone is connected to the frequency shift unit. The mobile phone can input the multi-channel signal after frequency shifting into the filter unit, and filter the multi-channel signal through the filter unit. The filtering process is used to filter out the single-channel signal corresponding to each channel from the multi-channel signal after frequency shifting. After filtering, the mobile phone can obtain the single-channel signal corresponding to each of the five channels.
[0174] Here, since the frequency shift processing and the filtering processing do not change the sampling frequency, the sampling frequency of the single-channel signal corresponding to each channel output by the filtering unit is the same as the sampling frequency of the multi-channel signal. The sampling frequency of the single-channel signal corresponding to each channel is equal to the first sampling frequency.
[0175] For example, Figure 7 As shown, the filtering unit of the mobile phone may include multiple sub-filtering units. Each sub-filtering unit may be a low pass filter (LPF). The number of sub-filtering units is the same as the number of channels scanned once, that is, the filtering unit includes 5 sub-filtering units. These 5 sub-filtering units can be respectively represented as sub-filtering unit 1 (represented as LPF1), sub-filtering unit 2 (represented as LPF2), sub-filtering unit 3 (represented as LPF3), sub-filtering unit 4 (represented as LPF4), and sub-filtering unit 5 (represented as LPF5).
[0176] Each sub-filter unit can filter out a single-channel signal corresponding to a channel in a multi-channel signal. The effective bandwidth of a channel is 20 MHz, so the pass bandwidth of each sub-filter unit can also be set to 20 MHz. The sampling frequency of the single-channel signal of a channel is 80 MHz (an example of the first sampling frequency).
[0177] The following is an example to illustrate the process of each sub-filter unit filtering out a single-channel signal corresponding to a channel in a multi-channel signal. Fig.10 As shown, in the multi-channel signal obtained after the frequency shift unit performs a frequency shift on the multi-channel signal, the center frequencies of channels 1 to 5 are 0MHz, 5MHz, 10MHz, 15MHz, and 20MHz respectively. After passing through the 5 sub-filtering units of the filtering unit, the mobile phone can obtain single-channel signals corresponding to the 5 channels respectively.
[0178] For sub-filter unit 1, sub-filter unit 1 is used to filter out the single-channel signal corresponding to channel 1. In this case, the mobile phone can set the passband of sub-filter unit 1 to -10MHz to 10MHz. After filtering the multi-channel signal, the sub-filter unit 1 (LPF1) of the mobile phone can filter out the single-channel signal corresponding to channel 1 with a center frequency of 0MHz and a bandwidth of 20MHz (which can be expressed as single-channel signal 1).
[0179] For sub-filter unit 2, sub-filter unit 2 is used to filter out the single-channel signal corresponding to channel 2. In this case, the mobile phone can set the passband of sub-filter unit 2 to -5MHz to 15MHz. After filtering the multi-channel signal, the sub-filter unit 2 (LPF2) of the mobile phone can filter out the single-channel signal corresponding to channel 2 with a center frequency of 5MHz and a bandwidth of 20MHz (which can be expressed as single-channel signal 2).
[0180] For sub-filter unit 3, sub-filter unit 3 is used to filter out the single-channel signal corresponding to channel 3. In this case, the mobile phone can set the passband of sub-filter unit 3 to 0MHz to 20MHz. After the sub-filter unit 3 (LPF3) of the mobile phone filters the multi-channel signal, it can filter out the single-channel signal corresponding to channel 3 with a center frequency of 10MHz and a bandwidth of 20MHz (which can be expressed as single-channel signal 3).
[0181] For sub-filter unit 4, sub-filter unit 4 is used to filter out the single-channel signal corresponding to channel 4. In this case, the mobile phone can set the passband of sub-filter unit 4 to 5MHz to 25MHz. After filtering the multi-channel signal, sub-filter unit 4 (LPF4) of the mobile phone can filter out the single-channel signal corresponding to channel 4 with a center frequency of 15MHz and a bandwidth of 20MHz (which can be expressed as single-channel signal 4).
[0182] For the sub-filter unit 5, the sub-filter unit 5 is used to filter out the single-channel signal corresponding to the channel 5. In this case, the mobile phone can set the passband of the sub-filter unit 5 to 20MHz to 25MHz. After filtering the multi-channel signal, the sub-filter unit 5 (LPF5) of the mobile phone can filter out the single-channel signal corresponding to the channel 5 with a center frequency of 20MHz and a bandwidth of 20MHz (which can be expressed as a single-channel signal 5).
[0183] In order to simplify the configuration of the filter unit, in some implementations, the mobile phone can uniformly configure the sub-filter units in the filter unit and set the passband of each sub-filter unit to -10MHz to 10MHz. Figure 8 As shown, each frequency shift subunit in the frequency shift unit of the mobile phone will output a multi-channel signal. The multi-channel signals output by different frequency shift subunits are located in different frequency bands. Each sub-filter unit of the filter unit of the mobile phone filters out a single channel signal corresponding to each channel.
[0184] For example, Fig.11 As shown, the filtering unit of the mobile phone may include sub-filtering unit 1, sub-filtering unit 2, sub-filtering unit 3, sub-filtering unit 4, and sub-filtering unit 5. Each sub-filtering unit is used to filter out a single channel signal of a corresponding channel.
[0185] Sub-filter unit 1 is connected to frequency shift sub-unit 1. Sub-filter unit 1 is used to receive multi-channel signal 1 output by frequency shift sub-unit 1. The center frequencies of channels 1 to 5 corresponding to multi-channel signal 1 are 0MHz, 5MHz, 10MHz, 15MHz, and 20MHz respectively. Fig.12As shown, the center frequency of channel 1 in the frequency band of multi-channel signal 1 changes to the preset center frequency 0 MHz. In this case, the mobile phone can filter out the single channel signal 1 corresponding to channel 1 with a center frequency of 0 MHz and a bandwidth of 20 MHz from the multi-channel signal 1 through the sub-filter unit 1.
[0186] The sub-filter unit 2 is connected to the frequency shift sub-unit 2. The sub-filter unit 2 is used to receive the multi-channel signal 2 output by the frequency shift sub-unit 2. The center frequencies of channels 1 to 5 corresponding to the multi-channel signal 2 are -5MHz, 0MHz, 5MHz, 10MHz, and 15MHz, respectively. The center frequency of channel 2 in the frequency band of the multi-channel signal 2 is changed to the preset center frequency 0MHz. In this case, the mobile phone can filter out the single-channel signal 2 corresponding to channel 2 with a center frequency of 0MHz and a bandwidth of 20MHz in the multi-channel signal 2 through the sub-filter unit 2.
[0187] The sub-filter unit 3 is connected to the frequency shift sub-unit 3. The sub-filter unit 3 is used to receive the multi-channel signal 3 output by the frequency shift sub-unit 3. The center frequencies of channels 1 to 5 in the frequency band of the multi-channel signal 3 are -10MMHz, -5MMHz, 0MMHz, 5MMHz and 10MMHz respectively. The center frequency of channel 3 in the frequency band of the multi-channel signal 3 is changed to the preset center frequency 0MHz. In this case, the mobile phone can filter out the single-channel signal 3 corresponding to channel 3 with a center frequency of 0MHz and a bandwidth of 20MHz in the multi-channel signal 3 through the sub-filter unit 3.
[0188] The sub-filter unit 4 is connected to the frequency shift sub-unit 4. The sub-filter unit 4 is used to receive the multi-channel signal 4 output by the frequency shift sub-unit 4. The center frequencies of channels 1 to 5 corresponding to the multi-channel signal 4 are -15MHz, -10MHz, -5MHz, 0MHz, and 5MHz, respectively. The center frequency of channel 4 in the frequency band of the multi-channel signal 4 is changed to the preset center frequency 0MHz. In this case, the mobile phone can filter out the single-channel signal 4 corresponding to channel 4 with a center frequency of 0MHz and a bandwidth of 20MHz in the multi-channel signal 4 through the sub-filter unit 4.
[0189] The sub-filter unit 5 is connected to the frequency shift sub-unit 5. The sub-filter unit 5 is used to receive the multi-channel signal 5 output by the frequency shift sub-unit 5. The center frequencies of channels 1 to 5 corresponding to the multi-channel signal 5 are -20MHz, -15MHz, -10MHz, -5MHz, and 0MHz, respectively. The center frequency of channel 5 in the frequency band of the multi-channel signal 5 is changed to the preset center frequency 0MHz. In this case, the mobile phone can filter out the single-channel signal 5 corresponding to channel 5 with a center frequency of 0MHz and a bandwidth of 20MHz in the multi-channel signal 5 through the sub-filter unit 5.
[0190] In some examples, after a multi-channel signal undergoes a frequency shift process, channel 3 among channels 1 to 5 corresponding to the frequency-shifted multi-channel signal is just moved to the preset center frequency of 0 MHz. Then the frequency shift subunit 3 may not be set in the frequency shift unit of the mobile phone. In this case, the mobile phone can filter out the single-channel signal 3 corresponding to channel 3 with a center frequency of 0 MHz and a bandwidth of 20 MHz from the multi-channel signal 3 through the sub-filter unit 3.
[0191] S605, the mobile phone resamples the single-channel signal of the first sampling frequency corresponding to each channel to obtain a single-channel signal of the second sampling frequency corresponding to each channel.
[0192] The sampling frequency (such as the second sampling frequency) required for baseband processing of the baseband module of the mobile phone or the backend processing of the module after the baseband module is usually inconsistent with the initial sampling frequency (such as the first sampling frequency) of the multi-channel signal. In the case where the sampling frequency required for baseband processing or backend processing is inconsistent with the initial sampling frequency of the multi-channel signal, the mobile phone can resample the single-channel signal of the first sampling frequency and convert the sampling frequency of the single-channel signal from the first sampling frequency to the second sampling frequency. The second sampling frequency is different from the first sampling frequency.
[0193] For example, Figure 7 As shown, in the baseband module of the mobile phone, the resampling unit is connected to the filtering unit. The resampling unit of the mobile phone can resample the single-channel signal corresponding to each channel, and convert the sampling frequency of the single-channel signal corresponding to each channel from 80 MHz (an example of the first sampling frequency) to 44 MHz (an example of the second sampling frequency).
[0194] Illustratively, the resampling process may include an interpolation operation, a filtering operation, and a decimation operation.
[0195] For example, Fig.13As shown, the resampling unit of the mobile phone can perform an interpolation operation on the 80MHz single-channel signal, insert multiple sampling points into the single-channel signal, and change the sampling frequency of the single-channel signal from 80MHz to 880MHz. Generally, the interpolation operation will introduce noise into the single-channel signal, so after the interpolation operation, the resampling unit of the mobile phone will also perform a filtering operation on the interpolated single-channel signal, filter the noise introduced by the interpolation operation, and obtain the single-channel signal after the noise is filtered out. The filtering operation does not change the sampling frequency of the single-channel signal, and at this time, the sampling frequency of the single-channel signal is still 880MHz. In a step forward, the resampling unit of the mobile phone performs a decimation operation on the single-channel signal after the noise is filtered out, and performs 20 times of sampling points on the single-channel signal of 880MHz, that is, 1 sampling point of the single-channel signal is extracted from the sampling points of the 20 single-channel signal to obtain the single-channel signal. In this way, the mobile phone can resample the single-channel signal with a first sampling frequency of 80MHz to a single-channel signal with a second sampling frequency of 44MHz.
[0196] Here, the resampling unit of the mobile phone performs resampling processing on the single-channel signal output by the filtering unit. The bandwidth corresponding to the resampling processing of the single-channel signal by the mobile phone is 20MHz. If the mobile phone resamples the multi-channel signal first and then performs filtering processing, the bandwidth corresponding to the resampling processing of the multi-channel signal by the mobile phone is 40MHz. It can be seen that the bandwidth corresponding to the resampling processing of the single-channel signal is much smaller than that corresponding to the resampling processing of the multi-channel signal. Resampling with a smaller bandwidth can improve the accuracy of the resampling processing, so that the single-channel signal obtained after the resampling processing has a higher signal quality.
[0197] It is understandable that the baseband module of the mobile phone can increase the sampling frequency through interpolation operation. The baseband module of the mobile phone can interpolate 0 values in a single-channel signal. The interpolation operation will introduce several mirror data of 0 frequency in the single-channel signal. Therefore, after the baseband module of the mobile phone performs an interpolation operation on the single-channel signal, the mirror data in the multi-channel signal is filtered out through a filtering operation. The baseband module of the mobile phone can reduce the sampling frequency through a decimation operation. The decimation operation easily introduces aliasing of the signal in the spectrum into the single-channel signal, causing distortion of the single-channel signal. Therefore, before the baseband module of the mobile phone performs an decimation operation on the single-channel signal, the single-channel signal is filtered through a filtering operation, which can reduce the aliasing of the single-channel signal in the subsequent decimation operation and filter out the noise in the single-channel signal. The filtering operation in the resampling process can be implemented by a half-wave filter.
[0198] In some examples, Figure 7 The filtering processing of the filtering unit and the resampling processing of the resampling unit can be collectively referred to as digital front end (Digital Front End) processing.
[0199] S606: The mobile phone identifies a target channel signal from the single channel signal corresponding to each channel.
[0200] The target channel signal is a signal transmitted using the target protocol type. For example, if the target protocol type is 802.11b, the target channel signal is a signal transmitted using 802.11b. After obtaining the single-channel signals corresponding to each channel, the mobile phone can identify the protocol type of each single-channel signal. If the protocol type of a single-channel signal among the single-channel signals is 802.11b, then the single-channel signal can be considered to be the target channel signal.
[0201] For example, Figure 7 As shown, the baseband module of the mobile phone can perform channel idle detection (Clear Channel Assessment, CCA) on 5 single-channel signals respectively through the carrier sensing unit, and identify the target channel signal among the 5 single-channel signals. The carrier sensing unit may include multiple sub-sensing units. The multiple sub-sensing units included in the carrier sensing unit are sub-sensing unit 1 (which can be expressed as CCA1), sub-sensing unit 2 (which can be expressed as CCA2), sub-sensing unit 3 (which can be expressed as CCA3), sub-sensing unit 4 (which can be expressed as CCA4) and sub-sensing unit 5 (which can be expressed as CCA5).
[0202] Each sub-listening unit can perform channel idle detection on the corresponding channel to determine whether the single channel signal of the current channel is the target channel signal transmitted using the 802.11b protocol. The channel idle detection may include detecting a Baker code corresponding to the target protocol type in the single channel signal of the corresponding channel.
[0203] Here, the Barker code corresponding to the target protocol type may be a synchronization code corresponding to the 802.11b protocol, which may be used to identify whether the single-channel signal is a signal of the target protocol type. The Barker code corresponding to the target protocol type may be pre-agreed upon by the mobile phone and the sender of the multi-channel signal. If the carrier sensing unit detects the Barker code corresponding to the target protocol type in the single-channel signal of a channel, it may be considered that a data frame encoded with the 802.11b protocol is identified in the single-channel signal of the channel. The single-channel signal of the channel is the target information signal. Furthermore, the mobile phone may read the information represented by the data frame in the target channel signal.
[0204] For example, sub-listening unit 1 may detect whether a single-channel signal of channel 1 carries a Barker code corresponding to a target protocol type. Sub-listening unit 2 may detect whether a single-channel signal of channel 2 carries a Barker code corresponding to a target protocol type. Sub-listening unit 3 may detect whether a single-channel signal of channel 3 carries a Barker code corresponding to a target protocol type. Sub-listening unit 4 may detect whether a single-channel signal of channel 4 carries a Barker code corresponding to a target protocol type. Sub-listening unit 5 may detect whether a single-channel signal of channel 5 carries a Barker code corresponding to a target protocol type.
[0205] The following is an example of a process in which a sub-listening unit detects whether a corresponding single-channel signal carries a Barker code corresponding to a target protocol type. In the example, it is taken as an example that sub-listening unit 1 detects whether a single-channel signal of channel 1 (or referred to as single-channel signal 1) carries a Barker code corresponding to a target protocol type.
[0206] like Fig.14 As shown, the sub-listening unit 1 can use the multi-bit data of the single-channel signal 1 as a detection window to perform a Barker code detection corresponding to the target protocol type. After the sub-listening unit 1 receives the single-channel signal 1, the sub-listening unit 1 can match the multi-bit data in the single-channel signal 1 that passes through the detection window with the Barker code corresponding to the target protocol type, and generate a correlation detection signal. The correlation detection signal can indicate whether the multi-bit data in the detection window matches the Barker code corresponding to the target protocol type. For example, if the correlation detection signal is a high level, it can indicate that the multi-bit data in the detection window matches the Barker code corresponding to the target protocol type. If the correlation detection signal is a low level, it can indicate that the multi-bit data in the detection window does not match the Barker code corresponding to the target protocol type.
[0207] For example, the detection window corresponds to 4 bits of data. If the 4 bits of data in the detection window match the Barker code corresponding to the target protocol type, a high level of the correlation detection signal can be generated. If the 4 bits of data in the detection window do not match the Barker code corresponding to the target protocol type, a low level of the correlation detection signal can be generated. The high level of the correlation detection signal corresponds to a signal peak. The sub-interception unit 1 can also count the signal peaks of the correlation detection signal. If the peak value of a signal peak reaches a preset peak value threshold, it can be considered that the 4 bits of data in the detection window match the Barker code corresponding to the target protocol type, and the count of the signal peak is increased by 1. If the peak value of a signal peak is less than the preset peak value threshold, it can be considered that the 4 bits of data in the detection window do not match the Barker code corresponding to the target protocol type, and the count of the signal peak remains unchanged. In the case where the count of the signal peak is greater than a pre-designed value (such as the count of the signal peak is greater than 3), it can be considered that the Barker code corresponding to the target protocol type is detected in the single-channel signal of channel 1. In the case where the single-channel signal of channel 1 carries the Barker code corresponding to the target protocol type, the single-channel signal of channel 1 can be considered to be the target channel signal.
[0208] Here, the detection window can slide backward according to the preset sliding step size. For example, the preset sliding step size is 1 bit. In the Barker code detection corresponding to the first target protocol type, the data of the detection window is the 1st bit to the 4th bit of the single-channel signal. In the Barker code detection corresponding to the second target protocol type, the data of the detection window is the 2nd bit to the 5th bit of the single-channel signal. And so on, until the detection window slides to the last bit of the current single-channel signal.
[0209] In some implementations, the mobile phone may also obtain the RSSI of each single channel signal. In this way, after confirming the target channel signal, the RSSI of the target channel signal may be obtained from the RSSIs of each single channel signal.
[0210] In this implementation, the received signal strength indicator can be used to indicate the signal strength of the received signal. If the RSSI value of a single-channel signal is larger, it means that the signal strength of the single-channel signal is larger. If the RSSI value of a single-channel signal is smaller, it means that the signal strength of the single-channel signal is smaller.
[0211] In an example of this implementation, the mobile phone may obtain the received signal strength indicator of the single-channel signal corresponding to each channel after resampling the single-channel signal corresponding to each channel, that is, after the above S605.
[0212] like Fig.15As shown, the mobile phone can calculate the received signal strength indication of each single-channel signal according to the single-channel signal output by each subsampling unit of the resampling unit, and obtain the received signal strength indication RSSI1 of single-channel signal 1, the received signal strength indication RSSI2 of single-channel signal 2, the received signal strength indication RSSI3 of single-channel signal 3, the received signal strength indication RSSI4 of single-channel signal 4, and the received signal strength indication RSSI5 of single-channel signal 5. Further, after determining the target channel signal in each single-channel signal, the mobile phone can obtain the received signal strength indication of the target channel signal from the received signal strength indications of each single-channel signal.
[0213] In another example of this implementation, the mobile phone can obtain the received signal strength indication of the single-channel signal corresponding to each channel after filtering the multi-channel signal to obtain the single-channel signal corresponding to each channel and before resampling the single-channel signal, that is, after the above S604 and before the above S605.
[0214] like Fig.16 As shown, the mobile phone can calculate the received signal strength indication of the single-channel signal of each channel according to the single-channel signal output by each sub-filtering unit of the filtering unit, and obtain the received signal strength indication RSSI1 of single-channel signal 1, the received signal strength indication RSSI2 of single-channel signal 2, the received signal strength indication RSSI3 of single-channel signal 3, the received signal strength indication RSSI4 of single-channel signal 4, and the received signal strength indication RSSI5 of single-channel signal 5. Further, after determining the target channel signal in each single-channel signal, the mobile phone can obtain the received signal strength indication of the target channel signal from the received signal strength indications of each single-channel signal.
[0215] It is understandable that, since the resampling unit of the mobile phone will resample each single-channel signal, the single-channel signal before the resampling process will be more accurate than the single-channel signal after the resampling process. Therefore, the received signal strength indication of each single-channel signal calculated by the mobile phone according to the single-channel signal output by each sub-filtering unit of the filtering unit has better accuracy.
[0216] In some implementations, the baseband module of the mobile phone may recognize that the single-channel signals of multiple channels all include signals of the target protocol type among the single-channel signals corresponding to each channel. In this case, the baseband module of the mobile phone may select a single-channel signal from the multiple single-channel signals including the target protocol type as the target channel signal according to the received signal strength indication of the single-channel signal.
[0217] For example, the baseband module of the mobile phone recognizes that the single-channel signals of channel 1 and channel 3 are both signals transmitted by the 802.11b protocol (an example of the target protocol type). In this case, the baseband module of the mobile phone can compare the RSSI of the single-channel signal of channel 1 with the RSSI of the single-channel signal of channel 3, and use the single-channel signal with the largest RSSI as the target channel signal.
[0218] In some implementations, during a Wi-Fi channel scan, the baseband module of the mobile phone may not identify a single-channel signal including a target protocol type among the single-channel signals corresponding to each channel. In this case, the mobile phone may perform a subsequent Wi-Fi channel scan to obtain the target channel signal in the subsequent Wi-Fi channel scan.
[0219] In some implementations, after obtaining the received signal strength indication of the target channel signal, the mobile phone may adjust the gain of the radio frequency signal according to the received signal strength indication of the target channel signal.
[0220] For example, Figure 5 As shown, the gain adjustment unit of the mobile phone obtains the RSSI of the target channel signal. If the RSSI value of the target channel signal is greater than or equal to the first preset strength value, it means that the RSSI value of the target channel signal is large. In this case, the gain adjustment unit sends a first gain adjustment instruction to the RF processing unit in the RF module, and instructs the RF processing unit to reduce the gain of the RF signal through the first gain adjustment instruction, so that the RSSI value of the next frame of the target channel signal obtained by the baseband module becomes smaller.
[0221] If the RSSI value of the target channel signal is less than or equal to the second preset strength value, it means that the RSSI value of the target channel signal is small. In this case, the gain adjustment unit sends a second gain adjustment instruction to the RF processing unit in the RF module, and instructs the RF processing unit to increase the gain of the RF signal through the second gain adjustment instruction, so that the RSSI value of the next frame of the target channel signal obtained by the mobile phone becomes larger.
[0222] If the RSSI value of the target channel signal is less than the first preset strength value and greater than the second preset strength value, it means that the RSSI value of the target channel signal is appropriate. In this case, the gain adjustment unit may not send instructions to the RF processing unit in the RF module, so that the next frame of the target channel signal obtained by the mobile phone remains within the second preset signal strength range.
[0223] Here, the first preset strength value and the second preset strength value are the upper limit and the lower limit of the second preset signal strength range, respectively. The first preset strength value is greater than the second preset strength value. The first preset strength value and the second preset strength value can be set according to actual application scenarios or requirements. This application does not limit the specific values of the first preset strength value and the second preset strength value.
[0224] By adjusting the RF signal received by the mobile phone through the RSSI of the target channel signal, the signal strength of the target channel signal can be controlled within an appropriate signal strength, thereby facilitating the mobile phone to perform subsequent processing on the target channel signal.
[0225] In some implementations, such as Figure 7 As shown, the baseband module of the mobile phone can also adjust the gain of the target channel signal through the digital gain unit. The digital gain unit is connected to the carrier sensing unit and can receive the target channel signal transmitted by the carrier sensing unit. The digital gain unit can perform gain control on the target channel signal so that the signal strength of the adjusted target channel signal is within the first preset strength range, making the target channel signal easier to process.
[0226] For example, the digital gain unit of the mobile phone can obtain the RSSI value of the target channel signal. If the RSSI value of the target channel signal is greater than or equal to the third preset strength value, it means that the RSSI value of the target channel signal is large. In this case, the digital gain unit can reduce the target channel signal. If the RSSI value of the target channel signal is less than or equal to the fourth preset strength value, it means that the RSSI value of the target channel signal is small. In this case, the digital gain unit can amplify the target channel signal. If the RSSI value of the target channel signal is less than the fourth preset strength value and greater than the fourth preset strength value, it means that the RSSI value of the target channel signal is appropriate. In this case, the gain adjustment unit may not adjust the gain of the target channel signal.
[0227] Here, the third preset strength value and the fourth preset strength value are the upper limit and the lower limit of the first preset signal strength range, respectively. The third preset strength value is greater than the fourth preset strength value. The third preset strength value and the fourth preset strength value can be set according to actual application scenarios or requirements. This application does not limit the specific values of the third preset strength value and the fourth preset strength value.
[0228] In the embodiment of the present application, after acquiring the multi-channel signal, the mobile phone first performs frequency shift processing on the multi-channel signal of the first sampling frequency, and then performs filtering processing on the multi-channel signal after the frequency shift processing to obtain a single-channel signal corresponding to each channel in the multiple channels. Furthermore, the mobile phone resamples the single-channel signal corresponding to each channel from the first sampling frequency to the second sampling frequency, and identifies the target channel signal in the single-channel signal of the second sampling frequency corresponding to each channel. In this way, the mobile phone scans multiple channels at one time, thereby improving the efficiency of the mobile phone connecting to the Wi-Fi network.
[0229] In some other embodiments of the present application, an electronic device is provided, including: an antenna, a memory and one or more processors. The antenna and the memory are coupled to the processor respectively. The antenna is used to receive single-channel or multi-channel signals. The memory stores computer program code, which includes computer instructions. When the computer instructions are executed by the processor, the electronic device can perform each function or step in the above method embodiment. Of course, the electronic device can also include other hardware structures. For example, the electronic device also includes hardware structures such as sensors and display screens. The structure of the terminal can refer to Figure 4 The structure of the mobile phone 100 is shown.
[0230] The embodiment of the present application also provides a chip system, which is applied to an electronic device. The chip system includes at least one processor and at least one interface circuit. The processor and the interface circuit can be interconnected by lines. For example, the interface circuit can be used to receive signals from other devices (such as memory). For another example, the interface circuit can be used to send signals to other devices (such as processors). Exemplarily, the interface circuit can read instructions stored in the memory and send the instructions to the processor. When the instruction is executed by the processor, the electronic device can perform the various steps in the above embodiments. Of course, the chip system can also include other discrete devices, which are not specifically limited in the embodiment of the present application.
[0231] An embodiment of the present application also provides a computer-readable storage medium, which includes computer instructions. When the computer instructions are executed on the above-mentioned electronic device, the electronic device executes each function or step in the above-mentioned method embodiment.
[0232] The present application also provides a computer program product, which, when executed on a computer, enables the computer to perform various functions or steps in the above method embodiment. For example, the computer may be the above electronic device.
[0233] The embodiment of the present application also provides a signal processing module, which is applied to an electronic device, and the electronic device includes an antenna, and the antenna is used to receive single-channel or multi-channel signals. The signal processing module includes a controller and a memory, and the memory is coupled to the controller. Among them, the memory stores a computer program code, and the computer program code includes computer instructions. When the computer instructions are executed by the controller, the signal processing module performs various functions or steps in the above method embodiment.
[0234] Through the description of the above implementation methods, technical personnel in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional modules is used as an example. In actual applications, the above-mentioned functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.
[0235] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0236] The units described as separate components may or may not be physically separated, and the components shown as units may be one physical unit or multiple physical units, that is, they may be located in one place or distributed in multiple different places. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0237] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of software functional units.
[0238] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium, including several instructions to enable a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read only memory (ROM), random access memory (RAM), disk or optical disk and other media that can store program code.
[0239] The above contents are only specific implementation methods of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions within the technical scope disclosed in the present application shall be included in the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.
Claims
1. A signal processing method, characterized in that: Applied to an electronic device, the electronic device includes an antenna, and the antenna is used to receive single-channel or multi-channel signals; the method includes: In one Wi-Fi channel scan, a multi-channel signal of n channels is obtained, wherein the multi-channel signal is obtained by the multi-channel signal received by the antenna; n is an integer greater than 1; Performing frequency shift processing on the multi-channel signal to obtain the multi-channel signal after the frequency shift processing; filtering out a single-channel signal corresponding to each of the n channels from the multi-channel signal after the frequency shift processing; A target channel signal is identified in a single channel signal corresponding to each of the n channels, wherein the target channel signal includes a signal of a target protocol type.
2. The method according to claim 1, characterized in that The electronic device comprises a filtering unit, wherein the filtering unit comprises n sub-filtering units; Filtering out a single channel signal corresponding to each of the n channels from the multi-channel signal after the frequency shift processing comprises: The multi-channel signals after the frequency shift processing are respectively input into the n sub-filtering units for filtering processing to obtain a single-channel signal output by each sub-filtering unit, wherein different sub-filtering units output single-channel signals corresponding to different channels.
3. The method according to claim 1 or 2, characterized in that: Before identifying the target channel signal in the single channel signal corresponding to each of the n channels, the method further includes: A resampling process is performed on the single-channel signal corresponding to each channel, and a sampling frequency of the single-channel signal is resampled from a first sampling frequency to a second sampling frequency.
4. The method according to claim 3, characterized in that The electronic device includes a resampling unit, wherein the resampling unit includes n subsampling units; resampling a single-channel signal of a first sampling frequency corresponding to each channel, and resampling the sampling frequency of the single-channel signal from the first sampling frequency to a second sampling frequency, comprising: The single-channel signal of the first sampling frequency corresponding to each channel is input into the corresponding sub-sampling unit of the n sub-sampling units for resampling processing, so as to obtain the single-channel signal of the second sampling frequency output by each sub-sampling unit.
5. The method according to claim 3 or 4, characterized in that: After resampling the single-channel signal corresponding to each channel and resampling the sampling frequency of the single-channel signal from the first sampling frequency to the second sampling frequency, the method further includes: A received signal strength indicator of a single-channel signal corresponding to each of the n channels is obtained.
6. The method according to any one of claims 1 to 4, characterized in that After filtering out the single-channel signal corresponding to each of the n channels from the multi-channel signal after the frequency shift processing, the method further includes: A received signal strength indicator of a single-channel signal corresponding to each of the n channels is obtained.
7. The method according to any one of claims 1 to 6, characterized in that The electronic device comprises a frequency shift unit, and the frequency shift unit comprises n frequency shift sub-units; Performing frequency shift processing on the multi-channel signal to obtain the multi-channel signal after the frequency shift processing includes: The multi-channel signal is input into each frequency shift subunit of the n frequency shift subunits respectively, and each frequency shift subunit performs frequency shift processing on the multi-channel signal to obtain a multi-channel signal after frequency shift processing by each frequency shift subunit; wherein different frequency shift subunits perform frequency shift processing at different frequency shift frequencies.
8. The method according to any one of claims 1 to 7, characterized in that Identifying a target channel signal in a single channel signal corresponding to each of the n channels includes: A target channel signal is identified in a single channel signal corresponding to each of the n channels according to a Barker code corresponding to the target protocol type.
9. The method according to any one of claims 1 to 8, characterized in that The method further comprises: Obtaining a received signal strength indicator of the target channel signal; According to the received signal strength indication of the target channel signal, the gain of the radio frequency signal of the n channels is adjusted; wherein the radio frequency signal is converted into a multi-channel signal of the n channels after analog-to-digital conversion.
10. The method according to any one of claims 1 to 9, characterized in that The step of acquiring the multi-channel signals of n channels comprises: Receiving the radio frequency signals of the n channels through the antenna; The radio frequency signal is mixed and analog-to-digital converted to obtain a multi-channel signal of the n channels.
11. The method according to claim 10, characterized in that After performing mixing processing and analog-to-digital conversion on the radio frequency signal to obtain the multi-channel signal of the n channels, the method further includes: A direct current signal in the multi-channel signal is filtered out.
12. The method according to any one of claims 1 to 11, characterized in that The target protocol type is 802.11b protocol.
13. An electronic device, characterized in that: The electronic device comprises: an antenna, a memory and one or more processors; the antenna and the memory are respectively coupled to the processor; the antenna is used to receive single-channel or multi-channel signals; The memory is used to store computer program codes, and the computer program codes include computer instructions. When the processor executes the computer instructions, the electronic device executes the method as claimed in any one of claims 1 to 12.
14. A computer-readable storage medium, characterized in that: The method comprises computer instructions, which, when executed on an electronic device, cause the electronic device to execute the method as claimed in any one of claims 1 to 12.
15. A signal processing module, characterized in that: The signal processing module is applied to an electronic device, wherein the electronic device comprises an antenna, and the antenna is used to receive single-channel or multi-channel signals; The signal processing module includes a controller and a memory, and the memory is coupled to the controller; wherein the memory stores computer program code, and the computer program code includes computer instructions, and when the computer instructions are executed by the controller, the signal processing module executes the method as described in any one of claims 1-12.