Communication control method and device, computer equipment and storage medium
By acquiring the connection quality of the second terminal and sending packets or notifications to it when the threshold is reached, ensuring stable communication connection between the wireless headset and the playback device, the problems of limited connection range and poor convenience are solved.
Patent Information
- Application Number
- CN202311268744.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-09-27
- Publication Date
- 2025-03-28
AI Technical Summary
The limited Bluetooth connection range between wireless headphones and playback devices causes the connection quality to deteriorate or disconnect when the user moves, limiting the convenience of the headphones.
By acquiring the connection quality of the second terminal, if the connection quality reaches or exceeds the preset threshold, the first terminal sends a data packet or notification to the second terminal, causing the second terminal to forward the data packet to the third terminal, ensuring that the communication connection between the first terminal and the third terminal is stable.
The space range in which connection can be established between the first terminal and the third terminal is expanded, the problem of poor connection quality or disconnection is solved, and the convenience of wireless headphones is improved.
Smart Images

Figure CN119729890A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field, and in particular to a communication control method, apparatus, computer equipment, and storage medium. Background Art
[0002] Wireless headphones have been a very popular type of headphones in recent years. They usually use Bluetooth to connect to playback devices and can play mobile phone audio without signal cables.
[0003] However, in daily use, the wireless headset and the playback device cannot exceed the Bluetooth connection range. As factors that affect the connection quality change, such as the distance between the playback device and the headset, for example, when the user is wearing the headset and is some distance away from the playback device, the connection quality will often deteriorate or even disconnect.
[0004] Therefore, if the user wants to ensure the stability of the connection between the earphone and the playback device, he can only move within a small range around the playback device. The range between the playback device and the earphone is too small, and the use of the earphone is inconvenient. Summary of the invention
[0005] To overcome the problems existing in the related art, the present disclosure provides a communication control method, an apparatus, a computer device and a storage medium.
[0006] A first aspect of the present disclosure provides a communication control method, applied to a first terminal, the method comprising:
[0007] Acquire a first connection quality of a second terminal, wherein the second terminal has communication connections with both the first terminal and the third terminal, and the first connection quality represents a connection quality between the second terminal and the third terminal;
[0008] In response to the first connection quality being greater than or equal to a preset first threshold, sending a first data packet to the second terminal, so that the third terminal sends the first data packet to the third terminal, the first data packet including a communication address of the third terminal;
[0009] And / or, in response to the first connection quality being greater than or equal to a preset first threshold, sending a notification to the second terminal so that the second terminal receives a second data packet sent by the third terminal and forwards it to the first terminal, wherein the second data packet includes a communication address of the first terminal.
[0010] Optionally, the obtaining the first connection quality of the second terminal includes:
[0011] In a process of data transmission between the first terminal and the third terminal, in response to a second connection quality being less than a preset second threshold, acquiring a first connection quality of the second terminal, where the second connection quality represents a connection quality between the first terminal and the third terminal;
[0012] And / or, in response to receiving the operation instruction, obtaining the first connection quality of the second terminal.
[0013] Optionally, the method further includes:
[0014] During data transmission between the first terminal and the third terminal, in response to a second connection quality being less than a preset second threshold, stopping sending data packets to the third terminal, wherein the second connection quality represents a connection quality between the first terminal and the third terminal.
[0015] Optionally, the method further includes:
[0016] During data transmission between the first terminal and the third terminal, broadcasting the communication address of the first terminal to the second terminal, so that the second terminal determines a third connection quality according to a connection state between the second terminal and the first terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal;
[0017] And / or, during data transmission between the first terminal and the third terminal, the communication address of the third terminal is broadcast to the second terminal, so that the second terminal determines the first connection quality according to the connection status of the second terminal and the third terminal.
[0018] Optionally, the obtaining the first connection quality of the second terminal includes:
[0019] Acquire a first connection quality of at least one second terminal;
[0020] The sending the first data packet to the second terminal includes:
[0021] Sending the first data packet to a second terminal having the greatest first connection quality among the at least one second terminal;
[0022] The sending a notification to the second terminal includes:
[0023] A notification is sent to a second terminal having the greatest first connection quality among the at least one second terminal.
[0024] Optionally, the method further includes:
[0025] Acquire a third connection quality of at least one second terminal, where the third connection quality represents a connection quality between the second terminal and the first terminal;
[0026] The sending the first data packet to the second terminal includes:
[0027] Sending a first data packet to a second terminal having the greatest third connection quality among the at least one second terminal;
[0028] The sending a notification to the second terminal includes:
[0029] A notification is sent to a second terminal having the greatest third connection quality among the at least one second terminal.
[0030] Optionally, the first terminal and the second terminal are electronic devices having a communication connection module, and the third terminal is an electronic accessory having a communication connection function.
[0031] A second aspect of the present disclosure provides a communication control method, applied to a second terminal, the method comprising:
[0032] In response to receiving a first data packet sent by a first terminal, sending the first data packet to the third terminal, wherein the first data packet is sent by the first terminal when a first connection quality is greater than or equal to a preset first threshold, the first connection quality represents a connection quality between the second terminal and the third terminal, and the first data packet includes a communication address of the third terminal;
[0033] And / or, in response to receiving the notification sent by the first terminal, receiving a second data packet sent by the third terminal, and sending the second data packet to the first terminal, wherein the second data packet includes a communication address of the first terminal.
[0034] Optionally, sending the first data packet to the third terminal includes:
[0035] The first data packet is packaged into a third data packet according to the communication address of the first terminal, and the third data packet is sent to the third terminal, where the third data packet simulates the first terminal as a sending terminal.
[0036] Optionally, the method further includes:
[0037] receiving a communication address of the first terminal broadcasted by the first terminal, and determining a third connection quality according to a connection state between the second terminal and the first terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal;
[0038] And / or, receiving the communication address of the third terminal broadcast by the first terminal, and determining a first connection quality according to a connection status between the second terminal and the third terminal, wherein the first connection quality represents a connection quality between the second terminal and the third terminal.
[0039] A third aspect of the present disclosure provides a communication control device, the device comprising:
[0040] A first connection quality acquisition module, configured to acquire a first connection quality of a second terminal, wherein the second terminal has communication connections with both the first terminal and the third terminal, and the first connection quality represents a connection quality between the second terminal and the third terminal;
[0041] The first communication connection module is used to perform the following steps:
[0042] In response to the first connection quality being greater than or equal to a preset first threshold, sending a first data packet to the second terminal, so that the third terminal sends the first data packet to the third terminal, the first data packet including a communication address of the third terminal;
[0043] And / or, in response to the first connection quality being greater than or equal to a preset first threshold, sending a notification to the second terminal so that the second terminal receives a second data packet sent by the third terminal and forwards it to the first terminal, wherein the second data packet includes a communication address of the first terminal.
[0044] Optionally, when the first connection quality acquisition module is used to acquire the first connection quality of the second terminal, it is used to:
[0045] In a process of data transmission between the first terminal and the third terminal, in response to a second connection quality being less than a preset second threshold, acquiring a first connection quality of the second terminal, where the second connection quality represents a connection quality between the first terminal and the third terminal;
[0046] And / or, in response to receiving the operation instruction, obtaining the first connection quality of the second terminal.
[0047] Optionally, the device further comprises:
[0048] The sending stop module is used to stop sending data packets to the third terminal in response to a second connection quality being less than a preset second threshold during data transmission between the first terminal and the third terminal, wherein the second connection quality represents the connection quality between the first terminal and the third terminal.
[0049] Optionally, the device further comprises:
[0050] The communication address broadcast module is used to perform the following steps:
[0051] During data transmission between the first terminal and the third terminal, broadcasting the communication address of the first terminal to the second terminal, so that the second terminal determines a third connection quality according to a connection state between the second terminal and the first terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal;
[0052] And / or, during data transmission between the first terminal and the third terminal, the communication address of the third terminal is broadcast to the second terminal, so that the second terminal determines the first connection quality according to the connection status of the second terminal and the third terminal.
[0053] Optionally, when the first connection quality acquisition module is used to acquire the first connection quality of the second terminal, it is used to:
[0054] Acquire a first connection quality of at least one second terminal;
[0055] When the first communication connection module is used to send a first data packet to the second terminal, it is used to:
[0056] Sending the first data packet to a second terminal having the greatest first connection quality among the at least one second terminal;
[0057] When the first communication connection module is used to send a notification to the second terminal, it is used to:
[0058] A notification is sent to a second terminal having the greatest first connection quality among the at least one second terminal.
[0059] Optionally, the device further comprises:
[0060] A third connection quality acquisition module, configured to acquire a third connection quality of at least one second terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal;
[0061] When the first communication connection module is used to send a first data packet to the second terminal, it is used to:
[0062] Sending a first data packet to a second terminal having the greatest third connection quality among the at least one second terminal;
[0063] When the first communication connection module is used to send a notification to the second terminal, it is used to:
[0064] A notification is sent to a second terminal having the greatest third connection quality among the at least one second terminal.
[0065] A fourth aspect of the present disclosure provides a communication control device, the device comprising:
[0066] The first communication forwarding module is used to perform the following steps:
[0067] In response to receiving a first data packet sent by a first terminal, sending the first data packet to the third terminal, wherein the first data packet is sent by the first terminal when a first connection quality is greater than or equal to a preset first threshold, the first connection quality represents a connection quality between the second terminal and the third terminal, and the first data packet includes a communication address of the third terminal;
[0068] And / or, in response to receiving the notification sent by the first terminal, receiving a second data packet sent by the third terminal, and sending the second data packet to the first terminal, wherein the second data packet includes a communication address of the first terminal.
[0069] Optionally, when the first communication forwarding module is used to send the first data packet to the third terminal, it is used to:
[0070] The first data packet is packaged into a third data packet according to the communication address of the first terminal, and the third data packet is sent to the third terminal, where the third data packet simulates the first terminal as a sending terminal.
[0071] Optionally, the device further comprises:
[0072] The connection quality determination module is used to perform the following steps:
[0073] receiving a communication address of the first terminal broadcasted by the first terminal, and determining a third connection quality according to a connection state between the second terminal and the first terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal;
[0074] And / or, receiving the communication address of the third terminal broadcast by the first terminal, and determining a first connection quality according to a connection status between the second terminal and the third terminal, wherein the first connection quality represents a connection quality between the second terminal and the third terminal.
[0075] A fifth aspect of the present disclosure provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the method described in any one of the first aspect or the second aspect is implemented.
[0076] A sixth aspect of the present disclosure provides a computer-readable storage medium having a computer program stored thereon, wherein the program, when executed by a processor, implements the method described in any one of the first aspect or the second aspect.
[0077] The technical solution provided by the embodiments of the present disclosure may have the following beneficial effects:
[0078] In an embodiment of the present disclosure, the first terminal can obtain the connection quality of the second terminal and the third terminal by acquiring the first connection quality of the second terminal. When the first connection quality is greater than or equal to a preset first threshold, the first terminal sends a first data packet to the second terminal so that the second terminal forwards the first data packet to the third terminal, and / or sends a notification to the second terminal so that the second terminal receives the second data packet sent by the third terminal and forwards it to the first terminal.
[0079] Since the second terminal has a communication connection with the first terminal when the first connection quality of the second terminal can be acquired by the first terminal, and the comparison and judgment process of the first connection quality and the first threshold value ensures that the second terminal has a communication connection with the third terminal, the first terminal sends and / or receives data packets to the third terminal through the second terminal, thereby ensuring that when the connection state between the first terminal and the third terminal is poor, a unidirectional or bidirectional communication connection can still be maintained with the third terminal, thereby solving the problem that the connection quality may deteriorate or even be disconnected as factors affecting the connection quality, such as the distance between the first terminal and the third terminal, change.
[0080] When the first terminal is a playback device and the second terminal is a headset, the embodiment provided by the present disclosure can solve the problem that the range between the playback device and the headset is too small, making the headset inconvenient to use.
[0081] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0082] The accompanying drawings, which are incorporated in and constitute a part of this disclosure, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.
[0083] Figure 1 It is an application scenario diagram of a communication control method shown in some exemplary embodiments.
[0084] Figure 2 The following is a flow chart of a communication control method shown in some exemplary embodiments.
[0085] Figure 3 is a flow chart of another communication control method shown in some exemplary embodiments.
[0086] Figure 4 is a flow chart of yet another communication control method shown in some exemplary embodiments.
[0087] Figure 5 is a flow chart of yet another communication control method shown in some exemplary embodiments.
[0088] Figure 6 is a flow chart of another communication control method shown in some exemplary embodiments.
[0089] Figure 7 It is a three-side interaction diagram of a communication control method shown in some exemplary embodiments.
[0090] Figure 8 is a block diagram of a communication control device shown in some exemplary embodiments.
[0091] Fig. 9 is a block diagram of another communication control device shown in some exemplary embodiments.
[0092] Fig.10 The figure is a hardware structure diagram of a computer device shown in some exemplary embodiments. DETAILED DESCRIPTION
[0093] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present disclosure. Instead, they are merely examples of devices and methods consistent with some aspects of the present disclosure as detailed in the appended claims.
[0094] The terms used in this disclosure are for the purpose of describing specific embodiments only and are not intended to limit the disclosure. The singular forms of "a", "said" and "the" used in this disclosure and the appended claims are also intended to include plural forms unless the context clearly indicates otherwise. It should also be understood that the term "and / or" used herein refers to and includes any or all possible combinations of one or more associated listed items.
[0095] It should be understood that although the terms first, second, third, etc. may be used in the present disclosure to describe various information, such information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of the present disclosure, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, the word "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining".
[0096] Wireless headphones have been a very popular type of headphones in recent years. They usually use Bluetooth to connect to playback devices and can play mobile phone audio without signal cables.
[0097] However, in daily use, the wireless headset and the playback device cannot exceed the Bluetooth connection range. As factors that affect the connection quality change, such as the distance between the playback device and the headset, for example, when the user is wearing the headset and is some distance away from the playback device, the connection quality will often deteriorate or even disconnect.
[0098] Therefore, if the user wants to ensure the stability of the connection between the headset and the playback device, he can only move within a small range around the playback device. The range between the playback device and the headset is too small, and the use of the headset is inconvenient.
[0099] In order to better understand the communication control method, apparatus, computer device and storage medium provided by the embodiments of the present disclosure, the following describes an exemplary application environment applicable to the embodiments of the present disclosure. Figure 1 , is an application scenario diagram of a communication control method shown in some embodiments of the present disclosure. Among them, a router 11, a TV 12, a mobile phone 14, and a wireless headset 15 are all connected to a local area network 13, and the mobile phone 14 is making a voice call. The audio of the voice call is played through the wireless headset 15, and the built-in microphone of the wireless headset 15 records the user and sends it to the mobile phone 14, so that the mobile phone 14 completes the voice call process. The router 11, the TV 12, and the mobile phone 14 are electronic devices logged in to the same device manufacturer account. It should be understood that the above application scenario is only an exemplary scenario of the embodiments of the present disclosure and cannot limit the specific application of the embodiments of the present disclosure.
[0100] Next, the embodiments of the present disclosure are described in detail from the perspectives of the first terminal (eg, the mobile phone 14 in the above scenario) and the second terminal (eg, the router 11 in the above scenario).
[0101] In a first aspect, the present disclosure provides a communication control method applied to a first terminal. Figure 2 , is a flow chart of a communication control method according to an exemplary embodiment of the present disclosure, which includes the following steps:
[0102] S201, obtaining a first connection quality of a second terminal, wherein the second terminal has communication connections with both the first terminal and a third terminal, and the first connection quality represents a connection quality between the second terminal and the third terminal;
[0103] In this step, the second terminal is a terminal that has a communication connection with both the first terminal and the third terminal, wherein the communication connection can be defined as a communication link or connection established between two or more devices, systems or entities that can send data packets unidirectionally or bidirectionally, and this connection allows data, information, signals or commands to be transmitted between them to achieve communication, share resources, collaborate or perform specific tasks. This connection can be established by wired or wireless means, and can be based on various communication protocols, standards or technologies, such as the Internet, Ethernet, cellular networks, satellite communications, etc. The scope of the connection can be short-distance communication within a local area network or even a global wide area network connection. Preferably, the first terminal, the second terminal and the third terminal can be connected to a local area network, and the local area network can be implemented based on Ethernet technology or through a virtual local area network configured at the software level. It should be understood that in this step, there may be one or more second terminals, and the presence of multiple second terminals does not affect the original technical effect of this embodiment.
[0104] The first connection quality characterizes the connection quality between the second terminal and the third terminal. In other words, the first connection quality includes an indicator or parameter for quantifying and describing the performance and reliability of the communication connection between the second terminal and the third terminal. In the embodiment of the present disclosure, the measurement of the connection quality can be based on multiple factors, including but not limited to the following aspects: signal strength, which measures the strength of the transmission signal in the connection, usually expressed in the form of a signal receiving strength indicator (RSSI), and a higher signal strength usually represents a better connection quality; signal-to-noise ratio (SNR), which measures the ratio between signal and noise, and a higher signal-to-noise ratio usually represents a better connection quality; bit error rate (BER), which measures the proportion of erroneous bits occurring in data transmission, and a lower bit error rate usually represents a better connection quality; delay, which measures the time delay required for data to travel from the sender to the receiver, and a lower delay usually represents a better connection quality; bandwidth, which measures the data transmission rate available in the connection, and a higher bandwidth usually represents a better connection quality.
[0105] It should be understood that in the embodiments of the present disclosure, the greater the value of the connection quality, the better the connection quality. In actual application, the connection quality provided by the present disclosure can be reflected by any indicator or parameter, including an indicator or parameter whose value is greater and indicates a greater connection quality, and an indicator or parameter whose value is smaller and indicates a greater connection quality. The specific calculation method can also be set according to actual conditions, for example, different weights are set for the above-mentioned measurement factors to comprehensively calculate the connection quality, and the present disclosure does not limit it.
[0106] The specific method of obtaining the first connection quality of the second terminal can be set according to the actual situation. For example, the first terminal can broadcast a command to obtain the first connection quality. After receiving the command, the second terminal calculates the first connection quality according to the communication address of the third terminal indicated by the command and returns it to the first terminal. For another example, the second terminal can periodically scan the devices that it can connect to, and calculate the first connection quality in real time and broadcast it to the first terminal.
[0107] S202: In response to the first connection quality being greater than or equal to a preset first threshold, sending a first data packet to the second terminal so that the second terminal sends the first data packet to the third terminal, the first data packet including the communication address of the third terminal, and / or, in response to the first connection quality being greater than or equal to a preset first threshold, sending a notification to the second terminal so that the second terminal receives a second data packet sent by the third terminal and forwards it to the first terminal, the second data packet including the communication address of the first terminal.
[0108] In an optional case, when the first connection quality is greater than or equal to a preset first threshold, a first data packet is sent to the second terminal, so that the second terminal sends the first data packet to the third terminal.
[0109] The first threshold is a preset indicator for measuring whether the connection quality is available. When the connection quality is greater than or equal to the first threshold, the communication connection corresponding to the connection quality can be considered to be available. The setting of the first threshold can also be based on multiple measurement factors of the first connection quality, based on a reasonable available range that can characterize the connection quality.
[0110] When the first connection quality is greater than or equal to the first threshold, it can be considered that the communication connection between the second terminal and the third terminal is in an available state, and at this time, a first data packet is sent to the second terminal, and the first data packet includes the communication address of the third terminal. When the second terminal receives the first data packet sent by the first terminal, it can be known that the first terminal wants the second terminal to forward the first data packet to the third terminal, so as to parse the information in the data packet and know the communication address of the third terminal, and send the first data packet to the third terminal.
[0111] In this optional solution, the first terminal completes the process of sending a data packet to the third terminal through the second terminal, wherein the second terminal has an available communication connection with the third terminal, thereby realizing unidirectional information transmission from the first terminal to the third terminal.
[0112] In another optional solution, when the first connection quality is greater than or equal to a preset first threshold, a notification is sent to the second terminal, so that the second terminal receives the second data packet sent by the third terminal and forwards it to the first terminal.
[0113] Based on the above principle, when the first connection quality is greater than or equal to the first threshold, it can be considered that the communication connection between the second terminal and the third terminal is in an available state. At this time, the first terminal sends a notification to the second terminal, and the notification instructs the second terminal to receive the second data packet sent by the third terminal and forward it to the first terminal. When the second terminal receives the notification sent by the first terminal, the second terminal will obtain the permission to receive the second data packet sent by the third terminal. At this time, the second terminal can obtain the second data packet and send the second data packet to the first terminal.
[0114] In this optional solution, the first terminal completes the process of receiving the second data packet sent by the third terminal through the second terminal, wherein the second terminal has an available communication connection with the third terminal, thereby realizing unidirectional information transmission from the third terminal to the first terminal.
[0115] When the above two optional schemes exist at the same time, two-way communication between the first terminal and the third terminal can be realized. This communication is not limited to the direct connection between the first terminal and the third terminal, but by obtaining the second terminal, any terminal that has a communication connection with both the first terminal and the third terminal is used to relay the communication. Preferably, the connection quality between the first terminal and the second terminal, and the second terminal and the third terminal are better than the connection quality between the first terminal and the third terminal. For example, in the aforementioned exemplary application scenario, the distance between the router 11 and the wireless headset 15 and the distance between the router 11 and the mobile phone 14 can be made smaller than the distance between the mobile phone 14 and the wireless headset 15.
[0116] In order to implement the embodiments of the present disclosure, the first terminal and the second terminal should be configured with corresponding protocols, that is, protocols that can implement command interaction and data interaction between the first terminal and the second terminal. Specifically, when the first terminal sends a notification to the second terminal, the second terminal should be able to recognize the notification and learn that the first terminal wants the second terminal to transfer the second data packet sent by the third terminal, so as to perform data packet interception and forwarding operations. Similarly, if the method for obtaining the first connection quality is that the first terminal broadcasts a command to obtain the first connection quality, the second terminal should be able to recognize the acquisition command and learn that the first terminal wants to obtain the first connection quality, calculate the first connection quality according to the communication address of the third terminal indicated by the command and return it to the first terminal. Among them, the method for calculating the connection quality should also be preset in advance to ensure that the calculated connection quality has the meaning of quantifying and describing the performance and reliability of the communication connection.
[0117] Exemplarily, the first terminal and the second terminal may be devices logged into the same device manufacturer account. According to the internal authority control and data interaction scheme of the system configured by the device manufacturer, the requirement that the first terminal and the second terminal should be configured with corresponding protocols can be met.
[0118] As another example, a communication control protocol may be written by itself to define necessary preset information such as a method for calculating connection quality and command recognition, so as to meet the requirement that the first terminal and the second terminal should be configured with corresponding protocols.
[0119] In an embodiment of the present disclosure, the first terminal can obtain the connection quality of the second terminal and the third terminal by acquiring the first connection quality of the second terminal. When the first connection quality is greater than or equal to a preset first threshold, the first terminal sends a first data packet to the second terminal so that the second terminal forwards the first data packet to the third terminal, and / or sends a notification to the second terminal so that the second terminal receives the second data packet sent by the third terminal and forwards it to the first terminal.
[0120] Since the second terminal has a communication connection with the first terminal when the first connection quality of the second terminal can be acquired by the first terminal, and the comparison and judgment process of the first connection quality and the first threshold value ensures that the second terminal has a communication connection with the third terminal, the first terminal sends and / or receives data packets to the third terminal through the second terminal, which can ensure that when the connection state between the first terminal and the third terminal is poor, it can still maintain a unidirectional or bidirectional communication connection with the third terminal, expand the spatial range in which a connection can be established between the first terminal and the third terminal, and solve the problem that the connection quality may deteriorate or even be disconnected as factors affecting the connection quality such as the distance between the first terminal and the third terminal change.
[0121] When the first terminal is a playback device and the second terminal is a headset, the embodiment provided by the present disclosure can solve the problem that the range between the playback device and the headset is too small, making the headset inconvenient to use.
[0122] In some embodiments of the present disclosure, Figure 2 The step of obtaining the first connection quality of the second terminal in the communication control method shown includes at least one of the following execution modes:
[0123] The first mode: in a process of data transmission between the first terminal and the third terminal, in response to the second connection quality being less than a preset second threshold, obtaining the first connection quality of the second terminal, where the second connection quality represents the connection quality between the first terminal and the third terminal;
[0124] In this optional solution, when the second connection quality is less than a preset second threshold, the first connection quality of the second terminal is obtained. In other words, Figure 2 The communication control method shown is executed when the second connection quality is less than the preset second threshold. The second connection quality represents the connection quality between the first terminal and the third terminal. Based on the same principle as the above embodiment, when the second connection quality is less than the preset second threshold, it can be considered that the communication connection between the first terminal and the third terminal is in an unavailable state. At this time, the execution starts. Figure 2 The communication control method shown is to obtain the second terminal, so that the first terminal sends and / or receives data packets to the third terminal through the second terminal. The advantage of this optional solution is that Figure 2 The communication control method shown can be automatically triggered according to the quality of the second connection. When the user holds the third terminal away from the first terminal, the first terminal can automatically identify the current connection status and forward data packets through the second terminal without the need for manual operation by the user, thereby improving the convenience of user use.
[0125] The second manner: in response to receiving the operation instruction, obtaining the first connection quality of the second terminal.
[0126] In this optional solution, when the operation instruction is received, the first connection quality of the second terminal is obtained. In other words, Figure 2 The communication control method shown can be triggered and executed according to a manual operation of the user. The advantage of this optional solution is that when the user subjectively feels that the connection health between the first terminal and the third terminal is poor, the user can issue an operation instruction to enable the first terminal to obtain the second terminal and communicate with the third terminal through the second terminal. Due to the large difference in users' subjective feelings, this solution can provide a more flexible communication connection control solution for people who have high requirements for the connection quality between the first terminal and the second terminal.
[0127] In the embodiment of the present disclosure, by obtaining the connection quality between the first terminal and the third terminal, when the connection quality between the first terminal and the third terminal is less than a preset first threshold, a second terminal in the local area network whose connection quality with the third terminal is higher than a preset second threshold is obtained, and a data packet is sent and received from the second terminal to the third terminal, so that when the connection quality between the first terminal and the third terminal is unavailable, the first terminal can also timely discover and send and receive data packets to the third terminal through the second terminal, thereby solving the problem that the communication between the first terminal and the third terminal cannot continue when the connection status between the first terminal and the third terminal is poor. When the first terminal is a playback device and the second terminal is a headset, it can solve the problem that the range between the playback device and the headset is too small, and the headset is inconvenient to use.
[0128] In some embodiments of the present disclosure, see Figure 3 , is a flowchart of another communication control method shown in some exemplary embodiments, wherein, Figure 2 The communication control method shown also includes:
[0129] S301, during data transmission between the first terminal and the third terminal, in response to a second connection quality being less than a preset second threshold, stopping sending data packets to the third terminal, wherein the second connection quality represents a connection quality between the first terminal and the third terminal.
[0130] The second connection quality represents the connection quality between the first terminal and the third terminal. Based on the same principle as the aforementioned embodiment, when the second connection quality is less than a preset second threshold, it can be considered that the communication connection between the first terminal and the third terminal is in an unavailable state. At this time, sending data packets to the third terminal can be stopped. In other words, the communication connection between the first terminal and the third terminal can be disconnected to save power consumption of the first terminal. At the same time, when the communication connection between the first terminal and the third terminal is in an available state again, the third terminal will not receive the same data packets sent by multiple first terminals, thereby avoiding the problem of data processing confusion.
[0131] In the above embodiment, the communication control method actually completes the process of disconnecting the old connection and establishing the new connection, and realizes that when the second connection quality is less than the preset second threshold, the first terminal can disconnect the old connection with the third terminal and instead transfer the data packet through the qualified second terminal, thereby maintaining the connection between the first terminal and the third terminal.
[0132] In some embodiments of the present disclosure, see Figure 4 , is a flowchart of another communication control method shown in some exemplary embodiments, wherein: Figure 2 The communication control method shown also includes:
[0133] S401, during data transmission between the first terminal and the third terminal, broadcast the communication address of the first terminal to the second terminal, so that the second terminal determines a third connection quality according to the connection status of the second terminal and the first terminal, the third connection quality represents the connection quality between the second terminal and the first terminal, and / or, during data transmission between the first terminal and the third terminal, broadcast the communication address of the third terminal to the second terminal, so that the second terminal determines the first connection quality according to the connection status of the second terminal and the third terminal.
[0134] The communication address is an address that a terminal has and can be used to establish a communication connection, such as an IP (Internet Protocol) address, a MAC (Media Access Control) address, and the like.
[0135] In the above two optional schemes, during the process of data transmission between the first terminal and the third terminal, the communication addresses of the first terminal and the third terminal are broadcast to the second terminal, so that the second terminal can directly obtain the first connection quality and the third connection quality according to the above communication addresses. The advantage of this is that the second terminal can know the connection quality between itself and the first terminal and the third terminal while the first terminal and the third terminal are connected. When the first terminal obtains the first connection quality, the second terminal can directly return the above connection quality to the first terminal so that the first terminal can transfer the data packet through the qualified second terminal. Even if the second terminal does not continuously maintain the list of devices that represent the devices it can connect to, the second terminal can obtain the connection quality required by the first terminal with less calculation.
[0136] The present disclosure also provides some embodiments. Figure 2 The communication control method shown may have multiple second terminals, which may be Figure 2 The communication control method shown adds an additional screening condition for the second terminal.
[0137] In an optional scheme, the first terminal obtains the first connection quality of at least one second terminal, and the sending of the first data packet to the second terminal includes sending the first data packet to the second terminal with the highest first connection quality among the at least one second terminal, and the sending of the notification to the second terminal includes sending the notification to the second terminal with the highest first connection quality among the at least one second terminal.
[0138] In this optional solution, the first terminal obtains the first connection quality of at least one second terminal, and the communication control method provided by the present disclosure can achieve its technical effect by forwarding the data packet through a second terminal, so the first terminal can only transfer the data packet through the second terminal with the largest first connection quality. When multiple second terminals have the same first connection quality, the first terminal can select a second terminal to transfer the data packet by randomly selecting one or selecting one according to certain predetermined conditions (such as the order in which the first connection quality is obtained).
[0139] In another optional scheme, the first terminal obtains a third connection quality of at least one second terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal; sending the first data packet to the second terminal includes sending the first data packet to the second terminal having the largest third connection quality among the at least one second terminal; and sending a notification to the second terminal includes sending a notification to the second terminal having the largest third connection quality among the at least one second terminal.
[0140] In this optional solution, the first terminal obtains the third connection quality of at least one second terminal, wherein the third connection quality is calculated based on the connection status of the first terminal and the second terminal. The communication control method provided by the present disclosure can achieve its technical effect by forwarding data packets through a second terminal, so the first terminal can only transfer data packets through the second terminal with the largest third connection quality. When multiple second terminals have the same third connection quality, the first terminal can select a second terminal for data packet transfer by randomly selecting one or selecting one according to certain predetermined conditions (such as the order in which the third connection quality is obtained).
[0141] It should be understood that the screening conditions provided in the above two optional schemes can be considered comprehensively, that is, the first terminal can obtain the first connection quality and the third connection quality of at least one second terminal, and transfer the data packet through the second terminal with the largest first connection quality and the largest third connection quality. In the case where there are more than one second terminal and there is no second terminal with the largest first connection quality and the largest third connection quality, weights can be assigned to the first connection quality and the third connection quality to calculate the comprehensive connection quality, and the data packet can be terminated through the second terminal with the largest comprehensive connection quality.
[0142] In some embodiments of the present disclosure, the first terminal and the second terminal are electronic devices with communication connection modules, and the third terminal is an electronic accessory with communication connection function. Among them, electronic accessories refer to auxiliary devices or accessories used in conjunction with electronic devices to enhance or supplement the functions of electronic devices. Electronic accessories usually interact with electronic devices through wireless or wired connections and provide additional functions or enhance user experience. Common electronic accessories include wireless headphones, wireless microphones, smart bracelets, etc.
[0143] The above-mentioned embodiments provide common application scenarios of the communication control method provided by the present disclosure. When users use electronic accessories in a safer environment such as home, they often place the electronic device (first terminal) in a fixed location and then wear the electronic accessories to go to other places. In this process, the connection quality between the electronic accessory and the electronic device (first terminal) will decrease. At this time, by relaying the connection through another electronic device (second terminal), the spatial range in which a connection can be established between the electronic device (first terminal) and the electronic accessory is expanded, solving the problem that the connection quality may deteriorate or even become disconnected as factors affecting the connection quality, such as the distance between the electronic device (first terminal) and the electronic accessory, change.
[0144] In a second aspect, the present disclosure provides a communication control method applied to a second terminal. Figure 5 , is a flowchart of another communication control method according to an exemplary embodiment of the present disclosure, which includes the following steps:
[0145] S501, in response to receiving a first data packet sent by a first terminal, sending the first data packet to the third terminal, wherein the first data packet is sent by the first terminal when a first connection quality is greater than or equal to a preset first threshold, the first connection quality represents a connection quality between the second terminal and the third terminal, the first data packet includes a communication address of the third terminal, and / or, in response to receiving a notification sent by the first terminal, receiving a second data packet sent by the third terminal, sending the second data packet to the first terminal, the second data packet including the communication address of the first terminal.
[0146] Regarding receiving the second data packet sent by the third terminal, exemplarily, when the second terminal and the third terminal are connected by a network, the second terminal can use a network monitoring tool (Wireshark, tcpdump, etc.) to monitor all transmitted data packets on the network, and capture the data packet sent by the third terminal to the first terminal. In another exemplary embodiment, ARP (Address Resolution Protocol) spoofing technology can be used, that is, the second terminal sends a false ARP response packet to the third terminal, deceiving the third terminal to believe that the second terminal is the communication gateway of the first terminal. When the third terminal believes that the second terminal is the communication gateway of the first terminal, the third terminal will send the data packet to the second terminal. In another exemplary embodiment, port mirroring can be configured for the second terminal in a communication forwarding device (such as a router, a switch), that is, the data packet sent to the first terminal is mirrored to the port of the second terminal.
[0147] In the embodiment of the present disclosure, in response to receiving a data packet sent by the first terminal, the second terminal sends the first data packet to the third terminal, and in response to receiving a notification sent by the first terminal, receives a second data packet sent by the third terminal, and sends the second data packet to the first terminal, wherein the notification instructs the second terminal to receive the second data packet sent by the third terminal and forward it to the first terminal. Since the second terminal has a communication connection with the first terminal when the first connection quality of the second terminal can be obtained by the first terminal, and the comparison and judgment process of the first connection quality and the first threshold value ensures that the second terminal has a communication connection with the third terminal, the second terminal sends the first data packet to the third terminal and sends the second data packet to the first terminal, which actually completes the transit communication work between the first terminal and the third terminal, and can ensure that when the connection state between the first terminal and the third terminal is poor, the first terminal and the third terminal can still maintain a unidirectional or bidirectional communication connection, solving the problem that the connection quality may deteriorate or even disconnect with the change of factors affecting the connection quality such as the distance between the first terminal and the third terminal.
[0148] When the first terminal is a playback device and the second terminal is a headset, the embodiment provided by the present disclosure can solve the problem that the range between the playback device and the headset is too small, making the headset inconvenient to use.
[0149] In some embodiments of the present disclosure, Figure 5 The communication control method shown in the figure sends the first data packet to the third terminal, including:
[0150] The first data packet is packaged into a third data packet according to the communication address of the first terminal, and the third data packet is sent to the third terminal, where the third data packet simulates the first terminal as a sending terminal.
[0151] The above steps give a specific way for the second terminal to send the first data packet to the third terminal, that is, simulating the first terminal as a sending terminal, packaging the first data packet into a third data packet and sending the third data packet to the third terminal. Specifically, in actual application, the data packet usually contains information of the sender and the receiver. When the second terminal receives the first data packet, it can obtain the relevant information of the first terminal and the relevant information of the third terminal contained in the first data packet. Therefore, it is only necessary to modify the information about the receiver in the first data packet to the relevant information of the third terminal and maintain the information about the sender as the relevant information of the first terminal to realize the packaging process of the third data packet.
[0152] Since when the second terminal forwards the data packet sent by the first terminal to the third terminal, the first terminal is simulated as the sender of the data, and when the second terminal forwards the data packet sent by the third terminal to the first terminal, the reception of the data packet is completed by the second terminal, in other words, for the third terminal, in the process of the second terminal forwarding the data packets of the first terminal and the third terminal, the data packets received by the third terminal always use the first terminal as the sender, and the data packets sent by the third terminal always use the first terminal as the receiver, so the communication control method provided by the present disclosure can realize a completely senseless connection establishment or switching process for the third terminal, without the need to re-establish the connection on the third terminal side, reducing the difficulty of the software and hardware design of the third terminal, and eliminating the extra power consumption generated by re-establishing the connection during the communication control process. Since the battery capacity of electronic accessories is usually relatively small, the above advantages are particularly important when the third terminal is an electronic accessory.
[0153] In some embodiments of the present disclosure, see Figure 6 , is a flowchart of another communication control method shown in some exemplary embodiments, Figure 5 The communication control method shown also includes:
[0154] S601, receiving the communication address of the first terminal broadcast by the first terminal, determining a third connection quality according to the connection status of the second terminal and the first terminal, the third connection quality representing the connection quality between the second terminal and the first terminal, and / or, receiving the communication address of the third terminal broadcast by the first terminal, determining a first connection quality according to the connection status of the second terminal and the third terminal, the first connection quality representing the connection quality between the second terminal and the third terminal.
[0155] In the above two optional schemes, the second terminal receives the communication addresses of the first terminal and the third terminal, so as to directly obtain the first connection quality and the third connection quality according to the above communication addresses. The advantage of this is that when the first terminal broadcasts the above communication address to the second terminal while being able to maintain connection with the first terminal and the third terminal, the second terminal can know the connection quality between itself and the first terminal and the third terminal. When the first terminal wants to obtain the first connection quality, the second terminal can directly return the above connection quality to the first terminal, so that the first terminal can transfer the data packet through the qualified second terminal. Even if the second terminal does not continuously maintain the list of devices that represent the devices it can connect to, the second terminal can also obtain the connection quality required by the first terminal with less calculation.
[0156] In order to better understand the communication control method provided by the embodiment of the present disclosure, Figure 1 The embodiments of the present disclosure are described by taking the illustrated application scenario as an example.
[0157] See also Figure 7 , is a three-side interaction diagram of a communication control method shown in some exemplary embodiments, comprising the following steps:
[0158] S701, the first terminal sends a notification to the second terminal;
[0159] In the aforementioned Figure 1 In the exemplary description of the application scenario shown, the communication connection between the wireless headset 15 (third terminal) and the mobile phone 14 (first terminal) is in an unavailable state, that is, the condition that the second connection quality is less than the preset second threshold value described in some embodiments is satisfied. At this time, the mobile phone 14 stops sending data packets to the wireless headset 15 and obtains the first connection quality of at least one second terminal that has a communication connection with both the mobile phone 14 and the wireless headset 15. For example, the mobile phone 14 obtains two second terminals, the router 11 and the TV 12, among which the router 11 has the largest first connection quality and the largest third connection quality, and the mobile phone 14 sends a notification to the router 11.
[0160] S702, the first terminal sends a first data packet to the second terminal;
[0161] The mobile phone 14 sends the first data packet to the router 11 , so that the router 11 sends the first data packet to the wireless headset 15 .
[0162] S703, the second terminal packages the first data packet into a third data packet;
[0163] In this step, after receiving the first data packet sent by the mobile phone 14, the router 11 simulates the mobile phone 14 as a sending terminal and packages the first data packet into a third data packet.
[0164] S704, the second terminal sends a third data packet to the third terminal;
[0165] In this step, the router 11 sends the third data packet to the wireless headset 15, so that the wireless headset 15 receives the third data packet and plays the audio.
[0166] S705, the third terminal sends a second data packet to the first terminal, but the second terminal receives the second data packet;
[0167] In this step, the wireless headset 15 sends the second data packet to the mobile phone 14, but because the router 11 receives the notification sent by the mobile phone 14, at this time, the router 11 has the authority to receive the second data packet on behalf of the mobile phone 14, so the second data packet is received by the router 11 instead.
[0168] S706: The second terminal sends a second data packet to the first terminal.
[0169] In this step, the router 11 sends the second data packet received in S705 to the mobile phone 14, so that the mobile phone 14 receives the audio recorded by the wireless headset 15, thereby completing the voice call process.
[0170] It should be understood that the above steps are merely exemplary descriptions, wherein the two-way communication between the mobile phone 14 and the wireless headset 15 can be sent in any time sequence, for example, the mobile phone 14 and the wireless headset 15 can simultaneously send data packets to each other and be forwarded by the router 11.
[0171] In summary, the embodiments provided by the present disclosure can ensure that when the connection state between the first terminal and the third terminal is poor, the first terminal can still maintain a one-way or two-way communication connection with the third terminal, expand the spatial range in which the connection can be established between the first terminal and the third terminal, and solve the problem that the connection quality may deteriorate or even disconnect as the distance between the first terminal and the third terminal and other factors affecting the connection quality change. When the first terminal is a playback device and the second terminal is a headset, the embodiments provided by the present disclosure can solve the problem that the range between the playback device and the headset is too small, making the use of the headset inconvenient.
[0172] Corresponding to the embodiments of the aforementioned method, the present disclosure also provides embodiments of a device and a terminal to which the device is applied.
[0173] The third aspect of the present disclosure provides a communication control device. Figure 8 , is a block diagram of a communication control device shown in some exemplary embodiments, the device comprising:
[0174] A first connection quality acquisition module 801 is used to acquire a first connection quality of a second terminal, wherein the second terminal has a communication connection with both the first terminal and the third terminal, and the first connection quality represents a connection quality between the second terminal and the third terminal;
[0175] The first communication connection module 802 is used to perform the following steps:
[0176] In response to the first connection quality being greater than or equal to a preset first threshold, sending a first data packet to the second terminal, so that the third terminal sends the first data packet to the third terminal, the first data packet including a communication address of the third terminal;
[0177] And / or, in response to the first connection quality being greater than or equal to a preset first threshold, sending a notification to the second terminal so that the second terminal receives a second data packet sent by the third terminal and forwards it to the first terminal, wherein the second data packet includes a communication address of the first terminal.
[0178] Optionally, when the first connection quality acquisition module 801 is used to acquire the first connection quality of the second terminal, it is used to:
[0179] In a process of data transmission between the first terminal and the third terminal, in response to a second connection quality being less than a preset second threshold, acquiring a first connection quality of the second terminal, where the second connection quality represents a connection quality between the first terminal and the third terminal;
[0180] And / or, in response to receiving the operation instruction, obtaining the first connection quality of the second terminal.
[0181] Optionally, the device further comprises:
[0182] The sending stop module is used to stop sending data packets to the third terminal in response to a second connection quality being less than a preset second threshold during data transmission between the first terminal and the third terminal, wherein the second connection quality represents the connection quality between the first terminal and the third terminal.
[0183] Optionally, the device further comprises:
[0184] The communication address broadcast module is used to perform the following steps:
[0185] During data transmission between the first terminal and the third terminal, broadcasting the communication address of the first terminal to the second terminal, so that the second terminal determines a third connection quality according to a connection state between the second terminal and the first terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal;
[0186] And / or, during data transmission between the first terminal and the third terminal, the communication address of the third terminal is broadcast to the second terminal, so that the second terminal determines the first connection quality according to the connection status of the second terminal and the third terminal.
[0187] Optionally, when the first connection quality acquisition module 801 is used to acquire the first connection quality of the second terminal, it is used to:
[0188] Acquire a first connection quality of at least one second terminal;
[0189] When the first communication connection module 802 is used to send a first data packet to the second terminal, it is used to:
[0190] Sending the first data packet to a second terminal having the greatest first connection quality among the at least one second terminal;
[0191] When the first communication connection module 802 is used to send a notification to the second terminal, it is used to:
[0192] A notification is sent to a second terminal having the greatest first connection quality among the at least one second terminal.
[0193] Optionally, the device further comprises:
[0194] A third connection quality acquisition module, configured to acquire a third connection quality of at least one second terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal;
[0195] When the first communication connection module is used to send a first data packet to the second terminal, it is used to:
[0196] Sending a first data packet to a second terminal having the greatest third connection quality among the at least one second terminal;
[0197] When the first communication connection module is used to send a notification to the second terminal, it is used to:
[0198] A notification is sent to a second terminal having the greatest third connection quality among the at least one second terminal.
[0199] A fourth aspect of the present disclosure provides a communication control device, see Fig. 9 , is a block diagram of another communication control device shown in some exemplary embodiments, the device comprising:
[0200] The first communication forwarding module 901 is used to perform the following steps:
[0201] In response to receiving a first data packet sent by a first terminal, sending the first data packet to the third terminal, wherein the first data packet is sent by the first terminal when a first connection quality is greater than or equal to a preset first threshold, the first connection quality represents a connection quality between the second terminal and the third terminal, and the first data packet includes a communication address of the third terminal;
[0202] And / or, in response to receiving the notification sent by the first terminal, receiving a second data packet sent by the third terminal, and sending the second data packet to the first terminal, wherein the second data packet includes a communication address of the first terminal.
[0203] Optionally, when the first communication forwarding module 901 is used to send the first data packet to the third terminal, it is used to:
[0204] The first data packet is packaged into a third data packet according to the communication address of the first terminal, and the third data packet is sent to the third terminal, where the third data packet simulates the first terminal as a sending terminal.
[0205] Optionally, the device further comprises:
[0206] The connection quality determination module is used to perform the following steps:
[0207] receiving a communication address of the first terminal broadcasted by the first terminal, and determining a third connection quality according to a connection state between the second terminal and the first terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal;
[0208] And / or, receiving the communication address of the third terminal broadcast by the first terminal, and determining a first connection quality according to a connection status between the second terminal and the third terminal, wherein the first connection quality represents a connection quality between the second terminal and the third terminal.
[0209] The implementation process of the functions and effects of each module in the above-mentioned device is specifically described in the implementation process of the corresponding steps in the above-mentioned method, which will not be repeated here.
[0210] For the device embodiment, since it basically corresponds to the method embodiment, the relevant parts can refer to the partial description of the method embodiment. The device embodiment described above is only schematic, wherein the modules described as separate components may or may not be physically separated, and the components displayed as modules may or may not be physical modules, that is, they may be located in one place, or they may be distributed on multiple network modules. Some or all of the modules may be selected according to actual needs to achieve the purpose of the disclosed solution. A person of ordinary skill in the art can understand and implement it without paying creative labor.
[0211] The embodiments of the communication control device disclosed in the present invention can be applied to a computer device. In a fifth aspect, the present invention provides a computer device. Fig.10 , which exemplarily shows a block diagram of a computer device. For example, the device 1000 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.
[0212] Reference Fig.10 , the device 1000 may include one or more of the following components: a processing component 1002 , a memory 1004 , a power component 1006 , a multimedia component 1008 , an audio component 1010 , an input / output (I / O) interface 1012 , a sensor component 1014 , and a communication component 1016 .
[0213] The processing component 1002 generally controls the overall operation of the device 1000, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 1002 may include one or more processors 1020 to execute instructions to perform all or part of the steps of the above-described method. In addition, the processing component 1002 may include one or more modules to facilitate interaction between the processing component 1002 and other components. For example, the processing component 1002 may include a multimedia module to facilitate interaction between the multimedia component 1008 and the processing component 1002.
[0214] The memory 1004 is configured to store various types of data to support the operation of the device 1000. Examples of such data include instructions for any application or method operating on the device 1000, contact data, phone book data, messages, pictures, videos, etc. The memory 1004 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.
[0215] The power component 1006 provides power to the various components of the device 1000. The power component 1006 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the device 1000.
[0216] The multimedia component 1008 includes a screen that provides an output interface between the device 1000 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 1008 includes a front camera and / or a rear camera. When the device 1000 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and the rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.
[0217] The audio component 1010 is configured to output and / or input audio signals. For example, the audio component 1010 includes a microphone (MIC), and when the device 1000 is in an operating mode, such as a call mode, a recording mode, and a speech recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 1004 or sent via the communication component 1016. In some embodiments, the audio component 1010 also includes a speaker for outputting audio signals.
[0218] I / O interface 1012 provides an interface between processing component 1002 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: home button, volume button, start button, and lock button.
[0219] The sensor assembly 1014 includes one or more sensors for providing various aspects of the status assessment of the device 1000. For example, the sensor assembly 1014 can detect the open / closed state of the device 1000, the relative positioning of components, such as the display and keypad of the device 1000, the sensor assembly 1014 can also detect the position change of the device 1000 or a component of the device 1000, the presence or absence of user contact with the device 1000, the orientation or acceleration / deceleration of the device 1000 and the temperature change of the device 1000. The sensor assembly 1014 can also include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 1014 can also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 1014 can also include an accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor or a temperature sensor.
[0220] The communication component 1016 is configured to facilitate wired or wireless communication between the device 1000 and other devices. The device 1000 can access a wireless network based on a communication standard, such as WiFi, 2G or 3G, 4G or 5G or a combination thereof. In an exemplary embodiment, the communication component 1016 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 1016 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.
[0221] In an exemplary embodiment, the device 1000 can be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors or other electronic components to execute the above-mentioned method for determining the holding method of the electronic device.
[0222] In a sixth aspect, the present disclosure, in an exemplary embodiment, further provides a non-transitory computer-readable storage medium including instructions, such as a memory 1004 including instructions, and the instructions can be executed by the processor 1020 of the device 1000 to complete the above-mentioned method for determining the holding mode of the electronic device. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.
[0223] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the disclosure disclosed herein. This application is intended to cover any variations, uses or adaptations of the present disclosure, which follow the general principles of the present disclosure and include common knowledge or customary technical means in the art that are not disclosed in the present disclosure.
[0224] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.
[0225] The above describes specific embodiments of the present disclosure. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recorded in the claims can be performed in an order different from that in the embodiments and still achieve the desired results. In addition, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0226] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the inventions claimed herein. The present disclosure is intended to cover any variations, uses, or adaptations of the present disclosure that follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not claimed in the present disclosure. The description and examples are to be considered exemplary only, and the true scope and spirit of the present disclosure are indicated by the following claims.
[0227] It should be understood that the present disclosure is not limited to the exact structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.
[0228] The above description is only a preferred embodiment of the present disclosure and is not intended to limit the present disclosure. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present disclosure shall be included in the scope of protection of the present disclosure.
Claims
1. A communication control method, characterized in that: Applied to a first terminal, the method includes: Acquire a first connection quality of a second terminal, wherein the second terminal has communication connections with both the first terminal and the third terminal, and the first connection quality represents a connection quality between the second terminal and the third terminal; In response to the first connection quality being greater than or equal to a preset first threshold, sending a first data packet to the second terminal, so that the second terminal sends the first data packet to the third terminal, the first data packet including a communication address of the third terminal; And / or, in response to the first connection quality being greater than or equal to a preset first threshold, sending a notification to the second terminal so that the second terminal receives a second data packet sent by the third terminal and forwards it to the first terminal, wherein the second data packet includes a communication address of the first terminal.
2. The communication control method according to claim 1, characterized in that: The obtaining the first connection quality of the second terminal includes: In a process of data transmission between the first terminal and the third terminal, in response to a second connection quality being less than a preset second threshold, acquiring a first connection quality of the second terminal, where the second connection quality represents a connection quality between the first terminal and the third terminal; And / or, in response to receiving the operation instruction, obtaining the first connection quality of the second terminal.
3. The communication control method according to claim 1, characterized in that: The method further comprises: During data transmission between the first terminal and the third terminal, in response to a second connection quality being less than a preset second threshold, stopping sending data packets to the third terminal, wherein the second connection quality represents a connection quality between the first terminal and the third terminal.
4. The communication control method according to claim 1, characterized in that: The method further comprises: During data transmission between the first terminal and the third terminal, broadcasting the communication address of the first terminal to the second terminal, so that the second terminal determines a third connection quality according to a connection state between the second terminal and the first terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal; And / or, during data transmission between the first terminal and the third terminal, the communication address of the third terminal is broadcast to the second terminal, so that the second terminal determines the first connection quality according to the connection status of the second terminal and the third terminal.
5. The communication control method according to claim 1, characterized in that: The obtaining the first connection quality of the second terminal includes: Acquire a first connection quality of at least one second terminal; The sending the first data packet to the second terminal includes: Sending the first data packet to a second terminal having the greatest first connection quality among the at least one second terminal; The sending a notification to the second terminal includes: A notification is sent to a second terminal having the greatest first connection quality among the at least one second terminal.
6. The communication control method according to claim 1, characterized in that: The method further comprises: Acquire a third connection quality of at least one second terminal, where the third connection quality represents a connection quality between the second terminal and the first terminal; The sending the first data packet to the second terminal includes: Sending a first data packet to a second terminal having the greatest third connection quality among the at least one second terminal; The sending a notification to the second terminal includes: A notification is sent to a second terminal having the greatest third connection quality among the at least one second terminal.
7. The communication control method according to any one of claims 1 to 6, characterized in that: The first terminal and the second terminal are electronic devices having communication connection modules, and the third terminal is an electronic accessory having a communication connection function.
8. A communication control method, characterized in that: Applied to the second terminal, the method includes: In response to receiving a first data packet sent by a first terminal, sending the first data packet to a third terminal, wherein the first data packet is sent by the first terminal when a first connection quality is greater than or equal to a preset first threshold, the first connection quality represents a connection quality between the second terminal and the third terminal, and the first data packet includes a communication address of the third terminal; And / or, in response to receiving the notification sent by the first terminal, receiving a second data packet sent by the third terminal, and sending the second data packet to the first terminal, wherein the second data packet includes the communication address of the first terminal.
9. The communication control method according to claim 8, characterized in that: The sending the first data packet to the third terminal includes: The first data packet is packaged into a third data packet according to the communication address of the first terminal, and the third data packet is sent to the third terminal, where the third data packet simulates the first terminal as a sending terminal.
10. The communication control method according to claim 8, characterized in that: The method further comprises: receiving a communication address of the first terminal broadcasted by the first terminal, and determining a third connection quality according to a connection state between the second terminal and the first terminal, wherein the third connection quality represents a connection quality between the second terminal and the first terminal; And / or, receiving the communication address of the third terminal broadcast by the first terminal, and determining a first connection quality according to a connection status between the second terminal and the third terminal, wherein the first connection quality represents a connection quality between the second terminal and the third terminal.
11. A communication control device, characterized in that: The device comprises: A first connection quality acquisition module, configured to acquire a first connection quality of a second terminal, wherein the second terminal has communication connections with both the first terminal and the third terminal, and the first connection quality represents a connection quality between the second terminal and the third terminal; The first communication connection module is used to perform the following steps: In response to the first connection quality being greater than or equal to a preset first threshold, sending a first data packet to the second terminal, so that the second terminal sends the first data packet to the third terminal, the first data packet including a communication address of the third terminal; And / or, in response to the first connection quality being greater than or equal to a preset first threshold, sending a notification to the second terminal so that the second terminal receives a second data packet sent by the third terminal and forwards it to the first terminal, wherein the second data packet includes a communication address of the first terminal.
12. A communication control device, characterized in that: The device comprises: The first communication forwarding module is used to perform the following steps: In response to receiving a first data packet sent by a first terminal, sending the first data packet to a third terminal, wherein the first data packet is sent by the first terminal when a first connection quality is greater than or equal to a preset first threshold, the first connection quality represents a connection quality between the second terminal and the third terminal, and the first data packet includes a communication address of the third terminal; And / or, in response to receiving the notification sent by the first terminal, receiving a second data packet sent by the third terminal, and sending the second data packet to the first terminal, wherein the second data packet includes the communication address of the first terminal.
13. A computer device, characterized in that: The method comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the method according to any one of claims 1 to 10 is implemented.
14. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 10 is implemented.