Data interaction method and device
By establishing an end-tube channel in the wireless LAN between STA and AP, STA and AP can quickly interact with channel abnormal information and measurement results, and jointly decide on the switched wireless channel, solving the problem of poor network stability when the channel abnormality is solved, and achieving the effect of quickly restoring communication connections and improving network stability.
Patent Information
- Application Number
- CN202311461892.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-01
- Publication Date
- 2025-05-13
AI Technical Summary
In a wireless LAN, communication connection between the STA and the AP may have abnormalities when the network is in poor condition, resulting in poor network stability of the STA and the STA cannot quickly determine channel abnormalities and switch.
By establishing an end-tube channel between the STA and the AP, the STA can quickly inform the AP when it detects a channel abnormality, and interact with the respective measurement results through the end-tube channel to jointly decide the switched wireless channel.
This method can quickly propagate channel abnormal information between STA and AP, save the overhead of STA for channel measurement, reduce network detection time, and restore communication connections without the user's perception, thereby improving network stability.
Smart Images

Figure CN119997114A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of electronic equipment, and in particular to a data interaction method and device. Background Art
[0002] In a wireless local area network, a station (STA) accesses the Ethernet by connecting to a wireless access point (AP) to perform related communication services.
[0003] When the network condition is not good, the communication connection between the STA and the AP may be abnormal. Usually, the STA and the AP can only determine the abnormality of the communication connection based on channel measurement after a period of time has passed since the abnormality occurred. After determining the abnormality of the communication connection, the STA can only wait for the abnormality to recover or re-establish the communication connection in response to the user's operation. However, this will result in poor network stability of the STA. Summary of the invention
[0004] The embodiments of the present application provide a data interaction method and device, which are applied in the technical field of electronic equipment.
[0005] In a first aspect, an embodiment of the present application provides a data interaction method, which is applied to a first device, and a communication connection is established between the first device and a second device. The method includes:
[0006] Establishing an end-pipe channel with the second device, wherein the end-pipe channel is used for the first device and the second device to exchange device information;
[0007] When it is determined that the communication connection with the second device meets the channel abnormality condition, sending indication information to the second device through the end pipe channel, where the indication information is used to indicate that a channel abnormality occurs in the communication connection between the first device and the second device;
[0008] Performing channel measurement on a plurality of channels to be selected to obtain a first measurement result;
[0009] Acquire, through the end pipe channel, second measurement results of the second device for the plurality of channels to be selected;
[0010] According to the first measurement result and the second measurement result, a wireless channel corresponding to the communication connection between the first device and the second device is switched.
[0011] In this implementation, by establishing an end-pipe channel for exchanging device information between the first device and the second device, when the first device determines that the wireless channel of the communication connection is abnormal, the channel abnormality can be quickly notified to the second device through the end-pipe channel, so as to save the overhead of the second device needing to perform channel measurement to determine the channel abnormality, and speed up the second device to determine the channel abnormality, and reduce the network detection time. In addition, the first device and the second device exchange their respective measurement results through the end-pipe channel, and finally the first device and the second device switch the wireless channel of the communication connection based on the measurement results of both parties, so that the communication connection between the first device and the second device can be restored as soon as possible without the user's perception, thereby improving the network stability of the first device or the second device.
[0012] In some implementations, the switching, according to the first measurement result and the second measurement result, of a wireless channel corresponding to the communication connection between the first device and the second device includes:
[0013] Determining a target channel from a plurality of candidate channels according to the first measurement result and the second measurement result;
[0014] The wireless channel corresponding to the communication connection between the first device and the second device is switched to the target channel.
[0015] In some implementations, determining a target channel from a plurality of candidate channels according to the first measurement result and the second measurement result includes:
[0016] Determine a first channel from the multiple channels to be selected according to the first measurement result and the second measurement result, wherein the channel quality of the first channel meets a preset condition;
[0017] Acquire, through the end pipe channel, a second channel determined by the second device from the multiple channels to be selected, wherein the channel quality of the second channel satisfies the preset condition;
[0018] The target channel is determined among the first channel and the second channel.
[0019] In this implementation, the first device and the second device both select a channel with better channel quality from multiple channels to be selected, and then select a target channel from the first channel determined by the first device and the second channel determined by the second device, thereby effectively improving the comprehensiveness of the information referenced by the selected target channel, thereby improving the effectiveness and accuracy of the selection of the target channel.
[0020] In some implementations, determining the target channel in the first channel and the second channel includes:
[0021] If the first channel and the second channel are consistent, determining the first channel as the target channel;
[0022] If the first channel and the second channel are inconsistent, a target channel is determined in the first channel and the second channel based on a preset strategy, and the target channel is synchronized between the first device and the second device through the end pipe channel.
[0023] In this implementation, when the first channel and the second channel are inconsistent, a target channel is selected from the two channels according to a certain strategy, and the selection results of both parties are synchronized through the end pipe channel, thereby ensuring that the first device and the second device can eventually switch channels based on the same target channel.
[0024] In some implementations, after performing channel measurement on the multiple channels to be selected to obtain the first measurement result, the method further includes:
[0025] The first measurement result is transmitted to the second device through the end tube channel.
[0026] In some implementations, if the first device is an AP device and the second device is a STA device, the method further includes:
[0027] When the first device detects a device failure, it sends guidance information to the second device through the end pipe channel, where the guidance information is used to instruct the second device to switch to establish a communication connection with other devices.
[0028] In some implementations, if the first device is a STA device and the second device is an AP device, the method further includes:
[0029] When the second device detects a device failure, receiving guidance information sent by the second device through the end pipe channel, wherein the guidance information is used to instruct the first device to switch to establish a communication connection with other devices;
[0030] In response to the guidance information, the communication connection with the second device is disconnected, and a communication connection is established with a third device.
[0031] In this implementation, when the AP device fails, guidance information is sent to the STA device through the end pipe channel so that the STA device can switch the communication connection as soon as possible, thereby effectively shortening the network disconnection time of the STA device and improving the network stability of the STA device.
[0032] In a second aspect, an embodiment of the present application provides a data interaction method, which is applied to a second device, and a communication connection is established between the second device and the first device. The method includes:
[0033] Establishing an end-pipe channel with the first device, wherein the end-pipe channel is used for the first device and the second device to exchange device information;
[0034] receiving, through the end pipe channel, indication information sent by the first device, the indication information being used to indicate that a channel abnormality occurs in the communication connection between the first device and the second device;
[0035] In response to the indication information, performing channel measurement on a plurality of channels to be selected to obtain a second measurement result;
[0036] Acquire, through the end pipe channel, first measurement results of the first device for the multiple channels to be selected;
[0037] According to the first measurement result and the second measurement result, a wireless channel corresponding to the communication connection between the first device and the second device is switched.
[0038] In some implementations, the switching, according to the first measurement result and the second measurement result, of a wireless channel corresponding to the communication connection between the first device and the second device includes:
[0039] Determining a target channel from a plurality of candidate channels according to the first measurement result and the second measurement result;
[0040] The wireless channel corresponding to the communication connection between the first device and the second device is switched to the target channel.
[0041] In some implementations, determining a target channel from a plurality of candidate channels according to the first measurement result and the second measurement result includes:
[0042] Determine a second channel from the multiple channels to be selected according to the first measurement result and the second measurement result, wherein the channel quality of the second channel meets a preset condition;
[0043] Acquire, through the end pipe channel, a first channel determined by the first device from among the multiple channels to be selected, wherein the channel quality of the first channel satisfies the preset condition;
[0044] The target channel is determined among the first channel and the second channel.
[0045] In some implementations, determining the target channel in the first channel and the second channel includes:
[0046] If the first channel and the second channel are consistent, determining the first channel as the target channel;
[0047] If the first channel and the second channel are inconsistent, a target channel is determined in the first channel and the second channel based on a preset strategy, and the target channel is synchronized between the first device and the second device through the end pipe channel.
[0048] In some implementations, after performing channel measurement on a plurality of candidate channels in response to the indication information to obtain a second measurement result, the method further includes:
[0049] The second measurement result is sent to the first device through the end tube channel.
[0050] In some implementations, if the second device is a STA device and the first device is an AP device, the method further includes:
[0051] When the first device detects a device failure, receiving guidance information sent by the first device through the end pipe channel, wherein the guidance information is used to instruct the second device to switch to establish a communication connection with other devices;
[0052] In response to the guidance information, the communication connection with the first device is disconnected, and a communication connection is established with a third device.
[0053] In some implementations, if the second device is an AP device and the first device is a STA device, the method further includes:
[0054] When the second device detects a device failure, guidance information is sent to the second device through the end pipe channel, where the guidance information is used to instruct the first device to switch to establish a communication connection with other devices.
[0055] In a third aspect, an embodiment of the present application provides a data interaction device, including:
[0056] A processing module, used to establish an end-pipe channel with the second device, wherein the end-pipe channel is used for the first device and the second device to exchange device information;
[0057] a sending module, configured to send indication information to the second device through the end pipe channel when it is determined that the communication connection with the second device meets the channel abnormality condition, wherein the indication information is used to indicate that a channel abnormality occurs in the communication connection between the first device and the second device;
[0058] The processing module is further used to perform channel measurement on a plurality of channels to be selected to obtain a first measurement result;
[0059] The processing module is further used to obtain, through the end pipe channel, second measurement results of the second device for the multiple channels to be selected;
[0060] The processing module is further configured to switch a wireless channel corresponding to the communication connection between the first device and the second device according to the first measurement result and the second measurement result.
[0061] In a fourth aspect, an embodiment of the present application provides a data interaction device, including:
[0062] A processing module, used to establish an end-pipe channel with the first device, wherein the end-pipe channel is used for the first device to exchange device information with the second device;
[0063] a sending module, configured to receive indication information sent by the first device through the end pipe channel, wherein the indication information is used to indicate that a channel abnormality occurs in the communication connection between the first device and the second device;
[0064] The processing module is further configured to perform channel measurement on a plurality of channels to be selected in response to the indication information to obtain a second measurement result;
[0065] The processing module is further used to obtain, through the end pipe channel, a first measurement result of the first device for the multiple channels to be selected;
[0066] The processing module is further configured to switch a wireless channel corresponding to the communication connection between the first device and the second device according to the first measurement result and the second measurement result.
[0067] In a fifth aspect, an embodiment of the present application provides an electronic device, comprising: a processor and a memory; the memory stores computer-executable instructions; the processor executes the computer-executable instructions stored in the memory, so that the electronic device executes the method of the first aspect or the second aspect.
[0068] In a sixth aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program. When the computer program is executed by a processor, the method of the first aspect or the second aspect is implemented.
[0069] In a seventh aspect, an embodiment of the present application provides a computer program product, which includes a computer program. When the computer program is executed, the computer executes the method of the first aspect or the second aspect.
[0070] In an eighth aspect, an embodiment of the present application provides a chip, the chip including a processor, the processor being used to call a computer program in a memory to execute the method described in the first aspect or the second aspect.
[0071] It should be understood that the second to eighth aspects of the present application correspond to the technical solutions of the first aspect of the present application, and the beneficial effects achieved by each aspect and the corresponding feasible implementation methods are similar and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0072] Figure 1 A schematic diagram of a communication scenario provided in an embodiment of the present application;
[0073] Figure 2 A signaling interaction diagram of a data interaction method provided in an embodiment of the present application;
[0074] Figure 3 Signaling interaction of the data interaction method provided in the embodiment of the present application Figure 2 ;
[0075] Figure 4 Signaling interaction of the data interaction method provided in the embodiment of the present application Figure 3 ;
[0076] Figure 5 A signaling interaction diagram for establishing an end-pipe channel provided in an embodiment of the present application;
[0077] Figure 6 A schematic diagram of the structure of the data interaction device provided in the embodiment of the present application Figure 1 ;
[0078] Figure 7 A schematic diagram of the structure of the data interaction device provided in the embodiment of the present application Figure 2 ;
[0079] Figure 8 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0080] In order to facilitate the clear description of the technical solutions of the embodiments of the present application, in the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or explanations. Any embodiment or design described as "exemplary" or "for example" in the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.
[0081] In the embodiments of the present application, "at least one" refers to one or more, and "plurality" refers to two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the previous and next associated objects are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, or c can represent: a, b, c, ab, ac, bc, or abc, where a, b, c can be single or multiple.
[0082] It should be noted that the "at..." in the embodiment of the present application can be the instant when a certain situation occurs, or a period of time after a certain situation occurs, and the embodiment of the present application does not specifically limit this. In addition, the display interface provided in the embodiment of the present application is only an example, and the display interface can also include more or less content.
[0083] In order to better understand the technical solution of the present application, the relevant technologies involved in the present application are further introduced in detail below.
[0084] First combine Figure 1 The application scenario of this application is described. Figure 1 A schematic diagram of a communication scenario provided in an embodiment of the present application. Figure 1 In this communication scenario, one end is an AP device and the other end is a STA device.
[0085] Among them, AP is the creator of a wireless network and the central node of the network. The wireless router used in general homes or offices is an AP. Furthermore, AP can be understood as the access point for mobile users to enter the wired network. It is mainly deployed in homes, buildings and campuses. The typical coverage radius is tens of meters to hundreds of meters. Of course, it can also be deployed outdoors. AP is equivalent to a bridge connecting wired and wireless networks. Its main function is to connect various wireless network clients together and then connect the wireless network to Ethernet. Specifically, AP can be a terminal device or network device with a wireless fidelity (WiFi) chip.
[0086] Among them, STA refers to a device connected to a wireless network. Each device connected to an AP is considered a station. In a wireless network, communication between stations is carried out through an AP. Exemplarily, a STA can be a wireless communication chip, a wireless sensor, or a wireless communication terminal. For example, a mobile phone that supports WiFi communication function, a tablet computer that supports WiFi communication function, a set-top box that supports WiFi communication function, a smart TV that supports WiFi communication function, a smart wearable device that supports WiFi communication function, a vehicle-mounted communication device that supports WiFi communication function, and a computer that supports WiFi communication function.
[0087] The STA in the communication system may also be referred to as an access terminal, user equipment, user unit, user station, mobile station, mobile station, remote station, remote terminal, mobile device, user terminal, terminal, wireless communication device, user agent or user device. The user equipment may be a cellular phone, a cordless phone, a Session Initiation Protocol (full name: Session Initiation Protocol, referred to as: SIP) phone, a wireless local loop (full name: Wireless Local Loop, referred to as: WLL) station, a personal digital processing (full name: Personal Digital Assistant, referred to as: PDA), a handheld device with wireless communication function, a computing device or other processing device connected to a wireless modem, a vehicle-mounted device, a wearable device, and a user device in a 5G network. As an example and not limitation, in an embodiment of the present application, the STA device may also be a wearable device. Wearable devices may also be referred to as wearable smart devices.
[0088] The relationship between AP and STA is that AP provides the opportunity to access the network wirelessly, while STA is the actual device connected to the network through AP. The communication range of STA is determined by the coverage range of AP, and only STA within the coverage range of AP can connect to the network.
[0089] In the actual implementation process, the specific implementation methods of the AP device and the STA device can be selected according to actual needs. This embodiment does not limit this. As long as the AP device can be used as an access point and the STA device can be used as a site, it can be used.
[0090] Based on the above introduction, it can be determined that STA devices can establish communication connections with AP devices to access Ethernet. However, when the network conditions are poor, the communication connection between STA and AP may be abnormal. These abnormalities may be caused by large channel interference, abnormal negotiation rate, AP device network port failure, etc. Regardless of which abnormal situation occurs, STA can only determine that the communication connection is abnormal based on a period of network detection. And for network abnormalities caused by AP device failure, STA cannot determine the cause of the abnormality.
[0091] After determining that an abnormality has occurred, the STA device can only wait for the network abnormality to recover, or re-establish a communication connection with the AP in response to a user's network reconnection operation, which will result in poor network stability of the STA device.
[0092] In response to the technical problems introduced above, this application proposes the following technical ideas: establish an end-pipe channel between AP and STA, where the end-pipe channel is used to exchange device information between AP and STA, so that AP and STA can quickly obtain the network abnormality and cause in a very short time, reducing the network detection time. In addition, AP and STA can also negotiate channel switching based on the end-pipe channel, thereby improving the quality of communication connection without user perception, so as to ensure the network stability of STA devices.
[0093] The data interaction method provided by the present application is described below in conjunction with specific embodiments. First of all, it should be noted that the contents introduced in the following embodiments include the interaction between the first device and the second device. In the contents described in the following embodiments, the first device is a device that actively initiates channel measurement and determines that the communication connection is abnormal, and the second device is a device that obtains the communication connection abnormality based on the end pipe channel.
[0094] In the actual implementation process, the first device may be an AP device, and the second device may be a STA device, that is, the AP device performs channel measurement to determine that the communication connection is abnormal, and informs the STA device through the end pipe channel.
[0095] Alternatively, the first device may be a STA device and the second device may be an AP device, that is, the STA device performs channel measurement to determine network abnormalities and informs the AP device through the end-pipe channel.
[0096] Both implementation methods are feasible in the present application. In the actual implementation process, which of the above implementation methods is used depends on which party's equipment initiates the channel measurement and determines the communication connection abnormality, and then the technical solution of the present application can be applied.
[0097] Based on the above introduction, the following first combines Figure 2 The technical solution of this application is introduced. Figure 2 A signaling interaction diagram of the data interaction method provided in an embodiment of the present application.
[0098] like Figure 2 As shown, the method includes:
[0099] S201: A first device and a second device establish an end-pipe channel, where the end-pipe channel is used for the first device and the second device to exchange device information.
[0100] In this embodiment, the first device can establish an end-pipe channel with the second device. The end-pipe channel in this embodiment is used for the first device and the second device to exchange device information. Specifically, the first device can send the device information of the first device to the second device based on the end-pipe channel, and can obtain the device information of the second device based on the end-pipe channel. Also, the second device can send the device information of the second device to the first device based on the end-pipe channel, and can obtain the device information of the first device based on the end-pipe channel.
[0101] It should be emphasized that the end-pipe channel in the present application is not a channel used as a backup link between the first device and the second device, and it does not undertake the work of transmitting business data, but is used for the first device and the second device to exchange their respective device information, so that the first device and the second device can perceive each other's device-related information. Device information may include, for example, network status information, business status information, etc. of the device. The specific implementation of device information can also be selected and expanded according to actual needs. In short, device information does not contain specific business data, and is usually information with a small amount of data. In one possible implementation method, all relevant information used to reflect the device itself can be used as device information in this application, for example, it can also include hardware parameters, software parameters, etc. of the device.
[0102] Exemplarily, the end-pipe channel in the present application may be a layer-2 transmission channel established based on the network layer, wherein the layer-2 may be understood as any hierarchical structure above the link layer.
[0103] In a possible implementation, after the STA device is started, or after the AP device is started, in response to the device starting up, the end-pipe channel can be established between the STA device and the AP device. Alternatively, the end-pipe channel can be established in response to an abnormal connection state between the first device and the second device.
[0104] S202: The first device determines that the communication connection between the first device and the second device satisfies a channel abnormality condition.
[0105] In this embodiment, a communication connection is established between the first device and the second device, wherein the communication connection between the first device and the second device can be, for example, a connection established based on the SSID (Service Set Identifier) and password of the AP device. The purpose of the communication connection between the first device and the second device is to transmit service data between the first device and the second device.
[0106] Exemplarily, the first device may perform channel measurement periodically, or the first device may also perform channel measurement at a certain triggering opportunity, so as to determine whether the communication connection between the first device and the second device meets the channel abnormality condition.
[0107] The channel abnormality condition may be, for example, that the channel parameters of the wireless channel corresponding to the communication connection meet the corresponding preset threshold. For example, the channel parameters may include at least one of the following: bit error rate (BER), spectrum density, bandwidth, signal-to-noise ratio (SNR), signal power, etc. For each channel parameter, a corresponding preset threshold may be set.
[0108] The first device performs channel measurement to determine the channel parameters of the wireless channel corresponding to the communication connection between the first device and the second device. For any channel parameter, it is compared with the corresponding preset threshold. If the relationship with the preset threshold is satisfied, it can be determined that the communication connection between the first device and the second device satisfies the channel abnormality condition.
[0109] Exemplarily, when the communication connection satisfies the channel abnormality condition, it can be determined that there is an abnormality in the wireless channel between the first device and the second device. More specifically, it can be understood that the channel interference between the first device and the second device is large.
[0110] It should be emphasized that the communication connection between the first device and the second device and the end-pipe channel established between the first device and the second device introduced above need to be understood separately, that is, the communication connection between the first device and the second device is not based on the end-pipe channel.
[0111] On the one hand, the end-pipe channel and the communication connection correspond to two independent data transmission links, so an abnormality in the communication connection will not affect the end-pipe channel.
[0112] On the other hand, if the communication connection is abnormal due to the poor network environment between the first device and the second device, it will not affect the end-pipe channel. Because the first device and the second device exchange business data based on the communication connection, and the amount of business data is usually very large, it will have a great impact on the second device when the communication connection is abnormal. The first device and the second device only exchange device information related to the communication connection based on the end-pipe channel, so the amount of data to be exchanged based on the end-pipe channel is very small. Because of this, the communication connection abnormality caused by the poor network environment will not have much impact on the data transmission of the end-pipe channel.
[0113] Furthermore, the communication connection itself is responsible for the transmission of business data, so transmitting device information based on the end-pipe channel can reduce interference with business data. At the same time, the end-pipe channel in this embodiment can be understood as a private data channel between the first device and the second device, so data transmission can be completed efficiently based on the end-pipe channel.
[0114] S203: The first device sends indication information to the second device through the end pipe channel, where the indication information is used to indicate that a channel abnormality occurs in the communication connection between the first device and the second device.
[0115] After the first device determines that the communication connection between the first device and the second device meets the channel abnormality condition, it can send indication information to the second device through the end pipe channel. The indication information is used to indicate that the communication connection between the first device and the second device is abnormal, so that the second device can quickly obtain the channel abnormality in a very short time, and the second device does not need to perform channel measurement.
[0116] Therefore, in the technical solution of the present application, on the one hand, the system overhead of the second device for channel measurement can be saved, and on the other hand, the speed at which the second device obtains channel anomalies can be accelerated, thereby quickly advancing subsequent operations and avoiding the second device being in a state of abnormal communication connection for a long time.
[0117] In an optional implementation, the indication information may also include the reason why the channel abnormality occurs in the communication connection between the first device and the second device. For example, after measurement, if the first device determines that the bit error rate of the wireless channel is too high, then the indication information may include notification information that the bit error rate is too high, so that the second device can clearly understand the specific reason for the channel abnormality.
[0118] S204: The second device performs channel measurement on a plurality of candidate channels in response to the indication information to obtain a second measurement result.
[0119] When the communication connection between the first device and the second device is poor due to channel abnormality, the wireless channel between the first device and the second device can be switched to a channel with better quality, which can solve the problem of poor communication connection to a certain extent.
[0120] Then the first device and the second device need to negotiate a target channel to be switched from multiple channels to be selected. Therefore, after receiving the indication information, the second device can respond to the indication information and perform channel measurement on the multiple channels to be selected, thereby obtaining a second measurement result, which includes the channel measurement results of each of the multiple channels to be selected measured by the second device.
[0121] The channel measurement may measure, for example, one or more parameters such as the channel transmission rate, signal-to-noise ratio, channel gain, noise power, etc. The corresponding second measurement result includes the above parameters corresponding to each selected channel. In the actual implementation process, the specific parameters measured by the channel measurement may also be selected and expanded according to actual needs.
[0122] S205. The second device sends the second measurement result to the first device through the end pipe channel.
[0123] After performing channel measurement to obtain the second measurement result, the second device can send the second measurement result to the first device through the end pipe channel. Sending the second measurement result based on the end pipe channel can effectively ensure the transmission stability and security of the second measurement result.
[0124] S206: The first device performs channel measurement on multiple channels to be selected to obtain a first measurement result.
[0125] In this embodiment, the first device also needs to perform channel measurement on multiple channels to be selected. The implementation method of the channel measurement is similar to that described above. After the first device performs the channel measurement, a first measurement result can be obtained.
[0126] S207: The first device sends the first measurement result to the second device through the end pipe channel.
[0127] Afterwards, the first device may send the first measurement result to the second device through the end-pipe channel. Similarly, sending the first measurement result through the end-pipe channel may effectively ensure the transmission security and stability of the first measurement result.
[0128] In this embodiment, the three steps S203 to S205 are taken as a whole, and the two steps S206 to S207 are taken as a whole, and the execution order of these two parts can be exchanged. That is to say, S203 to S205 can be executed first, and then S206 to S207, or S206 to S207 can be executed first, and then S203 to S205, or they can be executed in parallel, which is not limited in this embodiment and depends on the actual implementation.
[0129] S208: The first device and the second device switch the wireless channel corresponding to the communication connection between the first device and the second device according to the first measurement result and the second measurement result.
[0130] Based on the above introduction, the first device and the second device can both obtain the first measurement result measured by the first device and the second measurement result measured by the second device. Therefore, the first device and the second device can switch the wireless channel corresponding to the communication connection between the first device and the second device according to the first measurement result and the second measurement result.
[0131] Among them, when the wireless channel corresponding to the communication connection between the first device and the second device is switched according to the first measurement result and the second measurement result, a target channel with better quality can be selected from multiple channels to be selected according to the first measurement result and the second measurement result, and then the wireless channel corresponding to the communication connection between the first device and the second device is switched to the target channel.
[0132] Because the wireless channel between the first device and the second device is switched to a target channel with better quality, the problem of channel abnormality can be solved to a certain extent. The communication connection quality between the first device and the second device can be quickly and efficiently improved without the user's perception, thereby improving the network stability of the second device.
[0133] In a possible implementation, the first device and the second device may respectively perform an operation of selecting a target channel with better quality from multiple channels to be selected based on the first measurement result and the second measurement result, and then after both parties have negotiated the same target channel, the wireless channel corresponding to the communication connection between the first device and the second device is switched to the target channel. In this implementation, both the first device and the second device perform a channel selection operation, and then determine the target channel based on the selections of both parties, which can effectively improve the comprehensiveness of the reference information of the target channel finally determined.
[0134] Alternatively, only one of the first device and the second device may perform the operation of selecting a target channel with better quality from multiple channels to be selected based on the first measurement result and the second measurement result. If the first device performs the operation of selecting the target channel, then the first device may send notification information of the target channel to the second device through the end pipe channel; or, if the second device performs the operation of selecting the target channel, then the second device may send notification information of the target channel to the first device through the end pipe. After the first device and the second device synchronize the target channel, the first device and the second device respectively switch the wireless channel corresponding to the communication connection between the two parties to the target channel. In this implementation, only one of the first device and the second device performs the channel selection operation, and the other party can quickly obtain the determined target channel through the end pipe channel, thereby effectively saving the system overhead of one device.
[0135] The data interaction method provided by the embodiment of the present application includes: a first device and a second device establish an end-pipe channel, and the end-pipe channel is used for the first device and the second device to exchange device information. The first device determines that the communication connection between the first device and the second device meets the channel abnormality condition. The first device sends indication information to the second device through the end-pipe channel, and the indication information is used to indicate that the communication connection between the first device and the second device has a channel abnormality. In response to the indication information, the second device performs channel measurement on multiple channels to be selected to obtain a second measurement result. The second device sends the second measurement result to the first device through the end-pipe channel. The first device performs channel measurement on multiple channels to be selected to obtain a first measurement result. The first device sends the first measurement result to the second device through the end-pipe channel. The first device and the second device switch the wireless channel corresponding to the communication connection between the first device and the second device according to the first measurement result and the second measurement result. By establishing an end-pipe channel for exchanging device information between the first device and the second device, when the first device determines that the wireless channel of the communication connection is abnormal, the end-pipe channel can be used to quickly inform the second device of the channel abnormality, which can save the overhead of the second device needing to perform channel measurement to determine the channel abnormality on the one hand, and on the other hand, it can speed up the speed of the second device determining the channel abnormality and reduce the network detection time. After the first device and the second device synchronize the state of the channel abnormality, the first device and the second device can synchronously perform channel measurements, and further exchange their respective measurement results through the end-pipe channel. Finally, the first device and the second device switch the wireless channel of the communication connection based on the measurement results of both parties, so that the communication connection between the first device and the second device can be restored as soon as possible without the user's perception, thereby improving the network stability of the first device or the second device.
[0136] Based on the above introduction, the following Figure 3The specific implementation of performing wireless channel switching according to the first measurement result and the second measurement result in the data interaction method provided in the present application is further introduced in detail. Figure 3 Signaling interaction of the data interaction method provided in the embodiment of the present application Figure 2 .
[0137] like Figure 3 As shown, the method includes:
[0138] S301. A first device determines a first channel from a plurality of candidate channels according to a first measurement result and a second measurement result, and a channel quality of the first channel meets a preset condition.
[0139] Among them, the first measurement result includes the channel measurement results of each candidate channel measured by the first device, and the second measurement result includes the channel measurement results of each candidate channel measured by the second device. Therefore, the first device can determine the first channel among multiple candidate channels based on the first measurement result and the second measurement result.
[0140] Exemplarily, the first measurement result and the second measurement result may include one or more parameters such as transmission rate, signal-to-noise ratio, channel gain, noise power, etc., and then, for example, these parameters of each candidate channel may be integrated, and the channel with the best channel quality among multiple candidate channels may be determined as the first channel. Exemplarily, a preset condition may be set, and then the channel that meets the preset condition among multiple candidate channels is considered to be the channel with the best channel quality introduced in this embodiment, and is thereby determined as the first channel.
[0141] In a possible implementation, the preset condition in this embodiment may include, for example, at least one of the following: the transmission rate in the first measurement result and the second measurement result is greater than the rate threshold, the signal-to-noise ratio in the first measurement result and the second measurement result is greater than the signal-to-noise ratio threshold, the channel gain in the first measurement result and the second measurement result is greater than the gain threshold, and the noise power in the first measurement result and the second measurement result is less than the power threshold. In this implementation, the specific content included in the preset condition may depend on the parameters included in the measurement result, that is, the preset condition may be that the parameters of the selected channel in the first measurement result and the second measurement result both meet the corresponding threshold conditions.
[0142] Alternatively, when setting the preset conditions, because there are certain differences in the measurement capabilities of the first device and the second device, the measurement results of the channel measurement for the same candidate channel may also be different. In one implementation, a first weight may be set for the first device, and then a second weight may be set for the second device, and then for each candidate channel, the comprehensive parameters of the candidate channel are determined based on the channel parameters and the first weight in the first measurement result, and the channel parameters and the second weight in the second measurement result.
[0143] Exemplarily, the above processing can be performed for each channel parameter, so as to obtain multiple comprehensive parameters corresponding to each selected channel. For example, according to the transmission rate in the first measurement result and the transmission rate in the second measurement result, the comprehensive transmission rate of the selected channel can be obtained; and according to the signal-to-noise ratio in the first measurement result and the signal-to-noise ratio in the second measurement result, the comprehensive signal-to-noise ratio of the selected channel can be obtained; and according to the channel gain in the first measurement result and the channel gain in the second measurement result, the comprehensive channel gain of the selected channel can be obtained; and according to the noise power in the first measurement result and the noise power in the second measurement result, the comprehensive noise power of the selected channel can be obtained. In the actual implementation process, the specific implementation of the comprehensive parameters depends on the specific parameter content included in the first measurement result and the second measurement result.
[0144] On this basis, the preset conditions in this embodiment may include, for example, at least one of the following: the comprehensive transmission rate is greater than the rate threshold, the comprehensive signal-to-noise ratio is greater than the signal-to-noise ratio threshold, the comprehensive channel gain is greater than the gain threshold, and the comprehensive noise power is less than the power threshold. In this implementation, the specific content included in the preset conditions may also depend on the parameters included in the measurement results, that is, the preset conditions may be that the various comprehensive parameters of the selected channel determined according to the first measurement result and the second measurement result meet the corresponding threshold conditions.
[0145] In this embodiment, by combining the first measurement result determined by the first device for the channel to be selected, and the second measurement result determined by the second device for the channel to be selected, the first channel is determined from multiple channels to be selected. It is possible to select the first channel with the best channel quality by integrating the channel measurement results of the two devices, and the channel measurement results of the two devices are compatible, thereby effectively improving the rationality of the selected first channel and the comprehensiveness of the reference information.
[0146] In some special cases, if there are multiple candidate channels whose channel quality meets the preset conditions, one of the multiple candidate channels whose quality meets the preset conditions can be randomly selected as the first channel in this embodiment, or one can be randomly selected according to a certain strategy as the first channel in this embodiment. There is no restriction on the specific implementation here, as long as the channel quality of the first channel meets the preset conditions.
[0147] S302: The first device sends notification information of the first channel to the second device through the end pipe channel.
[0148] Because both the first device and the second device currently need to perform a channel switching operation, after determining the first channel, the first device can send notification information of the first channel to the second device through the end pipe channel, wherein the notification information is used to inform the second device that the first device currently selects the first channel as the channel to be switched.
[0149] S303: The second device determines a second channel from a plurality of candidate channels according to the first measurement result and the second measurement result, and the channel quality of the second channel meets a preset condition.
[0150] In this embodiment, the second device can also determine the second channel from multiple candidate channels according to the first measurement result and the second measurement result, and the channel quality of the second channel meets the preset condition. The implementation of S303 is similar to the implementation of S301 described above, and will not be repeated here.
[0151] S304: The second device sends notification information of the second channel to the first device through the end pipe channel.
[0152] The implementation of S304 is similar to the implementation of S302 described above, and will not be described in detail here.
[0153] In this embodiment, the two steps S301-S302 are taken as a whole, and the two steps S303-S304 are taken as a whole, and the execution order of these two parts can be exchanged. That is to say, S301-S302 can be executed first, and then S303-S304, or S303-S304 can be executed first, and then S301-S302, or they can be executed in parallel, which is not limited in this embodiment and depends on the actual implementation.
[0154] S305: Determine a target channel in the first channel and the second channel.
[0155] Afterwards, no matter for the first device or the second device, the two devices have already determined the first channel and the second channel determined by both parties, so the target channel can be determined in the first channel and the second channel.
[0156] In one implementation, if the first channel and the second channel are consistent, that is, the first device and the second device select the same channel, in this implementation, the first device can directly determine the first channel as the target channel, and the second device can directly determine the second channel as the target channel, wherein the first channel and the second channel are the same channel.
[0157] However, if the first channel and the second channel are not consistent, that is, the first device and the second device do not select the same channel, in this case, one of the first channel and the second channel needs to be selected as the target channel. For example, the target channel can be determined between the first channel and the second channel based on a preset strategy, wherein the preset strategy can be any of the following: based on the selection of the first device, based on the selection of the second device, or determining the channel with a smaller sequence number as the target channel.
[0158] It can be understood that, in fact, whether the first channel or the second channel is determined as the target channel to be switched in the end, it is feasible. Therefore, the first device and the second device can select one of the first channel and the second channel as the target channel according to the preset strategy, which can solve the problem of poor communication connection caused by the current wireless channel abnormality to a certain extent.
[0159] And theoretically, as long as the first device and the second device predetermine the preset strategy, they will select the same target channel. However, in order to ensure information consistency, both the first device and the second device, after determining the target channel in the first channel and the second channel based on the preset strategy, can further synchronize the target channel between the first device and the second device through the end pipe channel to ensure that both parties will perform channel switching based on the same target channel.
[0160] S306: Switch the wireless channel corresponding to the communication connection between the first device and the second device to a target channel.
[0161] After the first device and the second device have negotiated the same target channel, the wireless channel corresponding to the communication connection between the first device and the second device may be switched to the negotiated target channel.
[0162] Exemplarily, when the first device and the second device switch the wireless channel of the communication connection to the target channel, for example, the AP device in the first device and the second device switches to the target channel based on the CSA (Channel Switch Announcement) mechanism of the standard protocol, and then the STA devices in the first device and the second device connect to the target channel.
[0163] In the technical solution of the present application, by combining the first measurement result of the first device and the second measurement result of the second device, a channel with the best channel quality is selected from multiple channels to be selected, which can effectively improve the accuracy of the selected first channel and second channel and the comprehensiveness of the reference information. The first device will perform a channel selection operation to select the first channel, and the second device will perform a channel selection operation to select the second channel. After that, the first device and the second device will determine the target channel based on the channels selected by both parties, or they can determine the target channel by referring to the channel selection results of two different devices, which can also improve the accuracy and comprehensiveness of the target channel finally determined.
[0164] It can be understood that the above embodiment introduces an implementation method in which both the first device and the second device perform channel selection. The above embodiment does not elaborate on the implementation method in which only one of the first device and the second device performs channel selection and the other device obtains the determined target channel through the end pipe channel. However, no matter whether the first device performs channel selection or the second device performs channel selection, the specific processing method can still refer to the introduction of the above embodiment, and will not be repeated here.
[0165] The above embodiments introduce that when the wireless channel corresponding to the communication connection between the first device and the second device has large interference and anomalies, by switching the wireless channel, the problem of poor network quality can be alleviated or solved to a certain extent, thereby improving the network experience of the STA device.
[0166] However, if the AP device itself fails and cannot access the Ethernet, the STA device will be disconnected from the network accordingly. In this case, although the AP device and the STA device maintain a communication connection, the STA device connected to the AP device cannot access the Ethernet because the AP device cannot access the Ethernet. Also, when the AP device fails, channel switching cannot solve the problem of Ethernet disconnection. In this case, the STA device can only reconnect to the Ethernet by establishing a communication connection with the remaining AP devices with normal network access.
[0167] However, in the current technical solution, when the AP device fails and causes the Ethernet connection to be disconnected, the STA device can only determine that the network access is abnormal based on multiple network detections, and the STA device cannot directly determine the cause of the abnormality. After determining that the network access is abnormal, the STA device either waits for the AP device to recover from the failure, or responds to the user's network switching operation and re-establishes a communication connection with other devices to re-access the Ethernet. This may cause the STA device to be disconnected for a long time, thereby affecting the stability of the STA device's network access.
[0168] Combine the following Figure 4 In the technical solution of the present application, the method for handling a device failure of an AP device is described. Figure 4 Signaling interaction of the data interaction method provided in the embodiment of the present application Figure 3 .
[0169] like Figure 4 As shown, the method includes:
[0170] S401: An AP device detects a device failure.
[0171] In this embodiment, the AP device may, for example, periodically detect whether there is an abnormality in the AP device, or when the AP device fails, the AP device may detect the device failure. The device failure in this embodiment refers to the device failure of the AP device.
[0172] Among them, the equipment failure includes at least one of the following: abnormality of the WAN (wide area network) port of the AP device, abnormality of the negotiation rate of the AP device (for example, it may be less than the preset rate), abnormality of the RX (receive, Receive) interface of the AP device, and unrecoverable abnormality of the management frame, etc. All failures related to the AP device can be regarded as equipment failures in this application, and this embodiment does not limit this.
[0173] S402: The AP device sends guidance information to the STA device through the end pipe channel.
[0174] In this embodiment, the AP device and the STA device have pre-established an end-pipe channel, and the specific implementation of the end-pipe channel can refer to the introduction of the above embodiment. Therefore, after detecting a device failure, the AP device can send guidance information to the STA device through the end-pipe channel, wherein the guidance information is used to instruct the first device to switch to establish a communication connection with the remaining devices.
[0175] Because an AP device failure may cause the AP device to fail to access the Ethernet, and this failure cannot be recovered through operable methods such as channel switching, the AP device can use the boot information to guide the STA device to establish a communication connection with other devices, so as to achieve re-access to the Ethernet.
[0176] In a possible implementation, the guidance information may only instruct the first device to switch to establish a communication connection with the remaining devices, without suggesting which specific remaining devices they are. Alternatively, the guidance information may also suggest specific remaining devices, that is, the guidance information may include device information of the remaining devices (such as device identification, SSID, etc.), and the remaining devices may be, for example, other routing hotspots, other APs that can access Ethernet in the same MESH (mesh network) networking, and base stations (that is, guiding STA devices to access the cellular network).
[0177] Exemplarily, the boot information may also include the cause of the AP device failure, so as to inform the STA device of what kind of failure has occurred in the current AP device, so that the STA device can clearly understand the cause of the network abnormality.
[0178] S403: The STA device disconnects the communication connection with the AP device in response to the guidance information, and establishes a communication connection with a third device.
[0179] After receiving the guidance information, the STA device can determine that the AP device has failed based on the guidance information and that a network switch is currently required. Therefore, in response to the guidance information, the communication connection with the AP device is disconnected and a communication connection is established with a third device. The third device can be, for example, other routing hotspots introduced above, other APs that can access Ethernet in the same MESH networking as the failed AP device, base stations (that is, guiding the STA device to access the cellular network), etc. This embodiment does not limit the specific implementation of the third device, as long as the STA device can establish a communication connection with the third device and can access Ethernet through the third device.
[0180] In this embodiment, when the AP device detects a device failure, it can send guidance information through the end pipe channel to quickly notify the STA device, and instruct the STA device to switch to establish a communication connection with other devices that can access the Ethernet through the guidance information, thereby saving the time and cost of the STA device to perform network detection, and quickly perform network switching to restore the Ethernet connection, avoiding the situation where the STA device cannot connect to the Internet for a long time, so as to improve the networking stability of the STA device.
[0181] Based on the above embodiments, Figure 5 An exemplary introduction is given to the implementation method of establishing an end pipe channel between the first device and the second device in the technical solution provided in the present application. Figure 5 A signaling interaction diagram for establishing an end-pipe channel provided in an embodiment of the present application.
[0182] like Figure 5 As shown, the method includes:
[0183] S501. A STA device sends a device discovery signaling to an AP device.
[0184] Among them, the STA device needs to establish an end-pipe channel with the AP device. First, the STA device and the AP device need to sense each other, so the STA device can send a device discovery signaling (discover signaling) to the AP device, where the device discovery signaling is used to discover the AP device.
[0185] In a possible implementation, because the STA device has not sensed the AP device when sending the device discovery signaling, the STA device may send the discover signaling in a broadcasting manner, so as to send the device discovery signaling to the AP device.
[0186] S502: The AP device sends a response signaling to the STA device.
[0187] After receiving the device discovery signaling, the AP device may send an ACK signaling (ack) to the STA device in response to the device discovery signaling to inform the STA device that the device discovery signaling has been received, and also to allow the STA device to discover the AP device.
[0188] S503: The STA device sends a connection request to the AP device.
[0189] After the STA device and the AP device perceive each other based on the above interaction process, the STA device can send a connection request to the AP device, where the connection request is used to request to establish a data transmission channel with the AP device, namely, the end-pipe channel in this application.
[0190] S504: The AP device sends a key or certificate to the STA device.
[0191] If the AP device agrees to establish a data transmission channel with the STA device, it can send a key or certificate to the STA device.
[0192] S505: The STA device and the AP device perform verification and authentication based on the key or certificate, and establish an end-to-end channel in response to the authentication being successful.
[0193] Afterwards, the STA device and the AP device can perform mutual verification and authentication based on the key or certificate. In one possible implementation, the STA device can send an authentication request to the AP device according to the key or integer, and the authentication request includes the key or certificate introduced above.
[0194] Afterwards, the AP device can first verify whether the data is complete based on the key or certificate included in the authentication request. After the data verification is completed, it can further determine whether the key or certificate included in the authentication request is the same as the key or certificate issued by the AP device. If they are the same, the authentication is determined to be successful.
[0195] When it is confirmed that the authentication is successful, a data transmission channel can be established between the first device and the second device, which is the end-to-end channel in this application.
[0196] In the technical solution of the present application, based on the end-pipe channel, the first device and the second device can quickly and efficiently obtain device information of both parties, where the device information includes network status, channel switching related data, etc., thereby effectively shortening the time for the device to perform network detection, and based on the end-pipe channel, the channel switching can be quickly realized, or the AP device guides the STA device to realize the switching of the connected device as soon as possible, so as to shorten the duration of the STA device network abnormality and improve the network stability of the STA device.
[0197] The data interaction method of the embodiment of the present application has been described above, and the device for executing the above data interaction method provided by the embodiment of the present application is described below. Those skilled in the art can understand that the method and the device can be combined and referenced with each other, and the relevant device provided by the embodiment of the present application can execute the steps in the above data interaction method.
[0198] Figure 6 A schematic diagram of the structure of the data interaction device provided in the embodiment of the present application Figure 1 .like Figure 6 As shown, the device 60 includes: a processing module 601, a sending module 602;
[0199] Processing module 601, used to establish an end-pipe channel with a second device, where the end-pipe channel is used for the first device to exchange device information with the second device;
[0200] A sending module 602, configured to send indication information to the second device through the end pipe channel when it is determined that the communication connection with the second device meets the channel abnormality condition, wherein the indication information is used to indicate that a channel abnormality occurs in the communication connection between the first device and the second device;
[0201] The processing module 601 is further configured to perform channel measurement on a plurality of channels to be selected to obtain a first measurement result;
[0202] The processing module 601 is further configured to obtain, through the end pipe channel, second measurement results of the second device for the plurality of channels to be selected;
[0203] The processing module 601 is further configured to switch a wireless channel corresponding to the communication connection between the first device and the second device according to the first measurement result and the second measurement result.
[0204] In some implementations, the processing module 601 is specifically configured to:
[0205] Determining a target channel from a plurality of candidate channels according to the first measurement result and the second measurement result;
[0206] The wireless channel corresponding to the communication connection between the first device and the second device is switched to the target channel.
[0207] In some implementations, the processing module 601 is specifically configured to:
[0208] Determine a first channel from the multiple channels to be selected according to the first measurement result and the second measurement result, wherein the channel quality of the first channel meets a preset condition;
[0209] Acquire, through the end pipe channel, a second channel determined by the second device from the multiple channels to be selected, wherein the channel quality of the second channel satisfies the preset condition;
[0210] The target channel is determined among the first channel and the second channel.
[0211] In some implementations, the processing module 601 is specifically configured to:
[0212] If the first channel and the second channel are consistent, determining the first channel as the target channel;
[0213] If the first channel and the second channel are inconsistent, a target channel is determined in the first channel and the second channel based on a preset strategy, and the target channel is synchronized between the first device and the second device through the end pipe channel.
[0214] In some implementations, the sending module 602 is further configured to:
[0215] After performing channel measurement on the plurality of channels to be selected to obtain a first measurement result, the first measurement result is sent to the second device through the end pipe channel.
[0216] In some implementations, if the first device is an AP device and the second device is a STA device, the sending module 602 is further used to:
[0217] When the first device detects a device failure, it sends guidance information to the second device through the end pipe channel, where the guidance information is used to instruct the second device to switch to establish a communication connection with other devices.
[0218] In some implementations, if the first device is a STA device and the second device is an AP device, the processing module 601 is further used to:
[0219] When the second device detects a device failure, receiving guidance information sent by the second device through the end pipe channel, wherein the guidance information is used to instruct the first device to switch to establish a communication connection with other devices;
[0220] In response to the guidance information, the communication connection with the second device is disconnected, and a communication connection is established with a third device.
[0221] The device provided in this embodiment can be used to execute the technical solution of the above method embodiment. Its implementation principle and technical effect are similar and will not be described in detail in this embodiment.
[0222] Figure 7 A schematic diagram of the structure of the data interaction device provided in the embodiment of the present application Figure 2 .like Figure 7 As shown, the device 70 includes: a processing module 701, a sending module 702;
[0223] Processing module 701, used to establish an end-pipe channel with a first device, where the end-pipe channel is used for the first device to exchange device information with the second device;
[0224] A sending module 702, configured to receive indication information sent by the first device through the end pipe channel, wherein the indication information is used to indicate that a channel abnormality occurs in the communication connection between the first device and the second device;
[0225] The processing module 701 is further configured to perform channel measurement on a plurality of channels to be selected in response to the indication information to obtain a second measurement result;
[0226] The processing module 701 is further configured to obtain, through the end pipe channel, a first measurement result of the first device for the plurality of channels to be selected;
[0227] The processing module 701 is further configured to switch a wireless channel corresponding to the communication connection between the first device and the second device according to the first measurement result and the second measurement result.
[0228] In some implementations, the processing module 701 is specifically configured to:
[0229] Determining a target channel from a plurality of candidate channels according to the first measurement result and the second measurement result;
[0230] The wireless channel corresponding to the communication connection between the first device and the second device is switched to the target channel.
[0231] In some implementations, the processing module 701 is specifically configured to:
[0232] Determine a second channel from the multiple channels to be selected according to the first measurement result and the second measurement result, wherein the channel quality of the second channel meets a preset condition;
[0233] Acquire, through the end pipe channel, a first channel determined by the first device from among the multiple channels to be selected, wherein the channel quality of the first channel satisfies the preset condition;
[0234] The target channel is determined among the first channel and the second channel.
[0235] In some implementations, the processing module 701 is specifically configured to:
[0236] If the first channel and the second channel are consistent, determining the first channel as the target channel;
[0237] If the first channel and the second channel are inconsistent, a target channel is determined in the first channel and the second channel based on a preset strategy, and the target channel is synchronized between the first device and the second device through the end pipe channel.
[0238] In some implementations, the sending module 702 is further configured to:
[0239] In response to the indication information, channel measurement is performed on a plurality of channels to be selected to obtain a second measurement result, and then the second measurement result is sent to the first device through the end pipe channel.
[0240] In some implementations, if the second device is a STA device and the first device is an AP device, the processing module 701 is further used to:
[0241] When the first device detects a device failure, receiving guidance information sent by the first device through the end pipe channel, wherein the guidance information is used to instruct the second device to switch to establish a communication connection with other devices;
[0242] In response to the guidance information, the communication connection with the first device is disconnected, and a communication connection is established with a third device.
[0243] In some implementations, if the second device is an AP device and the first device is a STA device, the sending module 702 is further used to:
[0244] When the second device detects a device failure, guidance information is sent to the second device through the end pipe channel, where the guidance information is used to instruct the first device to switch to establish a communication connection with other devices.
[0245] The device provided in this embodiment can be used to execute the technical solution of the above method embodiment. Its implementation principle and technical effect are similar and will not be described in detail in this embodiment.
[0246] An embodiment of the present application provides an electronic device, Figure 8A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application.
[0247] like Figure 8 As shown, the electronic device 80 includes: a processor 801 and a memory 802; the memory 802 stores computer-executable instructions; the processor 801 executes the computer-executable instructions stored in the memory 802, so that the electronic device 80 executes the above method.
[0248] When the memory 802 is independently provided, the electronic device further includes a bus 803 for connecting the memory 802 and the processor 801 .
[0249] The embodiment of the present application provides a chip. The chip includes a processor, and the processor is used to call a computer program in a memory to execute the technical solution in the above embodiment. Its implementation principle and technical effect are similar to those of the above related embodiments, and will not be repeated here.
[0250] The embodiments of the present application also provide a computer-readable storage medium. The computer-readable storage medium stores a computer program. The above method is implemented when the computer program is executed by the processor. The method described in the above embodiment can be implemented in whole or in part by software, hardware, firmware, or any combination thereof. If implemented in software, the function can be stored as one or more instructions or codes on a computer-readable medium or transmitted on a computer-readable medium. Computer-readable media can include computer storage media and communication media, and can also include any medium that can transfer a computer program from one place to another. The storage medium can be any target medium that can be accessed by a computer.
[0251] In one possible implementation, a computer-readable medium may include RAM, ROM, compact disc read-only memory (CD-ROM) or other optical disk storage, disk storage or other magnetic storage devices, or any other medium that is intended to carry or store the required program code in the form of instructions or data structures and can be accessed by a computer. Moreover, any connection is appropriately referred to as a computer-readable medium. For example, if a coaxial cable, fiber optic cable, twisted pair, digital subscriber line (DSL) or wireless technology (such as infrared, radio and microwave) is used to transmit software from a website, server or other remote source, the coaxial cable, fiber optic cable, twisted pair, DSL or wireless technology such as infrared, radio and microwave are included in the definition of medium. Disks and optical disks as used herein include optical disks, laser disks, optical disks, digital versatile disks (DVD), floppy disks and Blu-ray disks, where disks usually reproduce data magnetically, while optical disks reproduce data optically using lasers. Combinations of the above should also be included in the scope of computer-readable media.
[0252] An embodiment of the present application provides a computer program product, which includes a computer program. When the computer program is executed, the computer executes the above method.
[0253] The embodiments of the present application are described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processing unit of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable device to generate a machine, so that the instructions executed by the processing unit of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0254] The above specific implementation methods further illustrate the purpose, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above are only specific implementation methods of the present invention and are not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made on the basis of the technical solutions of the present invention should be included in the scope of protection of the present invention.
Claims
1. A data interaction method, characterized in that: Applied to a first device, a communication connection is established between the first device and a second device, the method comprising: Establishing an end-pipe channel with the second device, wherein the end-pipe channel is used for the first device and the second device to exchange device information; When it is determined that the communication connection with the second device meets the channel abnormality condition, sending indication information to the second device through the end pipe channel, where the indication information is used to indicate that a channel abnormality occurs in the communication connection between the first device and the second device; Performing channel measurement on a plurality of channels to be selected to obtain a first measurement result; Acquire, through the end pipe channel, second measurement results of the second device for the plurality of channels to be selected; According to the first measurement result and the second measurement result, a wireless channel corresponding to the communication connection between the first device and the second device is switched.
2. The method according to claim 1, characterized in that: The switching, according to the first measurement result and the second measurement result, of a wireless channel corresponding to the communication connection between the first device and the second device includes: Determining a target channel from a plurality of candidate channels according to the first measurement result and the second measurement result; The wireless channel corresponding to the communication connection between the first device and the second device is switched to the target channel.
3. The method according to claim 2, characterized in that The determining a target channel from a plurality of candidate channels according to the first measurement result and the second measurement result includes: Determine a first channel from the multiple channels to be selected according to the first measurement result and the second measurement result, wherein the channel quality of the first channel meets a preset condition; Acquire, through the end pipe channel, a second channel determined by the second device from the multiple channels to be selected, wherein the channel quality of the second channel satisfies the preset condition; The target channel is determined among the first channel and the second channel.
4. The method according to claim 3, characterized in that The determining the target channel in the first channel and the second channel comprises: If the first channel and the second channel are consistent, determining the first channel as the target channel; If the first channel and the second channel are inconsistent, a target channel is determined in the first channel and the second channel based on a preset strategy, and the target channel is synchronized between the first device and the second device through the end pipe channel.
5. The method according to any one of claims 1 to 4, characterized in that: After performing channel measurement on the plurality of channels to be selected to obtain a first measurement result, the method further includes: The first measurement result is transmitted to the second device through the end tube channel.
6. The method according to claim 1, characterized in that If the first device is an access point AP device, and the second device is a station STA device, the method further includes: When the first device detects a device failure, it sends guidance information to the second device through the end pipe channel, where the guidance information is used to instruct the second device to switch to establish a communication connection with other devices.
7. The method according to claim 1, characterized in that If the first device is a STA device and the second device is an AP device, the method further includes: When the second device detects a device failure, receiving guidance information sent by the second device through the end pipe channel, wherein the guidance information is used to instruct the first device to switch to establish a communication connection with other devices; In response to the guidance information, the communication connection with the second device is disconnected, and a communication connection is established with a third device.
8. A data interaction method, characterized in that: Applied to a second device, a communication connection is established between the second device and the first device, the method comprising: Establishing an end-pipe channel with the first device, wherein the end-pipe channel is used for the first device and the second device to exchange device information; receiving, through the end pipe channel, indication information sent by the first device, the indication information being used to indicate that a channel abnormality occurs in the communication connection between the first device and the second device; In response to the indication information, performing channel measurement on a plurality of channels to be selected to obtain a second measurement result; Acquire, through the end pipe channel, first measurement results of the first device for the multiple channels to be selected; According to the first measurement result and the second measurement result, a wireless channel corresponding to the communication connection between the first device and the second device is switched.
9. The method according to claim 8, characterized in that The switching, according to the first measurement result and the second measurement result, of a wireless channel corresponding to the communication connection between the first device and the second device includes: Determining a target channel from a plurality of candidate channels according to the first measurement result and the second measurement result; The wireless channel corresponding to the communication connection between the first device and the second device is switched to the target channel.
10. The method according to claim 9, characterized in that The determining a target channel from a plurality of candidate channels according to the first measurement result and the second measurement result includes: Determine a second channel from the multiple channels to be selected according to the first measurement result and the second measurement result, wherein the channel quality of the second channel meets a preset condition; Acquire, through the end pipe channel, a first channel determined by the first device from among the multiple channels to be selected, wherein the channel quality of the first channel satisfies the preset condition; The target channel is determined among the first channel and the second channel.
11. The method according to claim 10, characterized in that The determining the target channel in the first channel and the second channel comprises: If the first channel and the second channel are consistent, determining the first channel as the target channel; If the first channel and the second channel are inconsistent, a target channel is determined in the first channel and the second channel based on a preset strategy, and the target channel is synchronized between the first device and the second device through the end pipe channel.
12. The method according to any one of claims 8 to 11, characterized in that: After performing channel measurement on a plurality of candidate channels in response to the indication information to obtain a second measurement result, the method further includes: The second measurement result is sent to the first device through the end tube channel.
13. The method according to claim 8, characterized in that If the second device is a STA device and the first device is an AP device, the method further includes: When the first device detects a device failure, receiving guidance information sent by the first device through the end pipe channel, wherein the guidance information is used to instruct the second device to switch to establish a communication connection with other devices; In response to the guidance information, the communication connection with the first device is disconnected, and a communication connection is established with a third device.
14. The method according to claim 8, characterized in that If the second device is an AP device and the first device is a STA device, the method further includes: When the second device detects a device failure, guidance information is sent to the second device through the end pipe channel, where the guidance information is used to instruct the first device to switch to establish a communication connection with other devices.
15. An electronic device, characterized in that: include: Processor and memory; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the electronic device performs the method as described in any one of claims 1-7 or any one of claims 8-14.
16. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the method according to any one of claims 1 to 7 or any one of claims 8 to 14 is implemented.
17. A computer program product, characterized in that The invention comprises a computer program, which, when being executed, causes a computer to execute the method according to any one of claims 1 to 7 or any one of claims 8 to 14.