Bluetooth playing control method and device, electronic equipment and storage medium

By establishing Bluetooth protocol connection and intelligent management channels in the car computer system, the problem of mobile media audio cannot be output when the car computer system plays non-Bluetooth sound sources is solved, ensuring the normal use of wireless call function and convenient audio playback experience.

CN120378848APending Publication Date: 2025-07-25GUANGZHOU AUTOMOBILE GROUP CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510640241.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-05-16
Publication Date
2025-07-25

AI Technical Summary

Technical Problem

When the car computer system plays non-Bluetooth sound sources, the media audio on the mobile phone cannot be output normally, resulting in the user having to manually disconnect the Bluetooth connection, which affects driving safety and is inconvenient.

Method used

By establishing a physical link connection based on Bluetooth protocol, building a telephone path and a media path, and intelligently managing the connection or disconnection of the media path according to the playback switching instructions, ensuring that when the wireless call function is used normally, the mobile media audio can be played normally through its own output module.

Benefits of technology

It realizes that when the non-Bluetooth sound source is played in the car system, the mobile media audio can be output normally, avoiding manual operations, and improving driving safety and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120378848A_ABST
    Figure CN120378848A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a Bluetooth playing control method and device, electronic equipment and a storage medium, and the method comprises the steps: responding to a Bluetooth pairing request of terminal equipment, and building Bluetooth connection with the terminal equipment, the Bluetooth connection being physical link connection based on a Bluetooth protocol; in response to successful establishment of the Bluetooth connection, establishing a telephone channel and a media channel; a playing switching instruction is obtained, and the playing switching instruction is used for indicating switching of a playing sound source and a playing application; on the basis of the condition that the telephone channel is kept connected, according to the playing switching instruction, a media channel is controlled to be connected or disconnected so as to control Bluetooth playing, and when the media channel is disconnected, the terminal equipment outputs media audios through an output module of the terminal equipment. The technical problem that the media audio of the mobile phone cannot be normally played under the scenes that the Bluetooth call function of the mobile phone and the vehicle-mounted terminal system is ensured to be normally used and the vehicle-mounted terminal system adopts non-Bluetooth sound source playing is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The embodiments of the present application relate to the technical field of Bluetooth audio transmission, and in particular, to a Bluetooth playback control method, device, electronic device, and storage medium. Background Art

[0002] Automotive infotainment systems generally integrate wireless communication functions, among which Bluetooth technology is a key wireless connection method for realizing seamless docking between mobile phones and vehicle head units. At the same time, the audio sources inside the vehicle head unit system are finely divided, including navigation audio sources, media audio sources, telephone audio sources, VR voices, and interactive sound effects, etc. Among them, the Bluetooth audio source is a type of media audio source, which is juxtaposed with non-Bluetooth audio sources, etc.

[0003] In the current in-vehicle Bluetooth audio system, when the vehicle head unit system establishes a Bluetooth connection with the mobile phone, if the vehicle head unit is playing a non-Bluetooth audio source (such as in-vehicle online music or USB music), the media audio on the mobile phone (such as text message reminder sounds, WeChat voices, etc.) cannot be output normally. The existing solution is that the user needs to manually disconnect the Bluetooth connection between the mobile phone and the vehicle head unit system, so that the media audio on the mobile phone can be played normally through the mobile phone player. This operation method is not only cumbersome, but also causes the loss of the wireless call function based on the Bluetooth connection between the mobile phone and the vehicle head unit system, and at the same time distracts the driver's attention and increases the driving risk.

[0004] Therefore, one of the important technical problems in the related art is how to ensure that the media audio on the mobile phone can also be output normally in the scenario where the vehicle head unit system plays a non-Bluetooth audio source while ensuring the normal Bluetooth call function between the mobile phone and the vehicle head unit system. For the above problems, no effective solution has been proposed yet. Summary of the Invention

[0005] The embodiments of the present application provide a Bluetooth playback control method, device, electronic device, and storage medium, aiming to improve the problem that the media audio on the mobile phone cannot be played normally in the scenario where the Bluetooth call function between the mobile phone and the vehicle head unit system is used normally and the vehicle head unit system plays a non-Bluetooth audio source.

[0006] According to one aspect of the embodiments of the present application, a Bluetooth playback control method is provided, including: responding to a Bluetooth pairing request of a terminal device, establishing a Bluetooth connection with the terminal device, where the Bluetooth connection is a physical link connection based on the Bluetooth protocol; responding to the successful establishment of the Bluetooth connection, constructing a telephone path and a media path; obtaining a playback switching instruction, where the playback switching instruction is used to indicate the switching of the playback audio source and the playback application; under the condition that the telephone path remains connected, according to the playback switching instruction, controlling the connection or disconnection of the media path to control Bluetooth playback, where when the media path is disconnected, the terminal device outputs media audio through the output module of the terminal device.

[0007] The above Bluetooth playback control method provided by the embodiments of the present application achieves the following technical effects: First, when the terminal device initiates a Bluetooth pairing request, the in-vehicle system responds and completes the pairing process, ensuring that wireless communication can be carried out between the terminal device and the in-vehicle system through the Bluetooth protocol, laying a foundation for subsequent telephone and media audio transmission; Second, after successfully establishing a Bluetooth connection, the in-vehicle system will respectively construct a telephone path and a media path, so that the Bluetooth connection between the in-vehicle and the terminal device has the functions of call and media playback; Further, upon obtaining a playback switching instruction, while the telephone path remains connected all the time, the in-vehicle system plays a specified type of sound source according to the playback switching instruction, and based on the switched sound source playback type, controls the connection or disconnection of the Bluetooth media path, so as to ensure that under the premise of smooth wireless circuit calls, when the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instruction, by controlling the disconnection of the media path connected by Bluetooth, it is ensured that the media audio of the terminal device can be normally output based on its own output module. Thus, under the premise of successfully establishing a Bluetooth connection between the mobile phone and the in-vehicle system, the embodiments of the present application respectively control the telephone path and the media path, and intelligently manage the state of the Bluetooth media path based on the obtained playback switching instruction, and can achieve the technical effect that when the wireless call function based on the Bluetooth connection between the mobile phone and the in-vehicle system is in normal use, and the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instruction, the media path is intelligently disconnected, so that the mobile phone media audio can be normally played through the mobile phone, thereby solving the problem that the mobile phone media audio cannot be normally played in the scenario where the Bluetooth call function between the mobile phone and the in-vehicle system is in normal use and the in-vehicle system uses a non-Bluetooth sound source for playback.

[0008] Optionally, in response to the successful establishment of a Bluetooth connection, constructing a telephone path and a media path includes: in response to the successful establishment of a Bluetooth connection, constructing a telephone path and obtaining memory data, where the memory data is used to represent the last playback record before the Bluetooth connection; according to the memory data, determining the playback sound source and the media application; in response to the playback sound source being a Bluetooth sound source, and / or, the media application being a target application, constructing a media path.

[0009] The above optional embodiments of the present application can achieve the following technical effects: After the Bluetooth connection is established, a stable path is immediately constructed for telephone communication, ensuring the immediate availability of the telephone function; In addition, obtaining the memory data representing the last playback record before the Bluetooth connection can help the system determine the playback sound source and the media application status to be set currently according to the previous usage situation; At the same time, when the system determines that the playback sound source is a Bluetooth sound source, the in-vehicle system will construct a media path, thereby ensuring the rapid availability of Bluetooth audio, avoiding the time for the user to manually switch the sound source or wait for the system to respond, and improving the immediacy of audio playback and the user experience.

[0010] Optionally, the playback switching instruction includes an audio source switching instruction and a media application switching instruction; according to the playback switching instruction, controlling the media path to be disconnected includes: in response to the audio source switching instruction indicating that the playback audio source after switching is a non-Bluetooth audio source, and the media application switching instruction indicating that the media application after switching is a non-target application, controlling the media path to be disconnected.

[0011] The above optional embodiment of the present application can achieve the following technical effects: when the system receives an audio source switching instruction indicating that the currently playing audio source should be switched to a non-Bluetooth audio source, and a media application switching instruction indicating that the current media application should be switched to a non-target application, the system will control the disconnection of the Bluetooth media path. This processing method avoids the audio conflict caused by the Bluetooth path being in an activated state when the locomotive system plays a non-Bluetooth audio source, resulting in the media audio of the terminal device not being able to play normally. By controlling the disconnection of the Bluetooth media path, the media audio of the terminal device can be played normally through its own output module.

[0012] Optionally, according to the playback switching instruction, controlling the media path connection includes: controlling the media path connection in response to the audio source switching instruction indicating that the switched playback audio source is a Bluetooth audio source, or the media application switching instruction indicating that the switched media application is a target application.

[0013] The above-mentioned optional embodiments of the present application can achieve the following technical effects: when the system receives an audio source switching instruction, indicating that the user wishes to switch to a Bluetooth audio source for playback, or when the system captures the user's selection of a media application that relies on Bluetooth transmission as a new playback source through a media application switching instruction, the system will automatically respond, so that the Bluetooth audio data or the audio of the media application can be transmitted to the infotainment system via Bluetooth in a stable and high-quality manner for playback, thereby meeting the user's immediate needs, avoiding the inconvenience of the user manually operating the Bluetooth connection, and providing a more intelligent and smooth audio playback experience.

[0014] Optionally, the Bluetooth playback control method further includes: recording an attempt time during the process of controlling the media path to attempt to connect or disconnect according to the playback switching instruction; and determining that the media path is successfully connected or disconnected in response to the attempt time being less than a preset time threshold.

[0015] The above-mentioned optional embodiments of the present application can achieve the following technical effects: by recording the attempt time, it helps to monitor the response speed and efficiency of the system operation, ensuring that user instructions can be executed in a timely manner; in addition, the setting of the preset time threshold and the implementation of the success confirmation logic ensure the efficiency of the system when performing Bluetooth playback control operations.

[0016] Optionally, the Bluetooth playback control method further includes: in response to the attempt time being greater than or equal to a preset time threshold, determining that the media path connection or disconnection fails, and then executing again the control of attempting to connect or disconnect the media path and re-recording the attempt time.

[0017] The above optional embodiments of the present application can achieve the following technical effects: By setting a retry mechanism and attempt time monitoring, the connection reliability of the Bluetooth media path in different scenarios can be effectively ensured. Even in the case of a failed initial attempt, the system can automatically retry until the connection is successfully established or disconnected, avoiding the degradation of the user experience caused by unstable connections.

[0018] Optionally, obtaining a playback switching instruction includes: obtaining user preference data; according to the user preference data, using a pre-trained playback recommendation model to determine a recommended playback sound source and a recommended media application; and according to the recommended playback sound source and the recommended media application, determining a playback switching instruction.

[0019] The above optional embodiments of the present application can achieve the following technical effects: By obtaining user preference data, the system can be helped to understand the user's preferences and needs. Furthermore, using a pre-trained deep learning model, the system can identify the user's playback preference pattern based on the user preference data, generate a list of recommended playback sound sources and recommended media applications, and use it to guide the system to generate a specific playback switching instruction according to the recommendation result, so that the system automatically switches to the recommended playback sound source and media application, realizing personalized and scenario-based audio playback control, providing a tailored audio playback experience for each user, and improving user satisfaction.

[0020] According to another aspect of the embodiments of the present application, there is also provided a Bluetooth playback control device, including: a connection module, configured to establish a Bluetooth connection with a terminal device in response to a Bluetooth pairing request of the terminal device, where the Bluetooth connection is a physical link connection based on the Bluetooth protocol; a construction module, configured to construct a telephone path and a media path in response to the successful establishment of the Bluetooth connection; an obtaining module, configured to obtain a playback switching instruction, where the playback switching instruction is used to indicate the switching of a playback sound source and a playback application; and a control module, configured to control the connection or disconnection of the media path to control Bluetooth playback according to the playback switching instruction on the condition that the telephone path remains connected, where when the media path is disconnected, the terminal device outputs media audio through an output module of the terminal device.

[0021] The above Bluetooth playback control device provided by the embodiments of the present application achieves the following technical effects: By quickly responding to Bluetooth pairing requests, the connection module can rapidly establish a Bluetooth connection and provide instant Bluetooth communication capabilities; the construction module is used to construct a telephone path and a media path to ensure that, under the condition of successful Bluetooth connection, the in-vehicle system can perform two-way transmission of telephone and audio data with the user's terminal device, providing comprehensive Bluetooth communication functions for the user; the acquisition module captures changes in the user's playback requirements. By intelligently obtaining playback switching instructions, the in-vehicle system can better conform to the user's usage habits and provide personalized services; according to the obtained playback switching instructions, while the telephone path remains connected at all times, the in-vehicle system plays the specified type of sound source according to the playback switching instructions. Based on the playback type of the switched sound source, it controls the connection or disconnection of the Bluetooth media path to achieve the technical effect that, on the premise of ensuring smooth wireless circuit calls, when the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instructions, by controlling the disconnection of the Bluetooth media path, it ensures that the media audio of the terminal device can be normally output based on its own output module. Thus, it realizes the technical effect that when the wireless call function based on Bluetooth connection between the mobile phone and the in-vehicle system is in normal use and the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instructions, the media path is intelligently disconnected, enabling the mobile phone media audio to be normally played through the mobile phone, and solving the problem that the mobile phone media audio cannot be normally played in the scenario where the Bluetooth call function between the mobile phone and the in-vehicle system is ensured to be in normal use and the in-vehicle system uses a non-Bluetooth sound source for playback.

[0022] According to another aspect of the embodiments of the present application, there is also provided an electronic device, including a processor and a memory. Among them, the memory is used to store a computer program; the processor is used to execute the program stored on the memory to implement the Bluetooth playback control method in any one of the above.

[0023] The above electronic device provided by the embodiments of the present application achieves the following technical effects: Storing the computer program corresponding to implementing the Bluetooth playback control method in any one of the above in the memory, and using the processor to execute the computer program stored on the memory, realizing the technical effect that when the wireless call function based on Bluetooth connection between the mobile phone and the in-vehicle system is in normal use and the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instructions, the media path is intelligently disconnected, enabling the mobile phone media audio to be normally played through the mobile phone, and solving the problem that the mobile phone media audio cannot be normally played in the scenario where the Bluetooth call function between the mobile phone and the in-vehicle system is ensured to be in normal use and the in-vehicle system uses a non-Bluetooth sound source for playback.

[0024] According to another aspect of the embodiments of the present application, there is also provided a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, it implements the Bluetooth playback control method in any one of the above.

[0025] The computer-readable storage medium provided by the embodiment of the present application achieves the following technical effects: storing the computer program corresponding to the Bluetooth playback control method in any of the above into the computer-readable storage medium, and using the processor to execute the computer program stored in the computer-readable storage medium, so as to realize the normal use of the wireless call function based on the Bluetooth connection between the mobile phone and the vehicle system, and when the vehicle system plays a non-Bluetooth sound source according to the playback switching instruction, intelligently disconnect the media path, so that the mobile phone media audio can be normally played through the mobile phone, and solve the problem that the mobile phone media audio cannot be normally played in the scenario where the Bluetooth call function between the mobile phone and the vehicle system is ensured to be used normally and the vehicle system uses a non-Bluetooth sound source for playback.

[0026] It should be noted that the general description above and the detailed description hereinafter are only for exemplifying and explaining the present application, and do not constitute a limitation to the present application. Brief Description of the Drawings

[0027] Figure 1 is a flowchart of the Bluetooth playback control method provided by one embodiment of the present application;

[0028] Figure 2 is a schematic architecture diagram of the Bluetooth playback control method provided by one embodiment of the present application;

[0029] Figure 3 is a structural diagram of the Bluetooth playback control device provided by one embodiment of the present application;

[0030] Figure 4 is a structural diagram of the electronic device provided by one embodiment of the present application. Detailed Embodiments

[0031] In order to make the technical problems, technical solutions and beneficial effects solved by the present application more clear and understandable, the present application will be further described in detail below in conjunction with embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0032] It should be noted that the terms "first", "second", etc. in the description, claims and above-mentioned drawings of this application are used to distinguish similar objects, and do not necessarily have to be used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged under appropriate circumstances, so that the embodiments of the present application described here can be implemented in an order different from those illustrated or described here. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device that includes a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.

[0033] According to an embodiment of the present invention, an embodiment of a Bluetooth playback control method is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order than here.

[0034] A Bluetooth playback control method provided by an embodiment of this application includes: in response to a Bluetooth pairing request of a terminal device, establishing a Bluetooth connection with the terminal device, where the Bluetooth connection is a physical link connection based on the Bluetooth protocol; in response to the successful establishment of the Bluetooth connection, constructing a telephone path and a media path; obtaining a playback switching instruction, where the playback switching instruction is used to indicate the switching of a playback sound source and a playback application; under the condition that the telephone path remains connected, according to the playback switching instruction, controlling the connection or disconnection of the media path to control Bluetooth playback, where when the media path is disconnected, the terminal device outputs media audio through an output module of the terminal device.

[0035] The above Bluetooth playback control method provided by the embodiments of the present application achieves the following technical effects: First, when the terminal device initiates a Bluetooth pairing request, the in-vehicle system responds and completes the pairing process, ensuring that wireless communication can be carried out between the terminal device and the in-vehicle system through the Bluetooth protocol, laying a foundation for subsequent telephone and media audio transmission; Second, after successfully establishing a Bluetooth connection, the in-vehicle system constructs a telephone path and a media path respectively, so that the Bluetooth connection between the in-vehicle system and the terminal device has the functions of call and media playback; Further, obtain a playback switching instruction. When the telephone path remains connected all the time, the in-vehicle system plays the specified type of sound source according to the playback switching instruction, and controls the connection or disconnection of the Bluetooth media path based on the switched sound source playback type, so as to ensure that under the premise of smooth wireless circuit calls, when the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instruction, by controlling the disconnection of the media path of the Bluetooth connection, it is ensured that the media audio of the terminal device can be normally output based on its own output module. Thus, under the premise of successfully establishing a Bluetooth connection between the mobile phone and the in-vehicle system, the embodiments of the present application control the telephone path and the media path respectively, and intelligently manage the state of the Bluetooth media path based on the obtained playback switching instruction, so as to realize the normal use of the wireless call function based on the Bluetooth connection between the mobile phone and the in-vehicle system, and when the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instruction, intelligently disconnect the media path, so that the mobile phone media audio can be normally played through the mobile phone, thus solving the problem that the mobile phone media audio cannot be normally played in the scenario where the Bluetooth call function between the mobile phone and the in-vehicle system is normally used and the in-vehicle system uses a non-Bluetooth sound source for playback.

[0036] Embodiment 1

[0037] The embodiments of the present application provide a Bluetooth playback control method. Please refer to Figure 1 , including the following steps:

[0038] S110: In response to a Bluetooth pairing request from a terminal device, establish a Bluetooth connection with the terminal device, where the Bluetooth connection is a physical link connection based on the Bluetooth protocol;

[0039] Specifically, when the user issues a Bluetooth pairing request on the terminal device (such as a smart phone or a smart watch), the Bluetooth module of the in-vehicle system (such as the in-vehicle cockpit information entertainment domain controller) starts to scan for Bluetooth devices in the surrounding environment. Bluetooth scanning is achieved based on radio broadcasts and searching for nearby Bluetooth devices. Once a matching device is detected, the pairing request can be responded to.

[0040] After receiving a Bluetooth pairing request from a terminal device, the infotainment domain controller establishes a Bluetooth connection with the terminal device according to the Bluetooth protocol stack. At this time, the established Bluetooth connection is a physical link connection based on the Bluetooth protocol. That is to say, only based on the Bluetooth protocol, a basic connection relationship is established between the terminal device and the in-vehicle system.

[0041] It can be understood that by automatically and quickly responding to the Bluetooth pairing request, users can seamlessly connect their terminal devices to the in-vehicle cockpit infotainment system without going through a cumbersome manual setup process, reducing the waiting time for users and enhancing the user experience.

[0042] S120: In response to the successful establishment of the Bluetooth connection, construct a telephone path and a media path;

[0043] Specifically, when the in-vehicle infotainment domain controller receives a Bluetooth pairing request from a terminal device and successfully establishes a Bluetooth connection, the controller will confirm the connection status to ensure that the data transmission channel has been stably established.

[0044] Specifically, after confirming the successful Bluetooth connection, further construct a telephone path for Bluetooth calls and a media path for media playback. Exemplarily, when a basic connection is successfully established between the in-vehicle system and the terminal device, further construct a telephone path based on the HFP (Hands-Free Profile) protocol to ensure the availability of call capabilities. Among them, HFP is a Bluetooth communication protocol defined by the Bluetooth Special Interest Group, mainly used to achieve wireless connection and communication between a mobile phone and a hands-free device (such as an in-vehicle Bluetooth system, a Bluetooth headset). The establishment of this path includes two-way transmission of audio signals and transmission of telephone control signals, ensuring that users can answer or make calls without directly operating the mobile phone.

[0045] At the same time, after confirming the successful Bluetooth connection, construct a media path based on the A2DP (Advanced Audio Distribution Profile) protocol. Among them, A2DP is a high-quality audio transmission protocol designed to achieve wireless transmission of high-quality audio, mainly used to transmit audio from a source device (such as a smartphone, a music player) to a receiving device (such as a Bluetooth headset, an in-vehicle audio system, a Bluetooth speaker, etc.).

[0046] By constructing a telephone path and a media path, the reliability of high-quality audio transmission and wireless phone calls is ensured, the risk of audio interruption and phone disconnection is reduced, and the stability of the in-vehicle Bluetooth system and user satisfaction are improved.

[0047] It should be noted that after the telephone connection and the media connection are successfully established, the telephone connection and the media connection between the terminal device and the in-vehicle system are in a normal connected state. In the case where the telephone connection and the media connection are not established, wireless transmission of audio and calls between the terminal device and the in-vehicle system cannot be achieved.

[0048] S130: Obtain a playback switching instruction, where the playback switching instruction is used to indicate the switching of the playback sound source and the playback application;

[0049] Specifically, the in-vehicle infotainment system can receive playback switching instructions from the user, and these instructions are issued through physical buttons, voice commands, touch screen operations, etc. In addition, the system can also automatically trigger playback switching instructions according to the user's behavior pattern or historical record to adapt to different usage scenarios.

[0050] Optionally, the system receives a playback switching instruction from the user, and the playback switching instruction is used to indicate the switching of the playback sound source and the playback application. Exemplarily, the playback instruction is an operation such as switching to Bluetooth music, pausing Bluetooth music, switching to online music, or USB music.

[0051] Specifically, after receiving the playback switching instruction, the system will analyze the specific content of the instruction to determine whether the user wishes to switch from the current sound source to the Bluetooth sound source or vice versa. Based on this judgment, the system will make an intelligent decision on whether to connect or disconnect the Bluetooth media connection and whether to adjust the state of the Bluetooth telephone connection.

[0052] It can be understood that by obtaining the playback switching instruction, the current needs of the user can be timely known, and the analysis result of the instruction can be used as the basis for dynamically adjusting the connection state of the Bluetooth media connection subsequently.

[0053] S140: Based on the condition that the telephone connection is maintained, according to the playback switching instruction, control the connection or disconnection of the media connection to control Bluetooth playback. When the media connection is disconnected, the terminal device outputs media audio through the output module of the terminal device.

[0054] Specifically, regardless of whether the user is currently using the Bluetooth media playback function, the system will maintain the connection state of the telephone connection. This means that even when Bluetooth media playback is not in use, the telephone connection is always ready to ensure that the user can make hands-free calls at any time.

[0055] Specifically, based on the analysis result of the playback switching instruction, the system intelligently judges whether to connect or disconnect the Bluetooth media connection. Exemplarily, when the user selects Bluetooth music or activates the Bluetooth music application through the in-vehicle system interface, the system will immediately establish an A2DP connection; when the user switches to non-Bluetooth sound source playback, the system will disconnect the A2DP connection to avoid resource waste and potential audio conflicts.

[0056] It should be noted that when the A2DP media path is disconnected, the media audio of the smart terminal is output through the output module of the terminal device. For example, the media audio of the mobile phone (subsequent descriptions of the smart terminal will take the mobile phone as an example) will no longer be played through the in-vehicle system, but directly output through the output module of the mobile phone itself (such as a speaker or headphones), ensuring that when the in-vehicle system does not support Bluetooth audio, the user can still hear the mobile phone media sound, such as WeChat voice, text message reminder sounds, etc.

[0057] In the non-Bluetooth audio source playback scenario, by intelligently controlling the disconnection of the Bluetooth media path, the technical effect is achieved that the mobile phone media audio can be normally played on the mobile phone under the condition that the wireless call function based on the Bluetooth connection between the mobile phone and the in-vehicle system is in normal use, thereby solving the problem that the mobile phone media audio cannot be normally played when the wireless call function based on the Bluetooth connection between the mobile phone and the in-vehicle system is in normal use and the in-vehicle system is currently playing a non-Bluetooth audio source.

[0058] Optionally, in the above step S120, in response to the successful establishment of the Bluetooth connection, constructing the telephone path and the media path includes the following steps:

[0059] S121, in response to the successful establishment of the Bluetooth connection, construct a telephone path and obtain memory data, where the memory data is used to represent the last playback record before the Bluetooth connection;

[0060] Specifically, when the Bluetooth connection between the mobile phone and the in-vehicle system is successfully established, the in-vehicle system first constructs a telephone path.

[0061] The construction of the telephone path is based on the automatic response of Bluetooth pairing, ensuring that the user can use the hands-free call function in the vehicle without being affected by subsequent audio sources or media application switching.

[0062] In addition, while constructing the telephone path, the in-vehicle system reads memory data from the storage unit, which represents the last playback record before the Bluetooth connection is disconnected, including but not limited to the type of audio source played, media application, volume setting, etc. The acquisition of memory data is the key basis for subsequent intelligent control of the media path.

[0063] By obtaining the memory data, the system can quickly understand the user's previous playback preferences, provide a basis for subsequent processing, and thus quickly restore to the previous playback state when the Bluetooth is reconnected, without the user having to reset.

[0064] Exemplarily, the last playback record before the user's last Bluetooth connection was disconnected shows that the user played music through a Bluetooth audio source and used a specific music playback application. When the user enters the vehicle again and reconnects the Bluetooth, the in-vehicle system first constructs a telephone connection, and then reads the playback history in the memory to obtain the information that the user last used a Bluetooth audio source and a music playback application.

[0065] S122. Determine the playback audio source and media application according to the memory data;

[0066] Specifically, the in-vehicle system analyzes the memory data to identify the type of playback audio source (such as Bluetooth music, online music, or USB music) that the user was using before the Bluetooth connection was disconnected and the media application (such as a specific music player, call application, etc.) that was used.

[0067] Based on the analysis result of the memory data, the system determines the playback audio source and media application that are most likely to be used currently, which provides decision-making information for the construction or disconnection of the media connection in the next step.

[0068] Exemplarily, if the memory data indicates that the last time was using a Bluetooth audio source and playing through Music Application A, then after the Bluetooth is reconnected, the in-vehicle system will automatically identify the music playback application and prepare to construct a media connection to resume music playback.

[0069] Optionally, if there are multiple audio source usage records in the memory data, the system can prioritize the audio source types to decide which audio source's media connection to construct under limited resources.

[0070] S123. In response to the playback audio source being a Bluetooth audio source and / or the media application being the target application, construct a media connection.

[0071] Specifically, the target application refers to an application used to play Bluetooth audio in the Bluetooth connection state, such as a music player or a Bluetooth phone application.

[0072] Specifically, the memory data shows that the user was playing a Bluetooth audio source or using the target application (such as the Bluetooth music playback application used by the user) before the last Bluetooth connection was disconnected, then the in-vehicle system will consider that the user has a high possibility of continuing to play using the Bluetooth audio source, and thus construct a media connection.

[0073] In addition, the process of constructing a media connection involves advanced functions of the Bluetooth protocol to ensure that audio data can be transmitted from the mobile phone side to the in-vehicle system and played through the in-vehicle audio system. The establishment of the A2DP protocol is based on a successful Bluetooth connection, ensuring the wireless transmission of audio data.

[0074] In summary, by automatically analyzing the memory data and intelligently constructing or disconnecting the media path, when the user reconnects the Bluetooth each time, there is no need to manually adjust the settings of the sound source or media application, and the system can automatically resume the playback state before the last disconnection, effectively improving the user experience.

[0075] Optionally, the playback switching instruction includes a sound source switching instruction and a media application switching instruction. In the above step S140, controlling the disconnection of the media path according to the playback switching instruction includes the following steps: in response to the sound source switching instruction indicating that the switched playback sound source is a non-Bluetooth sound source, and the media application switching instruction indicating that the switched media application is a non-target application, controlling the disconnection of the media path.

[0076] Specifically, the playback switching instruction is a command for the user or the system to switch between different sound sources (such as Bluetooth sound source, USB sound source, online sound source, etc.) or different media applications (such as music player, audiobook application, instant messaging application, etc.). Based on these instructions, the in-vehicle system can intelligently determine whether it is necessary to maintain the connection of the Bluetooth media path, avoiding unnecessary resource consumption and audio output conflicts.

[0077] Specifically, when the user or the system selects to switch to a non-Bluetooth sound source (such as a USB storage device, an online music streaming service, etc.) through the sound source switching instruction, the in-vehicle system will recognize this instruction and understand that the user currently does not intend to play audio through Bluetooth.

[0078] In addition, when the user selects a non-target application (such as the navigation application or radio application of the in-vehicle system) through the media application switching instruction, the in-vehicle system will further confirm whether it is necessary to disconnect the Bluetooth media path.

[0079] Furthermore, it should be understood that when selecting to switch to a non-Bluetooth sound source through the sound source switching instruction and selecting a non-target application through the media application switching instruction, at this time, the in-vehicle system can only play the non-Bluetooth sound source, and it is impossible to simultaneously listen to the mobile phone media audio. Since the audio system of the in-vehicle device focuses on processing the current sound source signal after switching to the non-Bluetooth sound source and no longer receives the audio data from Bluetooth, even if there is media audio on the mobile phone side, it cannot be played through the in-vehicle device, resulting in the situation that the user cannot synchronously listen to the mobile phone media audio while enjoying the non-Bluetooth sound source.

[0080] In this application, in response to the sound source switching instruction indicating that the switched playback sound source is a non-Bluetooth sound source, and the media application switching instruction indicating that the switched media application is a non-target application, the media path is controlled to be disconnected. When the user selects a non-Bluetooth sound source (such as USB music, in-vehicle online music service, etc.) and switches to a non-target application, the Bluetooth media path is disconnected, avoiding unnecessary energy consumption due to the continuous operation of the Bluetooth module. More importantly, after disconnecting the Bluetooth media path, the media audio on the mobile phone side (such as WeChat voice, mobile phone music playback, etc.) will not attempt to play through the speaker system of the vehicle, but directly through the audio output module of the mobile phone itself (such as speakers or headphones), ensuring that when playing non-Bluetooth sound sources in the vehicle system and without disconnecting the Bluetooth call established by the mobile phone, the media audio on the mobile phone side can be played normally.

[0081] Optionally, controlling the connection of the media path according to the playback switching instruction further includes: in response to the sound source switching instruction indicating that the switched playback sound source is a Bluetooth sound source, or the media application switching instruction indicating that the switched media application is a target application, controlling the connection of the media path.

[0082] Specifically, when the user selects to switch back to the Bluetooth sound source through the sound source switching instruction, it means that the user wants to play the audio stream again through a Bluetooth-connected device (such as a mobile phone). At this time, the vehicle system recognizes the user's intention and automatically activates the Bluetooth media path to prepare for the audio data transmission of the Bluetooth sound source.

[0083] The automatic reconnection mechanism reduces the manual operation when the user switches between Bluetooth sound sources and non-Bluetooth sound sources, making the switching of audio playback more convenient.

[0084] In addition, when the user selects a target application (which needs to transmit audio data to the vehicle system through the Bluetooth A2DP protocol) through the media application switching instruction, even if the current sound source is a non-Bluetooth sound source, the vehicle system will re-establish the Bluetooth media path to support the audio playback requirements of the specific application. This mechanism ensures that even in the case of a non-Bluetooth sound source, the audio data of the target application can be transmitted through the Bluetooth media path to meet the user's requirements for specific audio applications.

[0085] Exemplarily, the user is playing music through the USB sound source and needs to switch to the music playback application on the mobile phone. After the user selects the Bluetooth sound source on the vehicle system, the vehicle system receives the sound source switching instruction, immediately responds and re-establishes the Bluetooth media path, and the music playback application on the mobile phone side then sends audio data to the vehicle system through the Bluetooth media path, realizing a quick switch from the USB sound source to the Bluetooth sound source, and the user can continue to enjoy the music on the mobile phone through the vehicle speakers.

[0086] Optionally, the Bluetooth playback control method further includes:

[0087] S150. During the process of controlling the media path to attempt connection or disconnection according to the playback switching instruction, record the attempt time.

[0088] Specifically, after the in-vehicle system receives the playback switching instruction, it will immediately activate the Bluetooth module and attempt to establish or disconnect the Bluetooth media path according to the instruction. This process involves the interaction of the Bluetooth protocol stack and is affected by various factors, such as Bluetooth signal quality, the Bluetooth module status of the mobile phone and the in-vehicle system, environmental interference, etc., resulting in uncertainty in the time for attempting connection or disconnection. Therefore, the system starts recording the time at the moment of attempting to establish or disconnect the Bluetooth media path until the connection or disconnection operation is completed, and this recorded time is the attempt time.

[0089] By recording the attempt time, the in-vehicle system can monitor the duration of the Bluetooth media path connection or disconnection process in real time, which is crucial for identifying whether the operation is completed within the expected time. A long attempt time indicates that there is a fault or abnormality in the Bluetooth connection, such as Bluetooth module overload, signal interference, etc. Recording the attempt time helps to quickly locate the problem and provides data support for subsequent fault detection and diagnosis.

[0090] S160. In response to the attempt time being less than the preset time threshold, determine that the media path connection or disconnection is successful.

[0091] Specifically, the preset time threshold is preset according to the average operation time of the Bluetooth media path connection or disconnection and the system's requirement for response speed. If the result of the recorded attempt time is less than this threshold, the in-vehicle system will determine that the connection or disconnection operation of the Bluetooth media path is successful.

[0092] Ensuring that the connection or disconnection operation of the Bluetooth media path can be completed within a reasonable time, avoiding excessive waiting time for users when switching audio sources or applications, and providing an instant response user experience.

[0093] In addition, by setting the time threshold, those long-time attempt failures caused by reasons such as unstable Bluetooth signals and abnormal device states can be filtered out, effectively distinguishing temporary errors from successful operations, and improving the reliability of the Bluetooth playback control method.

[0094] Optionally, according to the historical record of the Bluetooth connection and the current environmental conditions (such as Bluetooth signal strength, interference situation, etc.), the in-vehicle system can dynamically adjust the preset time threshold to adapt to different operating environments and improve the adaptability and success rate of Bluetooth operations.

[0095] Optionally, the Bluetooth playback control method further includes: in response to the attempt time being greater than or equal to the preset time threshold, determine that the media path connection or disconnection fails, and then execute again the control of the media path to attempt connection or disconnection and re-record the attempt time.

[0096] Specifically, when the attempt time reaches or exceeds the preset time threshold, the in-vehicle system determines that the current connection or disconnection operation fails. This determination is based on the system's expectation of the Bluetooth operation response time, ensuring that when the operation is not completed within a reasonable time, timely feedback and processing can be carried out.

[0097] Specifically, once it is determined that the operation fails, the in-vehicle system will automatically restart the connection or disconnection process and attempt the second operation. This retry mechanism is based on the assumption that the Bluetooth connection process may be interfered by the outside world. By trying again, temporary problems can be excluded and the connection reliability can be improved.

[0098] During the second attempt, the system starts recording the attempt time again to monitor whether the second operation is completed within the preset time threshold. This step ensures that the system can continuously monitor the operation status and timely feedback the operation result.

[0099] Through the preset time threshold and the retry mechanism, the technical solution of this application improves the robustness of the Bluetooth playback control method. Even under unstable or interfering conditions, the connection or disconnection operation can be ensured to succeed eventually through multiple attempts. In addition, for users, this mechanism means that even if the initial attempt fails, there is no need for manual intervention. The in-vehicle system will automatically perform the retry, reducing the complexity of user operations and providing a smoother user experience.

[0100] Exemplarily, when the user uses the in-vehicle system and decides to switch to the USB sound source. The in-vehicle system attempts to disconnect the Bluetooth media path. However, due to some device resource conflicts, the disconnection time of the first attempt exceeds the preset time threshold. The system automatically recognizes that the disconnection fails, then performs the disconnection operation again and starts recording the attempt time again. In the second attempt, the disconnection operation is successfully completed, and the user can play the USB sound source normally while avoiding audio conflicts between the Bluetooth sound source and the USB sound source.

[0101] Optionally, to prevent excessive consumption of system resources caused by infinite loop retries, the in-vehicle system should set a limit on the maximum number of retries. When the maximum number of retries is reached, the system stops attempting and prompts the user that there may be a deeper fault and further checks on the Bluetooth device or contact with technical support are required.

[0102] Optionally, in step S130, obtaining the playback switching instruction includes:

[0103] S131, obtaining user preference data;

[0104] Specifically, collecting user preference data, which includes but is not limited to the following information:

[0105] Historical playback records: Record the audio source types and applications selected by the user in the past, such as Bluetooth music, USB music, online radio, etc., as well as the usage frequency; Time information: Analyze the user's playback preferences at specific times (such as in the morning, after work hours, etc.); Application usage patterns: Monitor the user's habits of using media applications, such as whether they often use Bluetooth music during commuting or use online video services in specific situations; Device connection status: Identify the connection history and preferences of the user's devices (such as mobile phones, USB devices, etc.), as well as the compatibility between devices; User feedback: Collect the user's direct feedback on the playback experience, including audio source switching, sound quality preferences, etc.

[0106] The purpose of obtaining these data is to provide training materials for the subsequent playback recommendation model to ensure that the recommendation results can be as close as possible to the actual needs of users.

[0107] S132, According to the user preference data, use the pre-trained playback recommendation model to determine the recommended playback audio source and recommended media application;

[0108] Specifically, after collecting the user preference data, input the data into the pre-trained playback recommendation model. This model is generated based on deep learning technology and can predict the user's playback audio source and media application selection in the current or future scenarios by analyzing and learning the user's historical behaviors and preferences.

[0109] Optionally, the working process of the playback recommendation model includes: converting the user preference data into a numerical or vector form that the model can process to provide input for the model; the model analyzes the user's playback behavior patterns based on the training data and algorithms and predicts the playback audio source and media application that the user is most likely to select; the model outputs the recommended playback audio source and media application to provide guidance for the next playback switching instruction.

[0110] S133, Determine the playback switching instruction according to the recommended playback audio source and recommended media application.

[0111] Specifically, when the playback recommendation model determines the recommended playback audio source and media application, the in-vehicle system will automatically execute the playback switching instruction according to these recommendation results. This means that the system can automatically switch to the playback audio source that the user is most likely to prefer and simultaneously start the corresponding media application without manual operation by the user, greatly enhancing the convenience of the playback experience.

[0112] It can be understood that by analyzing the user preference data and using the deep learning model for playback recommendation, the in-vehicle system can provide customized playback audio source and media application selections for each user, enhancing the personalization of the playback experience.

[0113] Exemplarily, when the user commutes every morning, they usually use the Bluetooth music function on their mobile phone. By analyzing the user preference data, the system identifies this pattern and automatically executes the instruction to switch to the Bluetooth audio source and media application when the user gets in the car and starts the in-vehicle infotainment system, without the need for manual operation by the user, saving time and providing a seamless playback experience.

[0114] Optionally, the playback recommendation model should have a real-time feedback learning function. According to the user's acceptance of the recommendation results, it dynamically adjusts the recommendation algorithm to provide more accurate recommendations.

[0115] Optionally, for the Bluetooth playback control method provided in the embodiments of the present application, please refer to Figure 2 , and it can be implemented as follows:

[0116] (1) When the infotainment domain system powers off, it remembers the last played audio source and media playback type.

[0117] (2) When the infotainment domain system powers on or is first paired with the mobile phone, it establishes an HFP protocol connection through Bluetooth scanning.

[0118] (3) When the infotainment domain system powers on or is first paired with the mobile phone, it performs Bluetooth scanning and makes an intelligent decision on whether to establish a Bluetooth A2DP protocol connection based on whether the last played audio source and media application are Bluetooth music.

[0119] (4) When the user switches the audio source and application in the infotainment domain system, the service background connects or disconnects the Bluetooth A2DP protocol. Specifically: when the Bluetooth music application is not in the foreground and the audio source is not Bluetooth music, the A2DP protocol connection with the mobile phone is disconnected; when the user clicks on the Bluetooth music application on the in-vehicle infotainment system interface and the application obtains the foreground focus at this time, the A2DP protocol connection with the mobile phone is quickly established; or when the user selects the Bluetooth audio source in the audio source selection, the A2DP protocol connection with the mobile phone is also quickly established, realizing a seamless intelligent audio source switch for the user.

[0120] (5) When the infotainment domain system intelligently disconnects or connects the A2DP protocol connection with the mobile phone, it needs to implement a failure retry strategy. After the disconnection or connection fails within a certain time (assuming 2s), it should perform a retry to avoid excessive waiting during the switch.

[0121] By implementing the above Bluetooth playback control method provided by the embodiments of the present application, the infotainment domain system of the vehicle head unit realizes intelligent and personalized audio management, significantly optimizes the connection and disconnection processes of Bluetooth audio sources, and improves the user experience. Specifically, by memorizing the last played audio source and media type when the system powers off, this method ensures that the system can make an intelligent decision on the establishment of the Bluetooth media path when the system powers on or re-pairs, avoiding unnecessary waste of Bluetooth resources. When the user switches the audio source or application, the system can automatically disconnect or quickly connect the Bluetooth A2DP protocol according to the current scenario, realizing seamless switching of audio output. Whether switching from a non-Bluetooth audio source to Bluetooth music or vice versa, the user can experience instant response, reducing the operation waiting time. In addition, this method also introduces a failure retry strategy. Even in the case of unstable Bluetooth connection, it can ensure the completion of the operation through automatic retry, avoiding long-term audio waiting, and enhancing the stability and reliability of the system.

[0122] Embodiment 2

[0123] The embodiments of the present application further provide a Bluetooth playback control device 30. Please refer to Figure 3 , which includes: a connection module 310, configured to establish a Bluetooth connection with a terminal device in response to a Bluetooth pairing request of the terminal device, where the Bluetooth connection is a physical link connection based on the Bluetooth protocol; a construction module 320, configured to construct a telephone path and a media path in response to a successful establishment of the Bluetooth connection; an acquisition module 330, configured to acquire a playback switching instruction, where the playback switching instruction is used to indicate the switching of the playback audio source and the playback application; a control module 340, configured to control the connection or disconnection of the media path to control Bluetooth playback according to the playback switching instruction on the condition that the telephone path remains connected, where when the media path is disconnected, the terminal device outputs media audio through an output module of the terminal device.

[0124] The above Bluetooth playback control device provided by the embodiments of the present application achieves the following technical effects: By quickly responding to Bluetooth pairing requests, the connection module can rapidly establish a Bluetooth connection, providing instant Bluetooth communication capabilities; the construction module is used to construct a telephone path and a media path, ensuring that under the condition of successful Bluetooth connection, the in-vehicle system can perform two-way transmission of telephone and audio data with the user's terminal device, providing comprehensive Bluetooth communication functions for the user; the acquisition module captures changes in the user's playback requirements. By intelligently obtaining a playback switching instruction, the in-vehicle system can better conform to the user's usage habits and provide personalized services; the control module, based on the obtained playback switching instruction and while keeping the telephone path always connected, the in-vehicle system plays a specified type of sound source according to the playback switching instruction. Based on the playback type of the switched sound source, it controls the connection or disconnection of the Bluetooth media path to achieve the technical effect that while ensuring the smoothness of the radio circuit call, when the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instruction, by controlling the disconnection of the Bluetooth media path, it ensures that the media audio of the terminal device can be normally output based on its own output module. Thus, the technical effect of realizing the normal use of the wireless call function based on Bluetooth connection between the mobile phone and the in-vehicle system, and when the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instruction, intelligently disconnecting the media path so that the mobile phone media audio can be normally played through the mobile phone is achieved, solving the problem that the mobile phone media audio cannot be normally played in the scenario where the Bluetooth call function between the mobile phone and the in-vehicle system is ensured to be normally used and the in-vehicle system uses a non-Bluetooth sound source for playback.

[0125] It should be noted that the optional implementation manners of this embodiment can refer to the relevant descriptions in Embodiment 1, and will not be elaborated here.

[0126] Embodiment 3

[0127] The embodiments of the present application also provide an electronic device 40. Please refer to Figure 4 , including a memory 410 and a processor 420. Among them, the memory 410 is used to store a computer program; the processor 420 is used to execute the program stored on the memory to implement the Bluetooth playback control method introduced in any embodiment of the present application.

[0128] The above electronic device provided by the embodiments of the present application achieves the following technical effects: Storing the computer program corresponding to the Bluetooth playback control method in any of the above into the memory, and using the processor to execute the computer program stored on the memory, achieving the technical effect that while the wireless call function based on Bluetooth connection between the mobile phone and the in-vehicle system is normally used, and when the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instruction, the media path is intelligently disconnected so that the mobile phone media audio can be normally played through the mobile phone, solving the problem that the mobile phone media audio cannot be normally played in the scenario where the Bluetooth call function between the mobile phone and the in-vehicle system is ensured to be normally used and the in-vehicle system uses a non-Bluetooth sound source for playback.

[0129] Those of ordinary skill in the art can understand that Figure 4 the structure shown is only illustrative, and the electronic device can also be a smart phone (such as an Android phone, an iOS phone, etc.), a tablet computer, a handheld computer, and a terminal device such as a Mobile Internet Device (MID). Figure 4 It does not limit the structure of the above-mentioned electronic device. For example, the electronic device 40 may further include more or fewer components (such as a network interface, a display device, etc.) than those shown Figure 4 in the figure, or have a different configuration from that shown Figure 4 in the figure.

[0130] Embodiment 4

[0131] The embodiment of the present application further provides a computer-readable storage medium, in which a computer program is stored, and when the computer program is executed by a processor, the Bluetooth playback control method introduced in any embodiment of the present application is implemented.

[0132] Optionally, in this embodiment, the above storage medium may include but is not limited to: various media that can store computer programs such as a USB flash drive, a read-only memory (ROM), a random access memory (RAM), a mobile hard disk, a magnetic disk, or an optical disc.

[0133] The above computer-readable storage medium provided by the embodiment of the present application achieves the following technical effects: storing the computer program corresponding to the Bluetooth playback control method in any of the above into the computer-readable storage medium, and using the processor to execute the computer program stored in the computer-readable storage medium, realizing the normal use of the wireless call function based on the Bluetooth connection between the mobile phone and the in-vehicle system, and when the in-vehicle system plays a non-Bluetooth sound source according to the playback switching instruction, intelligently disconnecting the media path, so that the mobile phone media audio can be normally played through the mobile phone, solving the problem that the mobile phone media audio cannot be normally played in the scenario where the Bluetooth call function between the mobile phone and the in-vehicle system is ensured to be normally used and the in-vehicle system uses a non-Bluetooth sound source for playback.

[0134] The serial numbers of the above embodiments of the present application are only for description and do not represent the advantages or disadvantages of the embodiments.

[0135] In the above embodiments of the present application, the descriptions of each embodiment have their own emphases. For the parts not detailed in a certain embodiment, reference may be made to the relevant descriptions of other embodiments.

[0136] In the present application, "a plurality of" means two or more.

[0137] In this application, unless otherwise clearly defined, the terms "install", "connect", and "link" shall be understood in a broad sense. For example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium, and it can be the communication inside two components. For those of ordinary skill in the art, the specific meanings of the above terms in this application can be understood according to specific situations.

[0138] The terms "first", "second", "third", "fourth", etc. (if any) in this application are used to distinguish similar objects and do not necessarily have to be used to describe a specific order or sequence.

[0139] The term "and / or" in this application is merely a description of the association relationship of associated objects, indicating that three relationships can exist. For example, A and / or B can represent: A exists alone, A and B exist simultaneously, and B exists alone. In addition, the character " / " in this application generally represents an "or" relationship between the associated objects before and after.

[0140] If there is no special instruction, all steps of this application can be carried out in sequence or randomly. For example, the method includes steps A and B, indicating that the method can include steps A and B carried out in sequence, or steps B and A carried out in sequence. For example, it is mentioned that the method may further include step C, indicating that step C can be added to the method in any order. For example, the method can include steps A, B, and C, or steps A, C, and B, or steps C, A, and B, etc.

[0141] The above are only the preferred embodiments of this application and are not intended to limit this application. Any modifications, equivalent replacements, and improvements made within the spirit and principles of this application shall be included within the protection scope of this application.

Claims

1. A Bluetooth playback control method, characterized in that, including: responding to a Bluetooth pairing request of a terminal device to establish a Bluetooth connection with the terminal device, where the Bluetooth connection is a physical link connection based on the Bluetooth protocol; responding to the successful establishment of the Bluetooth connection to construct a telephone path and a media path; obtaining a playback switching instruction, where the playback switching instruction is used to indicate the switching of a playback sound source and a playback application; under the condition that the telephone path remains connected, controlling the media path to be connected or disconnected according to the playback switching instruction to control Bluetooth playback, where when the media path is disconnected, the terminal device outputs media audio through an output module of the terminal device.

2. The method according to claim 1, characterized in that, Responding to the successful establishment of the Bluetooth connection to construct a telephone path and a media path includes: responding to the successful establishment of the Bluetooth connection to construct a telephone path and obtain memory data, where the memory data is used to represent the last playback record before the Bluetooth connection; determining a playback sound source and a media application according to the memory data; responding to the playback sound source being a Bluetooth sound source, and / or the media application being a target application, to construct the media path.

3. The method according to claim 1, characterized in that, The playback switching instruction includes a sound source switching instruction and a media application switching instruction; controlling the media path to be disconnected according to the playback switching instruction includes: responding to the sound source switching instruction indicating that the switched playback sound source is a non-Bluetooth sound source, and the media application switching instruction indicating that the switched media application is a non-target application, to control the media path to be disconnected.

4. The method according to claim 3, wherein Controlling the media path to be connected according to the playback switching instruction includes: responding to the sound source switching instruction indicating that the switched playback sound source is the Bluetooth sound source, or the media application switching instruction indicating that the switched media application is the target application, to control the media path to be connected.

5. The method according to claim 1, characterized in that, The method further includes: recording a trial time during the process of controlling the media path to attempt to connect or disconnect according to the playback switching instruction; responding to the trial time being less than a preset time threshold, determining that the media path connection or disconnection is successful.

6. The method according to claim 5, characterized in that, including: responding to the trial time being greater than or equal to the preset time threshold, determining that the media path connection or disconnection fails, and executing again the control of the media path to attempt to connect or disconnect and re-recording the trial time.

7. The method according to claim 1, characterized in that, Obtaining a playback switching instruction includes: obtaining user preference data; determining a recommended playback sound source and a recommended media application according to the user preference data by using a pre-trained playback recommendation model; determining the playback switching instruction according to the recommended playback sound source and the recommended media application.

8. A Bluetooth playback control device, characterized in that, including: a connection module, configured to respond to a Bluetooth pairing request of a terminal device to establish a Bluetooth connection with the terminal device, where the Bluetooth connection is a physical link connection based on the Bluetooth protocol; a construction module, configured to respond to the successful establishment of the Bluetooth connection to construct a telephone path and a media path; an obtaining module, configured to obtain a playback switching instruction, where the playback switching instruction is used to indicate the switching of a playback sound source and a playback application; A control module, configured to control connection or disconnection of the media path to control Bluetooth playback according to the playback switching instruction on the condition that the telephone path remains connected, wherein when the media path is disconnected, the terminal device outputs media audio through an output module of the terminal device.

9. An electronic device, characterized in that, It includes a processor and a memory, wherein The memory is used for storing a computer program; The processor is configured to execute the program stored on the memory to implement the method according to any one of claims 1-7.

10. A computer-readable storage medium, characterized in that, A computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the method according to any one of claims 1-7 is implemented.