A method, device, mobile terminal and storage medium for controlling bluetooth transmission

By keeping the audio data transmission status open in the Bluetooth protocol stack, the problem of audio data loss during vehicle terminal navigation is solved, complete transmission of audio data and audio and video synchronization are achieved, and the user navigation experience is improved.

CN115175131BActive Publication Date: 2024-08-27GUANGDONG OPPO MOBILE TELECOMMUNICATIONS CORP LTD
View PDF 9 Cites 0 Cited by

Patent Information

Application Number
CN202210761630.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-29
Publication Date
2024-08-27
Estimated Expiration
2042-06-29

AI Technical Summary

Technical Problem

When the existing Bluetooth protocol stack is used for vehicle terminal navigation, there is a problem of missing characters in audio data transmission, resulting in incomplete navigation audio data and affecting the user experience.

Method used

By establishing a Bluetooth connection with the vehicle-mounted terminal and determining that the map application is in navigation mode, the audio data transmission state is controlled to remain on to ensure that multiple segments of audio data are transmitted to the vehicle-mounted terminal in real time to avoid audio data loss.

Benefits of technology

It realizes the complete transmission of audio data from the vehicle terminal, improves the audio playback effect during navigation, and ensures the synchronization of audio and video.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115175131B
    Figure CN115175131B
Patent Text Reader

Abstract

The present application discloses a control method, device, mobile terminal and storage medium for Bluetooth transmission, the method comprising: establishing a Bluetooth connection with a vehicle-mounted terminal; when determining that the map application is in navigation mode, controlling the audio data transmission state to remain in an on state; when the audio data transmission state is in an on state, transmitting multiple audio data segments to the vehicle-mounted terminal based on the Bluetooth connection. Thus, when it is determined that the map application is in navigation mode, it means that the mobile terminal needs to frequently transmit audio data to the vehicle-mounted terminal. By controlling the audio data transmission state to remain in an on state, the mobile terminal can transmit multiple audio data segments to the vehicle-mounted terminal in real time and completely, so that the vehicle-mounted terminal plays the complete audio data, and the audio and video are synchronized, thereby improving the audio playback effect when the user is navigating.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to Bluetooth technology, and in particular to a method, device, mobile terminal and storage medium for controlling Bluetooth transmission. Background Art

[0002] At present, there are more and more application scenarios in which users use vehicle terminals for navigation. When using a vehicle terminal for navigation, the navigation audio data is short audio data with time intervals and a low duty cycle. The existing Bluetooth protocol stack will process each segment of audio data independently. When the mobile terminal has audio data to send to the vehicle terminal, the terminal enters the Audio / Video Distribution Transport Protocol (AVDTP) stream open state and starts transmitting audio data; when the audio data transmission is completed, the terminal will enter the Audio / Video Distribution Transport Protocol stream closed state; until the next segment of audio data is transmitted, it will re-enter the Audio / Video Distribution Transport Protocol stream start state, and audio data can be transmitted, and so on until the navigation ends. However, this transmission method may cause audio data to be lost. For example, "Turn left 150 meters ahead", the actual playback is "Turn left 150 meters ahead". Summary of the invention

[0003] The present application hopes to provide a method, device, equipment and storage medium for controlling Bluetooth transmission.

[0004] The technical solution of this application is implemented as follows:

[0005] In a first aspect, a method for controlling Bluetooth transmission is provided, the method comprising:

[0006] Establish a Bluetooth connection with the vehicle terminal;

[0007] When the map application is in navigation mode, the audio data transmission state is controlled to remain in the on state;

[0008] When the audio data transmission state is in the on state, multiple audio data segments are transmitted to the vehicle-mounted terminal based on the Bluetooth connection.

[0009] In a second aspect, a control device for Bluetooth transmission is provided, the device comprising:

[0010] A communication unit, used to establish a Bluetooth connection with the vehicle terminal;

[0011] A determination unit, used to control the audio data transmission state to remain in an on state when determining that the map application is in a navigation mode;

[0012] A transmission unit is used to transmit multiple audio data to the vehicle-mounted terminal based on the Bluetooth connection when the audio data transmission state is in the on-state.

[0013] According to a third aspect, a mobile terminal is provided, comprising: a processor and a memory configured to store a computer program that can be run on the processor, wherein the processor is configured to execute the steps of the method of the first aspect when running the computer program.

[0014] According to a fourth aspect, a computer-readable storage medium is provided, on which a computer program is stored, wherein the computer program implements the steps of the method according to the first aspect when executed by a processor.

[0015] The embodiments of the present application provide a method, device, mobile terminal and storage medium for controlling Bluetooth transmission. When it is determined that the map application is in navigation mode, it indicates that the mobile terminal needs to frequently transmit audio data to the vehicle terminal. By controlling the audio data transmission state to be maintained in an on state, the mobile terminal can transmit multiple audio data segments to the vehicle terminal in real time and completely, so that the vehicle terminal plays the complete audio data with synchronized audio and video, thereby improving the audio playback effect when the user is navigating. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] Figure 1 A first flow chart of a method for controlling Bluetooth transmission provided in an embodiment of the present application;

[0017] Figure 2 A schematic diagram of a Bluetooth connection provided in an embodiment of the present application;

[0018] Figure 3 A second flow chart of a method for controlling Bluetooth transmission provided in an embodiment of the present application;

[0019] Figure 4 A third flow chart of a method for controlling Bluetooth transmission provided in an embodiment of the present application;

[0020] Figure 5 A schematic diagram of the structure of a control device for Bluetooth transmission provided in an embodiment of the present application;

[0021] Figure 6 A schematic diagram of the composition structure of a mobile terminal provided in an embodiment of the present application. DETAILED DESCRIPTION

[0022] In order to enable a more detailed understanding of the features and technical contents of the embodiments of the present application, the implementation of the embodiments of the present application is described in detail below in conjunction with the accompanying drawings. The attached drawings are for reference only and are not used to limit the embodiments of the present application.

[0023] The present application embodiment provides a method for controlling Bluetooth transmission. Figure 1 This is a first flow chart of a method for controlling Bluetooth transmission provided in an embodiment of the present application, and the method for controlling Bluetooth transmission is applied to a mobile terminal.

[0024] like Figure 1 As shown, the control method of the Bluetooth transmission may specifically include:

[0025] Step 101: Establish a Bluetooth connection with the vehicle terminal.

[0026] In some embodiments, establishing a Bluetooth connection with a vehicle-mounted terminal includes: establishing a Bluetooth physical link (Asynchronous Connection Link, ACL) connection with the vehicle-mounted terminal; and establishing a logical link control and adaptation protocol (Logical Link Control and Adaptation Protocol, L2CAP) connection with the vehicle-mounted terminal; and establishing an audio / video distribution transport protocol (Audio / VideoDistribution Transport Protocol, AVDTP) connection with the vehicle-mounted terminal; and establishing a Bluetooth audio transmission protocol (Advanced Audio Distribution Profile, A2DP) connection with the vehicle-mounted terminal.

[0027] Figure 2 A schematic diagram of a Bluetooth connection provided in an embodiment of the present application is shown in FIG. Figure 2 As shown, the L2CAP layer is located on the upper layer of the ACL layer, the AVDTP layer is located on the upper layer of the L2CAP layer, and the A2DP layer is located on the upper layer of the AVDTP layer. Here, an ACL connection is established between the mobile terminal and the vehicle terminal at the ACL layer; on the basis of establishing the ACL connection, an L2CAP connection is established between the mobile terminal and the vehicle terminal at the L2CAP layer; on the basis of establishing the L2CAP connection, an AVDTP connection is established between the mobile terminal and the vehicle terminal at the AVDTP layer; on the basis of establishing the AVDTP connection, an A2DP connection is established between the mobile terminal and the vehicle terminal at the A2DP layer.

[0028] Here, the A2DP layer is used to encode the audio data sent from the audio module to obtain an audio stream and transmit it to the AVDTP layer; the AVDTP layer is used to encapsulate the audio stream and transmit it to the L2CAP layer; the L2CAP layer is used to encapsulate the audio stream again and transmit it to the ACL layer; the ACL layer is used to transmit the audio stream from the mobile terminal to the vehicle terminal. For example, the encoding method can be pulse code modulation (PCM) and adaptive differential pulse code modulation (ADPC).

[0029] Step 102: When determining that the map application is in navigation mode, controlling the audio data transmission state to remain in an on state.

[0030] It should be noted that in the embodiment of the present application, when it is determined that the map application is in navigation mode, it means that the mobile terminal needs to frequently transmit audio data to the vehicle terminal. By controlling the audio data transmission state to remain in an on state, the mobile terminal can transmit the audio data to the vehicle terminal in real time and completely, so that the vehicle terminal plays the complete audio data, thereby solving the problem of audio data loss.

[0031] In a possible implementation, whether the map application is in the navigation mode is determined by detecting the state of the map application.

[0032] In another possible implementation, when the map application is opened by the user, the number of audio data transmissions within a preset time period is recorded, and whether the map application is in navigation mode is determined based on the number of audio data transmissions.

[0033] In some embodiments, controlling the audio data transmission state to maintain in the on state includes: detecting the audio data transmission state; if the audio data transmission state is the on state, controlling the audio data transmission state to maintain in the on state; if the audio data transmission state is the off state, waiting to switch from the off state to the on state, and then controlling the audio data transmission state to maintain in the on state.

[0034] That is to say, when the audio data transmission status is on, it means that the mobile terminal is transmitting audio data to the vehicle-mounted terminal. After the audio data transmission is completed, the audio data transmission status of the mobile terminal continues to be controlled to remain in the on state. When the audio data transmission status is off, it means that the mobile terminal is not transmitting audio data to the vehicle-mounted terminal at this time. When the mobile terminal has audio data to transmit to the vehicle-mounted terminal, the audio data transmission status is controlled to switch from the off state to the on state. After the audio data transmission is completed, the audio data transmission status of the mobile terminal continues to be controlled to remain in the on state. This ensures that the mobile terminal can transmit the audio data to the vehicle-mounted terminal in real time and completely. When the audio data transmission status is maintained in the on state, the mobile terminal has no audio data transmission during the interval between the two audio data segments, and the vehicle-mounted terminal does not need to play at this time.

[0035] In some embodiments, after the audio data transmission state is maintained in the on state when it is determined that the map application is in the navigation mode, the method further includes: determining that the map application is switched from the navigation mode to the non-navigation mode; determining that there is other audio data that needs to be transmitted; and when it is detected that the audio data transmission operation stops, controlling the audio data transmission state to switch from the on state to the off state.

[0036] That is, when it is determined that the map application switches from navigation mode to non-navigation mode, it means that the user has exited the map application. If other audio data needs to be transmitted, such as playing music, the music application plays the music normally. If the audio data transmission stop operation is detected during the music playing, the music is stopped. For example, the audio stop operation can be controlled by the user through voice commands or by clicking the stop button.

[0037] Step 103: When the audio data transmission state is in the on state, multiple audio data segments are transmitted to the vehicle-mounted terminal based on the Bluetooth connection.

[0038] Combination Figure 2 As shown, the mobile terminal transmits the audio stream to the vehicle terminal based on the ACL connection. The vehicle terminal receives the audio stream and transmits the audio stream from the LAC layer to the L2CAP layer for a decapsulation operation. The decapsulated audio stream is transmitted from the L2CAP layer to the AVDTP layer for a secondary decapsulation operation. The audio stream that has been decapsulated again is transmitted from the AVDTP layer to the A2DP layer for decoding, and the audio data is obtained and played.

[0039] Here, the execution subject of step 101 to step 103 may be a processor of the mobile terminal.

[0040] By adopting the above technical solution, when it is determined that the map application is in navigation mode, it means that the mobile terminal needs to frequently transmit audio data to the vehicle terminal. By controlling the audio data transmission status to remain in the on state, the mobile terminal can transmit multiple audio data to the vehicle terminal in real time and completely, so that the vehicle terminal plays the complete audio data, and the audio and picture are synchronized, thereby improving the audio playback effect when the user is navigating.

[0041] In order to better reflect the purpose of this application, further examples are given based on the above embodiments of this application. Figure 3 This is a second flow chart of a method for controlling Bluetooth transmission provided in an embodiment of the present application, and the method for controlling Bluetooth transmission is applied to a mobile terminal.

[0042] like Figure 3 As shown, the control method of the Bluetooth transmission may specifically include:

[0043] Step 301: Establish a Bluetooth connection with the vehicle-mounted terminal.

[0044] In some embodiments, establishing a Bluetooth connection with a vehicle-mounted terminal includes: establishing a Bluetooth physical link (Asynchronous Connection Link, ACL) connection with the vehicle-mounted terminal; and establishing a logical link control and adaptation protocol (Logical Link Control and Adaptation Protocol, L2CAP) connection with the vehicle-mounted terminal; and establishing an audio / video distribution transport protocol (Audio / VideoDistribution Transport Protocol, AVDTP) connection with the vehicle-mounted terminal; and establishing a Bluetooth audio transmission protocol (Advanced Audio Distribution Profile, A2DP) connection with the vehicle-mounted terminal.

[0045] Combination Figure 2 As shown, the L2CAP layer is located on the upper layer of the ACL layer, the AVDTP layer is located on the upper layer of the L2CAP layer, and the A2DP layer is located on the upper layer of the AVDTP layer. Here, an ACL connection is established between the mobile terminal and the vehicle terminal at the ACL layer; on the basis of establishing the ACL connection, an L2CAP connection is established between the mobile terminal and the vehicle terminal at the L2CAP layer; on the basis of establishing the L2CAP connection, an AVDTP connection is established between the mobile terminal and the vehicle terminal at the AVDTP layer; on the basis of establishing the AVDTP connection, an A2DP connection is established between the mobile terminal and the vehicle terminal at the A2DP layer.

[0046] Here, the A2DP layer is used to encode the audio data sent from the audio module to obtain an audio stream and transmit it to the AVDTP layer; the AVDTP layer is used to encapsulate the audio stream and transmit it to the L2CAP layer; the L2CAP layer is used to encapsulate the audio stream again and transmit it to the ACL layer; the ACL layer is used to transmit the audio stream from the mobile terminal to the vehicle terminal. For example, the encoding method can be PCM encoding or ADPC encoding.

[0047] Step 302: When an application switching operation is detected, the package name of the application being opened is obtained.

[0048] That is, when an application switching operation is detected, it means that the first application is switched to the second application (i.e., the application being opened). The first application and the second application are not the same application. At this time, the package name of the application being opened is obtained to determine which function the application being opened has. For example, if the application being opened is an application with a navigation function, it is determined that the application being opened is a map application.

[0049] Step 303: When it is determined according to the package name that the application being opened is the map application, the number of audio data transmissions within a preset time period is recorded.

[0050] Here, when it is determined that the application being opened is a map application, each time audio data is transmitted to the vehicle terminal, the number of audio data transmissions is set to increase by one, and when the preset time length (such as 2 minutes) is reached, the number of audio data transmissions within the preset time length is obtained.

[0051] Step 304: Determine whether the map application is in navigation mode based on the number of audio data transmissions.

[0052] In some embodiments, determining that the map application is in navigation mode based on the number of audio data transmissions includes: determining that the map application is in navigation mode when the number of audio data transmissions is greater than or equal to a preset number of times. The method also includes: determining that the map application is in non-navigation mode when the number of audio data transmissions is less than the preset number of times.

[0053] That is, the condition for determining that the map application is in the navigation mode is that the number of audio data transmissions is greater than or equal to the preset number of times. Here, the preset number of times may be the minimum number of audio data transmissions used to determine that the map application is in the navigation mode.

[0054] In other words, in this embodiment, when the number of audio data transmissions within the preset time is greater than or equal to the preset number, that is, the audio data transmission frequency is high, the mobile terminal is frequently transmitting audio data to the vehicle-mounted terminal, so it is determined that the map application on the mobile terminal is in the navigation mode. Otherwise, it is determined that the map application on the mobile terminal is in the non-navigation mode.

[0055] Step 305: Control the audio data transmission state to remain in the on state.

[0056] In some embodiments, controlling the audio data transmission state to maintain in the on state includes: detecting the audio data transmission state; if the audio data transmission state is the on state, controlling the audio data transmission state to maintain in the on state; if the audio data transmission state is the off state, waiting to switch from the off state to the on state, and then controlling the audio data transmission state to maintain in the on state.

[0057] That is to say, when the audio data transmission status is on, it means that the mobile terminal is transmitting audio data to the vehicle-mounted terminal. After the audio data transmission is completed, the audio data transmission status of the mobile terminal continues to be controlled to remain on. When the audio data transmission status is off, it means that the mobile terminal is not transmitting audio data to the vehicle-mounted terminal at this time. When the mobile terminal has audio data to transmit to the vehicle-mounted terminal, the audio data transmission status is controlled to switch from off to on. After the audio data transmission is completed, the audio data transmission status of the mobile terminal continues to be controlled to remain on. This ensures that the mobile terminal can transmit the audio data to the vehicle-mounted terminal in real time and completely.

[0058] Step 306: When the audio data transmission state is in the on state, transmit multiple audio data segments to the vehicle-mounted terminal based on the Bluetooth connection.

[0059] based on Figure 2 As shown, the mobile terminal transmits the audio stream to the vehicle terminal based on the ACL connection. The vehicle terminal receives the audio stream and transmits the audio stream from the LAC layer to the L2CAP layer for a decapsulation operation. The decapsulated audio stream is transmitted from the L2CAP layer to the AVDTP layer for a secondary decapsulation operation. The audio stream that has been decapsulated again is transmitted from the AVDTP layer to the A2DP layer for decoding, and the audio data is obtained and played.

[0060] By adopting the above technical solution, the working mode (navigation mode or non-navigation mode) of the map application is determined by the number of audio data transmissions within a preset time length; when it is determined that the map application is in navigation mode, it means that the mobile terminal needs to frequently transmit audio data to the vehicle terminal, and by controlling the audio data transmission status to be maintained in an open state, the mobile terminal can transmit multiple audio data to the vehicle terminal in real time and completely, so that the vehicle terminal plays the complete audio data, and the audio and picture are synchronized, thereby improving the audio playback effect when the user is navigating.

[0061] Based on the above embodiments, the present application illustrates a method for controlling Bluetooth transmission. Figure 4This is a third flow chart of a method for controlling Bluetooth transmission provided in an embodiment of the present application, and the method for controlling Bluetooth transmission is applied to a mobile terminal.

[0062] like Figure 4 As shown, the control method of the Bluetooth transmission may specifically include:

[0063] Step 401: Establish a Bluetooth connection with the vehicle-mounted terminal.

[0064] Step 402: Enter the map application.

[0065] Here, when an application is opened, the package name of the application is obtained, and whether the currently opened application is a map application is determined according to the package name; if so, it is determined that the map application has been entered; if not, it is determined that the map application has not been entered.

[0066] Step 403: The number of audio data transmissions within the preset time length is greater than or equal to the preset number; if so, execute step 404; if not, execute step 407.

[0067] That is, when entering the map application, the number of audio data transmissions within the preset time length is recorded; when the number of audio data transmissions exceeds the preset number, it means that the mobile terminal is frequently sending audio data to the vehicle terminal, and it is determined that the map application on the mobile terminal is in navigation mode; when the number of audio data transmissions does not exceed the preset number, it means that the mobile terminal may never have sent audio data to the vehicle terminal, or may have sent audio data to the vehicle terminal very few times, such as using the map application briefly to enter navigation and then exiting, at this time it is determined that the map application on the mobile terminal is not in navigation mode.

[0068] Step 404: The map application is in navigation mode.

[0069] Step 405: The map application sends the audio data to the Bluetooth module.

[0070] Step 406: Control the audio data transmission state to remain in the on state.

[0071] By controlling the audio data transmission state to remain in the open state, the mobile terminal can transmit the encoded audio data (i.e., audio stream) to the vehicle terminal in real time and completely, so that the vehicle terminal plays the complete audio data, thus solving the problem of audio data loss.

[0072] Step 407: Whether to exit the navigation mode; if so, execute step 408; if not, execute step 405.

[0073] Step 408: The map application is in non-navigation mode.

[0074] Here, as long as the map application does not exit the navigation mode, the audio data transmission state is controlled to remain in the on state until the map application exits the navigation mode and no other audio data is detected to be transmitted, then the audio data transmission state is controlled to switch to the off state; conversely, if other audio data is detected to be transmitted, such as playing music, the music application plays music normally until the audio data transmission stop operation is detected again, then the music is stopped. For example, the audio data transmission stop operation can be controlled by the user through voice commands or by clicking the stop button.

[0075] In order to implement the method of the embodiment of the present application, based on the same inventive concept, the embodiment of the present application also provides a control device for Bluetooth transmission, Figure 5 Schematic diagram of the structure of the control device for Bluetooth transmission in the embodiment of the present application. Figure 5 As shown, the control device 50 for Bluetooth transmission includes:

[0076] The communication unit 501 is used to establish a Bluetooth connection with the vehicle-mounted terminal;

[0077] A determination unit 502, configured to control the audio data transmission state to remain in an on state when determining that the map application is in a navigation mode;

[0078] The control unit 503 is used to transmit the audio data to the vehicle-mounted terminal based on the Bluetooth connection.

[0079] By adopting the above technical solution, when it is determined that the map application is in navigation mode, it means that the mobile terminal needs to frequently transmit audio data to the vehicle terminal. By controlling the audio data transmission status to remain in the on state, the mobile terminal can transmit multiple audio data to the vehicle terminal in real time and completely, so that the vehicle terminal plays the complete audio data, and the audio and picture are synchronized, thereby improving the audio playback effect when the user is navigating.

[0080] In some embodiments, the determining unit 502 is specifically configured to obtain the package name of the application being opened when an application switching operation is detected;

[0081] When it is determined according to the package name that the application being opened is the map application, recording the number of times the audio data is turned on or off within a preset time period;

[0082] It is determined that the map application is in navigation mode based on the number of times the audio data is turned on or off.

[0083] In some embodiments, the determination unit 502 is further configured to determine that the map application is in navigation mode when the number of audio data transmissions is greater than or equal to a preset number of times.

[0084] In some embodiments, the determination unit 502 is further configured to determine that the map application is in a non-navigation mode when the number of audio data transmissions is less than the preset number of times.

[0085] In some embodiments, the determination unit 502 specifically detects the audio data transmission status;

[0086] If the audio data transmission state is the on state, controlling the audio data transmission state to remain in the on state;

[0087] If the audio data transmission state is in the off state, after waiting to be switched from the off state to the on state, the audio data transmission state is controlled to be maintained in the on state.

[0088] In some embodiments, after the audio data transmission state is maintained in the on state, the determining unit 502 is further configured to determine that the map application is switched from the navigation mode to the non-navigation mode;

[0089] Determining that there is other audio data that needs to be transmitted;

[0090] When the audio data transmission stop operation is detected, the audio data transmission state is controlled to switch from the on state to the off state.

[0091] In some embodiments, the communication unit 501 is specifically used to establish a Bluetooth physical link ACL connection with the vehicle-mounted terminal;

[0092] and establishing a logical link control and adaptation protocol L2CAP connection with the vehicle-mounted terminal;

[0093] and establishing an audio / video distribution transmission protocol AVDTP connection with the vehicle-mounted terminal;

[0094] And establish a Bluetooth audio transmission protocol A2DP connection with the vehicle-mounted terminal.

[0095] The present application also provides another mobile terminal. Figure 6 Schematic diagram of the structure of the mobile terminal in the embodiment of the present application. Figure 6 As shown, the mobile terminal 60 includes: a processor 601 and a memory 602 configured to store a computer program that can be run on the processor;

[0096] The processor 601 is configured to execute the method steps in the aforementioned embodiment when running a computer program.

[0097] Of course, in practical applications, Figure 6As shown, the various components in the mobile terminal are coupled together via a bus system 603. It is understood that the bus system 603 is used to realize the connection and communication between these components. In addition to the data bus, the bus system 603 also includes a power bus, a control bus, and a status signal bus. However, for the sake of clarity, Figure 6 Various buses are labeled as bus system 603.

[0098] In practical applications, the processor may be at least one of an application-specific integrated circuit (ASIC), a digital signal processing device (DSPD), a programmable logic device (PLD), a field-programmable gate array (FPGA), a controller, a microcontroller, and a microprocessor. It is understandable that for different devices, the electronic device used to implement the functions of the processor may also be other, and the embodiments of the present application do not specifically limit this.

[0099] The above-mentioned memory can be a volatile memory (volatile memory), such as a random access memory (RAM); or a non-volatile memory (non-volatile memory), such as a read-only memory (ROM), a flash memory, a hard disk (HDD) or a solid-state drive (SSD); or a combination of the above-mentioned types of memory, and provide instructions and data to the processor.

[0100] In an exemplary embodiment, the present application also provides a computer-readable storage medium for storing a computer program.

[0101] Optionally, the computer-readable storage medium can be applied to any one of the methods in the embodiments of the present application, and the computer program enables the computer to execute the corresponding processes implemented by the processor in each method in the embodiments of the present application. For the sake of brevity, they are not repeated here.

[0102] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as: multiple units or components can be combined, or can be integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the components shown or discussed can be through some interfaces, and the indirect coupling or communication connection of the devices or units can be electrical, mechanical or other forms.

[0103] The units described above as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units; some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0104] In addition, all functional units in the embodiments of the present invention may be integrated into one processing module, or each unit may be a separate unit, or two or more units may be integrated into one unit; the above integrated unit may be implemented in the form of hardware or in the form of hardware plus software functional units. A person of ordinary skill in the art may understand that all or part of the steps of implementing the above method embodiments may be completed by hardware related to program instructions, and the above program may be stored in a computer-readable storage medium, which, when executed, executes the steps of the above method embodiments; and the above storage medium includes various media that can store program codes, such as mobile storage devices, read-only memories (ROM), random access memories (RAM), magnetic disks or optical disks.

[0105] The methods disclosed in several method embodiments provided in this application can be arbitrarily combined without conflict to obtain new method embodiments.

[0106] The features disclosed in several product embodiments provided in this application can be arbitrarily combined without conflict to obtain new product embodiments.

[0107] The features disclosed in several method or device embodiments provided in this application can be arbitrarily combined without conflict to obtain new method embodiments or device embodiments.

[0108] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed by the present invention, which should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.

Claims

1. A method for controlling Bluetooth transmission, applied to a mobile terminal, characterized in that: The method comprises: Establish a Bluetooth connection with the vehicle terminal; When the map application is in navigation mode, the audio data transmission state is controlled to remain in the on state; When the audio data transmission state is in the on state, multiple audio data segments are transmitted to the vehicle-mounted terminal based on the Bluetooth connection.

2. The method according to claim 1, characterized in that The determining that the map application is in the navigation mode includes: When an application switching operation is detected, obtain the package name of the application being opened; When it is determined according to the package name that the application being opened is the map application, recording the number of audio data transmissions within a preset time period; It is determined based on the number of audio data transmissions that the map application is in navigation mode.

3. The method according to claim 2, characterized in that The determining that the map application is in navigation mode based on the number of audio data transmissions includes: When the audio data transmission number is greater than or equal to a preset number, it is determined that the map application is in navigation mode.

4. The method according to claim 3, characterized in that The method further comprises: When the audio data transmission number is less than the preset number, it is determined that the map application is in a non-navigation mode.

5. The method according to any one of claims 1 to 4, characterized in that: The controlling audio data transmission state to be maintained in an on state comprises: Detecting the audio data transmission status; If the audio data transmission state is the on state, controlling the audio data transmission state to remain in the on state; If the audio data transmission state is in the off state, after waiting to be switched from the off state to the on state, the audio data transmission state is controlled to be maintained in the on state.

6. The method according to any one of claims 1 to 4, characterized in that: After the step of controlling the audio data transmission state to remain in the on state when determining that the map application is in the navigation mode, the method further includes: Determining that the map application is switched from the navigation mode to the non-navigation mode; Determining that there is other audio data that needs to be transmitted; When the audio data transmission stop operation is detected, the audio data transmission state is controlled to switch from the on state to the off state.

7. The method according to claim 1, characterized in that The establishing of a Bluetooth connection with the vehicle-mounted terminal includes: Establishing a Bluetooth physical link ACL connection with the vehicle-mounted terminal; and establishing a logical link control and adaptation protocol L2CAP connection with the vehicle-mounted terminal; and establishing an audio / video distribution transmission protocol AVDTP connection with the vehicle-mounted terminal; And establish a Bluetooth audio transmission protocol A2DP connection with the vehicle-mounted terminal.

8. A control device for Bluetooth transmission, applied to a mobile terminal, characterized in that: The device comprises: A communication unit, used to establish a Bluetooth connection with the vehicle terminal; A determination unit, used to control the audio data transmission state to remain in an on state when determining that the map application is in a navigation mode; A transmission unit is used to transmit multiple audio data to the vehicle-mounted terminal based on the Bluetooth connection when the audio data transmission state is in the on-state.

9. A mobile terminal, characterized in that: The mobile terminal comprises: a processor and a memory configured to store a computer program that can be run on the processor, Wherein, the processor is configured to execute the steps of the method according to any one of claims 1 to 7 when running the computer program.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Open vSwitch-based method and system for realizing ACL function

    CN104168200A

  • Audio input and output method and system and computer readable storage medium

    CN110010139A

  • Information broadcasting method and device based on Bluetooth connection, terminal and storage medium

    CN110087215A

  • Audio resource control method, vehicle-mounted terminal and system

    CN111328061A

  • Audio data playing method and device, equipment and storage medium

    CN113709691A