Wi-Fi device control method, device, electronic device and storage medium

By decoding the Beacon frame while judging the sleep conditions when the Wi-Fi device is in a sleep state, the problem that Wi-Fi devices cannot timely understand communication needs when reducing power consumption, and achieve faster sleep state switching and low power consumption effects.

CN115103429BActive Publication Date: 2025-03-14BESTECHNIC SHANGHAI CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210696582.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-20
Publication Date
2025-03-14
Estimated Expiration
2042-06-20

AI Technical Summary

Technical Problem

When existing Wi-Fi devices reduce power consumption, they may not be able to timely understand the communication needs of the access point, resulting in excessive delays and even reconnection, which consumes greater power.

Method used

By decoding the target Beacon frame while decoding the target Beacon frame, it is determined whether the decoded data meets the sleep conditions. If it is satisfied, switch to the sleep state to reduce the wake-up time.

Benefits of technology

It effectively shortens the wake-up time of Wi-Fi devices, enables Wi-Fi devices to enter sleep faster, and reasonably achieves the purpose of low power consumption.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115103429B_ABST
    Figure CN115103429B_ABST
Patent Text Reader

Abstract

The present application discloses a control method, device, electronic device and storage medium for a Wi-Fi device, belonging to the field of wireless communication technology. The method includes: when the Wi-Fi device is in a sleep state, if it is determined that the Beacon frame receiving period indicated by the AP has been reached, it switches to a wake-up state, calls the PHY layer component to decode the currently received target Beacon frame, and whenever the amount of decoded data reaches a multiple of a preset amount, calls the MAC layer component to determine whether the newly added preset amount of decoded data meets the sleep condition, and switches to a sleep state if it does. In this way, it is not necessary to wait for all the decoded data to determine whether the sleep condition is met, and switch to a sleep state when the sleep condition is met, which can effectively shorten the wake-up time of the Wi-Fi device, enable the Wi-Fi device to enter the sleep state faster, and reasonably achieve the purpose of low power consumption.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of wireless communication technology, and in particular to a control method, device, electronic device and storage medium for a Wi-Fi device. Background Art

[0002] With the development of wireless communication technology, Wireless Fidelity (Wi-Fi) technology has been widely used. However, when Wi-Fi is applied to electrical devices, low power consumption is usually required.

[0003] In the related art, low power consumption is generally achieved by putting the Wi-Fi device into a sleep state, that is, when it is found that there is no data communication between the Wi-Fi device and the access point (AP), the Wi-Fi device is put into a sleep state, and then switched to an awake state when the AP sends a beacon frame, and whether it is necessary to communicate with the AP is determined based on the Beacon frame. Assuming that the AP sends Beacon frames at a period of 100ms, the Wi-Fi device needs to wake up once every 100ms, which is called DTIM1. If the Wi-Fi device needs to further reduce power consumption, it can also wake up once every 200ms, which is called DTIM2, or wake up once every 300ms, which is called DTIM3. However, the problem with DTIM2 and DTIM3 is that the communication needs of the AP may not be known in time, resulting in excessive delay. Excessive delay may cause the AP to think that the Wi-Fi device has been disconnected, resulting in the need for the Wi-Fi device to reconnect, which will undoubtedly consume more power.

[0004] Therefore, how to reasonably achieve low power consumption of Wi-Fi devices remains a technical problem that needs to be solved urgently. Summary of the invention

[0005] The embodiments of the present application provide a control method, an apparatus, an electronic device, and a storage medium for a Wi-Fi device, so as to reasonably realize low power consumption of the Wi-Fi device.

[0006] In a first aspect, an embodiment of the present application provides a method for controlling a Wi-Fi device, including:

[0007] When the Wi-Fi device is in sleep mode, if it is determined that the beacon frame reception period indicated by the access point AP has been reached, it switches to awake mode;

[0008] Call the physical PHY layer component to decode the currently received target Beacon frame;

[0009] Performing low-power processing on the target Beacon frame, wherein the low-power processing means that when the amount of decoded data reaches a multiple of a preset amount, a media access control MAC layer component is called to determine whether the newly added preset amount of decoded data meets the sleep condition;

[0010] If it is determined that the sleep condition is met, the state is switched to the sleep state.

[0011] In some embodiments, it also includes:

[0012] Determining a proportion of Beacon frames to be processed with low power consumption based on a signal quality of a wireless signal carrying the target Beacon frame;

[0013] Based on the Beacon frame ratio, determining numbering characteristics of Beacon frames for low power consumption processing;

[0014] If it is determined that the number of the target Beacon meets the numbering characteristics, low power consumption processing is performed on the target Beacon frame.

[0015] In some embodiments, determining the proportion of Beacon frames to be processed with low power consumption based on the signal quality of the wireless signal carrying the target Beacon frame includes:

[0016] When the signal quality of the wireless signal is higher than the preset signal quality, determining the first ratio value as the Beacon frame ratio;

[0017] When the signal quality of the wireless signal is not higher than the preset signal quality, a second ratio value is determined as the Beacon frame ratio, and the second ratio value is smaller than the first ratio value.

[0018] In some embodiments, the signal quality of the wireless signal is determined by the misjudgment rate of the sleep condition when the MAC layer component does not correct the decoded data, or the signal quality of the wireless signal is determined by the signal-to-noise ratio of the wireless signal at the PHY layer.

[0019] In some embodiments, the first ratio value is 100%.

[0020] In a second aspect, an embodiment of the present application provides a control device for a Wi-Fi device, including:

[0021] The first switching module is used for, when the Wi-Fi device is in a sleep state, switching to a wake-up state if it is determined that the beacon frame receiving period indicated by the access point AP has been reached;

[0022] The decoding module is used to call the physical PHY layer component to decode the currently received target Beacon frame;

[0023] A processing module, configured to perform low-power processing on the target Beacon frame, wherein the low-power processing means that when the amount of decoded data reaches a multiple of a preset amount, a media access control MAC layer component is called to determine whether the newly added preset amount of decoded data meets a sleep condition;

[0024] The second switching module is used to switch to the sleep state if it is determined that the sleep condition is met.

[0025] In some embodiments, it also includes:

[0026] A first determination module, configured to determine a proportion of Beacon frames to be processed with low power consumption based on a signal quality of a wireless signal carrying the target Beacon frame;

[0027] A second determination module is used to determine the numbering characteristics of Beacon frames for low power consumption processing based on the Beacon frame ratio;

[0028] The processing module is further configured to perform low power consumption processing on the target Beacon frame if it is determined that the number of the target Beacon meets the numbering characteristics.

[0029] In some embodiments, the first determining module is specifically configured to:

[0030] When the signal quality of the wireless signal is higher than the preset signal quality, determining the first ratio value as the Beacon frame ratio;

[0031] When the signal quality of the wireless signal is not higher than the preset signal quality, a second ratio value is determined as the Beacon frame ratio, and the second ratio value is smaller than the first ratio value.

[0032] In some embodiments, the signal quality of the wireless signal is determined by the misjudgment rate of the sleep condition when the MAC layer component does not correct the decoded data, or the signal quality of the wireless signal is determined by the signal-to-noise ratio of the wireless signal at the PHY layer.

[0033] In some embodiments, the first ratio value is 100%.

[0034] In a third aspect, an embodiment of the present application provides an electronic device, comprising: at least one processor, and a memory communicatively connected to the at least one processor, wherein:

[0035] The memory stores a computer program that can be executed by at least one processor. The computer program is executed by the at least one processor so that the at least one processor can execute the control method of the Wi-Fi device.

[0036] In a fourth aspect, an embodiment of the present application provides a storage medium. When a computer program in the storage medium is executed by a processor of an electronic device, the electronic device can execute the above-mentioned control method of the Wi-Fi device.

[0037] In the embodiment of the present application, when the Wi-Fi device is in a sleep state, if it is determined that the Beacon frame receiving cycle indicated by the AP has been reached, it switches to an awake state, calls the PHY layer component to decode the currently received target Beacon frame, and calls the MAC layer component to determine whether the newly added preset amount of decoded data meets the sleep condition whenever the amount of decoded data reaches a multiple of the preset amount. If it is determined that the sleep condition is met, it switches to a sleep state. In this way, when the Wi-Fi device is in a sleep state, the preset amount of decoded data obtained by decoding the target Beacon frame can be used to determine whether the sleep condition is met based on this part of the decoded data, without having to wait until all the decoded data is obtained before making a judgment. This can effectively shorten the wake-up time of the Wi-Fi device, allowing the Wi-Fi device to enter the sleep state faster, thereby reasonably achieving the purpose of low power consumption. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] The drawings described herein are used to provide a further understanding of the present application and constitute a part of the present application. The illustrative embodiments of the present application and their descriptions are used to explain the present application and do not constitute an improper limitation on the present application. In the drawings:

[0039] Figure 1 An application scenario diagram of a Wi-Fi device control method provided in an embodiment of the present application;

[0040] Figure 2 A flowchart of a method for controlling a Wi-Fi device provided in an embodiment of the present application;

[0041] Figure 3 A schematic diagram of a target Beacon frame processing process provided in an embodiment of the present application;

[0042] Figure 4 A flowchart of another method for controlling a Wi-Fi device provided in an embodiment of the present application;

[0043] Figure 5 A schematic diagram of the structure of a control device for a Wi-Fi device provided in an embodiment of the present application;

[0044] Figure 6 A schematic diagram of the hardware structure of an electronic device for implementing a control method for a Wi-Fi device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0045] In order to reasonably achieve low power consumption of a Wi-Fi device, the embodiments of the present application provide a control method, an apparatus, an electronic device, and a storage medium for a Wi-Fi device.

[0046] The preferred embodiments of the present application are described below in conjunction with the drawings in the specification. It should be understood that the preferred embodiments described herein are only used to illustrate and explain the present application, and are not used to limit the present application. In addition, the embodiments and features in the embodiments of the present application may be combined with each other if there is no conflict.

[0047] In order to facilitate the understanding of this application, the technical terms involved in this application are:

[0048] Wi-Fi devices refer to devices that access the network through Wi-Fi, which usually require an external power supply or battery power. Common Wi-Fi devices include smartphones, tablets, portable personal computers, sweeping robots, Wi-Fi cameras, smart door locks, etc. The working states of Wi-Fi devices include sleep state and wake state. The sleep state refers to the state of the Wi-Fi device when it is not transmitting data, and the wake state refers to the state of the Wi-Fi device when it is transmitting data.

[0049] AP, the communication bridge between wireless network and wired network, is the core device of building wireless local area network (WLAN). Wi-Fi devices within the signal coverage of AP can communicate through AP. In wireless network, AP is equivalent to the hub of wired network, which can connect various Wi-Fi devices.

[0050] The physical (Physical, PHY) layer is the lowest layer in the Open System Interconnection Reference Model (OSI). It is directly oriented to the physical media (i.e., communication channels) that actually carry out data transmission. The transmission unit of the physical layer is bit, i.e., a binary bit ("0" or "1"). The actual bit transmission must rely on the transmission equipment and physical media, but the physical layer does not refer to a specific physical device, nor does it refer to the physical media for signal transmission. Instead, it refers to providing a physical connection for the upper layer (data link layer) to transmit the original bit stream above the physical media. The physical layer stipulates: to create, maintain, and dismantle the physical links required for data transmission, and to provide mechanical, electronic, functional, and standardized characteristics. Simply put, the physical layer ensures that the original data can be transmitted on various physical media. In an embodiment of the present application, the functions of the PHY layer can be implemented as PHY layer components, that is, the PHY layer components can implement all the functions of the PHY layer such as decoding and processing Beacon frames.

[0051] The Media Access Control (MAC) layer is mainly responsible for controlling the physical medium connected to the physical layer. Generally, after the decoded data of the PHY layer reaches the MAC layer, it is first verified. After the verification is completed, it is determined whether there is a communication demand and subsequent operations are performed. In the embodiment of the present application, the function of the MAC layer can be implemented as a MAC layer component.

[0052] Signal-to-noise ratio (SNR) refers to the ratio of signal to noise in an electronic device or electronic system. The unit of measurement for signal-to-noise ratio is dB, and its calculation method is 10lg (Ps / Pn), where Ps and Pn represent the effective power of signal and noise respectively, which can also be converted into a ratio of voltage amplitude: 20Lg (Vs / Vn), where Vs and Vn represent the "effective value" of signal and noise voltage respectively. The signal here refers to the electronic signal from outside the device that needs to be processed by this device, and the noise refers to the irregular additional signal (or information) that does not exist in the original signal after passing through the device, and this signal does not change with the change of the original signal.

[0053] Figure 1 An application scenario diagram of a control method for a Wi-Fi device provided in an embodiment of the present application includes an AP and a Wi-Fi device, wherein:

[0054] AP can transmit signals to the outside. All Wi-Fi devices within its signal coverage range can request to access the AP and then access the network through the AP.

[0055] Wi-Fi devices can transmit data with APs in the awake state. When there is no data transmission, they can enter the sleep state and wake up at a certain period to receive Beacon frames sent by APs. The Beacon frame contains an identifier of whether the AP has a data cache belonging to the Wi-Fi device. If the Wi-Fi device finds that the Beacon frame contains an identifier of its own data cache, it can remain awake and transmit data to the AP; if it finds that the Beacon does not contain an identifier of its own data cache, it can enter the sleep state until the next Beacon frame reception cycle arrives and repeats the above operations.

[0056] Normally, in order to reduce the power consumption of Wi-Fi devices, when the Wi-Fi device is in sleep state, if it is determined that the Beacon frame reception period indicated by the AP has been reached, it will switch to the awake state, call the PHY layer component to decode the currently received target Beacon frame, and after obtaining all the decoded data of the target Beacon frame, call the MAC layer component to correct all the decoded data. After the correction is completed, it will determine whether the sleep conditions are met based on all the decoded data. If so, it will switch to the sleep state.

[0057] In order to further reduce the power consumption of Wi-Fi devices, the embodiment of the present application proposes a solution for decoding the target Beacon frame while judging whether the decoded data meets the sleep condition. Since it is not necessary to obtain all the decoded data to judge whether the sleep condition is met, and the sleep state can be entered when the sleep condition is met, the wake-up time of the Wi-Fi device can be effectively shortened, allowing the Wi-Fi to enter the sleep state faster.

[0058] The solution of the embodiment of the present application is introduced below with reference to a specific flow chart.

[0059] Figure 2 A flowchart of a control method for a Wi-Fi device provided in an embodiment of the present application, the method is applied to Figure 1 In a Wi-Fi device, the method includes the following steps.

[0060] In step 201, when the Wi-Fi device is in a sleep state, if it is determined that the Beacon frame receiving period indicated by the AP has arrived, it switches to an awake state.

[0061] Among them, the Beacon frame receiving period is 100ms, 200ms, 300ms, etc.

[0062] In step 202, the PHY layer component is called to decode the currently received target Beacon frame.

[0063] The decoding process includes operations such as channel estimation, equalization, demapping, and decoding.

[0064] In actual applications, the target Beacon frame can be decoded while being received to improve processing efficiency.

[0065] In step 203, low power consumption processing is performed on the target Beacon frame, wherein low power consumption processing means that when the amount of decoded data reaches a multiple of a preset amount, a MAC layer component is called to determine whether the newly added preset amount of decoded data meets the sleep condition.

[0066] If the preset amount is 3 bytes, then when the amount of decoded data reaches 3 bytes, the MAC layer component can be called to determine whether the 3 bytes of decoded data meet the sleep conditions. When the amount of PHY layer decoded data reaches 6 bytes, the MAC layer component can be called again to determine whether the newly added 3 bytes of decoded data meet the sleep conditions, and so on.

[0067] The sleep condition is as follows: the decoded data contains a Traffic Indication Message Element ID (TIM EI), and the content of the TIM EI is not updated.

[0068] Generally, each Beacon frame contains Traffic Indication Message (TIM) information, but the TIM information may or may not contain TIM EI. By diagnosing the value of EI by the MAC layer component, it can be determined whether the TIM EI is received. If the TIM EI is received, it can be further determined whether the content of the TIM EI is updated to determine whether the above-mentioned sleep conditions are met.

[0069] Specifically, if the value of the MAC layer component diagnosis EI is 5, it is determined that the TIM EI is received. Further, the content of the TIM EI can be analyzed. If the content of the TIM EI is updated, it is determined that the sleep condition is not met. If the content of the TIM EI is not updated, it is determined that the sleep condition is met; if the value of the MAC layer diagnosis EI is not 5, it is determined that the TIM EI is not received.

[0070] In step 204, if it is determined that the sleep condition is met, the state is switched to the sleep state.

[0071] The above process is introduced below with an example.

[0072] Figure 3 A schematic diagram of the processing process of a target Beacon frame provided in an embodiment of the present application. Assume that the target Beacon frame is fully decoded by the PHY layer component to obtain a total of 9 bytes of decoded data, and the 9 bytes of decoded data are represented by: data block 1, data block 2, data block 3, and the size of each data block can be 3 bytes. Assume that the decoding rate of the PHY layer component is 2ms / data block, and the rate at which the MAC layer component determines whether the sleep condition is met is 1ms / data block. And assume that the MAC layer component determines that the sleep condition is met based on data block 2.

[0073] Then, under normal circumstances, it takes 6ms for the PHY layer component to complete all decoding processing. After the PHY layer component is fully decoded, the MAC layer component first performs correction. Assuming that the correction takes 1ms, after the correction is passed, the MAC layer component is called to determine whether the three data blocks meet the sleep condition. It takes 1ms to determine whether data block 1 meets the sleep condition, and 1ms for data block 2. When it is determined that data block 2 is completed, it is determined that the sleep condition is met and the sleep state is switched. Therefore, the whole process takes 9ms.

[0074] According to the scheme of the embodiment of the present application, if the preset amount is 3 bytes, the MAC layer component can be called every time a data block is obtained to determine whether the data block meets the sleep condition. In this way, data block 1 is obtained at the end of the 2nd ms, and the MAC layer component determines that data block 1 does not meet the sleep condition at the end of the 3rd ms. Data block 2 is obtained at the end of the 4th ms, and at the end of the 5th ms, the MAC layer component can determine that data block 2 meets the sleep condition and can switch to the sleep state. The whole process takes 5ms.

[0075] Obviously, the wake-up time of the Wi-Fi device is reduced from 9ms to 5ms, which enables the Wi-Fi device to enter the sleep state 4ms earlier, effectively shortening the wake-up time and thus reducing power consumption.

[0076] Generally, after obtaining the decoded data, the MAC layer component first corrects the decoded data, and then determines whether the decoded data meets the sleep condition after the correction. In the above embodiment, the MAC layer component directly determines whether the decoded data meets the sleep condition without correcting the decoded data, which may lead to errors in judgment, and the error probability is closely related to the signal quality of the wireless signal carrying the Beacon frame. To this end, low power consumption processing can be performed in combination with the signal quality of the wireless signal carrying the Beacon frame.

[0077] Figure 4 A flowchart of another method for controlling a Wi-Fi device provided in an embodiment of the present application includes the following steps.

[0078] In step 401, based on the signal quality of the wireless signal carrying the target Beacon frame, the proportion of Beacon frames to be processed with low power consumption is determined.

[0079] In some embodiments, the signal quality of the wireless signal carrying the target Beacon frame is determined by the false positive rate of the sleep condition when the MAC layer component does not correct the decoded data.

[0080] For example, a time period before the current time is selected. For each Beacon frame in this time period, after obtaining all the decoded data of the Beacon frame, the MAC layer component first corrects all the decoded data. After the correction, it determines whether the sleep condition is met based on all the decoded data. The obtained determination result is taken as determination result 1, and the determination result directly determined without correction is taken as determination result 2. If determination result 2 is different from determination result 1, a misjudgment can be recorded. Afterwards, the ratio of the number of misjudgments to the number of Beacon frames received in this time period is determined as the misjudgment rate of the sleep condition.

[0081] Furthermore, if the error rate of the sleep condition is higher than the set value, the signal quality of the wireless signal carrying the target Beacon frame is determined to be no higher than the preset signal quality. If the error rate of the sleep condition is not higher than the set value, the signal quality of the wireless signal carrying the target Beacon frame is determined to be higher than the preset signal quality.

[0082] In some embodiments, the signal quality of the wireless signal is determined by a signal-to-noise ratio of the wireless signal carrying the target Beacon frame at the PHY layer.

[0083] For example, 10 Beacon frames whose reception time is earlier than the target Beacon frame are selected, the signal-to-noise ratio of the wireless signal carrying each Beacon frame at the PHY layer is calculated, and the average value of the 10 signal-to-noise ratios is determined as the signal-to-noise ratio of the wireless signal carrying the target Beacon frame at the PHY layer.

[0084] Further, when the signal-to-noise ratio of the wireless signal carrying the target Beacon frame at the PHY layer is higher than a preset value, it is determined that the signal quality of the wireless signal carrying the target Beacon frame is not higher than the preset signal quality; when the signal-to-noise ratio of the wireless signal carrying the target Beacon frame at the PHY layer is not higher than the preset value, it is determined that the signal quality of the wireless signal carrying the target Beacon frame is higher than the preset signal quality.

[0085] In specific implementation, when the signal quality of the wireless signal is higher than the preset signal quality, the first ratio value can be determined as the Beacon frame ratio, and when the signal quality of the wireless signal is not higher than the preset signal quality, the second ratio value can be determined as the Beacon frame ratio, wherein the second ratio value is smaller than the first ratio value.

[0086] For example, the first ratio value is 50% and the second ratio value is 30%. That is to say, when the signal quality is higher than the preset signal quality, 50% of the Beacon frames can be processed with low power consumption. When the signal quality is not higher than the preset signal quality, 30% of the Beacon frames can be processed with low power consumption.

[0087] It is worth noting that when the first ratio value is 100%, that is, when the signal quality is higher than the preset signal quality, low power consumption processing is performed on all Beacon frames to achieve low power consumption to the greatest extent.

[0088] In step 402, based on the Beacon frame ratio, the numbering characteristics of the Beacon frames for low power consumption processing are determined.

[0089] Assuming that the Beacon frame ratio is 50%, the numbering characteristics of the Beacon frames for low power consumption processing may be an even number or an odd number; assuming that the Beacon frame ratio is 30%, the numbering characteristics of the Beacon frames for low power consumption processing may be a number modulo 3 equal to zero.

[0090] In step 403, when the Wi-Fi device is in the sleep state, if it is determined that the Beacon frame receiving period indicated by the AP has arrived, it switches to the awake state.

[0091] In step 404, the PHY layer component is called to decode the currently received target Beacon frame.

[0092] In step 405, if it is determined that the number of the target Beacon meets the numbering characteristics, the target Beacon frame is subjected to low power consumption processing, wherein low power consumption processing means that when the amount of decoded data reaches a multiple of a preset amount, the MAC layer component is called to determine whether the newly added preset amount of decoded data meets the sleep condition.

[0093] Assuming that the numbering feature is an even number, when the number of the target Beacon is an even number such as 2, 4, 6, ..., the target Beacon frame can be processed with low power consumption.

[0094] The implementation of the low power consumption processing in this step can be referred to step 203 and will not be described in detail here.

[0095] In step 406, if it is determined that the sleep condition is met, the state is switched to the sleep state.

[0096] In addition, if it is determined that the sleep condition is not met, the awake state can be maintained and data transmission with the AP can be started. When there is no data transmission with the AP within a preset time, the sleep state can be re-entered.

[0097] The above process is introduced below with an example.

[0098] For example, 10 Beacon frames are selected, the signal-to-noise ratio of the wireless signal carrying each Beacon frame at the PHY layer is calculated, and the average value of the 10 signal-to-noise ratios is calculated. If the average value is higher than the preset value, it is determined that the quality of the wireless signal is not high. If the average value is not higher than the preset value, it is determined that the quality of the wireless signal is high.

[0099] Assuming that the proportion of Beacon frames that are processed with low power consumption is 100% when the quality of the wireless signal is high, each Beacon frame received can be processed with low power consumption to maximize the low power consumption of the Wi-Fi device.

[0100] Assuming that the proportion of Beacon frames that are processed with low power consumption when the quality of wireless signals is not high is 20%, then one Beacon frame out of every five received Beacon frames can be processed with low power consumption. In this way, when the signal quality is not high, the power consumption of Wi-Fi devices can be reduced and the Wi-Fi devices can be informed of the AP data transmission requirements in a timely manner.

[0101] Based on the same technical concept, an embodiment of the present application also provides a control device for a Wi-Fi device. The principle of solving the problem by the control device for the Wi-Fi device is similar to that of the control method for the Wi-Fi device mentioned above. Therefore, the implementation of the control device for the Wi-Fi device can refer to the implementation of the control method for the Wi-Fi device, and the repeated parts will not be repeated.

[0102] Figure 5 A schematic structural diagram of a control device for a Wi-Fi device provided in an embodiment of the present application includes a first switching module 501 , a decoding module 502 , a processing module 503 , and a second switching module 504 .

[0103] The first switching module 501 is used for, when the Wi-Fi device is in a sleep state, switching to a wake-up state if it is determined that the beacon frame receiving period indicated by the access point AP has been reached;

[0104] The decoding module 502 is used to call the physical PHY layer component to decode the currently received target Beacon frame;

[0105] The processing module 503 is used to perform low-power processing on the target Beacon frame, wherein the low-power processing means that when the amount of decoded data reaches a multiple of a preset amount, a media access control MAC layer component is called to determine whether the newly added preset amount of decoded data meets the sleep condition;

[0106] The second switching module 504 is configured to switch to the sleep state if it is determined that the sleep condition is met.

[0107] In some embodiments, it also includes:

[0108] A first determination module 505 is used to determine the proportion of Beacon frames to be processed with low power consumption based on the signal quality of the wireless signal carrying the target Beacon frame;

[0109] A second determination module 506 is used to determine the numbering characteristics of Beacon frames for low power consumption processing based on the Beacon frame ratio;

[0110] The processing module 503 is further configured to perform low power consumption processing on the target Beacon frame if it is determined that the number of the target Beacon meets the numbering characteristics.

[0111] In some embodiments, the first determining module 505 is specifically configured to:

[0112] When the signal quality of the wireless signal is higher than the preset signal quality, determining the first ratio value as the Beacon frame ratio;

[0113] When the signal quality of the wireless signal is not higher than the preset signal quality, a second ratio value is determined as the Beacon frame ratio, and the second ratio value is smaller than the first ratio value.

[0114] In some embodiments, the signal quality of the wireless signal is determined by the misjudgment rate of the sleep condition when the MAC layer component does not correct the decoded data, or the signal quality of the wireless signal is determined by the signal-to-noise ratio of the wireless signal at the PHY layer.

[0115] In some embodiments, the first ratio value is 100%.

[0116] The division of modules in the embodiments of the present application is schematic and is only a logical function division. There may be other division methods in actual implementation. In addition, the functional modules in the embodiments of the present application may be integrated in a processor, or may exist physically separately, or two or more modules may be integrated in one module. The coupling between the modules may be achieved through some interfaces, which are usually electrical communication interfaces, but it is not excluded that they may be mechanical interfaces or other forms of interfaces. Therefore, the modules described as separate components may or may not be physically separated, and may be located in one place or distributed to different locations of the same or different devices. The above-mentioned integrated modules may be implemented in the form of hardware or in the form of software functional modules.

[0117] After introducing the control method and apparatus of the Wi-Fi device according to the exemplary embodiment of the present application, next, an electronic device according to another exemplary embodiment of the present application is introduced.

[0118] Refer to the following Figure 6 The electronic device 130 implemented according to this embodiment of the present application is described. Figure 6The electronic device 130 shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.

[0119] like Figure 6 As shown, the electronic device 130 is in the form of a general electronic device. The components of the electronic device 130 may include but are not limited to: the at least one processor 131, the at least one memory 132, and a bus 133 connecting different system components (including the memory 132 and the processor 131).

[0120] Bus 133 represents one or more of several types of bus structures, including a memory bus or memory controller, a peripheral bus, a processor, or a local bus using any of a variety of bus architectures.

[0121] The memory 132 may include a readable medium in the form of a volatile memory, such as a random access memory (RAM) 1321 and / or a cache memory 1322 , and may further include a read-only memory (ROM) 1323 .

[0122] The memory 132 may also include a program / utility 1325 having a set (at least one) of program modules 1324, such program modules 1324 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.

[0123] The electronic device 130 may also communicate with one or more external devices 134 (e.g., keyboards, pointing devices, etc.), may also communicate with one or more devices that enable a user to interact with the electronic device 130, and / or communicate with any device that enables the electronic device 130 to communicate with one or more other electronic devices (e.g., routers, modems, etc.). Such communication may be performed via an input / output (I / O) interface 135. Furthermore, the electronic device 130 may also communicate with one or more networks (e.g., a local area network (LAN), a wide area network (WAN), and / or a public network, such as the Internet) via a network adapter 136. As shown, the network adapter 136 communicates with other modules for the electronic device 130 via a bus 133. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 130, including but not limited to: microcode, device drivers, redundant processors, external disk drive arrays, RAID systems, tape drives, and data backup storage systems.

[0124] In an exemplary embodiment, a storage medium is also provided, and when a computer program in the storage medium is executed by a processor of an electronic device, the electronic device can perform the control method of the above-mentioned Wi-Fi device. Optionally, the storage medium can be a non-temporary computer-readable storage medium, for example, the non-temporary computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0125] In an exemplary embodiment, the electronic device of the present application may include at least one processor and a memory communicatively connected to the at least one processor, wherein the memory stores a computer program executable by the at least one processor, and when the computer program is executed by the at least one processor, the at least one processor may perform the steps of any Wi-Fi device control method provided in the embodiments of the present application.

[0126] In an exemplary embodiment, a computer program product is also provided. When the computer program product is executed by an electronic device, the electronic device can implement any exemplary method provided in the present application.

[0127] Furthermore, the computer program product may use any combination of one or more readable media. The readable medium may be a readable signal medium or a readable storage medium. The readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a RAM, a ROM, an erasable programmable read-only memory (EPROM), a flash memory, an optical fiber, a compact disk read only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.

[0128] The program product for controlling the Wi-Fi device in the embodiment of the present application may adopt a CD-ROM and include program code, and may be run on a computing device. However, the program product of the present application is not limited thereto, and in this document, a readable storage medium may be any tangible medium containing or storing a program, which may be used by or in combination with an instruction execution system, apparatus, or device.

[0129] The readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, wherein the readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. The readable signal medium may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.

[0130] The program code contained on the readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, radio frequency (RF), etc., or any suitable combination of the foregoing.

[0131] It should be noted that, although several units or subunits of the device are mentioned in the above detailed description, this division is merely exemplary and not mandatory. In fact, according to the embodiments of the present application, the features and functions of two or more units described above can be embodied in one unit. Conversely, the features and functions of one unit described above can be further divided into multiple units to be embodied.

[0132] In addition, although the operations of the method of the present application are described in a specific order in the drawings, this does not require or imply that the operations must be performed in this specific order, or that all the operations shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps.

[0133] Although the preferred embodiments of the present application have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present application.

[0134] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.

Claims

1. A method for controlling a Wi-Fi device, characterized in that: include: When the Wi-Fi device is in sleep mode, if it is determined that the beacon frame reception period indicated by the access point AP has been reached, it switches to awake mode; Call the physical PHY layer component to decode the currently received target Beacon frame; The target Beacon frame is subjected to low-power consumption processing, wherein the low-power consumption processing refers to calling a media access control MAC layer component to determine whether the newly added preset amount of decoded data meets a sleep condition when the amount of decoded data reaches a multiple of a preset amount; wherein the sleep condition is that the preset amount of decoded data contains a data to be transmitted indication information element identifier TIM EI, and the content of the TIM EI is not updated; If it is determined that the sleep condition is met, switching to the sleep state; Determining a proportion of Beacon frames to be processed with low power consumption based on a signal quality of a wireless signal carrying the target Beacon frame; Based on the Beacon frame ratio, determining numbering characteristics of Beacon frames for low power consumption processing; If it is determined that the number of the target Beacon meets the numbering characteristics, low power consumption processing is performed on the target Beacon frame.

2. The method according to claim 1, characterized in that Determining the proportion of Beacon frames to be processed with low power consumption based on the signal quality of the wireless signal carrying the target Beacon frame includes: When the signal quality of the wireless signal is higher than the preset signal quality, determining the first ratio value as the Beacon frame ratio; When the signal quality of the wireless signal is not higher than the preset signal quality, a second ratio value is determined as the Beacon frame ratio, and the second ratio value is smaller than the first ratio value.

3. The method according to claim 1, characterized in that The signal quality of the wireless signal is determined by the misjudgment rate of the sleep condition when the MAC layer component does not correct the decoded data, or the signal quality of the wireless signal is determined by the signal-to-noise ratio of the wireless signal at the PHY layer.

4. The method according to claim 2, characterized in that The first ratio value is 100%.

5. A control device for a Wi-Fi device, characterized in that: include: The first switching module is used for, when the Wi-Fi device is in a sleep state, switching to a wake-up state if it is determined that the beacon frame receiving period indicated by the access point AP has been reached; The decoding module is used to call the physical PHY layer component to decode the currently received target Beacon frame; A processing module, configured to perform low-power processing on the target Beacon frame, wherein the low-power processing refers to calling a media access control MAC layer component to determine whether the newly added preset amount of decoded data meets a sleep condition when the amount of decoded data reaches a multiple of a preset amount; wherein the sleep condition is that the preset amount of decoded data contains a data to be transmitted indication information element identification code TIM EI, and the content of the TIM EI is not updated; A second switching module, configured to switch to a sleep state if it is determined that the sleep condition is met; A first determination module, configured to determine a proportion of Beacon frames to be processed with low power consumption based on a signal quality of a wireless signal carrying the target Beacon frame; A second determination module is used to determine the numbering characteristics of Beacon frames for low power consumption processing based on the Beacon frame ratio; The processing module is further configured to perform low power consumption processing on the target Beacon frame if it is determined that the number of the target Beacon meets the numbering characteristics.

6. The device according to claim 5, characterized in that The first determining module is specifically configured to: When the signal quality of the wireless signal is higher than the preset signal quality, determining the first ratio value as the Beacon frame ratio; When the signal quality of the wireless signal is not higher than the preset signal quality, a second ratio value is determined as the Beacon frame ratio, and the second ratio value is smaller than the first ratio value.

7. An electronic device, characterized in that: include: at least one processor, and a memory communicatively connected to the at least one processor, wherein: The memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor so that the at least one processor can perform the method according to any one of claims 1 to 4.

8. A storage medium, characterized in that: When the computer program in the storage medium is executed by a processor of an electronic device, the electronic device can execute the method according to any one of claims 1 to 4.

Citation Information

Patent Citations

  • Speculative power save

    US20080181156A1

  • Smart beacon processing

    WO2015094363A1