Bluetooth communication method and system, earphone, storage medium and computer program product
By implementing multi-point connection function and priority management in Bluetooth headsets, the problem that traditional Bluetooth headsets can only connect two devices at the same time is solved, and the simultaneous connection with multiple devices is achieved, improving the user experience.
Patent Information
- Application Number
- CN202510070246.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-16
- Publication Date
- 2025-04-25
AI Technical Summary
Traditional Bluetooth headsets can only connect to two terminal devices at the same time, and cannot use multiple Bluetooth devices at the same time, limiting the user's convenience and experience.
Multi-point connectivity is enabled by implementing multi-device connections in Bluetooth headsets, allowing Bluetooth connections to be established with three or more electronic devices and by prioritization comparisons to determine whether to block or preempt audio focus.
The Bluetooth headset is enabled to connect simultaneously with multiple devices, improving user convenience and experience, and being able to effectively manage audio focus when multiple devices exist.
Smart Images

Figure CN119893749A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of Bluetooth communication technology, and in particular to a Bluetooth communication method, system, headset, storage medium and computer program product. Background Art
[0002] With the development of communication technology, Bluetooth headsets (including but not limited to Bluetooth headset-type devices that play audio, such as Bluetooth speakers and other Bluetooth devices) have been widely used. However, in traditional technology, limited by Bluetooth protocols and features, the same Bluetooth headset is only allowed to connect to two terminal devices at the same time, and switch audio streams between the two devices. This scenario and feature of maintaining two Bluetooth connections is called a multi-point feature. For example, when listening to music with a Bluetooth headset, another Bluetooth device sends an incoming call notification, and the Bluetooth headset will switch to a call state. As a result, users cannot use multiple Bluetooth devices through the Bluetooth headset at the same time. Summary of the invention
[0003] In view of at least one of the above technical problems existing in the prior art, this application is proposed. According to one aspect of this application, a Bluetooth communication method is provided, which is applied to a Bluetooth headset, and the Bluetooth headset establishes Bluetooth connections with a first electronic device, a second electronic device, and a third electronic device respectively; the method comprises:
[0004] Obtaining a first request of a first application in the first device, where the first request is used to apply for an audio focus; wherein a second application holds the audio focus, and the second application is installed in the second device or the third device;
[0005] In response to the first request, comparing the priority of the first application with the priority of the second application;
[0006] When the priority of the first application is less than or equal to the priority of the second application, blocking the application of the first application;
[0007] When the priority of the first application is greater than the priority of the second application, the audio focus of the second application is seized.
[0008] In some embodiments, when the priority of the first application is greater than the priority of the second application, after seizing the audio focus of the second application, the method further includes:
[0009] Playing the audio data of the first application based on the audio focus;
[0010] The audio data of the second application is paused; or the audio data of the second application is played in another playback mode, wherein the another playback mode includes the default preferred playback mode of the electronic device to which the second application belongs.
[0011] In some embodiments, after playing the audio data of the first application based on the audio focus, the method further includes:
[0012] After the audio data of the first application is played, the audio focus is switched back to the second application.
[0013] In some embodiments, the application of the electronic device includes a telephone application or a media player application; wherein the priority of the telephone application is greater than the priority of the media player application.
[0014] In some embodiments, the method further comprises:
[0015] When the Bluetooth headset is switched from the non-connection mode to the connection mode, detecting whether the Bluetooth headset has established a Bluetooth connection with the first electronic device, the second electronic device, and the third electronic device;
[0016] When the Bluetooth headset has not established a Bluetooth connection with any one of the first electronic device, the second electronic device and the third electronic device, the Bluetooth headset is enabled to establish a Bluetooth connection with the electronic device with which the connection has not been established.
[0017] In some embodiments, the Bluetooth headset comprises a true wireless stereo headset, and the true wireless stereo headset comprises a first earplug and a second earplug; the method further comprises:
[0018] The first earplug establishes a first Bluetooth connection with the second application to receive and play audio data of the second application;
[0019] The first earbud establishes a true wireless stereo connection with the second earbud;
[0020] The first earbud sends the connection parameters of the first Bluetooth connection to the second earbud through the true wireless stereo connection, so that the second earbud establishes a second Bluetooth connection with the second application based on the connection parameters of the first Bluetooth connection; wherein the second earbud monitors the second application through the second Bluetooth connection, and receives and plays audio data of the second application.
[0021] In some embodiments, the first Bluetooth connection includes a Bluetooth asynchronous link connection; and the second Bluetooth connection includes a smart Bluetooth transmission technology link connection.
[0022] In some embodiments, the first earbud of the true wireless stereo headset stores Bluetooth connection information with any electronic device; the method further includes:
[0023] When the true wireless stereo headset is switched from a non-connection mode to a connection mode, establishing a true wireless stereo connection between the first earplug and the second earplug;
[0024] Detecting whether the true wireless stereo headset establishes a Bluetooth connection with the first electronic device, the second electronic device, and the third electronic device;
[0025] In the case that the true wireless stereo headset has not established a Bluetooth connection with any of the first electronic device, the second electronic device and the third electronic device, based on the Bluetooth connection information between the first earbud and any of the electronic devices stored in the first earbud, the first earbud establishes a Bluetooth asynchronous link connection with the electronic device with which the connection has not been established, and the second earbud establishes a smart Bluetooth transmission technology link connection with the electronic device with which the connection has not been established.
[0026] In some embodiments, the Bluetooth headset further includes a stereo headset, the stereo headset includes a Bluetooth module and a distribution module, and the Bluetooth module is used to connect to the electronic device; the method further includes:
[0027] The Bluetooth module receives the audio data of the second application;
[0028] The distribution module distributes the audio data of the second application to the left channel device and the right channel device of the stereo headset.
[0029] In some embodiments, the method further comprises:
[0030] When the Bluetooth module switches from the non-connection mode to the connection mode, detecting whether the Bluetooth module establishes Bluetooth connections with the first electronic device, the second electronic device, and the third electronic device;
[0031] In the case that the Bluetooth module has not established a Bluetooth connection with any one of the first electronic device, the second electronic device and the third electronic device, the Bluetooth module is enabled to establish a Bluetooth connection with the electronic device with which the connection has not been established.
[0032] Another aspect of the present application embodiment provides a Bluetooth communication system, the system comprising a Bluetooth headset, a first electronic device, a second electronic device and a third electronic device, the Bluetooth headset respectively establishing Bluetooth connections with the first electronic device, the second electronic device and the third electronic device; wherein,
[0033] The Bluetooth headset is used for:
[0034] Obtaining a first request of a first application in the first device, where the first request is used to apply for an audio focus; wherein a second application holds the audio focus, and the second application is installed in the second device or the third device;
[0035] In response to the first request, comparing the priority of the first application with the priority of the second application;
[0036] When the priority of the first application is less than or equal to the priority of the second application, blocking the application of the first application;
[0037] When the priority of the first application is greater than the priority of the second application, the audio focus of the second application is seized.
[0038] In some embodiments, the Bluetooth headset comprises a true wireless stereo headset or a stereo headset.
[0039] Another aspect of the embodiment of the present application provides a true wireless stereo headset, the true wireless stereo headset comprising a first earplug and a second earplug; wherein,
[0040] The first earplug is used to establish a first Bluetooth connection with a second application to receive and play audio data of the second application;
[0041] The first earbud is further configured to establish a true wireless stereo connection with the second earbud, and the first earbud sends connection parameters of the first Bluetooth connection to the second earbud through the true wireless stereo connection;
[0042] The second earplug is used to establish a second Bluetooth connection with the second application based on the connection parameters of the first Bluetooth connection;
[0043] The second earplug is further used to monitor the second application through the second Bluetooth connection, and receive and play audio data of the second application;
[0044] The true wireless stereo headset further includes a memory and a processor, wherein the memory stores a computer program executed by the processor, and when the computer program is executed by the processor, the processor executes the Bluetooth communication method as described above.
[0045] Another aspect of the embodiment of the present application provides a stereo headset, the stereo headset comprising a Bluetooth module and a distribution module; wherein:
[0046] The Bluetooth module is used to connect to electronic devices;
[0047] The Bluetooth module is further used to receive audio data of the second application;
[0048] The distribution module is used to distribute the audio data of the second application to the left channel device and the right channel device of the stereo headset;
[0049] The stereo headset further includes a memory and a processor. The memory stores a computer program to be executed by the processor. When the computer program is executed by the processor, the processor executes the Bluetooth communication method as described above.
[0050] On another aspect, an embodiment of the present application provides a storage medium, on which a computer program is stored. When the computer program is executed by a processor, the processor executes the Bluetooth communication method as described above.
[0051] On the other hand, the embodiments of the present application provide a computer program product, which implements the steps of the above method when the computer program / instructions are executed by a processor.
[0052] In the Bluetooth communication method of the embodiment of the present application, the Bluetooth headset is connected to at least three electronic devices, and when an electronic device applies for audio focus, the priority of the application of the front device and the application of the rear device is used to determine whether to block or seize the audio focus. In this way, the Bluetooth headset can be connected to multiple devices, allowing users to have a better experience. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0054] Figure 1 A schematic flow chart showing a Bluetooth communication method according to an embodiment of the present application;
[0055] FIG. 2( a ) is a schematic diagram showing that the audio focus of media audio is on a second application of a second electronic device according to an embodiment of the present application;
[0056] FIG2( b ) is a schematic diagram showing a Bluetooth headset blocking a request of a first application to obtain audio focus according to an embodiment of the present application;
[0057] Figure 3 A schematic flowchart of playing audio data of a first application based on a new audio focus according to an embodiment of the present application is shown;
[0058] Figure 4 A schematic diagram showing how media audio preempts the audio focus of media audio according to the present application;
[0059] FIG5( a ) is a schematic diagram showing that the audio focus of a telephone audio is on a second electronic device according to an embodiment of the present application;
[0060] FIG5( b ) is a schematic diagram showing a telephone audio preempting the audio focus of a telephone audio according to an embodiment of the present application;
[0061] Figure 6 A schematic diagram showing telephone audio preempting media audio according to an embodiment of the present application;
[0062] Figure 7 A schematic flow chart showing how to switch the audio focus back to the previous device after playing the audio data of the rear device according to an embodiment of the present application;
[0063] Figure 8 A schematic flow chart showing a process of switching a Bluetooth headset from a non-connection mode to a connection mode according to another embodiment of the present application;
[0064] Fig. 9 A schematic diagram showing a true wireless stereo headset establishing a Bluetooth connection with the first electronic device, the second electronic device, and the third electronic device according to an embodiment of the present application;
[0065] Fig.10 A schematic flowchart showing a method of establishing a second Bluetooth connection between a true wireless stereo headset and a second application according to an embodiment of the present application is shown;
[0066] Fig.11 A schematic flow chart showing a true wireless stereo headset reconnection process according to an embodiment of the present application;
[0067] Fig.12 A schematic flow chart showing a stereo headset reconnection process according to an embodiment of the present application;
[0068] Fig.13 A schematic flow chart showing a Bluetooth module reconnection process of a stereo headset according to an embodiment of the present application;
[0069] Fig.14 A schematic block diagram of a true wireless stereo headset according to an embodiment of the present application is shown;
[0070] Fig.15 A schematic block diagram of a stereo headset according to an embodiment of the present application is shown. DETAILED DESCRIPTION
[0071] In order to enable those skilled in the art to better understand the technical solutions of the embodiments of the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0072] Currently, many terminal devices can transmit audio to Bluetooth headsets through the Bluetooth audio transmission model protocol (Advanced Audio Distribution Profile, A2DP) to play audio. Bluetooth headsets support connecting to multiple Bluetooth devices at the same time. Each connection will maintain a Bluetooth connection and send and receive data. These Bluetooth connections occupy a certain amount of Bluetooth bandwidth. However, the Bluetooth bandwidth is limited. When the Bluetooth audio data stream bit rate is high and environmental interference causes retransmission, it may cause jamming. Generally, the impact is small when a Bluetooth headset is connected to two terminals at the same time. If three terminal devices are connected at the same time, it will affect audio transmission and cause jamming. Therefore, when the user configures a Bluetooth headset and turns on high-bitrate audio codec, the headset will actively limit the maximum number of connections, for example, connecting to a maximum of two devices. However, when a user has multiple Bluetooth devices, how to allow users to obtain better convenience and experience is an urgent problem to be solved today.
[0073] Based on at least one of the above technical problems, the present application provides a Bluetooth communication method, which is applied to a Bluetooth headset, and the Bluetooth headset establishes Bluetooth connections with a first electronic device, a second electronic device, and a third electronic device respectively; the method includes: obtaining a first request of a first application in the first device, and the first request is used to apply for audio focus; wherein the second application holds the audio focus, and the second application is installed in the second device or the third device; in response to the first request, comparing the priority of the first application with the priority of the second application; if the priority of the first application is less than or equal to the priority of the second application, blocking the application of the first application; if the priority of the first application is greater than the priority of the second application, seizing the audio focus of the second application. In the Bluetooth communication method of the embodiment of the present application, the Bluetooth headset is connected to at least three electronic devices, and when there is an electronic device applying for audio focus, the priority of the application of the front device and the application of the rear device is used to determine whether to block or seize the audio focus. In this way, the connection between the Bluetooth headset and multiple devices can be realized, so that users can get a better experience.
[0074] Figure 1A schematic flow chart of a Bluetooth communication method according to an embodiment of the present application is shown. Applied to a Bluetooth headset, the Bluetooth headset establishes Bluetooth connections with a first electronic device, a second electronic device, and a third electronic device respectively. The embodiment of the present application can connect three devices at the same time through the blocking and preemption strategy of the Bluetooth connection, so that the user can get a better experience.
[0075] The electronic devices of the embodiments of the present application may include personal computers, laptop computers, tablet computers, mobile phones, VR glasses and other portable electronic devices.
[0076] like Figure 1 As shown, the Bluetooth communication method 100 according to the embodiment of the present application may include the following steps S101, S102, S103 and S104:
[0077] In step S101, a first request of a first application in the first device is obtained, where the first request is used to apply for audio focus.
[0078] Many terminal devices can play audio by transmitting audio to Bluetooth headsets through the Bluetooth audio transmission model protocol (Advanced Audio Distribution Profile, A2DP). When two or more applications output audio streams to play audio at the same time, the system will mix all audio streams together. Therefore, in order to avoid all audio applications playing at the same time, "audio focus" is designed, that is, only one application can obtain audio focus at a time. When an application needs to output audio, it needs to request audio focus, and after obtaining focus, it can play sound. However, obtaining audio focus does not mean that the application can hold it until the playback is completed. Other applications can also request focus, thereby preempting the audio focus held by the application.
[0079] In one example, a second application holds the audio focus, and the second application is installed on the second device or the third device.
[0080] In step S102, in response to the first request, the priority of the first application is compared with the priority of the second application.
[0081] The application of the electronic device may include a telephone application or a media player application, and the priority of the telephone application is greater than the priority of the media player application.
[0082] In step S103, when the priority of the first application is less than or equal to the priority of the second application, the application of the first application is blocked.
[0083] As shown in FIG2(a), it is a schematic diagram of the audio focus of the media audio being on the second application of the second electronic device. The Bluetooth headset receives an audio stream (STREAMING) based on the Bluetooth audio transmission model protocol (Advanced Audio Distribution Profile, A2DP) sent by the second electronic device. The Bluetooth audio transmission model protocol (A2DP) can use the chip in the headset to stack data to achieve high-definition sound.
[0084] As shown in Figure 2(b), it is a schematic diagram of the Bluetooth headset blocking the first application's request to obtain audio focus. When the first application of the first electronic device sends a request to obtain audio focus to the Bluetooth headset, since the priority of the first application is less than or equal to the second application of the second electronic device, the Bluetooth headset rejects the request of the first application (REJECT REQUEST), but still receives the Bluetooth audio transmission model protocol audio stream (A2DPSTREAMING) sent by the second application of the second electronic device, and the audio focus is still on the second application of the second electronic device.
[0085] In step S104, when the priority of the first application is greater than the priority of the second application, the audio focus of the second application is seized.
[0086] In one embodiment of the present application, Figure 3 As shown, when the priority of the first application is greater than the priority of the second application, after seizing the audio focus of the second application, the method further includes step S301:
[0087] In step S301, audio data of the first application is played based on the audio focus.
[0088] The audio data of the second application is paused; or the audio data of the second application is played in another playback mode, wherein the another playback mode includes the default preferred playback mode of the electronic device to which the second application belongs.
[0089] In one example, if Figure 4 As shown, it is a schematic diagram of media audio grabbing media audio focus according to an embodiment of the present application. Figure 4The second electronic device in the is in the media audio playback state, and the headphone audio focus is on the second electronic device. When the first application of the first electronic device initiates media audio, if the Bluetooth headset is configured as the media audio preempts the media audio option, the Bluetooth headset will issue a Bluetooth command to pause (PAUSE) the audio playback of the second application of the second electronic device (front device), so that the audio transmission model protocol of the second electronic device is in a suspended state (A2DP SUSPEND), and then switch the audio focus to the first application audio of the first electronic device (rear device), and the Bluetooth headset receives the audio transmission model protocol audio stream (A2DP STREAMING) of the first application of the first electronic device (rear device) to play the audio. Of course, if the Bluetooth headset is configured as the media audio does not preempt the media audio option, the headset will reject the Bluetooth playback request of the first electronic device (rear device) or disconnect the Bluetooth audio transmission model protocol (A2DP), so that the first electronic device (rear device) does not play or uses the speaker of the first electronic device to play the media audio.
[0090] In other embodiments, some enhanced options may also be configured in the Bluetooth headset, for example, the first electronic device seizes the audio focus of the second electronic device, and then when the first electronic device (rear device) pauses playing the media audio, the Bluetooth headset resumes playing the audio of the second electronic device (front device).
[0091] In another example, as shown in FIG5(a), it is a schematic diagram that the audio focus of the telephone audio is on the second electronic device. The Bluetooth headset receives the audio stream (STREAMING) of the connection-oriented synchronous transmission mode (Synchronous Connection Oriented, SCO) sent by the second electronic device. The audio stream (SCO STREAMING) of the connection-oriented synchronous transmission mode can provide lower latency and higher transmission rate.
[0092] As shown in Figure 5(b), it is a schematic diagram of the telephone audio preempting the audio focus of the telephone audio of an embodiment of the present application. The second electronic device is in the telephone state, and the headset audio focus is on the second electronic device (front device). When the first electronic device (rear device) initiates the telephone audio, if it is configured as the telephone audio preempts the telephone audio option, the Bluetooth headset will issue a Bluetooth instruction to hold (HOLD) the telephone state of the second electronic device (front device), for example, the synchronous transmission mode audio stream (SCO STREAMING) received by the second electronic device is in the hold state (HOLD), and then the audio focus is switched to the audio of the first electronic device (rear device), and the synchronous transmission mode audio stream (SCO STREAMING) of the first electronic device is received to play the audio, and the Bluetooth hands-free protocol (Hands-Free, HFP) of the third electronic device is in the disconnected state (DISCONNECTED). If it is configured that the telephone audio does not preempt the telephone audio option, the Bluetooth headset will reject the Bluetooth audio channel establishment instruction of the first electronic device (rear device), so that the first electronic device (rear device) does not play or uses the speaker of the first electronic device to play the telephone audio.
[0093] In other embodiments, some enhanced options can also be configured in the Bluetooth headset. For example, the first electronic device seizes the audio focus of the second electronic device. When the first electronic device (the rear device) hangs up the phone, the Bluetooth headset will actively initiate the establishment of a telephone audio channel to restore the telephone audio of the second electronic device (the front device) that has lost the audio focus.
[0094] In another example, Figure 6As shown, it is a schematic diagram of telephone audio preempting media audio in an embodiment of the present application. In the connection structure of the Bluetooth headset and the first electronic device, the second electronic device and the third electronic device as shown in Figure 2 (a), since the priority of telephone audio is higher than that of media audio, the telephone audio preempts the media audio option by default. The second electronic device is in the media audio state, at which time the Bluetooth headset receives the audio stream (STREAMING) based on the Bluetooth audio transmission model protocol (Advanced Audio Distribution Profile, A2DP) sent by the second electronic device. The audio focus of the Bluetooth headset is on the second electronic device. When the first electronic device initiates telephone audio, the Bluetooth headset will issue a Bluetooth command to pause transmission (PAUSE) of the audio stream (A2DP STREAMING) based on the Bluetooth audio transmission model protocol of the second electronic device (front device), and then switch the audio focus to the synchronous transmission mode audio stream (SCO STREAMING) of the first electronic device (rear device), and the Bluetooth hands-free protocol (Hands-Free, HFP) of the third electronic device is in a disconnected state (DISCONNECTED). Enhanced options can also be configured, for example, the first electronic device seizes the focus audio of the second electronic device. After the first electronic device (front device) hangs up the call, the Bluetooth headset will restore the media audio of the device that has lost focus due to the first electronic device (front device).
[0095] In one embodiment of the present application, Figure 7 As shown, after playing the audio data of the first application based on the audio focus, the method further includes step S801:
[0096] In step S701, after the audio data of the first application is played, the audio focus is switched back to the second application.
[0097] As shown above, some enhanced options can be configured in the Bluetooth headset, for example, the first electronic device seizes the audio focus of the second electronic device. When the first electronic device (the rear device) hangs up the phone, the Bluetooth headset will actively initiate the establishment of a phone audio channel and restore the phone audio of the second electronic device (the front device) that has lost the audio focus. For another example, the first electronic device seizes the audio focus of the second electronic device, and then when the first electronic device (the rear device) pauses playing the media audio, the Bluetooth headset resumes playing the audio of the second electronic device (the front device).
[0098] In one embodiment of the present application, Figure 8 , which is a schematic flow chart of a process of switching a Bluetooth headset from a non-connection mode to a connection mode. The process 800 of switching a Bluetooth headset from a non-connection mode to a connection mode includes steps S801 and S802:
[0099] In step S801, when the Bluetooth headset is switched from the non-connection mode to the connection mode, detecting whether the Bluetooth headset has established Bluetooth connections with the first electronic device, the second electronic device, and the third electronic device;
[0100] In step S802, when the Bluetooth headset has not established a Bluetooth connection with any one of the first electronic device, the second electronic device and the third electronic device, the Bluetooth headset is enabled to establish a Bluetooth connection with the electronic device with which the connection has not been established.
[0101] In one embodiment of the present application, the Bluetooth headset comprises a true wireless stereo headset, and the true wireless stereo headset comprises a first earplug and a second earplug. Fig. 9 The figure shows a schematic diagram of establishing a Bluetooth connection between a true wireless stereo headset and the first electronic device, the second electronic device, and the third electronic device. In one example, the first Bluetooth connection includes an asynchronous Bluetooth link connection (ACL); the second Bluetooth connection includes an intelligent Bluetooth retransmission technology (IBRT) link connection.
[0102] Here, the Bluetooth Asynchronous Link Connection (ACL) is an asynchronous connectionless link, which is mainly used for packet data transmission. Bluetooth operation commands are transmitted through this link. The Bluetooth Asynchronous Link Connection (ACL) is a packet-oriented connection. It supports both symmetric and asymmetric transmission traffic, and also supports broadcast information. Here, the Bluetooth Asynchronous Link Connection (ACL) is mainly used for transmission scenarios where real-time requirements are not very high, such as listening to music. Intelligent Bluetooth Transmission Technology (IBRT) is an in-ear transmission technology that can support left and right simultaneous sound, and is extremely comfortable to use with one ear. In-ear transmission technology can greatly reduce the delay problem of the left and right ears, and truly achieve split simultaneous sound. At the same time, the left and right ears are used alternately, which can avoid the discomfort caused by long-term wearing of one side, increase the degree of use, and effectively protect our hearing.
[0103] like Fig.10 As shown, the method further includes step S1001, step S1002 and step S1003:
[0104] In step S1001, the first earplug establishes a first Bluetooth connection with the second application to receive and play audio data of the second application;
[0105] In step S1002, the first earplug establishes a True Wireless Stereo (TWS) connection with the second earplug;
[0106] In step S1003, the first earbud sends connection parameters of the first Bluetooth connection to the second earbud through the true wireless stereo (TWS) connection, so that the second earbud establishes a second Bluetooth connection with the second application based on the connection parameters of the first Bluetooth connection.
[0107] The second earplug monitors the second application through the second Bluetooth connection, and receives and plays the audio data of the second application.
[0108] True Wireless Stereo (TWS) is a technology used in audio devices, especially headphones. It allows users to achieve wireless transmission of sound without cables, greatly improving the convenience and freedom of use. True Wireless Stereo (TWS) headphones usually contain two independent earbuds, each of which can communicate directly with the device to achieve wireless separation of left and right channels, providing a more immersive listening experience. The working principle of True Wireless Stereo (TWS) mainly includes two parts: first, the mobile phone or other audio device connects to the main headset via Bluetooth; then, the main headset quickly connects to the secondary headset wirelessly to achieve binaural stereo effect. In this process, the Bluetooth protocol ensures efficient and stable transmission of audio signals. With the continuous advancement of Bluetooth technology, the connection stability and sound quality performance of TWS headphones have also been significantly improved.
[0109] In one example, the first earplug of the true wireless stereo headset stores Bluetooth connection information with any electronic device. Fig.11 , which is a schematic flow chart of a true wireless stereo headset reconnection process 1100 according to an embodiment of the present application. The true wireless stereo headset reconnection process 1100 includes step S1101, step S1102 and step S1103:
[0110] In step S1101, when the true wireless stereo headset is switched from a non-connection mode to a connection mode, establishing a true wireless stereo (TWS) connection between the first earplug and the second earplug;
[0111] In step S1102, it is detected whether the true wireless stereo headset has established a Bluetooth connection with the first electronic device, the second electronic device, and the third electronic device; if not, step S1003 is executed; otherwise, the process ends;
[0112] In step S1103, when the true wireless stereo headset has not established a Bluetooth connection with any of the first electronic device, the second electronic device and the third electronic device, based on the Bluetooth connection information between the first earbud and any of the electronic devices stored in the first earbud, an asynchronous link connection (ACL) is established between the first earbud and the electronic device with which the connection has not been established, and an intelligent Bluetooth transmission technology (IBRT) link connection is established between the second earbud and the electronic device with which the connection has not been established.
[0113] In another embodiment of the present application, the Bluetooth headset further comprises a stereo headset, the stereo headset comprises a Bluetooth module and a distribution module, and the Bluetooth module is used to connect to an electronic device. Fig.12 FIG. 1 is a schematic flow chart of a stereo headset reconnection process 1200 according to an embodiment of the present application. The stereo headset reconnection process 1200 includes step S1201 and step S1202:
[0114] In step S1201, the Bluetooth module receives audio data of the second application;
[0115] In step S1202, the distribution module distributes the audio data of the second application to the left channel device and the right channel device of the stereo headset.
[0116] In one example, if Fig.13 As shown, Fig.13 , which is a schematic flow chart of a Bluetooth module reconnection process 1300 of a stereo headset according to an embodiment of the present application. The method further includes step S1301 and step S1302:
[0117] In step S1301, when the Bluetooth module is switched from the non-connection mode to the connection mode, detecting whether the Bluetooth module has established Bluetooth connections with the first electronic device, the second electronic device, and the third electronic device;
[0118] In step S1302, when the Bluetooth module has not established a Bluetooth connection with any one of the first electronic device, the second electronic device and the third electronic device, the Bluetooth module is enabled to establish a Bluetooth connection with the electronic device with which the connection has not been established.
[0119] In the Bluetooth communication method of the embodiment of the present application, the Bluetooth headset is connected to at least three electronic devices, and when an electronic device applies for audio focus, the priority of the application of the front device and the application of the rear device is used to determine whether to block or seize the audio focus. In this way, the Bluetooth headset can be connected to multiple devices, allowing users to have a better experience.
[0120] Combine the following Figure 2(a) to Figure 6The stereo headset of the present application is described. Figure 2(a) to Figure 6 As shown, the Bluetooth communication system of the embodiment of the present application may include a Bluetooth headset, a first electronic device, a second electronic device and a third electronic device, and the Bluetooth headset establishes Bluetooth connections with the first electronic device, the second electronic device and the third electronic device respectively.
[0121] The Bluetooth headset is used for:
[0122] Obtaining a first request of a first application in the first device, where the first request is used to apply for an audio focus; wherein a second application holds the audio focus, and the second application is installed in the second device or the third device;
[0123] In response to the first request, comparing the priority of the first application with the priority of the second application;
[0124] When the priority of the first application is less than or equal to the priority of the second application, blocking the application of the first application;
[0125] When the priority of the first application is greater than the priority of the second application, the audio focus of the second application is seized.
[0126] In one example, the Bluetooth headset includes a true wireless stereo headset or a stereo headset.
[0127] Combine the following Fig.14 The true wireless stereo headset 1400 of the present application is described, wherein: Fig.14 A schematic block diagram of a true wireless stereo headset 1400 according to an embodiment of the present application is shown.
[0128] The true wireless stereo headset includes a first earplug 1401 and a second earplug 1402.
[0129] The first earplug 1401 is used to establish a first Bluetooth connection with a second application to receive and play audio data of the second application;
[0130] The first earplug 1401 is further configured to establish a TWS connection with the second earplug 1402, and the first earplug sends connection parameters of the first Bluetooth connection to the second earplug through the TWS connection;
[0131] The second earplug 1402 is used to establish a second Bluetooth connection with the second application based on the connection parameters of the first Bluetooth connection;
[0132] The second earplug 1402 is further configured to monitor the second application through the second Bluetooth connection, and receive and play audio data of the second application.
[0133] The true wireless stereo headset further includes a memory and a processor, wherein the memory stores a computer program executed by the processor, and when the computer program is executed by the processor, the processor executes the Bluetooth communication method as described above.
[0134] Combine the following Fig.15 The stereo headset of the present application is described, wherein: Fig.15 A schematic block diagram of a stereo headset 1500 according to an embodiment of the present application is shown.
[0135] The stereo headset includes a Bluetooth module 1501 and a distribution module 1502; wherein,
[0136] The Bluetooth module 1501 is used to connect to electronic devices;
[0137] The Bluetooth module 1501 is further used to receive audio data of the second application;
[0138] The distribution module 1502 is used to distribute the audio data of the second application to the left channel device and the right channel device of the stereo headset.
[0139] The stereo headset further includes a memory and a processor. The memory stores a computer program to be executed by the processor. When the computer program is executed by the processor, the processor executes the Bluetooth communication method as described above.
[0140] In addition, according to an embodiment of the present application, a computer-readable storage medium is also provided, on which program instructions are stored. When the program instructions are executed by a computer or a processor, they are used to execute the corresponding steps of the Bluetooth communication method of the embodiment of the present application.
[0141] In addition, according to an embodiment of the present application, a computer program product is also provided. When the computer program / instructions are executed by a processor, the steps of the method described above are implemented.
[0142] The Bluetooth communication system, true wireless stereo headset, stereo headset, storage medium and computer program product of the embodiments of the present application have the same advantages as the aforementioned Bluetooth communication method because they can implement the aforementioned Bluetooth communication method.
[0143] Although example embodiments have been described herein with reference to the accompanying drawings, it should be understood that the above example embodiments are merely exemplary and are not intended to limit the scope of the present application to this. Those of ordinary skill in the art may make various changes and modifications therein without departing from the scope and spirit of the present application. All these changes and modifications are intended to be included within the scope of the present application as required by the appended claims.
[0144] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0145] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic, for example, the division of the units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed.
[0146] In the description provided herein, a large number of specific details are described. However, it is understood that the embodiments of the present application can be practiced without these specific details. In some instances, well-known methods, structures and techniques are not shown in detail so as not to obscure the understanding of this description.
[0147] Similarly, it should be understood that in order to streamline the present application and help understand one or more of the various inventive aspects, in the description of the exemplary embodiments of the present application, the various features of the present application are sometimes grouped together into a single embodiment, figure, or description thereof. However, the method of the present application should not be interpreted as reflecting the following intention: the claimed application requires more features than the features clearly stated in each claim. More specifically, as reflected in the corresponding claims, the inventive point is that the corresponding technical problem can be solved with features less than all the features of a single disclosed embodiment. Therefore, the claims following the specific embodiment are hereby explicitly incorporated into the specific embodiment, wherein each claim itself serves as a separate embodiment of the present application.
[0148] It will be understood by those skilled in the art that, except for mutually exclusive features, all features disclosed in this specification (including the accompanying claims, abstracts and drawings) and all processes or units of any method or device disclosed in this specification may be combined in any combination. Unless otherwise expressly stated, each feature disclosed in this specification (including the accompanying claims, abstracts and drawings) may be replaced by an alternative feature that provides the same, equivalent or similar purpose.
[0149] In addition, those skilled in the art will appreciate that, although some embodiments described herein include certain features included in other embodiments but not other features, the combination of features of different embodiments is meant to be within the scope of the present application and form different embodiments. For example, in the claims, any one of the claimed embodiments can be used in any combination.
[0150] The various component embodiments of the present application can be implemented in hardware, or in software modules running on one or more processors, or in a combination thereof. It should be understood by those skilled in the art that a microprocessor or digital signal processor (DSP) can be used in practice to implement some or all functions of some modules according to the embodiments of the present application. The application can also be implemented as a device program (e.g., computer program and computer program product) for executing a part or all of the methods described herein. Such a program implementing the present application can be stored on a computer-readable medium, or can have the form of one or more signals. Such a signal can be downloaded from an Internet website, or provided on a carrier signal, or provided in any other form.
[0151] It should be noted that the above embodiments illustrate the present application rather than limit the present application, and that those skilled in the art may design alternative embodiments without departing from the scope of the appended claims. In the claims, any reference symbol between brackets should not be constructed as a limitation to the claims. The word "comprising" does not exclude the presence of elements or steps not listed in the claims. The word "one" or "an" preceding an element does not exclude the presence of multiple such elements. The present application may be implemented by means of hardware including several different elements and by means of a suitably programmed computer. In a unit claim that lists several devices, several of these devices may be embodied by the same hardware item. The use of the words first, second, and third, etc. does not indicate any order. These words may be interpreted as names.
[0152] The above is only a specific implementation or description of a specific implementation of the present application, and the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. The protection scope of the present application shall be based on the protection scope of the claims.
Claims
1. A Bluetooth communication method, characterized in that: Applied to a Bluetooth headset, the Bluetooth headset establishes Bluetooth connections with a first electronic device, a second electronic device, and a third electronic device respectively; the method comprises: Obtaining a first request of a first application in the first device, where the first request is used to apply for an audio focus; wherein a second application holds the audio focus, and the second application is installed in the second device or the third device; In response to the first request, comparing the priority of the first application with the priority of the second application; When the priority of the first application is less than or equal to the priority of the second application, blocking the application of the first application; When the priority of the first application is greater than the priority of the second application, the audio focus of the second application is seized.
2. The method according to claim 1, characterized in that In a case where the priority of the first application is greater than the priority of the second application, after seizing the audio focus of the second application, the method further includes: Playing the audio data of the first application based on the audio focus; The audio data of the second application is paused; or the audio data of the second application is played in another playback mode, wherein the another playback mode includes the default preferred playback mode of the electronic device to which the second application belongs.
3. The method according to claim 2, characterized in that After playing the audio data of the first application based on the audio focus, the method further includes: After the audio data of the first application is played, the audio focus is switched back to the second application.
4. The method according to claim 3, characterized in that The application of the electronic device includes a telephone application or a media player application; wherein the priority of the telephone application is greater than the priority of the media player application.
5. The method according to claim 1, characterized in that The method further comprises: When the Bluetooth headset is switched from the non-connection mode to the connection mode, detecting whether the Bluetooth headset has established a Bluetooth connection with the first electronic device, the second electronic device, and the third electronic device; When the Bluetooth headset has not established a Bluetooth connection with any one of the first electronic device, the second electronic device and the third electronic device, the Bluetooth headset is enabled to establish a Bluetooth connection with the electronic device with which the connection has not been established.
6. The method according to any one of claims 1 to 5, characterized in that: The Bluetooth headset comprises a true wireless stereo headset, and the true wireless stereo headset comprises a first earplug and a second earplug; the method further comprises: The first earplug establishes a first Bluetooth connection with the second application to receive and play audio data of the second application; The first earbud establishes a true wireless stereo connection with the second earbud; The first earbud sends the connection parameters of the first Bluetooth connection to the second earbud through the true wireless stereo connection, so that the second earbud establishes a second Bluetooth connection with the second application based on the connection parameters of the first Bluetooth connection; wherein the second earbud monitors the second application through the second Bluetooth connection, and receives and plays audio data of the second application.
7. The method according to claim 5, characterized in that in, The first Bluetooth connection includes a Bluetooth asynchronous link connection; and the second Bluetooth connection includes a smart Bluetooth transmission technology link connection.
8. The method according to claim 7, characterized in that The first earplug of the true wireless stereo headset stores Bluetooth connection information with any electronic device; the method further includes: When the true wireless stereo headset is switched from a non-connection mode to a connection mode, establishing a true wireless stereo connection between the first earplug and the second earplug; Detecting whether the true wireless stereo headset has established a Bluetooth connection with the first electronic device, the second electronic device, and the third electronic device; In the case that the true wireless stereo headset has not established a Bluetooth connection with any of the first electronic device, the second electronic device and the third electronic device, based on the Bluetooth connection information between the first earbud and any of the electronic devices stored in the first earbud, the first earbud establishes a Bluetooth asynchronous link connection with the electronic device with which the connection has not been established, and the second earbud establishes a smart Bluetooth transmission technology link connection with the electronic device with which the connection has not been established.
9. The method according to any one of claims 1 to 5, characterized in that: The Bluetooth headset also includes a stereo headset, the stereo headset includes a Bluetooth module and a distribution module, and the Bluetooth module is used to connect to the electronic device; the method also includes: The Bluetooth module receives the audio data of the second application; The distribution module distributes the audio data of the second application to the left channel device and the right channel device of the stereo headset.
10. The method according to claim 9, characterized in that The method further comprises: When the Bluetooth module switches from the non-connection mode to the connection mode, detecting whether the Bluetooth module establishes Bluetooth connections with the first electronic device, the second electronic device, and the third electronic device; In the case that the Bluetooth module has not established a Bluetooth connection with any one of the first electronic device, the second electronic device and the third electronic device, the Bluetooth module is enabled to establish a Bluetooth connection with the electronic device with which the connection has not been established.
11. A Bluetooth communication system, characterized in that: The system includes a Bluetooth headset, a first electronic device, a second electronic device and a third electronic device, wherein the Bluetooth headset establishes Bluetooth connections with the first electronic device, the second electronic device and the third electronic device respectively; wherein The Bluetooth headset is used for: Obtaining a first request of a first application in the first device, where the first request is used to apply for an audio focus; wherein a second application holds the audio focus, and the second application is installed in the second device or the third device; In response to the first request, comparing the priority of the first application with the priority of the second application; When the priority of the first application is less than or equal to the priority of the second application, blocking the application of the first application; When the priority of the first application is greater than the priority of the second application, the audio focus of the second application is seized.
12. The system according to claim 11, characterized in that The Bluetooth headset includes a true wireless stereo headset or a stereo headset.
13. A true wireless stereo headset, characterized in that: The true wireless stereo headset comprises a first earplug and a second earplug; wherein, The first earplug is used to establish a first Bluetooth connection with a second application to receive and play audio data of the second application; The first earbud is further configured to establish a true wireless stereo connection with the second earbud, and the first earbud sends connection parameters of the first Bluetooth connection to the second earbud through the true wireless stereo connection; The second earplug is used to establish a second Bluetooth connection with the second application based on the connection parameters of the first Bluetooth connection; The second earplug is further used to monitor the second application through the second Bluetooth connection, and receive and play audio data of the second application; The true wireless stereo headset also includes a memory and a processor, wherein the memory stores a computer program executed by the processor, and when the computer program is executed by the processor, the processor executes the Bluetooth communication method according to any one of claims 1 to 8.
14. A stereo headset, characterized in that: The stereo headset includes a Bluetooth module and a distribution module; wherein, The Bluetooth module is used to connect to electronic devices; The Bluetooth module is further used to receive audio data of the second application; The distribution module is used to distribute the audio data of the second application to the left channel device and the right channel device of the stereo headset; The stereo headset further includes a memory and a processor, wherein the memory stores a computer program executed by the processor, and when the computer program is executed by the processor, the processor executes the Bluetooth communication method according to any one of claims 1 to 5, 9, and 10.
15. A computer-readable storage medium, characterized in that: The storage medium stores a computer program, and when the computer program is executed by the processor, the processor executes the Bluetooth communication method according to any one of claims 1 to 10.
16. A computer program product, characterized in that When the computer program / instructions are executed by a processor, the steps of the method according to any one of claims 1 to 10 are implemented.