WO2022151833A1 - Data transmission method and apparatus, and electronic device and storage medium - Google Patents

Data transmission method and apparatus, and electronic device and storage medium Download PDF

Info

Publication number
WO2022151833A1
WO2022151833A1 PCT/CN2021/131396 CN2021131396W WO2022151833A1 WO 2022151833 A1 WO2022151833 A1 WO 2022151833A1 CN 2021131396 W CN2021131396 W CN 2021131396W WO 2022151833 A1 WO2022151833 A1 WO 2022151833A1
Authority
WO
WIPO (PCT)
Prior art keywords
bluetooth
protocol
audio data
data packet
link
Prior art date
Application number
PCT/CN2021/131396
Other languages
French (fr)
Chinese (zh)
Inventor
任凯
Original Assignee
Oppo广东移动通信有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Oppo广东移动通信有限公司 filed Critical Oppo广东移动通信有限公司
Publication of WO2022151833A1 publication Critical patent/WO2022151833A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/08Protocols for interworking; Protocol conversion
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W76/00Connection management
    • H04W76/10Connection setup
    • H04W76/14Direct-mode setup

Definitions

  • the embodiments of the present application relate to the field of communication technologies, and in particular, to a data transmission method, an apparatus, an electronic device, and a storage medium.
  • Embodiments of the present application provide a data transmission method, device, electronic device, and storage medium, which realize the transmission of audio data packets between Bluetooth devices supporting different Bluetooth protocols through a data transmission device supporting multiple Bluetooth protocols, thereby improving the compatibility of audio sharing. sex.
  • the embodiment of the present application provides a data transmission method, and the method includes:
  • the second audio data packet based on the second Bluetooth protocol is transmitted to a second Bluetooth device.
  • An embodiment of the present application provides a data transmission device, and the device includes:
  • a first communication module configured to receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device
  • a data conversion module configured to convert the first audio data packet into a second audio data packet based on the second Bluetooth protocol
  • a second communication module configured to transmit the second audio data packet based on the second Bluetooth protocol to a second Bluetooth device.
  • An embodiment of the present application provides an electronic device, the electronic device includes: a processor, a memory, and a communication bus;
  • the communication bus configured to implement a communication connection between the processor and the memory
  • the processor is configured to execute one or more programs stored in the memory to implement the above data transmission method.
  • An embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the foregoing data transmission method is implemented.
  • FIG. 1 is a schematic flowchart of a data transmission method according to an embodiment of the present application.
  • FIG. 2 is a schematic diagram 1 of an exemplary audio sharing scenario provided by an embodiment of the present application.
  • FIG. 3 is a second schematic diagram of an exemplary audio sharing scenario provided by an embodiment of the present application.
  • FIG. 4 is a schematic structural diagram of a data transmission apparatus provided by an embodiment of the present application.
  • FIG. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
  • an embodiment of the present application provides a data transmission method, the method comprising:
  • the second audio data packet based on the second Bluetooth protocol is transmitted to a second Bluetooth device.
  • a Bluetooth connection is established with the first Bluetooth device supporting the first Bluetooth protocol.
  • establishing a Bluetooth connection with the first Bluetooth device supporting the first Bluetooth protocol includes:
  • the receiving the first audio data packet based on the first Bluetooth protocol from the first Bluetooth device includes:
  • the first audio data packet transmitted by the first Bluetooth device is received from the first type of transmission link.
  • the first Bluetooth protocol is a low-power Bluetooth communication protocol
  • the first type of transmission link is a low-power Bluetooth periodic broadcast link
  • the first Bluetooth protocol is a classic Bluetooth communication protocol
  • the first type of transmission link is a classic Bluetooth asynchronous link.
  • a Bluetooth connection is established with the second Bluetooth device supporting the second Bluetooth protocol.
  • establishing a Bluetooth connection with the second Bluetooth device supporting the second Bluetooth protocol includes:
  • the described transmission of the second audio data packet based on the second Bluetooth protocol to the second Bluetooth device includes:
  • the second audio data packet is transmitted to the second Bluetooth device on the second type of transmission link.
  • the second Bluetooth protocol is a low-power Bluetooth communication protocol
  • the second type of transmission link is a low-power Bluetooth periodic broadcast link
  • the second Bluetooth protocol is a classic Bluetooth communication protocol
  • the second type of transmission link is a classic Bluetooth ACL link.
  • the first Bluetooth protocol is a low-power Bluetooth communication protocol
  • the second Bluetooth protocol is a classic Bluetooth communication protocol
  • the first Bluetooth protocol is a classic Bluetooth communication protocol
  • the second Bluetooth protocol is a low-power Bluetooth communication protocol.
  • the audio data types included in the first audio data packet and the second audio data packet are: monophonic audio data and/or dual-channel audio data.
  • an embodiment of the present application provides a data transmission device, and the device includes:
  • a first communication module configured to receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device
  • a data conversion module configured to convert the first audio data packet into a second audio data packet based on the second Bluetooth protocol
  • a second communication module configured to transmit the second audio data packet based on the second Bluetooth protocol to a second Bluetooth device.
  • the first communication module is further configured to establish a Bluetooth connection with the first Bluetooth device supporting the first Bluetooth protocol.
  • the first communication module is specifically configured to establish a first type of transmission link for implementing data packet transmission with the first Bluetooth device through a first Bluetooth protocol; Type transmission link, receiving the first audio data packet transmitted by the first Bluetooth device.
  • the first Bluetooth protocol is a low-power Bluetooth communication protocol
  • the first type of transmission link is a low-power Bluetooth periodic broadcast link
  • the first Bluetooth protocol is a classic Bluetooth communication protocol
  • the first type of transmission link is a classic Bluetooth asynchronous link.
  • the second communication module is further configured to establish a Bluetooth connection with the second Bluetooth device supporting the second Bluetooth protocol.
  • the second communication module is specifically configured to establish a second type of transmission link with the second Bluetooth device; on the second type of transmission link, to the first The two Bluetooth devices transmit the second audio data packet.
  • the second Bluetooth protocol is a low-power Bluetooth communication protocol
  • the second type of transmission link is a low-power Bluetooth periodic broadcast link
  • the second Bluetooth protocol is a classic Bluetooth communication protocol
  • the second type of transmission link is a classic Bluetooth ACL link.
  • the first Bluetooth protocol is a Bluetooth low energy communication protocol
  • the second Bluetooth protocol is a classic Bluetooth communication protocol
  • the first Bluetooth protocol is a classic Bluetooth communication protocol
  • the second Bluetooth protocol is a low-power Bluetooth communication protocol.
  • the audio data types included in the first audio data packet and the second audio data packet are: monophonic audio data and/or dual-channel audio data.
  • an embodiment of the present application provides an electronic device, where the electronic device includes: a processor, a memory, and a communication bus;
  • the communication bus configured to implement a communication connection between the processor and the memory
  • the processor is configured to execute one or more programs stored in the memory to implement the above data transmission method.
  • an embodiment of the present application provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, implements the above data transmission method.
  • a data transmission method provided by an embodiment of the present application is implemented by a data transmission device.
  • the data transmission device for implementing the data transmission method may be a mobile phone, a tablet computer, or other devices.
  • the specific data transmission device is not limited in the embodiment of the present application.
  • FIG. 1 is a schematic flowchart of a data transmission method provided by an embodiment of the present application. As shown in FIG. 1, in the embodiment of the present application, the data transmission method mainly includes the following steps:
  • S101 Receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device.
  • the data transmission apparatus may receive the first audio data packet based on the first Bluetooth protocol and transmitted by the first Bluetooth device.
  • both the data transmission device and the first Bluetooth device support the first Bluetooth protocol, therefore, the data transmission device can establish a Bluetooth connection with the first Bluetooth device supporting the first Bluetooth protocol, thereby Further receive the first audio data packet.
  • the first Bluetooth device may specifically be devices such as a mobile phone, a tablet computer, and the like that support the first Bluetooth protocol, which are not limited in the embodiments of the present application.
  • the first Bluetooth protocol is a Bluetooth low energy communication protocol, or a classic Bluetooth communication protocol.
  • the specific first Bluetooth protocol is not limited in this embodiment of the present application.
  • the data transmission device may establish a first type of transmission link with the first Bluetooth device through the first Bluetooth protocol; on the first type of transmission link, receive the first Bluetooth The first audio packet transmitted by the device.
  • the data transmission apparatus may first establish a first type of transmission link for implementing data packet transmission with the first Bluetooth device through the first Bluetooth protocol, so that the first Bluetooth device may The first audio data packet is transmitted to the data transmission device on the first type of transmission link, and accordingly, the data transmission device can receive the first audio data packet on the first type of transmission link.
  • the first Bluetooth protocol is a low-power Bluetooth communication protocol
  • the first type of transmission link is a low-power Bluetooth periodic broadcast link.
  • the Bluetooth protocol is a classic Bluetooth communication protocol
  • the first type of transmission link is a classic Bluetooth asynchronous link (Asynchronous Link, ACL).
  • the first audio data packet is an audio data packet based on the first Bluetooth protocol, that is, the first audio data packet satisfies the data packet structure, length, and word size defined in the first Bluetooth protocol. savings and other conditions.
  • the specific first audio data packet is not limited in this embodiment of the present application.
  • the data transmission device after receiving the first audio data packet based on the first Bluetooth protocol, the data transmission device further converts the first audio data packet into a second audio data packet based on the second Bluetooth protocol.
  • the second Bluetooth protocol is a different Bluetooth protocol from the first Bluetooth protocol.
  • the first Bluetooth protocol is a low-power Bluetooth communication protocol
  • the second Bluetooth protocol is a classic Bluetooth communication protocol
  • the first Bluetooth protocol is a classic Bluetooth communication protocol
  • the second Bluetooth protocol is a low-power Bluetooth communication protocol.
  • the application examples are not limited.
  • the data transmission device not only supports the above-mentioned first Bluetooth protocol, but also supports the second Bluetooth protocol. Therefore, in the case of obtaining the first audio data packet based on the first Bluetooth protocol , in order to transmit the audio data included in the data packet to the device supporting the second Bluetooth protocol, the first audio data packet needs to be converted to obtain the second audio data packet based on the second Bluetooth protocol.
  • the data transmission device converts the first audio data packet into the second audio data packet based on the second Bluetooth protocol, that is, the first audio data packet is demodulated first, and then adjusted into a second audio data packet based on the second Bluetooth protocol.
  • the second audio data packet satisfies conditions such as the data packet structure, length, and byte amount defined in the second Bluetooth protocol.
  • the specific second audio data packet is not limited in this embodiment of the present application.
  • the audio data contained in the first audio data packet and the second audio data packet are different audio data packets, the audio data contained are the same, and the specific audio data contained is not limited in this application.
  • the audio data types included in the first audio data packet and the second audio data packet are: monophonic audio data and/or dual-channel audio data, and the data type of the audio data contained in the audio data packet can be based on actual application scenarios and The requirements are determined, which is not limited in the embodiments of the present application.
  • the data transmission apparatus may transmit the second audio data packet based on the second Bluetooth protocol to the second Bluetooth device.
  • both the data transmission device and the second Bluetooth device support the second Bluetooth protocol, therefore, the data transmission device can establish a Bluetooth connection with the second Bluetooth device supporting the second Bluetooth protocol, thereby Further transmission of the second audio data packet is performed.
  • the second Bluetooth device may specifically be a device such as a Bluetooth headset or a Bluetooth speaker that supports the second Bluetooth protocol, which is not limited in the embodiment of the present application.
  • the data transmission device may establish a second type of transmission link with the second Bluetooth device through the second Bluetooth protocol; on the second type of transmission link, to the second Bluetooth device The device transmits the second audio data packet.
  • the data transmission device may first establish a second type of transmission link for realizing data packet transmission with the second Bluetooth device through the second Bluetooth protocol, so that the data transmission device can The second audio data packet is transmitted to the second Bluetooth device on the second type of transmission link, and accordingly, the second Bluetooth device can receive the second audio data packet on the second type of transmission link.
  • the second Bluetooth protocol is a low-power Bluetooth communication protocol
  • the second type of transmission link is a low-power Bluetooth periodic broadcast link.
  • the Bluetooth protocol is a classic Bluetooth communication protocol
  • the second type of transmission link is a classic Bluetooth ACL link.
  • the first Bluetooth device supports the first Bluetooth protocol
  • the second Bluetooth device supports the second Bluetooth protocol
  • the two Bluetooth devices respectively support different Bluetooth protocols
  • the two Bluetooth devices cannot directly
  • a Bluetooth connection is realized to transmit audio data packets
  • the data transmission device supports both the first Bluetooth protocol and the second Bluetooth protocol, that is, it can realize Bluetooth communication with the first Bluetooth device that supports the first Bluetooth protocol, and can also communicate with the first Bluetooth device that supports the first Bluetooth protocol.
  • the second bluetooth device of the second bluetooth protocol realizes communication, therefore, the data transmission device can establish a bluetooth connection with the first bluetooth device and the second bluetooth device respectively through the corresponding bluetooth protocol.
  • the transmission of audio data packets between the first Bluetooth device and the second Bluetooth device is realized, and the compatibility of audio sharing is improved.
  • the data transmission device since the data transmission device supports two different Bluetooth protocols, it can also be used as an audio sharing source to share the audio locally stored by itself to the first Bluetooth device and/or the first Bluetooth device and/or the first Bluetooth device. 2. Bluetooth devices.
  • FIG. 2 is a schematic diagram 1 of an exemplary audio sharing scenario provided by an embodiment of the present application.
  • the audio sharing scenario includes Bluetooth device 1, Bluetooth device 2, Bluetooth device 3 and a data transmission device.
  • Bluetooth device 1 is a device supporting the Bluetooth low energy communication protocol
  • the device 3 is a device that supports the classic Bluetooth communication protocol
  • the data transmission device is a device that supports both the low-power Bluetooth communication protocol and the classic Bluetooth communication protocol.
  • the data transmission device can establish a low-power Bluetooth periodic broadcast link with the Bluetooth device 1, so as to receive the audio data packet A transmitted by the Bluetooth device 1 in the low-power Bluetooth periodic broadcast link, and Carry out protocol conversion of audio data packets, convert audio data packet A into audio data packet B, in addition, the data transmission device can also establish a classic Bluetooth asynchronous link with Bluetooth device 2 and Bluetooth device 3 respectively, so that the two The classic Bluetooth asynchronous link transmits the audio data packet B to the corresponding connected Bluetooth device, that is, audio sharing between the Bluetooth device 1 and the Bluetooth device 2 and the Bluetooth device 3 can be realized.
  • the bluetooth device 2 and the bluetooth device 3 can also implement the audio sharing process to the bluetooth device 1 through the data transmission device, which will not be repeated here.
  • the data transmission device can not only be used as a relay device between the Bluetooth device 1 and the Bluetooth device 2 and the Bluetooth device 3, but also can independently realize the transmission of audio data packets with the Bluetooth device 1, the Bluetooth device 2 and the Bluetooth device 3.
  • FIG. 3 is a second schematic diagram of an exemplary audio sharing scenario provided by an embodiment of the present application.
  • an audio sharing scenario includes a Bluetooth device 1, a Bluetooth device 2, and a data transmission device, wherein the Bluetooth device 1 is a device that supports the Bluetooth low energy communication protocol, and the data
  • the transmission device is a device that supports both the low-power bluetooth communication protocol and the classic Bluetooth communication protocol.
  • the data transmission device can establish a low-power bluetooth periodic broadcast link with the bluetooth device 1, so as to be in the low-power bluetooth periodic broadcast chain.
  • the channel receives the audio data packet A transmitted by the Bluetooth device 1, and performs the protocol conversion of the audio data packet, and converts the audio data packet A into the audio data packet B.
  • the Bluetooth device 2 is not limited to a single Bluetooth device, that is, it may include two or more Bluetooth devices.
  • the Bluetooth device 2 is a plurality of Bluetooth devices, one of them can establish a classic Bluetooth asynchronous link with the data transmission device , directly receive the audio data packet B transmitted by the data transmission device through the classic Bluetooth asynchronous link, and other Bluetooth devices can obtain the relevant information of the data transmission device by communicating with the Bluetooth device, so as to monitor the data transmission device to obtain audio. packet B.
  • the above two audio sharing scenarios are only two achievable scenarios provided based on the data transmission method provided by the present application.
  • the provided data transmission method implements other forms of audio sharing solutions, which are not limited in the embodiments of the present application.
  • a data transmission method provided by an embodiment of the present application includes: receiving a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device; converting the first audio data packet into second audio data based on a second Bluetooth protocol packet; transmitting the second audio data packet based on the second Bluetooth protocol to the second Bluetooth device.
  • the data transmission method provided by the embodiment of the present application realizes the transmission of audio data packets between Bluetooth devices supporting different Bluetooth protocols through a data transmission device supporting multiple Bluetooth protocols, thereby improving the compatibility of audio sharing.
  • FIG. 4 is a schematic structural diagram of a data transmission apparatus according to an embodiment of the present application. As shown in FIG. 4, in the embodiment of the present application, the data transmission device includes:
  • a first communication module 401 configured to receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device
  • a data conversion module 402 configured to convert the first audio data packet into a second audio data packet based on the second Bluetooth protocol
  • the second communication module 403 is configured to transmit the second audio data packet based on the second Bluetooth protocol to a second Bluetooth device.
  • the first communication module 401 is further configured to establish a Bluetooth connection with the first Bluetooth device supporting the first Bluetooth protocol.
  • the second communication module 403 is further configured to establish a Bluetooth connection with the second Bluetooth device supporting the second Bluetooth protocol.
  • the first Bluetooth protocol is a Bluetooth low energy communication protocol
  • the second Bluetooth protocol is a classic Bluetooth communication protocol
  • the first Bluetooth protocol is a classic Bluetooth communication protocol
  • the second Bluetooth protocol is a low-power Bluetooth communication protocol.
  • the audio data types included in the first audio data packet and the second audio data packet are: monophonic audio data and/or dual-channel audio data.
  • a data transmission device provided by an embodiment of the present application receives a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device; converts the first audio data packet into a second audio data packet based on a second Bluetooth protocol; The second audio data packet based on the second Bluetooth protocol is transmitted to the second Bluetooth device.
  • the data transmission device provided by the embodiment of the present application supports multiple Bluetooth protocols, thereby enabling transmission of audio data packets between Bluetooth devices supporting different Bluetooth protocols, and improving the compatibility of audio sharing.
  • FIG. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present application. As shown in FIG. 5, in this embodiment of the present application, it includes: a processor 501, a memory 502, and a communication bus 503;
  • the communication bus 503 is configured to realize the communication connection between the processor 501 and the memory 502;
  • the processor 501 is configured to execute one or more programs stored in the memory 502 to implement the above data transmission method.
  • the computer-readable storage medium may be a volatile memory (volatile memory), such as a random access memory (Random-Access Memory, RAM); or a non-volatile memory (non-volatile memory), such as a read-only memory (Read-only memory) Only Memory, ROM), flash memory (flash memory), hard disk (Hard Disk Drive, HDD) or solid-state drive (Solid-State Drive, SSD); it can also be a respective device including one or any combination of the above memories, such as Mobile phones, computers, tablet devices, personal digital assistants, etc.
  • volatile memory volatile memory
  • RAM random access memory
  • non-volatile memory non-volatile memory
  • Read-only memory Read-only memory
  • flash memory flash memory
  • HDD Hard Disk Drive
  • SSD solid-state drive
  • the embodiments of the present application may be provided as a method, a system, or a computer program product. Accordingly, the application may take the form of a hardware embodiment, a software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media having computer-usable program code embodied therein, including but not limited to disk storage, optical storage, and the like.
  • These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory result in an article of manufacture comprising instruction means, the instructions
  • An apparatus implements the functions specified in a flow or flows of the implementation flow diagram and/or a block or blocks of the block diagram.
  • These computer program instructions can also be loaded on a computer or other programmable data processing device to cause a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process such that The instructions provide steps for implementing the functions specified in the flow or blocks of the implementing flow diagram and/or the block or blocks of the block diagram.
  • Embodiments of the present application provide a data transmission method, apparatus, electronic device, and storage medium.
  • the method includes: receiving a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device; converting the first audio data packet into a The second audio data packet based on the second Bluetooth protocol; the second audio data packet based on the second Bluetooth protocol is transmitted to the second Bluetooth device.
  • the technical solutions provided by the embodiments of the present application support multiple Bluetooth protocols, thereby enabling the transmission of audio data packets between Bluetooth devices supporting different Bluetooth protocols, and improving the compatibility of audio sharing.

Abstract

Disclosed are a data transmission method and apparatus, and an electronic device and a storage medium. The method comprises: receiving, from a first Bluetooth device, a first audio data packet that is based on a first Bluetooth protocol; converting the first audio data packet into a second audio data packet that is based on a second Bluetooth protocol; and transmitting, to a second Bluetooth device, the second audio data packet that is based on the second Bluetooth protocol.

Description

一种数据传输方法、装置、电子设备及存储介质A data transmission method, device, electronic device and storage medium
相关申请的交叉引用CROSS-REFERENCE TO RELATED APPLICATIONS
本申请基于申请号202110055803.7、申请日为2021年01月15日,申请名称为“一种数据传输方法、装置、电子设备及存储介质”的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此以引入方式结合在本申请中。This application is based on the Chinese patent application with the application number 202110055803.7, the application date is January 15, 2021, and the application name is "A data transmission method, device, electronic device and storage medium", and claims the priority of the Chinese patent application , the entire content of this Chinese patent application is hereby incorporated by reference into this application.
技术领域technical field
本申请实施例涉及通信技术领域,尤其涉及一种数据传输方法、装置、电子设备及存储介质。The embodiments of the present application relate to the field of communication technologies, and in particular, to a data transmission method, an apparatus, an electronic device, and a storage medium.
背景技术Background technique
随着低功耗蓝牙技术的不断发展,音频分享将会通过低功耗蓝牙技术的周期性广播实现,即音频数据的发送端通过广播方式进行音频数据传输,对于音频数据的接收端的数量没有限制。With the continuous development of low-power bluetooth technology, audio sharing will be realized through periodic broadcast of low-power bluetooth technology, that is, the sender of audio data transmits audio data through broadcasting, and there is no limit to the number of receivers of audio data. .
然而,对于目前大多数的蓝牙耳机等电子设备,其仅支持通过经典蓝牙技术进行音频数据的传输,难以与支持低功耗蓝牙音频技术的电子设备实现音频数据的传输,音频分享的兼容性较差。However, for most of the current electronic devices such as Bluetooth headsets, they only support the transmission of audio data through the classic Bluetooth technology, and it is difficult to realize the transmission of audio data with electronic devices that support the Bluetooth low-power audio technology, and the compatibility of audio sharing is relatively low. Difference.
发明内容SUMMARY OF THE INVENTION
本申请实施例提供一种数据传输方法、装置、电子设备及存储介质,通过支持多种蓝牙协议的数据传输装置实现支持不同蓝牙协议的蓝牙设备之间音频数据包的传输,提高音频分享的兼容性。Embodiments of the present application provide a data transmission method, device, electronic device, and storage medium, which realize the transmission of audio data packets between Bluetooth devices supporting different Bluetooth protocols through a data transmission device supporting multiple Bluetooth protocols, thereby improving the compatibility of audio sharing. sex.
本申请实施例的技术方案是这样实现的:The technical solutions of the embodiments of the present application are implemented as follows:
本申请实施例提供了一种数据传输方法,所述方法包括:The embodiment of the present application provides a data transmission method, and the method includes:
从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包;Receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device;
将所述第一音频数据包转换为基于第二蓝牙协议的第二音频数据包;以及converting the first audio data packet into a second audio data packet based on a second Bluetooth protocol; and
向第二蓝牙设备传输基于所述第二蓝牙协议的所述第二音频数据包。The second audio data packet based on the second Bluetooth protocol is transmitted to a second Bluetooth device.
本申请实施例提供了一种数据传输装置,所述装置包括:An embodiment of the present application provides a data transmission device, and the device includes:
第一通信模块,配置为从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包;a first communication module, configured to receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device;
数据转换模块,配置为将所述第一音频数据包转换为基于第二蓝牙协议的第二音频数据包;a data conversion module, configured to convert the first audio data packet into a second audio data packet based on the second Bluetooth protocol;
第二通信模块,配置为向第二蓝牙设备传输基于所述第二蓝牙协议的所述第二音频数据包。A second communication module configured to transmit the second audio data packet based on the second Bluetooth protocol to a second Bluetooth device.
本申请实施例提供了一种电子设备,所述电子设备包括:处理器、存储器和通信总线;An embodiment of the present application provides an electronic device, the electronic device includes: a processor, a memory, and a communication bus;
所述通信总线,配置为实现所述处理器和所述存储器之间的通信连接;the communication bus configured to implement a communication connection between the processor and the memory;
所述处理器,配置为执行所述存储器存储的一个或多个程序,以实现上述数据传输方法。The processor is configured to execute one or more programs stored in the memory to implement the above data transmission method.
本申请实施例提供了一种计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现上述数据传输方法。An embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the foregoing data transmission method is implemented.
附图说明Description of drawings
图1为本申请实施例提供的一种数据传输方法的流程示意图;1 is a schematic flowchart of a data transmission method according to an embodiment of the present application;
图2为本申请实施例提供的一种示例性的音频分享场景示意图一;FIG. 2 is a schematic diagram 1 of an exemplary audio sharing scenario provided by an embodiment of the present application;
图3为本申请实施例提供的一种示例性的音频分享场景示意图二;FIG. 3 is a second schematic diagram of an exemplary audio sharing scenario provided by an embodiment of the present application;
图4为本申请实施例提供的一种数据传输装置的结构示意图;以及FIG. 4 is a schematic structural diagram of a data transmission apparatus provided by an embodiment of the present application; and
图5为本申请实施例提供的一种电子设备的结构示意图。FIG. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present application.
具体实施方式Detailed ways
第一方面,本申请实施例提供了一种数据传输方法,所述方法包括:In a first aspect, an embodiment of the present application provides a data transmission method, the method comprising:
从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包;Receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device;
将所述第一音频数据包转换为基于第二蓝牙协议的第二音频数据包;以及converting the first audio data packet into a second audio data packet based on a second Bluetooth protocol; and
向第二蓝牙设备传输基于所述第二蓝牙协议的所述第二音频数据包。The second audio data packet based on the second Bluetooth protocol is transmitted to a second Bluetooth device.
在上述方法中,还包括:In the above method, it also includes:
与支持所述第一蓝牙协议的所述第一蓝牙设备建立蓝牙连接。A Bluetooth connection is established with the first Bluetooth device supporting the first Bluetooth protocol.
在上述方法中,所述与支持所述第一蓝牙协议的所述第一蓝牙设备建立蓝牙连接,包括:In the above method, establishing a Bluetooth connection with the first Bluetooth device supporting the first Bluetooth protocol includes:
通过第一蓝牙协议,与所述第一蓝牙设备建立用于实现数据包传输的第一类型传输链路;Establish a first type of transmission link for implementing data packet transmission with the first Bluetooth device through the first Bluetooth protocol;
所述从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包,包括:The receiving the first audio data packet based on the first Bluetooth protocol from the first Bluetooth device includes:
从所述第一类型传输链路,接收所述第一蓝牙设备传输的所述第一音频数据包。The first audio data packet transmitted by the first Bluetooth device is received from the first type of transmission link.
在上述方法中,在所述第一蓝牙协议为低功耗蓝牙通信协议的情况下,所述第一类型传输链路为低功耗蓝牙周期性广播链路;In the above method, in the case that the first Bluetooth protocol is a low-power Bluetooth communication protocol, the first type of transmission link is a low-power Bluetooth periodic broadcast link;
在所述第一蓝牙协议为经典蓝牙通信协议的情况下,所述第一类型传输链路为经典蓝牙异步链路。When the first Bluetooth protocol is a classic Bluetooth communication protocol, the first type of transmission link is a classic Bluetooth asynchronous link.
在上述方法中,还包括:In the above method, it also includes:
与支持所述第二蓝牙协议的所述第二蓝牙设备建立蓝牙连接。A Bluetooth connection is established with the second Bluetooth device supporting the second Bluetooth protocol.
在上述方法中,所述与支持所述第二蓝牙协议的所述第二蓝牙设备建立蓝牙连接,包括:In the above method, establishing a Bluetooth connection with the second Bluetooth device supporting the second Bluetooth protocol includes:
建立与所述第二蓝牙设备之间的第二类型传输链路;establishing a second type of transmission link with the second Bluetooth device;
所述向第二蓝牙设备传输基于所述第二蓝牙协议的所述第二音频数据 包,包括:The described transmission of the second audio data packet based on the second Bluetooth protocol to the second Bluetooth device includes:
在所述第二类型传输链路上,向所述第二蓝牙设备传输所述第二音频数据包。The second audio data packet is transmitted to the second Bluetooth device on the second type of transmission link.
在上述方法中,在所述第二蓝牙协议为低功耗蓝牙通信协议的情况下,所述第二类型传输链路为低功耗蓝牙周期性广播链路;In the above method, in the case that the second Bluetooth protocol is a low-power Bluetooth communication protocol, the second type of transmission link is a low-power Bluetooth periodic broadcast link;
在所述第二蓝牙协议为经典蓝牙通信协议的情况下,所述第二类型传输链路为经典蓝牙ACL链路。When the second Bluetooth protocol is a classic Bluetooth communication protocol, the second type of transmission link is a classic Bluetooth ACL link.
在上述方法中,所述第一蓝牙协议为低功耗蓝牙通信协议,所述第二蓝牙协议为经典蓝牙通信协议;或In the above method, the first Bluetooth protocol is a low-power Bluetooth communication protocol, and the second Bluetooth protocol is a classic Bluetooth communication protocol; or
所述第一蓝牙协议为经典蓝牙通信协议,所述第二蓝牙协议为低功耗蓝牙通信协议。The first Bluetooth protocol is a classic Bluetooth communication protocol, and the second Bluetooth protocol is a low-power Bluetooth communication protocol.
在上述方法中,所述第一音频数据包和所述第二音频数据包包括的音频数据类型为:单声道音频数据和/或双声道音频数据。In the above method, the audio data types included in the first audio data packet and the second audio data packet are: monophonic audio data and/or dual-channel audio data.
第二方面,本申请实施例提供了一种数据传输装置,所述装置包括:In a second aspect, an embodiment of the present application provides a data transmission device, and the device includes:
第一通信模块,配置为从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包;a first communication module, configured to receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device;
数据转换模块,配置为将所述第一音频数据包转换为基于第二蓝牙协议的第二音频数据包;a data conversion module, configured to convert the first audio data packet into a second audio data packet based on the second Bluetooth protocol;
第二通信模块,配置为向第二蓝牙设备传输基于所述第二蓝牙协议的所述第二音频数据包。A second communication module configured to transmit the second audio data packet based on the second Bluetooth protocol to a second Bluetooth device.
在上述数据传输装置中,所述第一通信模块,还配置为与支持所述第一蓝牙协议的所述第一蓝牙设备建立蓝牙连接。In the above data transmission apparatus, the first communication module is further configured to establish a Bluetooth connection with the first Bluetooth device supporting the first Bluetooth protocol.
在上述数据传输装置中,所述第一通信模块,具体配置为通过第一蓝牙协议,与所述第一蓝牙设备建立用于实现数据包传输的第一类型传输链路;从所述第一类型传输链路,接收所述第一蓝牙设备传输的所述第一音频数据包。In the above data transmission device, the first communication module is specifically configured to establish a first type of transmission link for implementing data packet transmission with the first Bluetooth device through a first Bluetooth protocol; Type transmission link, receiving the first audio data packet transmitted by the first Bluetooth device.
在上述数据传输装置中,在所述第一蓝牙协议为低功耗蓝牙通信协议的情况下,所述第一类型传输链路为低功耗蓝牙周期性广播链路;In the above data transmission device, in the case that the first Bluetooth protocol is a low-power Bluetooth communication protocol, the first type of transmission link is a low-power Bluetooth periodic broadcast link;
在所述第一蓝牙协议为经典蓝牙通信协议的情况下,所述第一类型传输链路为经典蓝牙异步链路。When the first Bluetooth protocol is a classic Bluetooth communication protocol, the first type of transmission link is a classic Bluetooth asynchronous link.
在上述数据传输装置中,所述第二通信模块,还配置为与支持所述第二蓝牙协议的所述第二蓝牙设备建立蓝牙连接。In the above data transmission apparatus, the second communication module is further configured to establish a Bluetooth connection with the second Bluetooth device supporting the second Bluetooth protocol.
在上述数据传输装置中,所述第二通信模块,具体配置为建立与所述第二蓝牙设备之间的第二类型传输链路;在所述第二类型传输链路上,向所述第二蓝牙设备传输所述第二音频数据包。In the above data transmission device, the second communication module is specifically configured to establish a second type of transmission link with the second Bluetooth device; on the second type of transmission link, to the first The two Bluetooth devices transmit the second audio data packet.
在上述数据传输装置中,在所述第二蓝牙协议为低功耗蓝牙通信协议的情况下,所述第二类型传输链路为低功耗蓝牙周期性广播链路;In the above data transmission device, in the case that the second Bluetooth protocol is a low-power Bluetooth communication protocol, the second type of transmission link is a low-power Bluetooth periodic broadcast link;
在所述第二蓝牙协议为经典蓝牙通信协议的情况下,所述第二类型传输链路为经典蓝牙ACL链路。When the second Bluetooth protocol is a classic Bluetooth communication protocol, the second type of transmission link is a classic Bluetooth ACL link.
在上述数据传输装置中,所述第一蓝牙协议为低功耗蓝牙通信协议,所述第二蓝牙协议为经典蓝牙通信协议;或In the above data transmission device, the first Bluetooth protocol is a Bluetooth low energy communication protocol, and the second Bluetooth protocol is a classic Bluetooth communication protocol; or
所述第一蓝牙协议为经典蓝牙通信协议,所述第二蓝牙协议为低功耗蓝牙通信协议。The first Bluetooth protocol is a classic Bluetooth communication protocol, and the second Bluetooth protocol is a low-power Bluetooth communication protocol.
在上述数据传输装置中,所述第一音频数据包和所述第二音频数据包包括的音频数据类型为:单声道音频数据和/或双声道音频数据。In the above data transmission apparatus, the audio data types included in the first audio data packet and the second audio data packet are: monophonic audio data and/or dual-channel audio data.
第三方面,本申请实施例提供了一种电子设备,所述电子设备包括:处理器、存储器和通信总线;In a third aspect, an embodiment of the present application provides an electronic device, where the electronic device includes: a processor, a memory, and a communication bus;
所述通信总线,配置为实现所述处理器和所述存储器之间的通信连接;the communication bus configured to implement a communication connection between the processor and the memory;
所述处理器,配置为执行所述存储器存储的一个或多个程序,以实现上述数据传输方法。The processor is configured to execute one or more programs stored in the memory to implement the above data transmission method.
第四方面,本申请实施例提供了一种计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现上述数据传输方法。In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, implements the above data transmission method.
为了使本申请的目的、技术方案及优点更加清楚明白,以下结合附图及实施例,对本申请进行进一步详细说明。应当理解,此处描述的具体实施例仅仅用以解释本申请,并不用于限定本申请。In order to make the purpose, technical solutions and advantages of the present application more clearly understood, the present application will be described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application, but not to limit the present application.
本申请实施例提供的一种数据传输方法,通过数据传输装置实现。需要说明的是,在本申请的实施例中,实现数据传输方法的数据传输装置可以是手机、平板电脑等设备。具体的数据传输装置本申请实施例不作限定。A data transmission method provided by an embodiment of the present application is implemented by a data transmission device. It should be noted that, in the embodiments of the present application, the data transmission device for implementing the data transmission method may be a mobile phone, a tablet computer, or other devices. The specific data transmission device is not limited in the embodiment of the present application.
图1为本申请实施例提供的一种数据传输方法的流程示意图。如图1所示,在本申请的实施例中,数据传输方法主要包括以下步骤:FIG. 1 is a schematic flowchart of a data transmission method provided by an embodiment of the present application. As shown in FIG. 1, in the embodiment of the present application, the data transmission method mainly includes the following steps:
S101、从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包。S101. Receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device.
在本申请的实施例中,数据传输装置可以接收第一蓝牙设备传输的基于第一蓝牙协议的第一音频数据包。In the embodiment of the present application, the data transmission apparatus may receive the first audio data packet based on the first Bluetooth protocol and transmitted by the first Bluetooth device.
需要说明的是,在本申请的实施例中,数据传输装置和第一蓝牙设备均支持第一蓝牙协议,因此,数据传输装置可以与支持第一蓝牙协议的第一蓝牙设备建立蓝牙连接,从而进一步进行第一音频数据包的接收。It should be noted that, in the embodiment of the present application, both the data transmission device and the first Bluetooth device support the first Bluetooth protocol, therefore, the data transmission device can establish a Bluetooth connection with the first Bluetooth device supporting the first Bluetooth protocol, thereby Further receive the first audio data packet.
需要说明的是,在本申请的实施例中,第一蓝牙设备具体可以为支持第一蓝牙协议的手机、平板电脑等设备,本申请实施例不作限定。It should be noted that, in the embodiments of the present application, the first Bluetooth device may specifically be devices such as a mobile phone, a tablet computer, and the like that support the first Bluetooth protocol, which are not limited in the embodiments of the present application.
需要说明的是,在本申请的实施例中,第一蓝牙协议为低功耗蓝牙通信协议,或者,经典蓝牙通信协议。具体的第一蓝牙协议本申请实施例不作限定。It should be noted that, in the embodiments of the present application, the first Bluetooth protocol is a Bluetooth low energy communication protocol, or a classic Bluetooth communication protocol. The specific first Bluetooth protocol is not limited in this embodiment of the present application.
具体的,在本申请的实施例中,数据传输装置可以通过第一蓝牙协议,建立与第一蓝牙设备之间的第一类型传输链路;在第一类型传输链路上,接收第一蓝牙设备传输的第一音频数据包。Specifically, in the embodiment of the present application, the data transmission device may establish a first type of transmission link with the first Bluetooth device through the first Bluetooth protocol; on the first type of transmission link, receive the first Bluetooth The first audio packet transmitted by the device.
可以理解的是,在本申请的实施例中,数据传输装置可以通过第一蓝牙协议,先与第一蓝牙设备建立用于实现数据包传输的第一类型传输链路,第一蓝牙设备从而可以在第一类型传输链路上向数据传输装置传输第一音频数据包,相应的,数据传输装置即可在第一类型传输链路上实现第一音 频数据包的接收。It can be understood that, in the embodiment of the present application, the data transmission apparatus may first establish a first type of transmission link for implementing data packet transmission with the first Bluetooth device through the first Bluetooth protocol, so that the first Bluetooth device may The first audio data packet is transmitted to the data transmission device on the first type of transmission link, and accordingly, the data transmission device can receive the first audio data packet on the first type of transmission link.
具体的,在本申请的实施例中,在第一蓝牙协议为低功耗蓝牙通信协议的情况下,相应的,第一类型传输链路为低功耗蓝牙周期性广播链路,在第一蓝牙协议为经典蓝牙通信协议的情况下,相应的,第一类型传输链路为经典蓝牙异步链路(Asynchronous Link,ACL)。Specifically, in the embodiment of the present application, in the case where the first Bluetooth protocol is a low-power Bluetooth communication protocol, correspondingly, the first type of transmission link is a low-power Bluetooth periodic broadcast link. When the Bluetooth protocol is a classic Bluetooth communication protocol, correspondingly, the first type of transmission link is a classic Bluetooth asynchronous link (Asynchronous Link, ACL).
需要说明的是,在本申请的实施例中,第一音频数据包为基于第一蓝牙协议的音频数据包,即第一音频数据包满足第一蓝牙协议中限定的数据包结构、长度、字节量等条件。具体的第一音频数据包本申请实施例不作限定。It should be noted that, in the embodiment of the present application, the first audio data packet is an audio data packet based on the first Bluetooth protocol, that is, the first audio data packet satisfies the data packet structure, length, and word size defined in the first Bluetooth protocol. savings and other conditions. The specific first audio data packet is not limited in this embodiment of the present application.
S102、将第一音频数据包转换为基于第二蓝牙协议的第二音频数据包。S102. Convert the first audio data packet into a second audio data packet based on the second Bluetooth protocol.
在本申请的实施例中,数据传输装置在接收到基于第一蓝牙协议的第一音频数据包之后,进一步的,将第一音频数据包转换为基于第二蓝牙协议的第二音频数据包。In the embodiment of the present application, after receiving the first audio data packet based on the first Bluetooth protocol, the data transmission device further converts the first audio data packet into a second audio data packet based on the second Bluetooth protocol.
需要说明的是,在本申请的实施例中,第二蓝牙协议为与第一蓝牙协议不同的蓝牙协议。具体的,第一蓝牙协议为低功耗蓝牙通信协议,第二蓝牙协议为经典蓝牙通信协议,或者,第一蓝牙协议为经典蓝牙通信协议,第二蓝牙协议为低功耗蓝牙通信协议,本申请实施例不作限定。It should be noted that, in the embodiment of the present application, the second Bluetooth protocol is a different Bluetooth protocol from the first Bluetooth protocol. Specifically, the first Bluetooth protocol is a low-power Bluetooth communication protocol, and the second Bluetooth protocol is a classic Bluetooth communication protocol, or the first Bluetooth protocol is a classic Bluetooth communication protocol, and the second Bluetooth protocol is a low-power Bluetooth communication protocol. The application examples are not limited.
需要说明的是,在本申请的实施例中,数据传输装置不仅支持上述第一蓝牙协议,同样支持第二蓝牙协议,因此,其在获得基于第一蓝牙协议的第一音频数据包的情况下,为了实现后续将该数据包包括的音频数据传输至支持第二蓝牙协议的设备,需要先对第一音频数据包进行转换,得到基于第二蓝牙协议的第二音频数据包。It should be noted that, in the embodiments of the present application, the data transmission device not only supports the above-mentioned first Bluetooth protocol, but also supports the second Bluetooth protocol. Therefore, in the case of obtaining the first audio data packet based on the first Bluetooth protocol , in order to transmit the audio data included in the data packet to the device supporting the second Bluetooth protocol, the first audio data packet needs to be converted to obtain the second audio data packet based on the second Bluetooth protocol.
需要说明的是,在本申请的实施例中,数据传输装置将第一音频数据包转换为基于第二蓝牙协议的第二音频数据包,即将第一音频数据包先解调后,再调整成基于第二蓝牙协议的数据包。第二音频数据包满足第二蓝牙协议中限定的数据包结构、长度、字节量等条件。具体的第二音频数据 包本申请实施例不作限定。It should be noted that, in the embodiment of the present application, the data transmission device converts the first audio data packet into the second audio data packet based on the second Bluetooth protocol, that is, the first audio data packet is demodulated first, and then adjusted into a second audio data packet based on the second Bluetooth protocol. Data packets based on the second Bluetooth protocol. The second audio data packet satisfies conditions such as the data packet structure, length, and byte amount defined in the second Bluetooth protocol. The specific second audio data packet is not limited in this embodiment of the present application.
可以理解的是,在本申请的实施例中,第一音频数据包和第二音频数据包虽然为不同的音频数据包,但是包含的音频数据是相同的,具体包含的音频数据本申请不作限定。此外,第一音频数据包和第二音频数据包包括的音频数据类型为:单声道音频数据和/或双声道音频数据,音频数据包包含的音频数据的数据类型可以根据实际应用场景和需求确定,本申请实施例不作限定。It can be understood that, in the embodiment of the present application, although the first audio data packet and the second audio data packet are different audio data packets, the audio data contained are the same, and the specific audio data contained is not limited in this application. . In addition, the audio data types included in the first audio data packet and the second audio data packet are: monophonic audio data and/or dual-channel audio data, and the data type of the audio data contained in the audio data packet can be based on actual application scenarios and The requirements are determined, which is not limited in the embodiments of the present application.
S103、向第二蓝牙设备传输基于第二蓝牙协议的第二音频数据包。S103. Transmit the second audio data packet based on the second Bluetooth protocol to the second Bluetooth device.
在本申请的实施例中,数据传输装置在得到基于第二蓝牙协议的第二音频数据包之后,可以向第二蓝牙设备传输基于第二蓝牙协议的第二音频数据包。In the embodiment of the present application, after obtaining the second audio data packet based on the second Bluetooth protocol, the data transmission apparatus may transmit the second audio data packet based on the second Bluetooth protocol to the second Bluetooth device.
需要说明的是,在本申请的实施例中,数据传输装置和第二蓝牙设备均支持第二蓝牙协议,因此,数据传输装置可以与支持第二蓝牙协议的第二蓝牙设备建立蓝牙连接,从而进一步进行第二音频数据包的传输。It should be noted that, in the embodiment of the present application, both the data transmission device and the second Bluetooth device support the second Bluetooth protocol, therefore, the data transmission device can establish a Bluetooth connection with the second Bluetooth device supporting the second Bluetooth protocol, thereby Further transmission of the second audio data packet is performed.
需要说明的是,在本申请的实施例中,第二蓝牙设备具体可以为支持第二蓝牙协议的蓝牙耳机、蓝牙音箱等设备,本申请实施例不作限定。It should be noted that, in the embodiment of the present application, the second Bluetooth device may specifically be a device such as a Bluetooth headset or a Bluetooth speaker that supports the second Bluetooth protocol, which is not limited in the embodiment of the present application.
具体的,在本申请的实施例中,数据传输装置可以通过第二蓝牙协议,建立与第二蓝牙设备之间的第二类型传输链路;在第二类型传输链路上,向第二蓝牙设备传输第二音频数据包。Specifically, in the embodiment of the present application, the data transmission device may establish a second type of transmission link with the second Bluetooth device through the second Bluetooth protocol; on the second type of transmission link, to the second Bluetooth device The device transmits the second audio data packet.
可以理解的是,在本申请的实施例中,数据传输装置可以通过第二蓝牙协议,先与第二蓝牙设备建立用于实现数据包传输的第二类型传输链路,数据传输装置从而可以在第二类型传输链路上向第二蓝牙设备传输第二音频数据包,相应的,第二蓝牙设备即可在第二类型传输链路上实现第二音频数据包的接收。It can be understood that, in the embodiment of the present application, the data transmission device may first establish a second type of transmission link for realizing data packet transmission with the second Bluetooth device through the second Bluetooth protocol, so that the data transmission device can The second audio data packet is transmitted to the second Bluetooth device on the second type of transmission link, and accordingly, the second Bluetooth device can receive the second audio data packet on the second type of transmission link.
具体的,在本申请的实施例中,在第二蓝牙协议为低功耗蓝牙通信协议的情况下,相应的,第二类型传输链路为低功耗蓝牙周期性广播链路, 在第二蓝牙协议为经典蓝牙通信协议的情况下,相应的,第二类型传输链路为经典蓝牙ACL链路。Specifically, in the embodiment of the present application, in the case where the second Bluetooth protocol is a low-power Bluetooth communication protocol, correspondingly, the second type of transmission link is a low-power Bluetooth periodic broadcast link. When the Bluetooth protocol is a classic Bluetooth communication protocol, correspondingly, the second type of transmission link is a classic Bluetooth ACL link.
可以理解的是,在本申请的实施例中,第一蓝牙设备支持第一蓝牙协议,第二蓝牙设备支持第二蓝牙协议,两个蓝牙设备分别支持不同的蓝牙协议,两个蓝牙设备不能直接实现蓝牙连接,从而进行音频数据包的传输,而数据传输装置同时支持第一蓝牙协议与第二蓝牙协议,即既可以与支持第一蓝牙协议的第一蓝牙设备实现蓝牙通信,也可以与支持第二蓝牙协议的第二蓝牙设备实现通信,因此,数据传输装置可以与第一蓝牙设备和第二蓝牙设备分别通过对应的蓝牙协议建立蓝牙连接,作为音频数据包交换的设备,通过桥接的方式实现第一蓝牙设备与第二蓝牙设备之间音频数据包的传输,提高音频分享的兼容性。It can be understood that, in the embodiment of the present application, the first Bluetooth device supports the first Bluetooth protocol, the second Bluetooth device supports the second Bluetooth protocol, the two Bluetooth devices respectively support different Bluetooth protocols, and the two Bluetooth devices cannot directly A Bluetooth connection is realized to transmit audio data packets, and the data transmission device supports both the first Bluetooth protocol and the second Bluetooth protocol, that is, it can realize Bluetooth communication with the first Bluetooth device that supports the first Bluetooth protocol, and can also communicate with the first Bluetooth device that supports the first Bluetooth protocol. The second bluetooth device of the second bluetooth protocol realizes communication, therefore, the data transmission device can establish a bluetooth connection with the first bluetooth device and the second bluetooth device respectively through the corresponding bluetooth protocol. The transmission of audio data packets between the first Bluetooth device and the second Bluetooth device is realized, and the compatibility of audio sharing is improved.
需要说明的是,在本申请的实施例中,由于数据传输装置支持两种不同的蓝牙协议,其也可以作为音频分享源,将自身本地存储的音频,分享至第一蓝牙设备和/或第二蓝牙设备。It should be noted that, in the embodiments of the present application, since the data transmission device supports two different Bluetooth protocols, it can also be used as an audio sharing source to share the audio locally stored by itself to the first Bluetooth device and/or the first Bluetooth device and/or the first Bluetooth device. 2. Bluetooth devices.
图2为本申请实施例提供的一种示例性的音频分享场景示意图一。如图2所示,在音频分享场景中,包括蓝牙设备1、蓝牙设备2、蓝牙设备3和数据传输装置,其中,蓝牙设备1为支持低功耗蓝牙通信协议的设备,蓝牙设备2和蓝牙设备3为支持经典蓝牙通信协议的设备,数据传输装置为同时支持低功耗蓝牙通信协议和经典蓝牙通信协议的设备。如图2所示,数据传输装置可以与蓝牙设备1之间建立低功耗蓝牙周期性广播链路,从而在低功耗蓝牙周期性广播链路接收蓝牙设备1传输的音频数据包A,并进行音频数据包的协议转换,将音频数据包A转换为音频数据包B,此外,数据传输装置还可以与蓝牙设备2和蓝牙设备3之间分别建立经典蓝牙异步链路,从而分别在两个经典蓝牙异步链路向对应连接的蓝牙设备传输音频数据包B,即可以实现蓝牙设备1与蓝牙设备2和蓝牙设备3之间的音频分享。需要说明的是,蓝牙设备2和蓝牙设备3也可以通过数据传输装 置实现向蓝牙设备1的音频分享过程,在此不再赘述。此外,数据传输装置不仅可以作为蓝牙设备1与蓝牙设备2和蓝牙设备3之间的中转设备,其也可以独立与蓝牙设备1、蓝牙设备2和蓝牙设备3实现音频数据包的传输。FIG. 2 is a schematic diagram 1 of an exemplary audio sharing scenario provided by an embodiment of the present application. As shown in Figure 2, in the audio sharing scenario, it includes Bluetooth device 1, Bluetooth device 2, Bluetooth device 3 and a data transmission device. Among them, Bluetooth device 1 is a device supporting the Bluetooth low energy communication protocol, and Bluetooth device 2 and Bluetooth The device 3 is a device that supports the classic Bluetooth communication protocol, and the data transmission device is a device that supports both the low-power Bluetooth communication protocol and the classic Bluetooth communication protocol. As shown in Figure 2, the data transmission device can establish a low-power Bluetooth periodic broadcast link with the Bluetooth device 1, so as to receive the audio data packet A transmitted by the Bluetooth device 1 in the low-power Bluetooth periodic broadcast link, and Carry out protocol conversion of audio data packets, convert audio data packet A into audio data packet B, in addition, the data transmission device can also establish a classic Bluetooth asynchronous link with Bluetooth device 2 and Bluetooth device 3 respectively, so that the two The classic Bluetooth asynchronous link transmits the audio data packet B to the corresponding connected Bluetooth device, that is, audio sharing between the Bluetooth device 1 and the Bluetooth device 2 and the Bluetooth device 3 can be realized. It should be noted that the bluetooth device 2 and the bluetooth device 3 can also implement the audio sharing process to the bluetooth device 1 through the data transmission device, which will not be repeated here. In addition, the data transmission device can not only be used as a relay device between the Bluetooth device 1 and the Bluetooth device 2 and the Bluetooth device 3, but also can independently realize the transmission of audio data packets with the Bluetooth device 1, the Bluetooth device 2 and the Bluetooth device 3.
图3为本申请实施例提供的一种示例性的音频分享场景示意图二。如图3所示,在本申请的实施例中,在音频分享场景中,包括蓝牙设备1、蓝牙设备2和数据传输装置,其中,蓝牙设备1为支持低功耗蓝牙通信协议的设备,数据传输装置为同时支持低功耗蓝牙通信协议和经典蓝牙通信协议的设备,数据传输装置可以与蓝牙设备1之间建立低功耗蓝牙周期性广播链路,从而在低功耗蓝牙周期性广播链路接收蓝牙设备1传输的音频数据包A,并进行音频数据包的协议转换,将音频数据包A转换为音频数据包B。此外,蓝牙设备2不限于单个蓝牙设备,即其可以包括两个或两个以上蓝牙设备,在蓝牙设备2为多个蓝牙设备的情况下,其中一个可以与数据传输装置建立经典蓝牙异步链路,直接通过经典蓝牙异步链路接收到数据传输装置传输的音频数据包B,而其他蓝牙设备可以通过与该蓝牙设备通信,获取数据传输装置的相关信息,从而对数据传输装置进行监听以获得音频数据包B。FIG. 3 is a second schematic diagram of an exemplary audio sharing scenario provided by an embodiment of the present application. As shown in FIG. 3 , in the embodiment of the present application, an audio sharing scenario includes a Bluetooth device 1, a Bluetooth device 2, and a data transmission device, wherein the Bluetooth device 1 is a device that supports the Bluetooth low energy communication protocol, and the data The transmission device is a device that supports both the low-power bluetooth communication protocol and the classic Bluetooth communication protocol. The data transmission device can establish a low-power bluetooth periodic broadcast link with the bluetooth device 1, so as to be in the low-power bluetooth periodic broadcast chain. The channel receives the audio data packet A transmitted by the Bluetooth device 1, and performs the protocol conversion of the audio data packet, and converts the audio data packet A into the audio data packet B. In addition, the Bluetooth device 2 is not limited to a single Bluetooth device, that is, it may include two or more Bluetooth devices. In the case where the Bluetooth device 2 is a plurality of Bluetooth devices, one of them can establish a classic Bluetooth asynchronous link with the data transmission device , directly receive the audio data packet B transmitted by the data transmission device through the classic Bluetooth asynchronous link, and other Bluetooth devices can obtain the relevant information of the data transmission device by communicating with the Bluetooth device, so as to monitor the data transmission device to obtain audio. packet B.
需要说明的是,在本申请的实施例中,上述两种音频分享场景仅为基于本申请提供的数据传输方法提供的两种可实现的场景,当然,还可以根据实际应用需求,结合本申请提供的数据传输方法实现其他形式的音频分享方案,本申请实施例不作限定。It should be noted that, in the embodiments of the present application, the above two audio sharing scenarios are only two achievable scenarios provided based on the data transmission method provided by the present application. The provided data transmission method implements other forms of audio sharing solutions, which are not limited in the embodiments of the present application.
本申请实施例提供的一种数据传输方法,包括:从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包;将第一音频数据包转换为基于第二蓝牙协议的第二音频数据包;向第二蓝牙设备传输基于第二蓝牙协议的第二音频数据包。本申请实施例提供的数据传输方法,通过支持多种蓝牙协议的数据传输装置实现支持不同蓝牙协议的蓝牙设备之间音频数据包的传 输,提高音频分享的兼容性。A data transmission method provided by an embodiment of the present application includes: receiving a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device; converting the first audio data packet into second audio data based on a second Bluetooth protocol packet; transmitting the second audio data packet based on the second Bluetooth protocol to the second Bluetooth device. The data transmission method provided by the embodiment of the present application realizes the transmission of audio data packets between Bluetooth devices supporting different Bluetooth protocols through a data transmission device supporting multiple Bluetooth protocols, thereby improving the compatibility of audio sharing.
本申请实施例提供了一种数据传输装置。图4为本申请实施例提供的一种数据传输装置的结构示意图。如图4所示,在本申请的实施例中,数据传输装置包括:The embodiments of the present application provide a data transmission device. FIG. 4 is a schematic structural diagram of a data transmission apparatus according to an embodiment of the present application. As shown in FIG. 4, in the embodiment of the present application, the data transmission device includes:
第一通信模块401,配置为从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包;A first communication module 401, configured to receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device;
数据转换模块402,配置为将所述第一音频数据包转换为基于所述第二蓝牙协议的第二音频数据包;A data conversion module 402, configured to convert the first audio data packet into a second audio data packet based on the second Bluetooth protocol;
第二通信模块403,配置为向第二蓝牙设备传输基于所述第二蓝牙协议的所述第二音频数据包。The second communication module 403 is configured to transmit the second audio data packet based on the second Bluetooth protocol to a second Bluetooth device.
在本申请一实施例中,所述第一通信模块401,还配置为与支持所述第一蓝牙协议的所述第一蓝牙设备建立蓝牙连接。In an embodiment of the present application, the first communication module 401 is further configured to establish a Bluetooth connection with the first Bluetooth device supporting the first Bluetooth protocol.
在本申请一实施例中,所述第二通信模块403,还配置为与支持所述第二蓝牙协议的所述第二蓝牙设备建立蓝牙连接。In an embodiment of the present application, the second communication module 403 is further configured to establish a Bluetooth connection with the second Bluetooth device supporting the second Bluetooth protocol.
在本申请一实施例中,所述第一蓝牙协议为低功耗蓝牙通信协议,所述第二蓝牙协议为经典蓝牙通信协议;或In an embodiment of the present application, the first Bluetooth protocol is a Bluetooth low energy communication protocol, and the second Bluetooth protocol is a classic Bluetooth communication protocol; or
所述第一蓝牙协议为经典蓝牙通信协议,所述第二蓝牙协议为低功耗蓝牙通信协议。The first Bluetooth protocol is a classic Bluetooth communication protocol, and the second Bluetooth protocol is a low-power Bluetooth communication protocol.
在本申请一实施例中,所述第一音频数据包和所述第二音频数据包包括的音频数据类型为:单声道音频数据和/或双声道音频数据。In an embodiment of the present application, the audio data types included in the first audio data packet and the second audio data packet are: monophonic audio data and/or dual-channel audio data.
本申请实施例提供的一种数据传输装置,从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包;将第一音频数据包转换为基于第二蓝牙协议的第二音频数据包;向第二蓝牙设备传输基于第二蓝牙协议的第二音频数据包。本申请实施例提供的数据传输装置,支持多种蓝牙协议,从而能够实现支持不同蓝牙协议的蓝牙设备之间音频数据包的传输,提高音频分享的兼容性。A data transmission device provided by an embodiment of the present application receives a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device; converts the first audio data packet into a second audio data packet based on a second Bluetooth protocol; The second audio data packet based on the second Bluetooth protocol is transmitted to the second Bluetooth device. The data transmission device provided by the embodiment of the present application supports multiple Bluetooth protocols, thereby enabling transmission of audio data packets between Bluetooth devices supporting different Bluetooth protocols, and improving the compatibility of audio sharing.
本申请实施例还提供了一种电子设备。图5为本申请实施例提供的一种电子设备的结构示意图。如图5所示,在本申请的实施例中,包括:处理器501、存储器502和通信总线503;The embodiments of the present application also provide an electronic device. FIG. 5 is a schematic structural diagram of an electronic device according to an embodiment of the present application. As shown in FIG. 5, in this embodiment of the present application, it includes: a processor 501, a memory 502, and a communication bus 503;
所述通信总线503,配置为实现所述处理器501和所述存储器502之间的通信连接;The communication bus 503 is configured to realize the communication connection between the processor 501 and the memory 502;
所述处理器501,配置为执行所述存储器502存储的一个或多个程序,以实现上述数据传输方法。The processor 501 is configured to execute one or more programs stored in the memory 502 to implement the above data transmission method.
本申请实施例提供了一种计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现上述数据传输方法。计算机可读存储介质可以是易失性存储器(volatile memory),例如随机存取存储器(Random-Access Memory,RAM);或者非易失性存储器(non-volatile memory),例如只读存储器(Read-Only Memory,ROM),快闪存储器(flash memory),硬盘(Hard Disk Drive,HDD)或固态硬盘(Solid-State Drive,SSD);也可以是包括上述存储器之一或任意组合的各自设备,如移动电话、计算机、平板设备、个人数字助理等。An embodiment of the present application provides a computer-readable storage medium, on which a computer program is stored, and when the computer program is executed by a processor, the foregoing data transmission method is implemented. The computer-readable storage medium may be a volatile memory (volatile memory), such as a random access memory (Random-Access Memory, RAM); or a non-volatile memory (non-volatile memory), such as a read-only memory (Read-only memory) Only Memory, ROM), flash memory (flash memory), hard disk (Hard Disk Drive, HDD) or solid-state drive (Solid-State Drive, SSD); it can also be a respective device including one or any combination of the above memories, such as Mobile phones, computers, tablet devices, personal digital assistants, etc.
本领域内的技术人员应明白,本申请的实施例可提供为方法、系统、或计算机程序产品。因此,本申请可采用硬件实施例、软件实施例、或结合软件和硬件方面的实施例的形式。而且,本申请可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器和光学存储器等)上实施的计算机程序产品的形式。As will be appreciated by those skilled in the art, the embodiments of the present application may be provided as a method, a system, or a computer program product. Accordingly, the application may take the form of a hardware embodiment, a software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media having computer-usable program code embodied therein, including but not limited to disk storage, optical storage, and the like.
本申请是参照根据本申请实施例的方法、设备(系统)、和计算机程序产品的实现流程示意图和/或方框图来描述的。应理解可由计算机程序指令实现流程示意图和/或方框图中的每一流程和/或方框、以及实现流程示意图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执 行的指令产生用于实现在实现流程示意图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。The present application is described with reference to schematic flowcharts and/or block diagrams of implementations of methods, apparatuses (systems), and computer program products according to embodiments of the present application. It will be understood that each process and/or block in the schematic flowchart illustrations and/or block diagrams, and combinations of processes and/or blocks in the schematic flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to the processor of a general purpose computer, special purpose computer, embedded processor or other programmable data processing device to produce a machine such that the instructions executed by the processor of the computer or other programmable data processing device produce Means for implementing the functions specified in a process or processes and/or a block or blocks in the block diagrams.
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在实现流程示意图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory result in an article of manufacture comprising instruction means, the instructions An apparatus implements the functions specified in a flow or flows of the implementation flow diagram and/or a block or blocks of the block diagram.
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在实现流程示意图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。These computer program instructions can also be loaded on a computer or other programmable data processing device to cause a series of operational steps to be performed on the computer or other programmable device to produce a computer-implemented process such that The instructions provide steps for implementing the functions specified in the flow or blocks of the implementing flow diagram and/or the block or blocks of the block diagram.
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本实用申请揭露的技术范围内,可轻易想到的变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。The above are only specific embodiments of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed in the present application. , shall be covered within the scope of protection of this application. Therefore, the protection scope of the present application should be subject to the protection scope of the claims.
工业实用性Industrial Applicability
本申请实施例提供了一种数据传输方法、装置、电子设备及存储介质,方法包括:从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包;将第一音频数据包转换为基于第二蓝牙协议的第二音频数据包;向第二蓝牙设备传输基于第二蓝牙协议的第二音频数据包。本申请实施例提供的技术方案,支持多种蓝牙协议,从而能够实现支持不同蓝牙协议的蓝牙设备之间音频数据包的传输,提高音频分享的兼容性。Embodiments of the present application provide a data transmission method, apparatus, electronic device, and storage medium. The method includes: receiving a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device; converting the first audio data packet into a The second audio data packet based on the second Bluetooth protocol; the second audio data packet based on the second Bluetooth protocol is transmitted to the second Bluetooth device. The technical solutions provided by the embodiments of the present application support multiple Bluetooth protocols, thereby enabling the transmission of audio data packets between Bluetooth devices supporting different Bluetooth protocols, and improving the compatibility of audio sharing.

Claims (20)

  1. 一种数据传输方法,所述方法包括:A data transmission method, the method comprising:
    从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包;Receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device;
    将所述第一音频数据包转换为基于第二蓝牙协议的第二音频数据包;以及converting the first audio data packet into a second audio data packet based on a second Bluetooth protocol; and
    向第二蓝牙设备传输基于所述第二蓝牙协议的所述第二音频数据包。The second audio data packet based on the second Bluetooth protocol is transmitted to a second Bluetooth device.
  2. 根据权利要求1所述的方法,其中,所述方法还包括:The method of claim 1, wherein the method further comprises:
    与支持所述第一蓝牙协议的所述第一蓝牙设备建立蓝牙连接。A Bluetooth connection is established with the first Bluetooth device supporting the first Bluetooth protocol.
  3. 根据权利要求2所述的方法,其中,所述与支持所述第一蓝牙协议的所述第一蓝牙设备建立蓝牙连接,包括:The method according to claim 2, wherein the establishing a Bluetooth connection with the first Bluetooth device supporting the first Bluetooth protocol comprises:
    通过第一蓝牙协议,与所述第一蓝牙设备建立用于实现数据包传输的第一类型传输链路;Establish a first type of transmission link for implementing data packet transmission with the first Bluetooth device through the first Bluetooth protocol;
    所述从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包,包括:The receiving the first audio data packet based on the first Bluetooth protocol from the first Bluetooth device includes:
    从所述第一类型传输链路,接收所述第一蓝牙设备传输的所述第一音频数据包。The first audio data packet transmitted by the first Bluetooth device is received from the first type of transmission link.
  4. 根据权利要求3所述的方法,其中,The method of claim 3, wherein,
    在所述第一蓝牙协议为低功耗蓝牙通信协议的情况下,所述第一类型传输链路为低功耗蓝牙周期性广播链路;In the case that the first Bluetooth protocol is a low-power Bluetooth communication protocol, the first type of transmission link is a low-power Bluetooth periodic broadcast link;
    在所述第一蓝牙协议为经典蓝牙通信协议的情况下,所述第一类型传输链路为经典蓝牙异步链路。When the first Bluetooth protocol is a classic Bluetooth communication protocol, the first type of transmission link is a classic Bluetooth asynchronous link.
  5. 根据权利要求1或2所述的方法,其中,所述方法还包括:The method according to claim 1 or 2, wherein the method further comprises:
    与支持所述第二蓝牙协议的所述第二蓝牙设备建立蓝牙连接。A Bluetooth connection is established with the second Bluetooth device supporting the second Bluetooth protocol.
  6. 根据权利要求5所述的方法,其中,所述与支持所述第二蓝牙协议的所述第二蓝牙设备建立蓝牙连接,包括:The method according to claim 5, wherein the establishing a Bluetooth connection with the second Bluetooth device supporting the second Bluetooth protocol comprises:
    建立与所述第二蓝牙设备之间的第二类型传输链路;establishing a second type of transmission link with the second Bluetooth device;
    所述向第二蓝牙设备传输基于所述第二蓝牙协议的所述第二音频数据包,包括:The transmitting the second audio data packet based on the second Bluetooth protocol to the second Bluetooth device includes:
    在所述第二类型传输链路上,向所述第二蓝牙设备传输所述第二音频数据包。The second audio data packet is transmitted to the second Bluetooth device on the second type of transmission link.
  7. 根据权利要求6所述的方法,其中,The method of claim 6, wherein,
    在所述第二蓝牙协议为低功耗蓝牙通信协议的情况下,所述第二类型传输链路为低功耗蓝牙周期性广播链路;In the case that the second Bluetooth protocol is a low-power Bluetooth communication protocol, the second type of transmission link is a low-power Bluetooth periodic broadcast link;
    在所述第二蓝牙协议为经典蓝牙通信协议的情况下,所述第二类型传输链路为经典蓝牙ACL链路。When the second Bluetooth protocol is a classic Bluetooth communication protocol, the second type of transmission link is a classic Bluetooth ACL link.
  8. 根据权利要求1所述的方法,其中,The method of claim 1, wherein,
    所述第一蓝牙协议为低功耗蓝牙通信协议,所述第二蓝牙协议为经典蓝牙通信协议;或The first Bluetooth protocol is a low-power Bluetooth communication protocol, and the second Bluetooth protocol is a classic Bluetooth communication protocol; or
    所述第一蓝牙协议为经典蓝牙通信协议,所述第二蓝牙协议为低功耗蓝牙通信协议。The first Bluetooth protocol is a classic Bluetooth communication protocol, and the second Bluetooth protocol is a low-power Bluetooth communication protocol.
  9. 根据权利要求1所述的方法,其中,所述第一音频数据包和所述第二音频数据包包括的音频数据类型为:单声道音频数据和/或双声道音频数据。The method according to claim 1, wherein the audio data types included in the first audio data packet and the second audio data packet are: monophonic audio data and/or dual-channel audio data.
  10. 一种数据传输装置,所述装置包括:A data transmission device, the device includes:
    第一通信模块,配置为从第一蓝牙设备接收基于第一蓝牙协议的第一音频数据包;a first communication module, configured to receive a first audio data packet based on a first Bluetooth protocol from a first Bluetooth device;
    数据转换模块,配置为将所述第一音频数据包转换为基于第二蓝牙协议的第二音频数据包;a data conversion module, configured to convert the first audio data packet into a second audio data packet based on the second Bluetooth protocol;
    第二通信模块,配置为向第二蓝牙设备传输基于所述第二蓝牙协议的所述第二音频数据包。A second communication module configured to transmit the second audio data packet based on the second Bluetooth protocol to a second Bluetooth device.
  11. 根据权利要求10所述的数据传输装置,其中,The data transmission device according to claim 10, wherein,
    所述第一通信模块,还配置为与支持所述第一蓝牙协议的所述第一蓝 牙设备建立蓝牙连接。The first communication module is further configured to establish a Bluetooth connection with the first Bluetooth device supporting the first Bluetooth protocol.
  12. 根据权利要求11所述的数据传输装置,其中,The data transmission device according to claim 11, wherein,
    所述第一通信模块,具体配置为通过第一蓝牙协议,与所述第一蓝牙设备建立用于实现数据包传输的第一类型传输链路;从所述第一类型传输链路,接收所述第一蓝牙设备传输的所述第一音频数据包。The first communication module is specifically configured to establish a first-type transmission link with the first Bluetooth device for implementing data packet transmission through the first Bluetooth protocol; the first audio data packet transmitted by the first Bluetooth device.
  13. 根据权利要求12所述的数据传输装置,其中,The data transmission device according to claim 12, wherein,
    在所述第一蓝牙协议为低功耗蓝牙通信协议的情况下,所述第一类型传输链路为低功耗蓝牙周期性广播链路;In the case that the first Bluetooth protocol is a low-power Bluetooth communication protocol, the first type of transmission link is a low-power Bluetooth periodic broadcast link;
    在所述第一蓝牙协议为经典蓝牙通信协议的情况下,所述第一类型传输链路为经典蓝牙异步链路。When the first Bluetooth protocol is a classic Bluetooth communication protocol, the first type of transmission link is a classic Bluetooth asynchronous link.
  14. 根据权利要求10或11所述的数据传输装置,其中,The data transmission device according to claim 10 or 11, wherein,
    所述第二通信模块,还配置为与支持所述第二蓝牙协议的所述第二蓝牙设备建立蓝牙连接。The second communication module is further configured to establish a Bluetooth connection with the second Bluetooth device supporting the second Bluetooth protocol.
  15. 根据权利要求14所述的数据传输装置,其中,The data transmission device according to claim 14, wherein,
    所述第二通信模块,具体配置为建立与所述第二蓝牙设备之间的第二类型传输链路;在所述第二类型传输链路上,向所述第二蓝牙设备传输所述第二音频数据包。The second communication module is specifically configured to establish a second type of transmission link with the second Bluetooth device; on the second type of transmission link, transmit the second type of transmission link to the second Bluetooth device. Two audio packets.
  16. 根据权利要求15所述的数据传输装置,其中,The data transmission device according to claim 15, wherein,
    在所述第二蓝牙协议为低功耗蓝牙通信协议的情况下,所述第二类型传输链路为低功耗蓝牙周期性广播链路;In the case that the second Bluetooth protocol is a low-power Bluetooth communication protocol, the second type of transmission link is a low-power Bluetooth periodic broadcast link;
    在所述第二蓝牙协议为经典蓝牙通信协议的情况下,所述第二类型传输链路为经典蓝牙ACL链路。When the second Bluetooth protocol is a classic Bluetooth communication protocol, the second type of transmission link is a classic Bluetooth ACL link.
  17. 根据权利要求10所述的数据传输装置,其中,The data transmission device according to claim 10, wherein,
    所述第一蓝牙协议为低功耗蓝牙通信协议,所述第二蓝牙协议为经典蓝牙通信协议;或The first Bluetooth protocol is a low-power Bluetooth communication protocol, and the second Bluetooth protocol is a classic Bluetooth communication protocol; or
    所述第一蓝牙协议为经典蓝牙通信协议,所述第二蓝牙协议为低功耗 蓝牙通信协议。The first Bluetooth protocol is a classic Bluetooth communication protocol, and the second Bluetooth protocol is a low-power Bluetooth communication protocol.
  18. 根据权利要求10所述的数据传输装置,其中,所述第一音频数据包和所述第二音频数据包包括的音频数据类型为:单声道音频数据和/或双声道音频数据。The data transmission apparatus according to claim 10, wherein the audio data types included in the first audio data packet and the second audio data packet are: monophonic audio data and/or dual-channel audio data.
  19. 一种电子设备,所述电子设备包括:处理器、存储器和通信总线;An electronic device comprising: a processor, a memory and a communication bus;
    所述通信总线,配置为实现所述处理器和所述存储器之间的通信连接;the communication bus configured to implement a communication connection between the processor and the memory;
    所述处理器,配置为执行所述存储器存储的一个或多个程序,以实现权利要求1-9任一项所述的数据传输方法。The processor is configured to execute one or more programs stored in the memory to implement the data transmission method of any one of claims 1-9.
  20. 一种计算机可读存储介质,其上存储有计算机程序,该计算机程序被处理器执行时实现如权利要求1-9任一项所述的数据传输方法。A computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, implements the data transmission method according to any one of claims 1-9.
PCT/CN2021/131396 2021-01-15 2021-11-18 Data transmission method and apparatus, and electronic device and storage medium WO2022151833A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202110055803.7 2021-01-15
CN202110055803.7A CN114845280A (en) 2021-01-15 2021-01-15 Data transmission method and device, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
WO2022151833A1 true WO2022151833A1 (en) 2022-07-21

Family

ID=82447880

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/131396 WO2022151833A1 (en) 2021-01-15 2021-11-18 Data transmission method and apparatus, and electronic device and storage medium

Country Status (2)

Country Link
CN (1) CN114845280A (en)
WO (1) WO2022151833A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115499040A (en) * 2022-09-09 2022-12-20 安克创新科技股份有限公司 Bluetooth adapter and connection method thereof
CN116489629B (en) * 2023-03-31 2024-01-12 珠海市蓝辰科技有限公司 Bluetooth audio data transmission method, device, equipment and medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103916166A (en) * 2014-03-31 2014-07-09 尚奇浩康(北京)科技有限公司 Bluetooth data transmission method and bluetooth device
CN104467925A (en) * 2014-12-31 2015-03-25 重庆金瓯科技发展有限责任公司 Dual-mode Bluetooth communication control method and dual-mode Bluetooth communication switching device
CN109803189A (en) * 2019-01-24 2019-05-24 合肥星空物联信息科技有限公司 A kind of bluetooth headset based on BLE agreement
WO2020132818A1 (en) * 2018-12-24 2020-07-02 华为技术有限公司 Wireless short-distance audio sharing method and electronic device
CN111386717A (en) * 2017-12-01 2020-07-07 伯斯有限公司 Wireless low-latency audio content sharing
CN112272375A (en) * 2020-10-29 2021-01-26 博流智能科技(南京)有限公司 Bluetooth communication system and method and Bluetooth communication conversion device
CN112689222A (en) * 2020-12-14 2021-04-20 无锡中感微电子股份有限公司 Wireless audio conversion device and method

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103916166A (en) * 2014-03-31 2014-07-09 尚奇浩康(北京)科技有限公司 Bluetooth data transmission method and bluetooth device
CN104467925A (en) * 2014-12-31 2015-03-25 重庆金瓯科技发展有限责任公司 Dual-mode Bluetooth communication control method and dual-mode Bluetooth communication switching device
CN111386717A (en) * 2017-12-01 2020-07-07 伯斯有限公司 Wireless low-latency audio content sharing
WO2020132818A1 (en) * 2018-12-24 2020-07-02 华为技术有限公司 Wireless short-distance audio sharing method and electronic device
CN109803189A (en) * 2019-01-24 2019-05-24 合肥星空物联信息科技有限公司 A kind of bluetooth headset based on BLE agreement
CN112272375A (en) * 2020-10-29 2021-01-26 博流智能科技(南京)有限公司 Bluetooth communication system and method and Bluetooth communication conversion device
CN112689222A (en) * 2020-12-14 2021-04-20 无锡中感微电子股份有限公司 Wireless audio conversion device and method

Also Published As

Publication number Publication date
CN114845280A (en) 2022-08-02

Similar Documents

Publication Publication Date Title
US11611863B2 (en) Method and apparatus for low energy discovery
WO2022151833A1 (en) Data transmission method and apparatus, and electronic device and storage medium
EP3198947B1 (en) Method of communication and apparatus
EP3095292B1 (en) Bluetooth low energy secondary data channel with multi-rate streaming
WO2021121308A1 (en) Multipath transmission method and device
JP2017518697A (en) Establish reliable routes without expensive mesh peering
WO2014071564A1 (en) Proxy connection method and apparatus
US11558155B2 (en) Broadcast relay piconet for low energy audio
CN111698794B (en) Wireless audio sharing method
CN107040874A (en) Method, device and the bluetooth equipment of blue-teeth data simultaneously operating
KR20200106741A (en) Electronic device for transmitting response message in bluetooth network environment and method thereof
KR101990489B1 (en) Method and apparatus for transmitting http data using bluetooth in wireless communication system
WO2017185980A1 (en) Data transmission method and apparatus
CN105657040A (en) Inter-device intranet communication method and system
WO2024067687A1 (en) Information transmission method, first communication node, second communication node, and storage medium
JP2016541163A (en) System, method and device for changing relay operation of a wireless device
US7688718B2 (en) Variable-sized packet support for enhanced synchronous connection oriented links over a USB interface
WO2016015332A1 (en) Data transmission method and user equipment
WO2021147659A1 (en) Wireless communication device and wireless communication method
WO2022027680A1 (en) Wireless communication method and device
WO2016197626A1 (en) Control method and device
WO2019183961A1 (en) Communication method and terminal device
US20230024463A1 (en) Method of transmitting ack signal in wireless communication system and electronic device
WO2019047829A1 (en) Data transmission method, terminal, network device and communication system
WO2024016885A1 (en) Bluetooth connection method and apparatus, electronic device, and computer readable storage medium

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21919024

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21919024

Country of ref document: EP

Kind code of ref document: A1