Antenna mode switching method, electronic device, chip system, and storage medium

By monitoring the wireless router's data packets in MIMO mode, the electronic device can accurately determine whether the wireless router has switched to SISO mode, solving the problem of switching failure and achieving a stable communication connection.

WO2025200664A1PCT designated stage Publication Date: 2025-10-02HONOR DEVICE CO LTD
View PDF 7 Cites 0 Cited by

Patent Information

Application Number
PCT/CN2024/143533
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Priority Date
2024-03-29
Filing Date
2024-12-28
Publication Date
2025-10-02

AI Technical Summary

Technical Problem

When switching antenna modes, electronic devices cannot effectively sense whether the wireless router has switched successfully, resulting in communication abnormalities.

Method used

The electronic device monitors the data packets of the wireless router in MIMO mode, determines whether the wireless router has successfully switched to SISO mode based on the information in the data packet, and performs corresponding antenna mode switching after confirmation.

Benefits of technology

The success rate of antenna mode switching is improved, the occurrence of misjudgment and communication anomalies is reduced, and stable communication between electronic devices and wireless routers is ensured.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN2024143533_02102025_PF_FP_ABST
    Figure CN2024143533_02102025_PF_FP_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of wireless communications, and provides an antenna mode switching method, an electronic device, a chip system, and a storage medium. When an electronic device has established a wireless connection in an MIMO mode with a wireless router, if it is necessary to switch from the MIMO mode to an SISO mode in a specific scenario, an electronic device can send switching information to the wireless router instead of switching to the SISO mode immediately. The electronic device performs time-division detection to determine whether the wireless router performs switching successfully; if switching fails, other switching information can continue to be used to trigger the wireless router to switch to the SISO mode; and if the wireless router fails to be triggered to switch to the SISO mode even by using various switching information, a wireless connection in the SISO mode can be re-established with the wireless router by means of disconnection-and-reconnection. In this way, an electronic device can successfully establish a wireless connection in an SISO mode with a wireless router.
Need to check novelty before this filing date? Find Prior Art

Description

Antenna mode switching method, electronic device, chip system and storage medium

[0001] This application claims priority to the Chinese patent application filed with the State Intellectual Property Office on March 29, 2024, with application number 202410396104.2 and application name “Antenna mode switching method, electronic device, chip system and storage medium”, all contents of which are incorporated by reference into this application. Technical Field

[0002] The present application relates to the field of wireless communication technology, and in particular to an antenna mode switching method, electronic equipment, chip system and storage medium. Background Art

[0003] In the field of wireless communications, technologies for sending and receiving signals using antennas include single input single output (SISO) technology and multiple input multiple output (MIMO) technology.

[0004] Currently, the antenna mode used for signal transmission between electronic devices and wireless routers is mostly MIMO. In some scenarios, it is necessary to switch the antenna mode between the electronic device and the wireless router to SISO mode. However, when the electronic device triggers the switch between the electronic device and the wireless router, the switch often fails. However, the electronic device cannot detect whether the wireless router has successfully switched. Summary of the Invention

[0005] The present application provides an antenna mode switching method, an electronic device, a chip system, and a storage medium, which can sense whether a wireless router has been successfully switched on the electronic device side.

[0006] To achieve the above objectives, the first aspect of this application adopts the following technical solutions:

[0007] A method for switching an antenna mode includes:

[0008] When a wireless communication connection is established between an electronic device and a wireless router in MIMO mode, the electronic device sends first switching information to the wireless router, where the first switching information is used to instruct the wireless router to switch the antenna mode for communicating with the electronic device to the SISO mode;

[0009] The electronic device monitors the data packets sent by the wireless router in MIMO mode;

[0010] After receiving the first data packet sent by the wireless router in the MIMO mode, the electronic device determines, according to information carried in the first data packet, whether the wireless router successfully switches to the SISO mode based on the first switching information.

[0011] In the present application, when an electronic device and a wireless router establish a wireless connection in MIMO mode, if the electronic device needs to switch the MIMO mode to SISO mode due to a specific scenario, the electronic device may temporarily not switch to SISO mode, send switching information to the wireless router, and then monitor the data packets sent by the wireless router in MIMO mode; thereby determining whether the wireless router has successfully switched to SISO mode based on the data packets sent by the wireless router.

[0012] As an implementation of the first aspect, determining, according to the information carried in the first data packet, whether the wireless router successfully switches to the SISO mode based on the first switching information includes:

[0013] When the information carried in the first data packet indicates that the wireless router sends the first data packet in the SISO mode, the electronic device determines that the wireless router successfully switches to the SISO mode based on the first switching information;

[0014] When the information carried in the first data packet indicates that the wireless router sends the first data packet in MIMO mode, the electronic device determines that the wireless router fails to switch to SISO mode based on the first switching information.

[0015] In the present application, the electronic device side maintains the MIMO mode because, regardless of whether the wireless router switches successfully to send a data packet in the SISO mode or fails to switch to send a data packet in the MIMO mode, the electronic device can successfully parse it, thereby determining the mode of the wireless router when sending the data packet from the successfully parsed data packet, and then determining whether the wireless router switches successfully based on the mode.

[0016] As another implementation of the first aspect, after determining, according to the information carried in the first data packet, that the wireless router successfully switches to the SISO mode based on the first switching information, the method further includes:

[0017] The electronic device switches the antenna mode of the electronic device from the MIMO mode to the SISO mode, and communicates with the wireless router in the SISO mode.

[0018] In the present application, when the electronic device determines that the wireless router is switched successfully, the antenna mode for communicating with the wireless router may be switched to the SISO mode.

[0019] As another implementation of the first aspect, after determining, according to the information carried in the first data packet, that the wireless router successfully switches to the SISO mode based on the first switching information, the method further includes:

[0020] The electronic device monitors the data packets sent by the wireless router in MIMO mode.

[0021] In actual applications, since the electronic device determines whether the wireless router has been successfully switched based on the pattern in the data packet, and the wireless router may also send data packets in the SISO mode in the MIMO mode, the electronic device may make a misjudgment when determining whether the wireless router has been successfully switched. In order to reduce the possibility of misjudgment, the electronic device can continue to monitor the data packets of the wireless router in the MIMO mode, so as to determine whether the wireless router has been successfully switched based on the re-received data packets in the event of a misjudgment.

[0022] As another implementation of the first aspect, when the electronic device monitors the data packet sent by the wireless router in MIMO mode, the method further includes:

[0023] When the electronic device needs to send a second data packet to the wireless router, the electronic device sends the second data packet to the wireless router in a SISO mode.

[0024] In this application, since the wireless router may be switched successfully, in order to avoid the wireless router being unable to successfully parse the data packet sent by the electronic device in the SISO mode, the electronic device needs to send the data packet to the wireless router in the SISO mode.

[0025] As another implementation of the first aspect, after the electronic device determines, based on the information carried in the first data packet, that the wireless router successfully switches to the SISO mode based on the first switching information, while monitoring the data packets sent by the wireless router in the MIMO mode, the method further includes:

[0026] The electronic device receives a fourth data packet sent by the wireless router within the first time period, and information carried in the fourth data packet indicates that the wireless router sends the fourth data packet in MIMO mode;

[0027] determining, by the electronic device, that the wireless router fails to switch to the SISO mode based on the first switching information;

[0028] The electronic device does not receive a fourth data packet sent by the wireless router within a first time period, and the information carried in the fourth data packet indicates that the wireless router sends the fourth data packet in MIMO mode;

[0029] The electronic device determines that the wireless router successfully switches to the SISO mode based on the first switching information.

[0030] In this application, the duration for the electronic device to monitor in MIMO mode after determining that the wireless router has switched successfully can be set, which avoids the inability to switch to SISO mode and reduces the possibility of misjudgment.

[0031] As another implementation of the first aspect, when the electronic device determines that the wireless router fails to switch to the SISO mode based on the first switching information, the method further includes:

[0032] The electronic device sends second switching information to the wireless router, where the second switching information is used to instruct the wireless router to switch the antenna mode for communicating with the electronic device to the SISO mode;

[0033] detecting, by the electronic device, whether the wireless router successfully switches to the SISO mode based on the second switching information;

[0034] If the wireless router fails to switch to the SISO mode based on the second switching information, the electronic device sends third switching information to the wireless router, where the third switching information is used to instruct the wireless router to switch the antenna mode for communicating with the electronic device to the SISO mode.

[0035] The electronic device detects whether the wireless router successfully switches to the SISO mode based on the third switching information.

[0036] In this application, since there are different versions of the communication protocol, the switching information in different versions is different, and there may also be compatibility issues, so the wireless router can be triggered to switch to SISO mode through multiple versions of switching information to improve the switching success rate.

[0037] As another implementation manner of the first aspect, the first switching information, the second switching information, and the third switching information are different and are respectively one of SMPS, OMN, and OMI.

[0038] As another implementation of the first aspect, when the electronic device detects that the wireless router fails to successfully switch to the SISO mode based on the third switching information, the method further includes:

[0039] The electronic device interrupts the wireless communication connection with the wireless router;

[0040] After interrupting the wireless communication connection between the electronic device and the wireless router, the electronic device sends an association request to the wireless router, where the antenna mode of the electronic device carried in the association request is the SISO mode, and the association request is used to establish a wireless communication connection with the wireless router through the SISO mode.

[0041] As another implementation of the first aspect, after determining that the wireless router has successfully switched to the SISO mode, the electronic device further includes:

[0042] The electronic device stores a switching mode that triggers the wireless router to successfully switch to the SISO mode and a unique identifier of the wireless router in a white list, wherein the switching mode corresponds to one of SMPS, OMN and OMI.

[0043] In this application, the whitelist mechanism makes it unnecessary to frequently use multiple switching information to trigger wireless router switching when the same situation occurs again. Instead, a switching method that has successfully triggered wireless router switching in the past can be selected to improve switching efficiency.

[0044] As another implementation of the first aspect, before the electronic device sends the first switching information to the wireless router, the method further includes:

[0045] The electronic device fails to find the unique identifier of the wireless router from the white list.

[0046] As another implementation of the first aspect, the method further includes:

[0047] The electronic device queries the whitelist to obtain a switching mode corresponding to the unique identifier of the wireless router;

[0048] The electronic device triggers the wireless router to switch the antenna mode for communication between the wireless router and the electronic device to the SISO mode through the queried switching mode.

[0049] As another implementation of the first aspect, after the electronic device triggers the wireless router to switch the antenna mode for communication between the wireless router and the electronic device to the SISO mode through the queried switching mode, the method further includes:

[0050] If the electronic device detects that the wireless router fails to be switched by the queried switching method, it uses another switching method to trigger the wireless router to switch the antenna mode for communication between the wireless router and the electronic device to the SISO mode, wherein the other switching method is different from the queried switching method.

[0051] As another implementation of the first aspect, when the electronic device detects that the wireless router fails to successfully switch to the SISO mode based on the third switching information, the method further includes:

[0052] The unique identifier of the wireless router is added to a blacklist.

[0053] The present application also sets up a blacklist mechanism, so that if the switching method corresponding to each switching information fails, there is no need to use the switching method corresponding to the switching information according to the blacklist.

[0054] As another implementation of the first aspect, before the electronic device sends the first switching information to the wireless router, the method further includes:

[0055] The unique identifier of the wireless router is not found from the blacklist;

[0056] Correspondingly, if the unique identifier of the wireless router is found from the blacklist, a communication connection with the wireless router is re-established in the SISO mode by adopting a disconnection and reconnection method.

[0057] As another implementation of the first aspect, when the unique identifier of the wireless router is not found in the blacklist, the method further includes:

[0058] The electronic device queries the whitelist for the unique identifier of the wireless router, and the whitelist stores a switching mode for successfully triggering the wireless router to switch to the SISO mode when the electronic device and the wireless router establish a communication connection in the MIMO mode.

[0059] According to a second aspect, an electronic device is provided, comprising one or more processors and one or more memories; wherein the one or more memories are coupled to the one or more processors, and the one or more memories are used to store computer programs, so that when the one or more processors execute the computer programs, the electronic device implements any one of the methods of the first aspect of the present application.

[0060] In a third aspect, a chip system is provided, which is applied to an electronic device, and the chip system includes one or more processors, and the processor is used to call computer instructions so that the electronic device implements any method of the first aspect of this application.

[0061] In a fourth aspect, a computer-readable storage medium is provided, which stores a computer program. When the computer instructions are executed on an electronic device, the electronic device implements any one of the methods of the first aspect of the present application.

[0062] In a fifth aspect, an embodiment of the present application provides a computer program product, which, when running on a device, enables the electronic device to execute any one of the methods in the first aspect of the present application.

[0063] It can be understood that the beneficial effects of the second to fifth aspects mentioned above can be found in the relevant description of the first aspect mentioned above, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS

[0064] FIG1 is a schematic diagram of a hardware structure of an electronic device provided in an embodiment of the present application;

[0065] FIG2 is a schematic diagram illustrating the differences in data transmission using different antenna modes in the field of wireless communications according to an embodiment of the present application;

[0066] FIG3 is a timing diagram of a switching method of antenna modes provided in an embodiment of the present application;

[0067] FIG4 is a schematic diagram of the data format of an action frame provided in an embodiment of the present application;

[0068] FIG5 is a schematic diagram of the data format of a connection request message provided in an embodiment of the present application;

[0069] FIG6 is a timing diagram of another antenna mode switching method provided in an embodiment of the present application;

[0070] FIG7 is a schematic diagram of the structure of a data packet sent by a wireless router according to an embodiment of the present application;

[0071] FIG8 is a schematic diagram of a flow chart of a method for switching antenna modes provided in an embodiment of the present application;

[0072] FIG9 is a schematic diagram of a flow chart of another antenna mode switching method provided in an embodiment of the present application;

[0073] FIG10 is a data format of some fields of the OMN provided in an embodiment of the present application;

[0074] FIG11 is a data format of some fields of the OMI provided in an embodiment of the present application;

[0075] FIG12 is a flow chart of triggering a wireless router to switch to SISO mode through multiple switching modes according to an embodiment of the present application;

[0076] FIG13 is a timing diagram of an antenna mode switching method provided in an embodiment of the present application;

[0077] FIG14 is a timing diagram of another antenna mode switching method provided in an embodiment of the present application;

[0078] FIG15 is a timing diagram of another antenna mode switching method provided in an embodiment of the present application;

[0079] FIG16 is a flow chart of another antenna mode switching method provided in an embodiment of the present application. DETAILED DESCRIPTION

[0080] In the following description, specific details such as specific system structures and technologies are provided for illustration rather than limitation to facilitate a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details.

[0081] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, integers, steps, operations, elements and / or components, but does not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or collections thereof.

[0082] It should also be understood that in the embodiments of this application, "one or more" refers to one, two, or more than two; "and / or" describes the relationship between associated objects, indicating that three relationships can exist; for example, A and / or B can mean: A exists alone, A and B exist simultaneously, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the associated objects are in an "or" relationship.

[0083] In addition, in the description of this application specification and the appended claims, the terms "first", "second", "third", "fourth", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance.

[0084] References to "one embodiment" or "some embodiments" in this specification mean that a particular feature, structure, or characteristic described in conjunction with that embodiment is included in one or more embodiments of the present application. Thus, phrases such as "in one embodiment," "in some embodiments," "in other embodiments," and "in other embodiments" appearing in various places in this specification do not necessarily refer to the same embodiment, but rather mean "one or more but not all embodiments," unless otherwise specifically emphasized. The terms "including," "comprising," "having," and variations thereof all mean "including but not limited to," unless otherwise specifically emphasized.

[0085] An embodiment of the present application provides an antenna mode switching method that can be applied to electronic devices. The electronic devices in the embodiments of the present application can be tablet computers, mobile phones, wearable devices, laptop computers, ultra-mobile personal computers (UMPCs), netbooks, personal digital assistants (PDAs), etc. The embodiments of the present application do not limit the specific type of electronic devices.

[0086] Figure 1 shows a schematic diagram of the structure of an electronic device. Electronic device 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 194, and a subscriber identification module (SIM) card interface 195. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, etc.

[0087] It should be understood that the structures illustrated in the embodiments of the present application do not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 may include more or fewer components than shown, or may combine or separate certain components, or arrange the components differently. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.

[0088] The processor 110 may include one or more processing units. For example, the processor 110 may include an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU). The different processing units may be independent devices or integrated into one or more processors.

[0089] Processor 110 may also include a memory for storing instructions and data. In some embodiments, the memory in processor 110 is a cache memory. This memory can store instructions or data that have just been used or are being recycled by processor 110. If processor 110 needs to use the same instruction or data again, it can directly retrieve it from the memory. This avoids duplicate accesses, reduces processor 110 latency, and thus improves system efficiency.

[0090] The internal memory 121 can be used to store computer executable program codes, and the executable program codes include instructions. The processor 110 executes various functional applications and data processing of the electronic device 100 by running the instructions stored in the internal memory 121. The internal memory 121 may include a program storage area and a data storage area. Among them, the program storage area can store an operating system and an application required for at least one function (such as an image playback function, etc.). The touch sensor 180K is also called a "touch panel". The touch sensor 180K can be set on the display screen 194, and the touch sensor 180K and the display screen 194 form a touch screen, also called a "touch screen". The touch sensor 180K is used to detect touch operations acting on or near it. The touch sensor can pass the detected touch operation to the application processor to determine the type of touch event. Visual output related to the touch operation can be provided through the display screen 194. In other embodiments, the touch sensor 180K can also be set on the surface of the electronic device 100, which is different from the position of the display screen 194.

[0091] Electronic device 100 implements display functionality through a GPU, display screen 194, and an application processor. A GPU is a microprocessor for image processing that connects display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. Processor 110 may include one or more GPUs that execute program instructions to generate or modify display information.

[0092] Display screen 194 is used to display images, videos, and the like. Display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a MiniLED, a MicroLED, a Micro-OLED, or a quantum dot light-emitting diode (QLED). In some embodiments, electronic device 100 may include one or N display screens 194, where N is a positive integer greater than one.

[0093] The embodiments of the present application do not particularly limit the specific structure of the execution subject of the antenna mode switching method; as long as the code recording the antenna mode switching method of the embodiments of the present application can be executed to communicate according to the antenna mode switching method provided by the embodiments of the present application. For example, the execution subject of the antenna mode switching method provided by the embodiments of the present application can be a functional module in an electronic device that can call and execute a program, or a communication device used in an electronic device, such as a chip.

[0094] Technologies for sending and receiving signals using antennas in the field of wireless communications include single input single output (SISO), single transmit multiple receive (SIMO), multiple transmit single receive (MISO), and multiple input multiple output (MIMO).

[0095] Referring to (a) in Figure 2 , SISO technology requires that the path between the transmitting antenna at the transmitter and the receiving antenna at the receiver is unique, and that one signal is transmitted. In a wireless system, one signal can be defined as a spatial stream.

[0096] SIMO technology adds a receiving antenna at the receiving end so that the receiving end can receive two signals at the same time. Although there are two signals, the two signals are sent from the same transmitting antenna at the same transmitting end. Therefore, only one signal is still transmitted, which improves the transmission reliability compared to SISO technology.

[0097] MISO technology adds a transmitting antenna at the transmitting end, while maintaining one receiving antenna at the receiving end. However, since there is only one receiving antenna at the receiving end, the two signals transmitted by the two transmitting antennas at the transmitting end still need to be synthesized into one signal. That is, the two transmitting antennas at the transmitting end can only send the same data, and the transmitted signal is still one signal. Compared with SISO technology, the transmission reliability is improved.

[0098] Referring to (b) in FIG2 , MIMO technology adds a transmitting antenna to the transmitting end and a receiving antenna to the receiving end. In this way, the transmitting end has two transmitting antennas and the receiving end has two receiving antennas, and two signals can be sent independently.

[0099] Currently, the transmitting antenna and receiving antenna in the same electronic device can be a combined antenna with both transmitting and receiving functions, or two separate antennas, one with transmitting and the other with receiving functions. The subsequent embodiments of this application use the combined transmitting antenna and receiving antenna in the same electronic device as an example.

[0100] Two antennas can be set in an electronic device, each antenna has a transmitting function and a receiving function; two or more antennas can also be set in a wireless router, each antenna has a transmitting function and a receiving function. Electronic devices and wireless routers usually communicate with each other through MIMO. In some scenarios, the communication mode between the electronic device and the wireless router needs to be switched from MIMO mode (also understood as MIMO mode or MIMO technology) to SISO mode (also understood as SISO mode or SISO technology).

[0101] As an example, when transmitting the same data, the power consumption of using dual antennas is usually higher than that of using a single antenna. Therefore, in some scenarios where the transmission rate is not high but the power consumption is required, for example, when the electronic device is in sleep mode or the screen is off, in order to reduce power consumption, a single antenna transmission can be used, that is, the MIMO mode is switched to the SISO mode.

[0102] As another example, there may be other services in the electronic device that need to occupy an antenna for sending and receiving signals. In this case, one antenna needs to be given to other services (for example, when one of the antennas needs to be used for Bluetooth services), and the communication between the electronic device and the wireless router needs to use single-antenna transmission, that is, the MIMO mode is switched to the SISO mode.

[0103] However, when the electronic device triggers the switching of the communication between the electronic device and the wireless router to the SISO mode, the switching often fails, resulting in abnormal communication between the electronic device and the wireless router.

[0104] An embodiment of the present application provides an antenna mode switching method, in which an electronic device can trigger a wireless router to switch from MIMO mode to SISO mode. Because the wireless router in existing communication protocols does not actively inform the electronic device whether the wireless router has successfully switched, the electronic device can detect whether the wireless router has switched the communication mode between the electronic device and the wireless router from MIMO mode to SISO. If the electronic device determines that the wireless router has failed to switch, it can re-establish a communication connection with the wireless router in SISO mode by interrupting and reconnecting.

[0105] The antenna mode switching method provided by the embodiment of the present application is described in detail below with reference to Figure 3. The switching method is executed on the premise that a wireless communication connection has been established between the electronic device and the wireless router in the MIMO mode.

[0106] S01: The electronic device sends SISO switching information to the wireless router.

[0107] The electronic device can first switch to SISO mode and then send switching information to the wireless router. This switching information can indicate that the electronic device has switched to SISO mode. By sending this SISO switching information to the wireless router, the wireless router is informed that the electronic device has switched the antenna mode for communicating with the wireless router to SISO mode and instructs the wireless router to also switch to SISO mode for subsequent wireless communication with the electronic device. Of course, in actual applications, the wireless router can still use MIMO mode to communicate with other electronic devices.

[0108] In the embodiment of the present application, the electronic device may use a spatial multiplexing power save (SMPS) mode to send an action frame to instruct the wireless router to switch the antenna transmission mode from MIMO to SISO.

[0109] Refer to Figure 4, which shows the data format of the action frame provided in an embodiment of the present application.

[0110] When the B0 field is set to 0, it indicates static Spatial Multiplexing Power Save mode (or SM Power Save Enable), that is, the energy-saving mode of static multiple spatial streams. When it is set to 1, it indicates dynamic Spatial Multiplexing Power Save mode, that is, the energy-saving mode of dynamic multiple spatial streams. When it is set to 3, it indicates Spatial Multiplexing Power Save Disabled, that is, the multiple spatial stream mode with energy-saving mode disabled. Character 2 is reserved.

[0111] When the B1 field is set to 0, it indicates Spatial Multiplexing Mode (or SM Model), that is, multiple spatial stream mode; when it is set to 1, it indicates Spatial Single Mode, that is, single spatial stream mode.

[0112] B2 to B7 are reserved fields.

[0113] As an example of an action frame used to represent the switching information corresponding to the electronic device in an embodiment of the present application, the value of the B0 field is 1, and the value of the B1 field is 1.

[0114] S02: After receiving the SISO mode switching information, the wireless router sends a confirmation character to the electronic device. The confirmation character is used to indicate that the wireless router has received the SISO switching information sent by the electronic device.

[0115] S03: After receiving the SISO mode switching information, the wireless router performs SISO switching, but the switching fails.

[0116] In the embodiment of the present application, based on the communication protocol, the wireless router does not have a feedback mechanism when the switching fails, that is, the wireless router will also send a confirmation character to the electronic device when the switching fails.

[0117] Of course, in actual applications, there is no strict order in which S02 and S03 are executed.

[0118] As an example, after the wireless router successfully switches to the SISO mode, the electronic device and the wireless router can perform data transmission based on the SISO manner.

[0119] As another example, when the wireless router fails to successfully switch to SISO mode, the electronic device has already switched to SISO mode, and the wireless router is in MIMO mode. There are two receiving antennas on the wireless router, which can receive and successfully parse one channel of data sent by the electronic device in SISO mode; however, there is one receiving antenna on the electronic device. After receiving the two channels of data sent by the wireless router in MIMO mode, the electronic device cannot successfully parse the data, resulting in abnormal communication between the two.

[0120] As previously described, after the electronic device sends SISO switching information to the wireless router, the wireless router sends a confirmation character to the electronic device. This confirmation character is used to indicate that the wireless router has received the SISO switching information sent by the electronic device. The wireless router does not send information to the electronic device regarding whether the switch to SISO mode has been successful. To reduce or avoid communication anomalies between the electronic device and the wireless router, embodiments of the present application may further include a configuration in which the electronic device detects whether the wireless router has successfully switched to SISO mode.

[0121] S04: After receiving the confirmation character for the first duration, the electronic device sends a heartbeat request (Ping Req) to the wireless router, where the heartbeat request carries a payload.

[0122] In an embodiment of the present application, the electronic device may switch its MIMO mode to SISO mode before sending the SISO switching information. The electronic device needs to allow the wireless router time to perform the switching action, so it can be set to send a heartbeat request to the wireless router after receiving the confirmation character for a first time period.

[0123] Typically, heartbeat requests and heartbeat responses come in pairs. That is, when an electronic device sends a heartbeat request to a wireless router, the wireless router must return a heartbeat response if it receives and successfully interprets the request. By including a payload in the heartbeat request, the heartbeat response returned by the wireless router also carries a payload.

[0124] In current communication protocols, the maximum payload size is 32KB. In the embodiment of the present application, the payload carried in the heartbeat request can be set to 32KB. Of course, as the communication protocol is updated, the data size of the payload can also be changed, or as the communication protocol is updated, the payload can also be unchanged.

[0125] S05 , after receiving the heartbeat request sent by the electronic device, the wireless router sends a heartbeat response (Ping RSP) to the electronic device, and the heartbeat response also carries a payload.

[0126] In the embodiment of the present application, when the payload carried in the heartbeat response is 32KB, the wireless router needs to use the maximum number of spatial streams to send the heartbeat response.

[0127] If the wireless router successfully switches to the SISO mode, the maximum number of spatial streams is 1, and the heartbeat response is sent in the SISO mode. The electronic device can receive the heartbeat response sent by the wireless router in the SISO mode and correctly parse the heartbeat response.

[0128] If the wireless router fails to switch to SISO mode and remains in MIMO mode with a maximum of two spatial streams, the heartbeat response will be sent using MIMO. The electronic device may receive two MIMO signals from the wireless router (sending the heartbeat response via two signals), but may not be able to correctly interpret the heartbeat response. This inability to correctly interpret the heartbeat response is equivalent to a heartbeat timeout on the electronic device.

[0129] S06: When the electronic device receives a heartbeat response from the wireless router within the second time period and correctly analyzes the heartbeat response, it determines that the wireless router has successfully switched to the SISO mode (not shown).

[0130] The starting point of the second duration may be the moment when the electronic device sends the heartbeat request.

[0131] S07: If the electronic device does not receive a heartbeat response from the wireless router within the second time period, or receives a heartbeat response from the wireless router but cannot successfully parse the heartbeat response, it determines that the wireless router has not successfully switched to the SISO mode.

[0132] When the antenna patterns of the electronic device and the wireless router are inconsistent, there may be an abnormality in the communication between the electronic device and the wireless router. In order to restore the communication between the electronic device and the wireless router to normal, the electronic device can re-establish a communication connection with the wireless router to notify the electronic device that it is an electronic device in SISO mode.

[0133] S08: When the electronic device determines that the wireless router has not successfully switched to the SISO mode, the electronic device sends deauthentication information (Deauth) to the wireless router. The deauthentication information is used to forcibly interrupt the wireless connection between the electronic device and the wireless router.

[0134] In an embodiment of the present application, the electronic device may send a data packet for canceling authentication to forcibly interrupt the communication connection between the wireless router and the electronic device.

[0135] S09: After receiving the de-authentication information, the wireless router sends a confirmation character to the electronic device. The confirmation character is used to indicate that the wireless router has received the de-authentication information.

[0136] In the embodiment of the present application, the wireless router generally uses one spatial stream to send the confirmation character, so the electronic device can receive the confirmation character.

[0137] S10: The wireless router disconnects the MIMO mode wireless communication connection with the electronic device.

[0138] S11 , after receiving the confirmation character, the electronic device sends an authentication request (Auth REQ) to the wireless router.

[0139] S12: After receiving the authentication request, the wireless router sends a confirmation character to the electronic device, where the confirmation character is used to indicate that the wireless router has received the authentication request.

[0140] S13, the wireless router authenticates the authentication information carried in the authentication request.

[0141] S14, after the authentication is successful, the wireless router sends an authentication response to the electronic device, where the authentication response is used to indicate that the wireless router has successfully authenticated the authentication information of the electronic device.

[0142] S15, after receiving the authentication response, the electronic device sends a confirmation character to the wireless router, where the confirmation character is used to indicate that the electronic device has received the authentication response.

[0143] S16, after sending the confirmation character, the electronic device sends an association request (Assoc req) to the wireless router.

[0144] 5 , which shows some fields in an association request message according to an embodiment of the present application, the supported MCS Set in the association request message may be written as a 1x1 device (i.e., establishing a wireless communication connection with a wireless router in SISO mode).

[0145] S17, after receiving the association request, the wireless router sends a confirmation character to the electronic device, where the confirmation character is used to indicate that the wireless router has received the connection request.

[0146] S18: After receiving the association request, the wireless router sets the antenna mode for communicating with the electronic device to SISO.

[0147] Of course, the antenna mode for communicating with other electronic devices can still be MIMO. In a specific implementation, the execution order of S17 and S18 can be set according to actual conditions.

[0148] S19, after setting the antenna mode of the wireless router and the electronic device to SISO, the wireless router sends a connection response (Assoc RSP) to the electronic device.

[0149] S20: After receiving the connection response sent by the wireless router in the SISO mode, the electronic device sends a confirmation character to the wireless router, where the confirmation character is used to indicate that the electronic device has received the connection response sent by the wireless router.

[0150] Steps S09 to S20 are for the electronic device to reconnect using a disconnection and reconnection mechanism, and when reconnecting, notify the wireless router that it is a 1X1 device, thereby re-establishing a wireless communication connection with the wireless router in SISO mode.

[0151] As another embodiment of the present application, the electronic device may also detect whether the wireless router is switched successfully in another way.

[0152] As an example, after the wireless router successfully switches to SISO mode, when the wireless router needs to send a data packet to an electronic device, the wireless router sends the data packet to the electronic device in SISO mode. The electronic device can receive and correctly parse the data packet. After correctly parsing the data packet, the electronic device will send a confirmation character of the data packet to the wireless router. After receiving the confirmation character of the data packet, the wireless router determines that the electronic device has received and correctly parsed the data packet.

[0153] As another example, if the wireless router fails to successfully switch to SISO mode, and the wireless router needs to send a data packet to the electronic device, the wireless router sends the data packet (two-way data) to the electronic device in MIMO mode. Since the electronic device has switched to SISO mode, the electronic device receives one way of data in the data packet and cannot correctly parse the data. Therefore, the electronic device does not send an acknowledgment character to the wireless router. If the wireless router does not receive an acknowledgment character for the current data packet within a certain period of time, it may retransmit the data packet, for example, by retransmitting the data packet to the electronic device in MIMO mode and setting a retransmission flag in the retransmitted data packet. Similarly, if the electronic device still cannot successfully parse the data packet retransmitted in MIMO mode, it still will not send an acknowledgment character corresponding to the data packet retransmitted in MIMO mode to the wireless router. Therefore, the wireless router may retransmit the data packet at a reduced speed (retransmit with a reduced number of spatial streams). That is, the wireless router retransmits the data packet to the electronic device in SISO mode, and the data packet still has a retransmission flag. The electronic device can receive the complete data packet and can successfully parse the data packet. The electronic device can send an acknowledgment character for the data packet retransmitted in SISO mode to the wireless router. Of course, if the electronic device receives and successfully parses a data packet with a retransmission flag, it means that the wireless router has already transmitted the data packet in MIMO mode. The electronic device can determine that the wireless router has failed to switch to SISO mode.

[0154] To make the above embodiment clearer, reference is made to the timing diagram of the antenna mode switching method shown in FIG. 6 .

[0155] S01 to S03 can refer to the description in the embodiment shown in FIG3 , which will not be repeated here. The failure of wireless router switching is taken as an example.

[0156] After S03, the method further includes:

[0157] S34, when the wireless router needs to send a data packet, the wireless router sends the data packet to the electronic device in a MIMO manner (to avoid confusion, recorded as a second data packet).

[0158] S35, after receiving the data packet sent by the wireless router, the electronic device fails to parse the data packet.

[0159] Since the electronic device side is in SISO mode and the wireless router side is in MIMO mode, the electronic device side cannot successfully parse and obtain the second data packet.

[0160] Accordingly, the electronic device no longer sends the confirmation character of the second data packet to the wireless router.

[0161] S36: The wireless router does not receive a confirmation character of the second data packet sent by the electronic device within a certain period of time.

[0162] S37: If the electronic device does not receive an acknowledgment character for the second data packet sent by the electronic device within a certain period of time, the electronic device retransmits the data packet (referred to as a third data packet to avoid confusion) in MIMO mode. The third data packet carries a retransmission flag. The data content of the third data packet is the same as the data content of the second data packet.

[0163] S38, after the electronic device receives the data packet sent by the wireless router, it still fails to parse it.

[0164] The reason for the parsing failure can be found in the description in S35.

[0165] S39: The wireless router does not receive the confirmation character of the third data packet within a certain period of time.

[0166] In actual applications, if a wireless router cannot receive an acknowledgment character from an electronic device after resending a data packet (with a retransmission flag) multiple times in MIMO mode, it will reduce the speed or retransmit the data packet (still with a retransmission flag) using a different spatial stream. The specific details depend on the wireless router's mechanism.

[0167] The embodiment of the present application takes the resending of the data packet in SISO mode after step S39 as an example.

[0168] S40: If the wireless router does not receive an acknowledgment character for the third data packet within a certain period of time, it resends the data packet (referred to as the first data packet to avoid confusion) in SISO mode. The first data packet carries a retransmission flag. The data content of the first data packet is the same as the data content of the third data packet.

[0169] In the embodiment of the present application, the structure of the data packet sent by the wireless router is shown in FIG7 .

[0170] There is a retry field in the frame control of the MAC header of the data packet, and a corresponding flag can be written in the retry field as a retransmission flag. For example, the first flag indicates a retransmitted data packet, and the second flag indicates a non-retransmitted data packet.

[0171] S41, after the electronic device receives the data packet retransmitted in the SISO mode, it successfully parses it and determines that the data packet contains a retransmission identifier. Based on the retransmission identifier, it is determined that the wireless router has not successfully switched to the SISO mode. The wireless router currently retransmits the data packet in the SISO mode because the wireless router fails to send the data packet in the MIMO mode and the number of spatial streams is temporarily reduced for retransmission.

[0172] S42, after successfully parsing the data packet, the electronic device sends a confirmation character of the data packet to the wireless router.

[0173] Of course, when the wireless router receives the confirmation character of the first data packet sent in the SISO mode, it no longer repeatedly sends the data packet with the same data content.

[0174] After S42, if the electronic device determines that the wireless router has not successfully switched to the SISO mode, it executes S08 and subsequent steps. S08 and subsequent steps can be described with reference to the embodiment shown in FIG3.

[0175] Through the above examples, it can be understood that in some scenarios, electronic devices need to switch from MIMO mode to SISO mode. The electronic device can send switching information to the wireless router to inform the wireless router that the electronic device is in SISO mode, and instruct the wireless router to switch the antenna mode for communicating with the electronic device to SISO mode. At the same time, the electronic device can also detect whether the switch of the wireless router is successful. If it is detected that the wireless router has not successfully switched to SISO, it can also re-establish a communication connection with the wireless router by disconnecting and reconnecting, and notify the wireless router that the electronic device is a 1x1 device and can establish a communication connection in SISO mode when the communication connection is re-established. When the communication connection in SISO mode is re-established, abnormal situations in subsequent communications between the electronic device and the wireless router are reduced or avoided.

[0176] FIG3 and FIG6 respectively use different methods to determine whether the wireless router is switched successfully. In practical applications, the method shown in FIG3 or the method shown in FIG6 can be used. Of course, the methods shown in FIG3 and FIG6 can also be used at the same time. That is, after the electronic device receives the confirmation character of the SISO switching information sent by the wireless router, on the one hand, it executes S04 and sends a heartbeat request to the wireless router after a first time period; on the other hand, it waits to see whether a data packet with a retransmission flag is received and successfully parsed; if the electronic device first meets the condition of not successfully parsing the heartbeat response within the second time period, it determines that the wireless router switching has failed based on this condition; if the electronic device first meets the condition of receiving and successfully parsing the data packet with a retransmission flag, it determines that the wireless router switching has failed based on this condition.

[0177] As another embodiment of the present application, the present application also provides a blacklist mechanism, that is, the electronic device will add the wireless router with the switching failure record through the switching information to the blacklist. When the electronic device subsequently needs to switch from MIMO to SISO, it will no longer notify the wireless router to switch through the switching information, but will skip the sending of the switching information and the detection of whether the switching is successful, and directly re-establish the SISO mode wireless communication connection with the wireless router by disconnecting and reconnecting. When the wireless communication connection is re-established, the wireless router is notified at the same time that the electronic device is a 1X1 device.

[0178] That is, after S07, the method further includes: when the electronic device determines that the wireless router has not successfully switched to the SISO mode, the electronic device adds the basic service set identifier (BSSid) of the wireless router to the blacklist. And continue to execute S08 and subsequent steps. In addition, before the electronic device adds the BSSid of the wireless router to the blacklist, the electronic device needs to first query whether the BSSid of the current wireless router exists in the blacklist. If the wireless router is not found in the blacklist, the BSSid of the wireless router can be added to the blacklist. If the wireless router is found in the blacklist, there is no need to add the wireless router to the blacklist to avoid repeatedly adding the BSSid of the unified wireless router to the blacklist. Of course, the old record can also be overwritten by overwriting.

[0179] Of course, in actual applications, the electronic device can add the BSSid of the wireless router to the blacklist at any step after S07, not necessarily before S08.

[0180] As another embodiment of the present application, after S19, the method further includes: after the electronic device receives a connection response sent by the wireless router in the SISO mode, adding the BSSID of the wireless router carried in the connection response to a blacklist.

[0181] The BSSID of the wireless router may be used as the unique identifier of the wireless router. In practical applications, other information of the wireless router may also be used as the unique identifier of the wireless router.

[0182] Of course, after the electronic device and the wireless router re-establish the communication connection in the SISO manner in S19, it can be determined that the wireless router can communicate with the electronic device in the SISO manner.

[0183] To make it clearer that after S19 , the electronic device adds the BSSID of the wireless router to the blacklist, refer to the flowchart shown in FIG. 8 .

[0184] S71: The electronic device switches the antenna mode of the electronic device to the SISO mode.

[0185] S72, the electronic device sends switching information to the wireless router.

[0186] S73, the electronic device detects whether the wireless router is switched successfully.

[0187] S74: If the wireless router fails to switch to the SISO mode, a wireless connection in the SISO mode is established with the wireless router by disconnecting and reconnecting.

[0188] S75, the electronic device adds the unique identifier of the wireless router to the blacklist.

[0189] For detailed description of each step in FIG8 , reference may be made to the description of the embodiments shown in FIG3 and FIG6 .

[0190] The following describes a switching method when the electronic device needs to switch to the SISO mode for communication again after the wireless router is added to the blacklist, with reference to the flowchart shown in FIG9 .

[0191] S81: The electronic device switches the antenna mode of the electronic device to the SISO mode.

[0192] S82: The electronic device queries whether the unique identifier of the wireless router exists in the blacklist.

[0193] S83: If the unique identifier of the wireless router exists in the blacklist, the electronic device sends switching information to the wireless router, where the switching information is used to instruct the wireless router to switch to the SISO mode.

[0194] S84, the electronic device detects whether the wireless router is switched successfully.

[0195] S85: If the wireless router fails to switch, a wireless connection in SISO mode is established with the wireless router by disconnecting and reconnecting.

[0196] S86: After the electronic device re-establishes a wireless connection with the wireless router in the SISO mode, the unique identifier of the wireless router is added to the blacklist.

[0197] In addition, after S82, if the unique identifier of the wireless router does not exist in the blacklist, the electronic device directly executes S85, establishes a wireless connection in SISO mode with the wireless router by disconnecting and reconnecting, and executes S86. After the electronic device re-establishes a wireless connection with the wireless router in SISO mode, the unique identifier of the wireless router is added to the blacklist.

[0198] When adding the unique identifier of the wireless router to the blacklist, if the unique identifier of the current wireless router already exists in the blacklist, it is not necessary to add it again or add it in an overwritten manner.

[0199] In the above embodiment, the electronic device sends the Action frame in the SMPS manner when executing S01 to send the switching information to the wireless router.

[0200] In practical applications, the electronic device may also send the switching information to the wireless router in other ways.

[0201] As another example, S01, the electronic device sending SISO switching information to the wireless router includes:

[0202] The electronic device sends an operating mode notification (OMN) to the wireless router. The operating mode notification is located in an action frame. FIG10 shows the data format of some fields of the OMN.

[0203] The Rx NSS field and the Rx NSS Type field are used together to inform the wireless router that the electronic device has switched its antenna mode to SISO mode and to instruct the wireless router to also switch to SISO mode for subsequent wireless communication with the electronic device. If the value of the Rx NSS field is 0 and the value of the Rx NSS Type field is 0, it indicates that the electronic device has switched to SISO mode.

[0204] As another example, S01, the electronic device sending SISO switching information to the wireless router includes:

[0205] The electronic device sends an operating mode indication (OMI) to the wireless router. The OMI is located in a data packet, that is, the switching information is sent in the form of a data packet. Figure 11 shows the data format of some fields of the OMI.

[0206] The Rx NSS and Tx NSTS fields are used together to notify the wireless router that the electronic device has switched its antenna mode for communication with the wireless router to SISO mode, and to instruct the wireless router to also switch to SISO mode for subsequent wireless communication with the electronic device. If the Rx NSS field value is 0 and the Tx NSTS field value is 0, it indicates that the electronic device has switched to SISO mode.

[0207] SMPS, OMN, and OMI are different switching information defined in different versions of the Wi-Fi protocol. The electronic device can determine which switching information to use based on the protocol version of the wireless communication with the wireless router.

[0208] Of course, in actual applications, the electronic device may select one or more of SMPS, OMN and OMI as switching information, and send the switching information to the wireless router to instruct the wireless router to switch the antenna mode for communicating with the electronic device to SISO.

[0209] As another example, SMPS, OMN, and OMI may be sent sequentially to instruct the wireless router to switch to SISO until any switching information triggers the wireless router to successfully switch to SISO mode or until each switching information fails to successfully trigger the wireless router to switch to SISO mode.

[0210] 12 , which is a flow chart of another antenna mode switching method provided in an embodiment of the present application.

[0211] S91, the electronic device sends SISO switching information (SMPS) to the wireless router.

[0212] In the embodiment of the present application, this step can refer to S01 to S03 in Figure 3.

[0213] That is, after the electronic device sends the SISO switching information (SMPS) to the wireless router, the wireless router sends a confirmation character of the current switching information to the electronic device after receiving the SISO switching information. The wireless router also needs to execute the SISO mode switching (which may succeed or fail).

[0214] S92: The electronic device detects whether the wireless router is successfully switched to the SISO mode.

[0215] In the embodiment of the present application, the detection method (S04 to S07) shown in Figure 3 can be used, or the detection method (S34 to S41) shown in Figure 6 can be used. Of course, other detection methods can also be used.

[0216] 13 is a flow chart showing another method of detecting whether a wireless router has successfully switched to SISO mode according to an embodiment of the present application.

[0217] S101: The electronic device sends SISO switching information in the original MIMO mode.

[0218] Of course, in actual applications, the electronic device may also switch to the SISO mode first, send the switching information through the SISO mode, and then immediately switch back to the MIMO mode after sending.

[0219] S102: After receiving the switching information sent by the electronic device, the wireless router returns a confirmation character of the switching information to the electronic device.

[0220] S103: After receiving the switching information sent by the electronic device, the wireless router performs SISO switching.

[0221] The embodiment of the present application takes switching failure as an example.

[0222] S104: When the electronic device needs to send a data packet, it sends data packet A to the wireless router in SISO mode.

[0223] In the embodiment of the present application, the electronic device does not determine whether the wireless router is currently in the original MIMO mode or switched to the SISO mode, so it needs to send data packets in the SISO mode. In actual applications, the electronic device can send data packets in the SISO mode when in the MIMO mode.

[0224] In an embodiment of the present application, the data packet sent by the sender in SISO mode can be received and successfully parsed by the receiver in both MIMO mode and SISO mode; the data packet sent by the sender in MIMO mode can be received and successfully parsed by the receiver in MIMO mode, but cannot be successfully parsed in SISO mode.

[0225] After sending data packet A, the electronic device continues to maintain the MIMO mode.

[0226] In the embodiment of the present application, after sending data packet A, the electronic device continues to maintain the MIMO mode to monitor the data packets sent by the wireless router, so as to avoid failure to successfully receive and analyze the data packets sent by the wireless router in the MIMO mode in the SISO mode.

[0227] S105: After receiving data packet A, the wireless router sends a confirmation character to the electronic device.

[0228] S106 , when there is a need to send a data packet, the wireless router sends the data packet B in MIMO mode.

[0229] S107, the electronic device receives data packet B in MIMO mode, and is able to correctly parse it, and determines based on the information in the data packet that the wireless router is currently in MIMO mode, thereby determining that the wireless router switching has failed.

[0230] As an example, the data packets in this application (e.g., data packet A and data packet B) may be Quality of Service (QoS) data frames. The NSS field in the QoS data frame may indicate, using different characters, whether the sender of the data packet is sending the data packet in MIMO mode or SISO mode.

[0231] S108 , after successfully parsing data packet B, the electronic device sends a confirmation character of data packet B to the wireless router.

[0232] In this embodiment, steps S104 and S105 may not be present, that is, steps S104 and S105 are only executed when the electronic device needs to send a data packet to the wireless router. Similarly, steps S106 are only executed when the wireless router needs to send a data packet to the electronic device.

[0233] 14 is a flow chart showing another method of detecting whether a wireless router has successfully switched to SISO mode according to an embodiment of the present application.

[0234] The contents of S201 to S205 are similar to those of S101 to S105 , and the details can be referred to the description of S101 to S105 , which will not be repeated here. In S203 , the wireless router is switched successfully.

[0235] S206, the wireless router sends data packet B in SISO mode (successfully switched).

[0236] S207, after receiving data packet B, the electronic device successfully parses data packet B and determines based on the information in data packet B that the wireless router is currently in SISO mode, thereby determining that the wireless router is switched successfully.

[0237] S208: The electronic device sends a confirmation character of data packet B to the wireless router.

[0238] S209 , after determining that the wireless router has been switched successfully, the electronic device switches the antenna mode for communicating with the wireless router to the SISO mode.

[0239] Of course, in actual applications, the following situation may occur: the wireless router may temporarily use SISO mode when sending data packet B due to speed limits or other reasons, and may also use MIMO mode when speed limits are not required. Therefore, the wireless router sends data packet B in SISO mode, causing the electronic device to mistakenly believe that the wireless router has switched to SISO mode.

[0240] To avoid this situation, the electronic device can also be set to communicate with the wireless router in a time-division manner. That is, when there is a need to send a data packet, the electronic device sends the data packet in SISO mode under MIMO mode. After sending the data packet, the electronic device continues to maintain MIMO mode to listen for data packets sent by the wireless router. Once a data packet sent by the wireless router in MIMO mode is received, it is determined that the wireless router has failed to switch (failed to switch to SISO mode). This is because the electronic device can send data packets in both SISO mode and MIMO mode in MIMO mode, but it needs to send data packets in SISO mode when in SISO mode.

[0241] 15 , in which a wireless router switching failure is used as an example.

[0242] After S105, it also includes:

[0243] S206: The wireless router sends data packet B in SISO mode due to a need to reduce speed or spatial flow.

[0244] S207, the electronic device receives data packet B in MIMO mode, and can correctly parse it, and determines based on the information in the data packet that the wireless router sent the data packet in SISO mode, thereby determining that the wireless router has successfully switched.

[0245] S208: The electronic device sends a confirmation character of data packet B to the wireless router.

[0246] In order to avoid misjudgment by electronic devices, subsequent electronic devices communicate with the wireless router in a time-sharing manner.

[0247] S302: The electronic device determines that there is a need to send data packet C.

[0248] S303: The electronic device sends data packet C to the wireless router in SISO mode.

[0249] S304: After sending the data packet C, the electronic device continues to monitor the data packets from the wireless router in MIMO mode.

[0250] S305: The wireless router sends a confirmation character of the data packet C to the electronic device.

[0251] S306: When the wireless router needs to send data packet D to the electronic device, since there is no need to reduce the speed or the number of spatial streams, the data packet D is sent to the electronic device in the current MIMO mode.

[0252] S307: The electronic device successfully parses the data packet D and determines based on the information in the data packet that the wireless router is currently in MIMO mode, thereby determining that the wireless router switching has failed.

[0253] It can be understood that this approach can avoid or reduce misjudgment of the switching status of the wireless router.

[0254] If the electronic device detects that the wireless router has successfully switched to the SISO mode, the switching process ends.

[0255] Of course, in actual applications, after the electronic device determines that the wireless router has been successfully switched in S207, it maintains the time-division mode for a certain period of time. If it is determined that the wireless router is in MIMO mode based on the data packets sent by the wireless router within the certain period of time, it is determined that the wireless router switching has failed; if it is not determined that the wireless router switching has failed based on the data packets sent by the wireless router within the certain period of time, it is considered that the wireless router switching has been successful. Therefore, the time-division mode (monitoring the data packets of the wireless router in MIMO mode) can be ended, and the antenna mode for communication between the electronic device and the wireless router is switched to SISO mode.

[0256] 13 to 15 are all about the method of detecting whether the wireless router is switched successfully in S92. Continuing to describe the flow chart of the switching method shown in FIG12.

[0257] S93: If the electronic device detects that the wireless router fails to switch to the SISO mode, it sends SISO switching information (OMN) to the wireless router.

[0258] This step may refer to S01 to S03 in FIG. 3 , where the switching information is the OMN.

[0259] That is, after the electronic device sends the SISO switching information (OMN) to the wireless router, the wireless router sends a confirmation character of the current switching information to the electronic device after receiving the SISO switching information. The wireless router also needs to execute the SISO mode switching (which may succeed or fail).

[0260] S94, the electronic device detects whether the wireless router is successfully switched to the SISO mode.

[0261] In the embodiment of the present application, the detection method shown in Figure 3 (S04 to S07) can be adopted, or the detection method shown in Figure 6 (S34 to S41) can be adopted, and of course the detection method in S92 (shown in Figures 13 to 15) can also be adopted.

[0262] If the electronic device detects that the wireless router has successfully switched to the SISO mode, the switching process ends.

[0263] S95: If the electronic device detects that the wireless router fails to switch to the SISO mode, it sends SISO switching information (OMI) to the wireless router.

[0264] This step may refer to S01 to S03 in FIG. 3 , where the switching information is OMI.

[0265] That is, after the electronic device sends the SISO switching information (OMI) to the wireless router, the wireless router sends a confirmation character of the current switching information to the electronic device after receiving the SISO switching information. The wireless router also needs to execute the SISO mode switching (which may succeed or fail).

[0266] S96, the electronic device detects whether the wireless router is successfully switched to the SISO mode.

[0267] In the embodiment of the present application, the detection method shown in Figure 3 (S04 to S07) can be adopted, or the detection method shown in Figure 6 (S34 to S41) can be adopted. Of course, the detection method in S92 can also be adopted.

[0268] If the electronic device detects that the wireless router has successfully switched to the SISO mode, the switching process ends.

[0269] If the electronic device detects that the wireless router fails to switch to the SISO mode, it may execute a disconnection and reconnection process (specifically, refer to S08 to S20 shown in FIG. 3 ).

[0270] In the above example, the wireless router is triggered to switch to SISO mode in the order of SMPS, OMN, and OMI. In actual applications, other orders can also be set, and this application does not limit the specific order.

[0271] Accordingly, if the switching method shown in FIG12 can be used to trigger the wireless router to switch to SISO mode, a corresponding blacklist and whitelist mechanism is also set up. For details, refer to the switching method shown in FIG16.

[0272] A communication connection is established between the electronic device and the wireless router in MIMO mode.

[0273] S401: The electronic device searches the blacklist for the BSSID of the wireless router.

[0274] S402: If the electronic device finds the BSSID of the wireless router in the blacklist, it re-establishes a communication connection with the wireless router in the SISO mode by using the disconnection and reconnection method in the above embodiment.

[0275] S403: If the electronic device does not find the BSSID of the wireless router in the blacklist, it searches the BSSID of the wireless router in the whitelist.

[0276] S404: If the electronic device finds the BSSID of the wireless router in the white list, it obtains the historical successful switching method of the BSSID recorded in the white list.

[0277] In the embodiment of the present application, if the BSSID of the wireless router exists in the whitelist, it means that in the past, when the electronic device and the wireless router established a communication connection in MIMO mode, the electronic device successfully triggered the wireless router to switch to SISO mode through switching information.

[0278] S405: The electronic device sends switching information to the wireless router based on the switching mode corresponding to the BSSID of the wireless router in the whitelist.

[0279] As an example, if the switching mode recorded in the whitelist is SMPS, the Action frame of the SMPS mode continues to be sent to the wireless router. For details, please refer to the description in S91.

[0280] As another example, if the switching mode recorded in the whitelist is OMN, then the OMN continues to be sent to the wireless router. For details, please refer to the description in S93.

[0281] As another example, if the switching mode recorded in the whitelist is OMI, then OMI is continued to be sent to the wireless router. For details, please refer to the description in S95.

[0282] S406: The electronic device detects whether the wireless router is switched successfully.

[0283] If it is detected that the wireless router is switched successfully, communication with the wireless router can be carried out in a time-division manner, and details are described in the above embodiment.

[0284] If it is detected that the wireless router switching fails, the BSSID of the wireless router can be added to the blacklist, and a communication connection can be established with the wireless router in SISO mode by disconnecting and reconnecting.

[0285] After S403, there may be another situation: the BSSID of the wireless router is not found in the whitelist. That is, the BSSID of the wireless router does not exist in both the blacklist and the whitelist, which is equivalent to the electronic device establishing a communication connection with the wireless router in MIMO mode, but has not yet triggered the wireless router to switch to SISO mode by sending switching information. That is, it is executed according to the flow chart shown in Figure 12. Among them, when it is detected that the wireless router switches successfully, the BSSID of the wireless router and the switching method (SMPS, OMN or OMI) used when the switching is successful can be recorded in the whitelist. For details, please refer to S407, S408 and S409 in Figure 16. When it is detected that the wireless router switches unsuccessfully, the BSSID of the wireless router can be added to the blacklist.

[0286] In the embodiment shown in FIG15 , if the wireless router fails to switch but is mistakenly judged to be a successful switch, the BSSID of the wireless router will be added to the whitelist. However, if a subsequent switch failure is detected, the wireless router will continue to be triggered to switch to SISO mode through other switching methods. If the wireless router is successfully triggered to switch to SISO mode through other methods, the successful switching method corresponding to the BSSID of the wireless router is recorded in the whitelist in an overwritten manner (the switching method previously recorded in the whitelist may be a mistaken judgment). Of course, if all other methods fail to trigger the wireless router to switch to SISO mode, the BSSID of the wireless router is added to the blacklist (at this time, the whitelist may record a switching method that was mistakenly judged to be successful). The implementation of the embodiment of the present application requires first executing S301 to query the BSSID of the wireless router in the blacklist. If the BSSID of the wireless router is found in the blacklist, the disconnection and reconnection method is directly adopted. Even if the whitelist may record a switching method that was mistakenly judged to be successful, it does not affect the implementation of the embodiment of the present application.

[0287] In actual application, when the BSSID of the wireless router is added to the blacklist, it is possible to check whether the BSSID of the wireless router exists in the whitelist. If so, the BSSID of the wireless router and the corresponding switching method in the whitelist are deleted.

[0288] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.

[0289] An embodiment of the present application further provides a computer-readable storage medium, which stores a computer program. When the computer program is run on an electronic device, it can implement the steps in the above-mentioned various method embodiments.

[0290] The embodiments of the present application further provide a computer program product. When the computer program product is run on an electronic device or a wireless router, the electronic device can implement the steps in the above-mentioned various method embodiments.

[0291] 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 computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, which can be completed by instructing the relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and when the computer program is executed by the processor, it can implement the steps of the above-mentioned various method embodiments. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may include at least: any entity or device capable of carrying the computer program code to the first device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electric carrier signal, a telecommunication signal and a software distribution medium. For example, a USB flash drive, a mobile hard disk, a magnetic disk or an optical disk. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electric carrier signals and telecommunication signals.

[0292] The present application also provides a chip comprising a processor coupled to a memory, wherein the processor invokes a computer program stored in the memory to implement the steps of any method embodiment of the present application. The chip may be a single chip or a chip module composed of multiple chips.

[0293] In the above embodiments, the description of each embodiment has its own focus. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant description of other embodiments.

[0294] Those skilled in the art will appreciate that the units and method steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0295] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the various embodiments of the present application, and should all be included in the scope of protection of the present application.

Claims

1. A method for switching antenna modes, characterized in that: include: When a wireless communication connection is established between an electronic device and a wireless router in MIMO mode, the electronic device sends first switching information to the wireless router, where the first switching information is used to instruct the wireless router to switch the antenna mode for communicating with the electronic device to the SISO mode; The electronic device monitors the data packets sent by the wireless router in MIMO mode; After receiving the first data packet sent by the wireless router in the MIMO mode, the electronic device determines, according to information carried in the first data packet, whether the wireless router successfully switches to the SISO mode based on the first switching information.

2. The method according to claim 1, wherein Determining, according to the information carried in the first data packet, whether the wireless router successfully switches to the SISO mode based on the first switching information includes: When the information carried in the first data packet indicates that the wireless router sends the first data packet in the SISO mode, the electronic device determines that the wireless router successfully switches to the SISO mode based on the first switching information; When the information carried in the first data packet indicates that the wireless router sends the first data packet in MIMO mode, the electronic device determines that the wireless router fails to switch to SISO mode based on the first switching information.

3. The method according to claim 1 or 2, wherein: After determining, according to the information carried in the first data packet, that the wireless router successfully switches to the SISO mode based on the first switching information, the method further includes: The electronic device switches the antenna mode of the electronic device from the MIMO mode to the SISO mode, and communicates with the wireless router in the SISO mode.

4. The method according to claim 1 or 2, wherein: After determining, according to the information carried in the first data packet, that the wireless router successfully switches to the SISO mode based on the first switching information, the method further includes: The electronic device monitors the data packets sent by the wireless router in MIMO mode.

5. The method according to claim 1 or 4, wherein: When the electronic device monitors the data packet sent by the wireless router in MIMO mode, the method further includes: When the electronic device needs to send a second data packet to the wireless router, the electronic device sends the second data packet to the wireless router in a SISO mode.

6. The method according to claim 4, wherein After the electronic device determines, based on the information carried in the first data packet, that the wireless router has successfully switched to the SISO mode based on the first switching information, while monitoring the data packets sent by the wireless router in the MIMO mode, the method further includes: The electronic device receives a fourth data packet sent by the wireless router within the first time period, and information carried in the fourth data packet indicates that the wireless router sends the fourth data packet in MIMO mode; determining, by the electronic device, that the wireless router fails to switch to the SISO mode based on the first switching information; The electronic device does not receive a fourth data packet sent by the wireless router within a first time period, and the information carried in the fourth data packet indicates that the wireless router sends the fourth data packet in MIMO mode; The electronic device determines that the wireless router successfully switches to the SISO mode based on the first switching information.

7. The method according to claim 1 or 2, wherein: When the electronic device determines that the wireless router fails to switch to the SISO mode based on the first switching information, the method further includes: The electronic device sends second switching information to the wireless router, where the second switching information is used to instruct the wireless router to switch the antenna mode for communicating with the electronic device to the SISO mode; detecting, by the electronic device, whether the wireless router successfully switches to the SISO mode based on the second switching information; If the wireless router fails to switch to the SISO mode based on the second switching information, the electronic device sends third switching information to the wireless router, where the third switching information is used to instruct the wireless router to switch the antenna mode for communicating with the electronic device to the SISO mode; The electronic device detects whether the wireless router successfully switches to the SISO mode based on the third switching information.

8. The method according to claim 7, wherein The first switching information, the second switching information, and the third switching information are different from each other and are respectively one of SMPS, OMN, and OMI.

9. The method according to claim 7, wherein When the electronic device detects that the wireless router fails to switch to the SISO mode based on the third switching information, the method further includes: The electronic device interrupts the wireless communication connection with the wireless router; After interrupting the wireless communication connection between the electronic device and the wireless router, the electronic device sends an association request to the wireless router, where the antenna mode of the electronic device carried in the association request is the SISO mode, and the association request is used to establish a wireless communication connection with the wireless router through the SISO mode.

10. The method according to claim 1, wherein After determining that the wireless router has successfully switched to the SISO mode, the electronic device further includes: The electronic device stores a switching mode that triggers the wireless router to successfully switch to the SISO mode and a unique identifier of the wireless router in a white list, wherein the switching mode corresponds to one of SMPS, OMN and OMI.

11. The method according to claim 10, wherein Before the electronic device sends the first switching information to the wireless router, the method further includes: The electronic device fails to find the unique identifier of the wireless router from the white list.

12. The method according to claim 11, wherein The method further comprises: The electronic device queries the whitelist to obtain a switching mode corresponding to the unique identifier of the wireless router; The electronic device triggers the wireless router to switch the antenna mode for communication between the wireless router and the electronic device to the SISO mode through the queried switching mode.

13. The method according to claim 12, wherein: After the electronic device triggers the wireless router to switch the antenna mode for communication between the wireless router and the electronic device to the SISO mode through the queried switching mode, the method further includes: If the electronic device detects that the switching of the wireless router triggered by the queried switching method fails, it uses other switching methods to trigger the wireless router to switch the antenna mode for communication between the wireless router and the electronic device to the SISO mode, wherein the other switching method is different from the queried switching method.

14. The method according to claim 7, wherein When the electronic device detects that the wireless router fails to switch to the SISO mode based on the third switching information, the method further includes: The unique identifier of the wireless router is added to a blacklist.

15. The method according to claim 14, wherein Before the electronic device sends the first switching information to the wireless router, the method further includes: The unique identifier of the wireless router is not found from the blacklist; Correspondingly, if the unique identifier of the wireless router is found from the blacklist, a communication connection with the wireless router is re-established in the SISO mode by adopting a disconnection and reconnection method.

16. The method according to claim 15, wherein When the unique identifier of the wireless router is not found in the blacklist, the method further includes: The electronic device queries the whitelist for the unique identifier of the wireless router, and the whitelist stores a switching mode for successfully triggering the wireless router to switch to the SISO mode when the electronic device and the wireless router establish a communication connection in the MIMO mode.

17. An electronic device, characterized in that: The electronic device comprises one or more processors and one or more memories; wherein the one or more memories are coupled to the one or more processors, and the one or more memories are used to store a computer program, and when the one or more processors execute the computer program, the electronic device executes the method according to any one of claims 1 to 16.

18. A chip system, applied to electronic equipment, comprising one or more processors, characterized in that: The processor is configured to call computer instructions so that the electronic device executes the method according to any one of claims 1 to 16.

19. A computer-readable storage medium comprising a computer program, characterized in that When the computer program is run on an electronic device, the electronic device is caused to execute the method according to any one of claims 1 to 16.

Citation Information

Patent Citations

  • Terminal antenna switching control method and terminal

    CN106231662A

  • Wireless router and method for determining antenna working mode thereof

    CN106412987A

  • Communication control method and system

    CN110692205A

  • Wireless data transmission method and related equipment thereof

    CN114205879A

  • Power consumption adjustment method and device, equipment, storage medium and program product

    CN115361736A