WO2012151847A1 - 一种支持多种采样率的蓝牙立体声的实现方法和装置 - Google Patents

一种支持多种采样率的蓝牙立体声的实现方法和装置 Download PDF

Info

Publication number
WO2012151847A1
WO2012151847A1 PCT/CN2011/080936 CN2011080936W WO2012151847A1 WO 2012151847 A1 WO2012151847 A1 WO 2012151847A1 CN 2011080936 W CN2011080936 W CN 2011080936W WO 2012151847 A1 WO2012151847 A1 WO 2012151847A1
Authority
WO
WIPO (PCT)
Prior art keywords
sampling rate
bluetooth
pcm data
protocol
bluetooth stereo
Prior art date
Application number
PCT/CN2011/080936
Other languages
English (en)
French (fr)
Inventor
张忠海
万超
李明
Original Assignee
中兴通讯股份有限公司
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 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2012151847A1 publication Critical patent/WO2012151847A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R5/00Stereophonic arrangements
    • H04R5/033Headphones for stereophonic communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/60Substation equipment, e.g. for use by subscribers including speech amplifiers
    • H04M1/6033Substation equipment, e.g. for use by subscribers including speech amplifiers for providing handsfree use or a loudspeaker mode in telephone sets
    • H04M1/6041Portable telephones adapted for handsfree use
    • H04M1/6058Portable telephones adapted for handsfree use involving the use of a headset accessory device connected to the portable telephone
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M2250/00Details of telephonic subscriber devices
    • H04M2250/02Details of telephonic subscriber devices including a Bluetooth interface
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R2420/00Details of connection covered by H04R, not provided for in its groups
    • H04R2420/07Applications of wireless loudspeakers or wireless microphones

Definitions

  • the present invention relates to a Bluetooth transmission technology, and more particularly to a method and apparatus for implementing Bluetooth stereo sound that supports multiple sampling rates. Background technique
  • Bluetooth technology is increasingly used in the field of consumer electronics, especially Bluetooth stereo music in Bluetooth technology is increasingly becoming the choice of fashion people.
  • the main support for Bluetooth stereo playback is the Bluetooth Audio Transfer Profile (A2DP) protocol.
  • the A2DP protocol can use the chip inside the headset to stack data for high-definition sound.
  • the A2DP protocol only supports two sample rate audio files, namely 44.1KHz and 48KHz.
  • the sampling rate is getting lower and lower, and even audio files with 8KHz sampling rate similar to speech appear. Therefore, how to enable the Bluetooth headset to support audio files with multiple sampling rates is an urgent problem to be solved. Summary of the invention
  • the main object of the present invention is to provide a method and apparatus for implementing Bluetooth stereo sound supporting a plurality of sampling rates, which can solve the problem that an audio file of a plurality of sampling rates cannot realize Bluetooth stereo sound playback.
  • a method for implementing Bluetooth stereo with multiple sampling rates comprising: reading an audio file to be played, decoding the audio file into pulse code modulation (PCM) data; converting the sampling rate of the PCM data into a Bluetooth stereo protocol Sample rate; encode the converted PCM data After that, send it to the Bluetooth stereo headset for playback.
  • PCM pulse code modulation
  • the converting the sampling rate of the PCM data into a sampling rate conforming to the Bluetooth stereo protocol comprises: converting the sampling rate of the PCM data into a sampling rate conforming to the Bluetooth stereo protocol by using interpolation or decimation.
  • the method of interpolation or extraction is performed, including:
  • the sampling rate of the PCM data is lower than the sampling rate conforming to the Bluetooth stereo protocol, the sampling rate is converted by interpolation;
  • the sampling rate of the PCM data is higher than the sampling rate conforming to the Bluetooth stereo protocol, the sampling rate is converted by means of decimation.
  • the converted PCM data is encoded, it is sent to a Bluetooth stereo headset for playing, specifically: converting the converted PCM data according to the sampling frequency and the code stream, and encoding into a sub-band coding (SBC) format, through the serial port.
  • the data is sent to the Bluetooth chip in one time, decoded by the Bluetooth chip and modulated into an analog signal, and sent to the Bluetooth stereo headset for playing through the air interface.
  • SBC sub-band coding
  • the format of the audio file includes various encoding formats of the audio data; the compliance with the Bluetooth stereo sound recording rate includes: 44.1 KHz or 48 KHz.
  • An implementation device for supporting Bluetooth stereo with multiple sampling rates including: a main controller and a Bluetooth chip, wherein
  • the main controller is configured to read an audio file to be played, decode the audio file into PCM data, convert the sampling rate of the PCM data into a sampling rate conforming to the Bluetooth stereo protocol, and encode the converted PCM data to the PCM data.
  • the Bluetooth chip is configured to send the encoded data to a Bluetooth stereo headset for playing.
  • the main controller converts the sampling rate of the PCM data into a sampling rate conforming to the Bluetooth stereo protocol, including: converting the sampling rate of the PCM data into Bluetooth according to the interpolation or extraction method The sampling rate of the stereo protocol.
  • the main controller performs conversion by interpolation or extraction, including:
  • the sampling rate of the PCM data is lower than the sampling rate conforming to the Bluetooth stereo protocol, the sampling rate is converted by interpolation;
  • the sampling rate of the PCM data is higher than the sampling rate conforming to the Bluetooth stereo protocol, the sampling rate is converted by means of decimation.
  • the main controller encodes the converted PCM data and sends it to the Bluetooth chip, specifically: converting the converted PCM data according to the sampling frequency and the code stream, encoding the playing time, encoding into the SBC format, and using the serial port to data once. Send to the Bluetooth chip.
  • the format of the audio file includes various encoding formats of the audio data; the compliance with the Bluetooth stereo sound recording rate includes: 44.1 KHz or 48 KHz.
  • the invention provides a method and a device for implementing Bluetooth stereo with multiple sampling rates, first reading an audio file to be played, decoding the audio file into Pulse Code Modulation (PCM) data, and sampling the PCM data.
  • PCM Pulse Code Modulation
  • the rate is converted to a sampling rate that conforms to the Bluetooth stereo protocol; the converted PCM data is encoded and sent to a Bluetooth stereo headset for playback.
  • the sample rate is adjusted to calculate the amount of PCM data to be transmitted, and then the PCM data is encoded into the SBC format, and the SBC format data is once used. Send it to the Bluetooth chip. In this way, it is not necessary to convert and transmit according to the calculation method of each format.
  • FIG. 1 is a schematic flow chart of an implementation method of Bluetooth stereo supporting multiple sampling rates according to the present invention
  • FIG. 2 is a schematic diagram of sampling points of interpolation conversion according to the present invention
  • FIG. 3 is a schematic structural diagram of an apparatus for implementing Bluetooth stereo with multiple sampling rates according to the present invention. detailed description
  • the basic idea of the present invention is: first reading an audio file to be played, decoding the audio file into PCM data; converting the sampling rate of the PCM data into a sampling rate conforming to the Bluetooth stereo protocol; encoding the converted PCM data, transmitting Play the Bluetooth stereo headset.
  • FIG. 1 is a schematic flowchart of a method for implementing Bluetooth stereo with multiple sampling rates according to the present invention. As shown in FIG. 1 , the method specifically includes the following steps:
  • Step 101 Read an audio file to be played, and decode the audio file into PCM data.
  • the format of the audio file includes various encoding formats of the audio data. The most common ones are: MP3, AMR, AAC, WMR, WAV and other encoding formats.
  • Step 102 Convert the sampling rate of the PCM data to a sampling rate conforming to the Bluetooth stereo protocol.
  • the sampling rate conforming to the Bluetooth stereo protocol includes: 44.1KHZ or 48KHz.
  • the converting the sampling rate of the PCM data into a sampling rate conforming to the Bluetooth stereo protocol comprises: converting the sampling rate of the PCM data into a sampling rate conforming to the Bluetooth stereo protocol by using interpolation or decimation. Wherein, when the sampling rate of the PCM data is lower than the sampling rate conforming to the Bluetooth stereo protocol, the sampling rate is converted by interpolation; when the sampling rate of the PCM data is higher than the sampling rate conforming to the Bluetooth stereo protocol, the extraction method is utilized. Convert the sample rate.
  • Step 103 Encode the converted PCM data and send it to the Bluetooth stereo headset for playback.
  • the Bluetooth stereo headset after converting the converted PCM data, sending the data to the Bluetooth stereo headset for playing, specifically: converting the converted PCM data into a sub-band code according to the sampling frequency and the code stream, and encoding the sub-band code (Sub-Band) Codec, SBC) format, through the serial port, such as UART, the encoded data is sent to the Bluetooth chip in one time, decoded by the Bluetooth chip and modulated into The analog signal is sent to the Bluetooth stereo headset for playback via an air interface.
  • Sub-Band Codec, SBC sub-band code
  • sampling points of original data are sampling point 1, sampling point 2, sampling point 3, and sampling point 4, respectively, in the calculation process of the interpolation.
  • the interpolation algorithm is used to add the average of the first 2 points and the last 2 points, that is, the sampling point 1, the sampling point 2, the sampling point 3, and the sampling point 4 are added by dividing the value of 4 into the sampling size, and the interpolation is performed.
  • the position is located in the middle between sample point 2 and sample point 3, which is sample point 5 in the figure. This algorithm is much smoother than the normal mean interpolation method, and there is no abrupt sound.
  • FIG. 3 is a schematic structural diagram of an apparatus for implementing Bluetooth stereo with multiple sampling rates according to the present invention.
  • the apparatus includes: a main controller 31 and a Bluetooth chip 32, wherein the main controller 31 For reading an audio file to be played, decoding the audio file into PCM data, converting the sampling rate of the PCM data into a sampling rate conforming to the Bluetooth stereo protocol; encoding the converted PCM data and transmitting the converted PCM data to the Bluetooth chip 32;
  • the audio file may be stored in the device, or may be stored in a device in which the device is installed, such as a mobile phone, an MP3 player, a computer, or the like.
  • the format of the audio file includes various encoding formats of the audio data. The most common ones are: MP3, AMR, A AC, WMR, WAV and other encoding formats.
  • the sampling rate conforming to the Bluetooth stereo protocol includes: 44.1KHZ or 48 ⁇ .
  • the main controller 31 converts the sampling rate of the PCM data into a sampling rate conforming to the Bluetooth stereo protocol, including: converting the sampling rate of the PCM data into a sampling rate conforming to the Bluetooth stereo protocol by interpolation or decimation. Wherein, when the sampling rate of the PCM data is lower than the sampling rate conforming to the Bluetooth stereo protocol, the sampling rate is converted by interpolation; when the sampling rate of the PCM data is higher than the sampling rate conforming to the Bluetooth stereo protocol, the extraction method is utilized. Convert the sample rate.
  • the main controller 31 encodes the converted PCM data and sends the converted PCM data to the Bluetooth chip 32.
  • the converted PCM data is calculated into a SBC format according to the sampling frequency and the code stream, and is encoded into an SBC format. , for example: UART, once the encoded data is It is sent to the Bluetooth chip 32.
  • the Bluetooth chip 32 is configured to send the encoded data to a Bluetooth stereo headset for playing.
  • the Bluetooth chip 32 sends the encoded data to the Bluetooth stereo headset for playing, specifically: the Bluetooth chip 32 decodes the encoded data and modulates it into an analog signal, and sends the data to the Bluetooth stereo headset through the air interface. Play it.
  • the main controller 31 can use a baseband control chip, and the Bluetooth chip 32 can implement the above functions by using the BC6 model.
  • the advantages of the present invention are as follows:
  • the first one can support audio files of multiple sampling rates, so that it can be played by Bluetooth stereo:
  • the sampling frequency of music files supported by A2DP is 44.1khz and 48khz. Music for other sampling frequencies is not supported.
  • the present invention converts an audio file whose original sampling rate is not 44.lkhz and 48khz into a sampling rate of 44.1khz or 48khz by interpolation or decimation. If the sampling rate of the music file is lower than 44.1khz or 48khz, the interpolation becomes 44.1khz or 48khz. If the sampling rate of the music file is higher than 44. lkhz or 48khz, the extraction becomes 44.
  • the second code stream control method supporting various audio formats There are many audio formats and encoding methods at present, and the most common ones are MP3, AMR, AAC, WMR, WAV, and the like. Each format is different, how much time is played per frame, and how much data is sent to Bluetooth is different. Therefore, when the code stream is transmitted, it is transmitted according to the decoded PCM data, and the amount of PCM data to be transmitted is calculated according to the interpolation or the sample rate after the extraction, and then the PCM data is encoded into the SBC format, and these SBCs are once put.
  • the format data is sent to the Bluetooth chip. In this way, it is not necessary to convert and send according to the respective calculation modes of each format, which makes it more convenient for the user to listen to the audio file through Bluetooth, and also improves the sound quality of the Bluetooth listening.

Description

一种支持多种采样率的蓝牙立体声的实现方法和装置 技术领域
本发明涉及蓝牙传输技术, 特别是指一种支持多种采样率的蓝牙立体 声的实现方法和装置。 背景技术
目前蓝牙技术在消费性电子领域应用的日益广泛, 尤其是蓝牙技术中 的蓝牙立体声音乐也越来越成为时尚人士的选择。 而其中支持蓝牙立体声 播放的主要是依靠蓝牙音频传输模型 ( Advanced Audio Distribution Profile, A2DP )协议。 A2DP协议能够采用耳机内的芯片来堆栈数据, 达到声音的 高清晰度。
但是, A2DP协议里面只支持两种采样率的音频文件, 即 44.1KHz和 48KHz。然而随着现代压缩编码技术的提高,很多音乐压缩的程度越来越高, 采样率也越来越低, 甚至出现了和语音差不多的 8KHz采样率的音频文件。 因此如何使蓝牙耳机能够支持多种采样率的音频文件是急需解决的问题。 发明内容
有鉴于此, 本发明的主要目的在于提供一种支持多种采样率的蓝牙立 体声的实现方法和装置, 能够解决多种采样率的音频文件无法实现蓝牙立 体声播放的问题。
为达到上述目的, 本发明的技术方案是这样实现的:
一种支持多种采样率的蓝牙立体声的实现方法, 包括: 读取需要播放 的音频文件, 将音频文件解码为脉沖编码调制(PCM )数据; 将 PCM数据 的采样率转换为符合蓝牙立体声协议的采样率; 将转换后的 PCM数据编码 后, 发送给蓝牙立体声耳机进行播放。
所述将 PCM数据的采样率转换为符合蓝牙立体声协议的采样率,包括: 利用插值或抽取的方式,将 PCM数据的采样率转换为符合蓝牙立体声协议 的采样率。
所述插值或抽取的方式进行转换, 包括:
当 PCM数据的采样率低于符合蓝牙立体声协议的采样率时,利用插值 的方式对采样率进行转换;
当 PCM数据的采样率高于符合蓝牙立体声协议的采样率时,利用抽取 的方式对采样率进行转换。
所述将转换后的 PCM数据编码后, 发送给蓝牙立体声耳机进行播放, 具体为: 将转换后的 PCM数据根据采样频率和码流计算播放时间后, 编码 成子带编码(SBC )格式, 通过串口将数据一次性的发送给蓝牙芯片, 由蓝 牙芯片进行解码后调制成模拟信号, 通过空口发送给蓝牙立体声耳机进行 播放。
所述音频文件的格式包括音频数据的各种编码格式; 所述符合蓝牙立 体声十办议 ό 采样率包括: 44.1 KHz或 48KHz。
一种支持多种采样率的蓝牙立体声的实现装置, 包括: 主控制器和蓝 牙芯片, 其中,
所述主控制器,用于读取需要播放的音频文件,将音频文件解码为 PCM 数据, 将 PCM数据的采样率转换为符合蓝牙立体声协议的采样率; 将转换 后的 PCM数据编码后发送给蓝牙芯片;
所述蓝牙芯片, 用于将所述编码后的数据发送给蓝牙立体声耳机进行 播放。
所述主控制器将 PCM数据的采样率转换为符合蓝牙立体声协议的采样 率, 包括: 利用插值或抽取的方式, 将 PCM数据的采样率转换为符合蓝牙 立体声协议的采样率。
所述主控制器采用插值或抽取的方式进行转换, 包括:
当 PCM数据的采样率低于符合蓝牙立体声协议的采样率时, 利用插值 的方式对采样率进行转换;
当 PCM数据的采样率高于符合蓝牙立体声协议的采样率时,利用抽取 的方式对采样率进行转换。
所述主控制器将转换后的 PCM数据编码后发送给蓝牙芯片 , 具体为: 将转换后的 PCM数据根据采样频率和码流计算播放时间后, 编码成 SBC 格式, 通过串口将数据一次性的发送给蓝牙芯片。
所述音频文件的格式包括音频数据的各种编码格式; 所述符合蓝牙立 体声十办议 ό 采样率包括: 44.1 KHz或 48KHz。
本发明所提供的支持多种采样率的蓝牙立体声的实现方法和装置 , 首 先读取需要播放的音频文件, 将音频文件解码为脉沖编码调制(Pulse Code Modulation, PCM )数据; 将 PCM数据的采样率转换为符合蓝牙立体声协 议的采样率; 将转换后的 PCM数据编码后, 发送给蓝牙立体声耳机进行播 放。 在发送码流的过程中, 按照解码后的 PCM数据来发送, 并对采样率进 行调整后计算需要发送的 PCM数据量, 然后将这个 PCM数据编码为 SBC 格式, 再一次性把这些 SBC格式数据送给蓝牙芯片。 这样就不需要按照每 种格式各自的计算方式进行转换和发送, 一方面使得用户通过蓝牙收听音 频文件不再受到格式的限制更加方便, 另外也能提高蓝牙收听的音质, 实 现立体声播放。 附图说明
图 1 为本发明一种支持多种采样率的蓝牙立体声的实现方法流程示意 图;
图 2为本发明插值转换的采样点示意图; 图 3 为本发明一种支持多种采样率的蓝牙立体声的实现装置结构示意 图。 具体实施方式
本发明的基本思想是: 首先读取需要播放的音频文件, 将音频文件解 码为 PCM数据; 将 PCM数据的采样率转换为符合蓝牙立体声协议的采样 率; 将转换后的 PCM数据编码后, 发送给蓝牙立体声耳机进行播放。
下面结合附图和具体实施例对本发明的技术方案进一步详细阐述。 图 1 为本发明一种支持多种采样率的蓝牙立体声的实现方法流程示意 图, 如图 1所示, 所述方法具体包括以下步驟:
步驟 101 , 读取需要播放的音频文件, 将音频文件解码为 PCM数据; 具体的, 所述音频文件的格式包括音频数据的各种编码格式。 最常见 的有: MP3、 AMR、 AAC、 WMR、 WAV等编码格式。
步驟 102,将 PCM数据的采样率转换为符合蓝牙立体声协议的采样率; 具体的, 所述符合蓝牙立体声协议的采样率包括: 44.1KHZ或 48KHz。 所述将 PCM数据的采样率转换为符合蓝牙立体声协议的采样率, 包括: 利 用插值或抽取的方式,将 PCM数据的采样率转换为符合蓝牙立体声协议的 采样率。其中,当 PCM数据的采样率低于符合蓝牙立体声协议的采样率时, 利用插值的方式对采样率进行转换; 当 PCM数据的采样率高于符合蓝牙立 体声协议的采样率时, 利用抽取的方式对采样率进行转换。
步驟 103, 将转换后的 PCM数据编码后, 发送给蓝牙立体声耳机进行 播放。
具体的, 所述将转换后的 PCM数据编码后, 发送给蓝牙立体声耳机进 行播放, 具体为: 将转换后的 PCM数据根据采样频率和码流计算播放时间 后, 编码成子带编码 (Sub-Band Codec, SBC)格式, 通过串口例如 UART, 将编码后的数据一次性的发送给蓝牙芯片, 由蓝牙芯片进行解码后调制成 模拟信号, 通过空口发送给蓝牙立体声耳机进行播放。
图 2为本发明插值转换的采样点示意图, 如图 2所示, 原数据的采样 点分别为采样点 1、 采样点 2、 采样点 3和采样点 4, 所述插值的计算过程 中, 可以采用前 2个点与后 2个点的 4点相加后平均的插值算法, 即采样 点 1、 采样点 2、 采样点 3和采样点 4相加除以 4的值为采样的大小, 插值 的位置位于采样点 2和采样点 3之间的中间位置, 即图中采样点 5。 这种算 法相对普通的均值插值方法而言, 音质会平滑得多, 不会有突变音。
图 3 为本发明一种支持多种采样率的蓝牙立体声的实现装置结构示意 图, 如图 3所示, 所述装置中包括: 主控制器 31和蓝牙芯片 32, 其中, 所述主控制器 31 , 用于读取需要播放的音频文件, 将音频文件解码为 PCM数据, 将 PCM数据的采样率转换为符合蓝牙立体声协议的采样率; 将转换后的 PCM数据编码后发送给蓝牙芯片 32;
具体的, 所述音频文件可以保存在装置中, 也可以保存在安装了所述 装置的设备中, 所述设备例如: 手机、 MP3播放器、 电脑等。 所述音频文 件的格式包括音频数据的各种编码格式。最常见的有: MP3、 AMR、 A AC, WMR、 WAV等编码格式。
进一步的,所述符合蓝牙立体声协议的采样率包括: 44.1KHZ或 48ΚΗζ。 所述主控制器 31将 PCM数据的采样率转换为符合蓝牙立体声协议的采样 率, 包括: 利用插值或抽取的方式, 将 PCM数据的采样率转换为符合蓝牙 立体声协议的采样率。 其中, 当 PCM数据的采样率低于符合蓝牙立体声协 议的采样率时, 利用插值的方式对采样率进行转换; 当 PCM数据的采样率 高于符合蓝牙立体声协议的采样率时 , 利用抽取的方式对采样率进行转换。
进一步的, 所述主控制器 31将转换后的 PCM数据编码后发送给蓝牙 芯片 32,具体为:将转换后的 PCM数据根据采样频率和码流计算播放时间 后, 编码成 SBC格式, 通过串口, 例如: UART, 将编码后的数据一次性 的发送给蓝牙芯片 32。
所述蓝牙芯片 32, 用于将所述编码后的数据发送给蓝牙立体声耳机进 行播放。
具体的, 所述蓝牙芯片 32将所述编码后的数据发送给蓝牙立体声耳机 进行播放, 具体为: 蓝牙芯片 32将所述编码后的数据解码后调制成模拟信 号, 通过空口发送给蓝牙立体声耳机进行播放。
在实际应用中, 所述主控制器 31可以采用基带控制芯片, 所述蓝牙芯 片 32可以采用 BC6型号来实现上述功能。
综上所述本发明的优点在于以下两点: 第一可以支持多种采样率的音 频文件, 使其能用蓝牙立体声播放: 目前 A2DP所支持的音乐文件播放的 采样频率是 44.1khz和 48khz, 对于其他采样频率的音乐是不支持的。 本发 明就是通过插值或者抽取的方法将原本采样率不是 44. lkhz和 48khz的音频 文件转变成采样率为 44.1khz或者 48khz。如果音乐文件采样率低于 44.1khz 或者 48khz的就进行插值变成 44.1khz或者 48khz, 如果音乐文件采样率高 于 44. lkhz或者 48khz的就进行抽取变成 44. lkhz或者 48khz。 第二支持各 种音频格式的码流控制方法: 目前音频格式和编码方式有很多, 最常见的 有 MP3、 AMR、 AAC、 WMR、 WAV等。 每种格式各不相同, 每帧播放多 少时间, 该怎样向蓝牙送多少数据, 都不相同。 所以在发送码流的时候按 照解码后的 PCM数据来发送, 并按照插值或者抽取后的采样率来计算需要 发送的 PCM数据量, 然后将这个 PCM数据编码为 SBC格式, 再一次性把 这些 SBC格式数据送给蓝牙芯片。 这样就不需要按照每种格式各自的计算 方式进行转换和发送, 一方面使得用户通过蓝牙收听音频文件更加方便, 另外也能提高蓝牙收听的音质。
以上所述, 仅为本发明的较佳实施例而已, 并非用于限定本发明的保 护范围。

Claims

权利要求书
1、 一种支持多种采样率的蓝牙立体声的实现方法, 其特征在于, 所述 方法包括:
读取需要播放的音频文件, 将音频文件解码为脉沖编码调制 (PCM ) 数据;
将 PCM数据的采样率转换为符合蓝牙立体声协议的采样率;
将转换后的 PCM数据编码后, 发送给蓝牙立体声耳机进行播放。
2、 根据权利要求 1所述的方法, 其特征在于, 所述将 PCM数据的采 样率转换为符合蓝牙立体声协议的采样率, 包括: 利用插值或抽取的方式, 将 PCM数据的采样率转换为符合蓝牙立体声协议的采样率。
3、 根据权利要求 2所述的方法, 其特征在于, 所述利用插值或抽取的 方式进行转换, 包括:
当 PCM数据的采样率低于符合蓝牙立体声协议的采样率时,利用插值 的方式对采样率进行转换;
当 PCM数据的采样率高于符合蓝牙立体声协议的采样率时,利用抽取 的方式对采样率进行转换。
4、根据权利要求 1或 2所述的方法,其特征在于,所述将转换后的 PCM 数据编码后, 发送给蓝牙立体声耳机进行播放, 为:
将转换后的 PCM数据根据采样频率和码流计算播放时间后,编码成子 带编码(SBC )格式, 通过串口将编码后的数据一次性的发送给蓝牙芯片, 由蓝牙芯片进行解码后调制成模拟信号, 通过空口发送给蓝牙立体声耳机 进行播放。
5、 根据权利要求 1或 2所述的方法, 其特征在于, 所述音频文件的格 式包括音频数据的各种编码格式; 所述符合蓝牙立体声协议的采样率包括: 44.1 KHz或 48KHz。
6、 一种支持多种采样率的蓝牙立体声的实现装置, 其特征在于, 所述 装置包括: 主控制器和蓝牙芯片, 其中,
所述主控制器,用于读取需要播放的音频文件,将音频文件解码为 PCM 数据, 将 PCM数据的采样率转换为符合蓝牙立体声协议的采样率; 将转换 后的 PCM数据编码后发送给蓝牙芯片;
所述蓝牙芯片, 用于将所述编码后的数据发送给蓝牙立体声耳机进行 播放。
7、 根据权利要求 6所述的装置, 其特征在于, 所述主控制器将 PCM 数据的采样率转换为符合蓝牙立体声协议的采样率, 包括: 利用插值或抽 取的方式, 将 PCM数据的采样率转换为符合蓝牙立体声协议的采样率。
8、 根据权利要求 7所述的装置, 其特征在于, 所述主控制器采用插值 或抽取的方式进行转换, 包括:
当 PCM数据的采样率低于符合蓝牙立体声协议的采样率时,利用插值 的方式对采样率进行转换;
当 PCM数据的采样率高于符合蓝牙立体声协议的采样率时,利用抽取 的方式对采样率进行转换。
9、 根据权利要求 6或 7所述的装置, 其特征在于, 所述主控制器将转 换后的 PCM数据编码后发送给蓝牙芯片, 为: 将转换后的 PCM数据根据 采样频率和码流计算播放时间后, 编码成 SBC格式, 通过串口将编码后的 数据一次性的发送给蓝牙芯片。
10、 根据权利要求 6或 7所述的装置, 其特征在于, 所述音频文件的 格式包括音频数据的各种编码格式; 所述符合蓝牙立体声协议的采样率包 括: 44.1KHz或 48KHz。
PCT/CN2011/080936 2011-08-09 2011-10-18 一种支持多种采样率的蓝牙立体声的实现方法和装置 WO2012151847A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN2011102268783A CN102355309A (zh) 2011-08-09 2011-08-09 一种支持多种采样率的蓝牙立体声的实现方法和装置
CN201110226878.3 2011-08-09

Publications (1)

Publication Number Publication Date
WO2012151847A1 true WO2012151847A1 (zh) 2012-11-15

Family

ID=45578811

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2011/080936 WO2012151847A1 (zh) 2011-08-09 2011-10-18 一种支持多种采样率的蓝牙立体声的实现方法和装置

Country Status (2)

Country Link
CN (1) CN102355309A (zh)
WO (1) WO2012151847A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108271144A (zh) * 2018-03-23 2018-07-10 杜宁 一种与终端进行数据双向互传的蓝牙装置和系统

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103905834B (zh) * 2014-03-13 2017-08-15 深圳创维-Rgb电子有限公司 音频数据编码格式转换的方法及装置
CN105793925A (zh) * 2014-10-29 2016-07-20 联发科技股份有限公司 音频前端使用的音频采样率控制的方法及相关的非临时性机器可读介质
CN105813031A (zh) * 2014-12-30 2016-07-27 中兴通讯股份有限公司 彩铃的播放方法及装置
CN105913860A (zh) * 2015-12-18 2016-08-31 乐视致新电子科技(天津)有限公司 多播放器共同播放高保真声音的方法及装置
CN106205651A (zh) * 2016-06-30 2016-12-07 乐视控股(北京)有限公司 采样率转化方法、装置及终端
CN113489568B (zh) * 2018-02-14 2022-05-13 华为技术有限公司 一种高速传输音频数据的方法和装置
CN108419223A (zh) * 2018-02-27 2018-08-17 上海康斐信息技术有限公司 一种音乐耳机的播放方法及音乐耳机
CN108540902A (zh) * 2018-04-18 2018-09-14 四川斐讯信息技术有限公司 一种适用于物联网设备的蓝牙音频播放方法及系统
CN108648772A (zh) * 2018-04-19 2018-10-12 上海康斐信息技术有限公司 一种低功耗的蓝牙音频播放方法及电子设备
CN110634512A (zh) * 2019-09-29 2019-12-31 李翼东 音频文件采样率的转化方法、装置、设备及储存介质

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007110839A2 (en) * 2006-03-27 2007-10-04 Koninklijke Philips Electronics N.V. Method, system, and apparatus for sample rate conversion
CN101192832A (zh) * 2006-11-30 2008-06-04 美国博通公司 处理音频信号的方法和系统
CN101202593A (zh) * 2006-11-30 2008-06-18 美国博通公司 用于处理来自多个音频处理源的多速率音频的方法和系统
CN101217038A (zh) * 2008-01-17 2008-07-09 中兴通讯股份有限公司 音频数据sbc算法编码方法及蓝牙立体声子系统
CN101222793A (zh) * 2008-01-25 2008-07-16 中兴通讯股份有限公司 一种调节蓝牙立体声音质的方法及系统

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2007110839A2 (en) * 2006-03-27 2007-10-04 Koninklijke Philips Electronics N.V. Method, system, and apparatus for sample rate conversion
CN101192832A (zh) * 2006-11-30 2008-06-04 美国博通公司 处理音频信号的方法和系统
CN101202593A (zh) * 2006-11-30 2008-06-18 美国博通公司 用于处理来自多个音频处理源的多速率音频的方法和系统
CN101217038A (zh) * 2008-01-17 2008-07-09 中兴通讯股份有限公司 音频数据sbc算法编码方法及蓝牙立体声子系统
CN101222793A (zh) * 2008-01-25 2008-07-16 中兴通讯股份有限公司 一种调节蓝牙立体声音质的方法及系统

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108271144A (zh) * 2018-03-23 2018-07-10 杜宁 一种与终端进行数据双向互传的蓝牙装置和系统
CN108271144B (zh) * 2018-03-23 2023-12-19 杜宁 一种与终端进行数据双向互传的蓝牙装置和系统

Also Published As

Publication number Publication date
CN102355309A (zh) 2012-02-15

Similar Documents

Publication Publication Date Title
WO2012151847A1 (zh) 一种支持多种采样率的蓝牙立体声的实现方法和装置
US10200004B2 (en) Last mile equalization
JP7302006B2 (ja) Bluetoothデバイスを操作するための方法
WO2018152679A1 (zh) 音频文件的传输、接收方法及装置、设备及其系统
WO2016026427A1 (zh) 卡拉ok的实现方法及系统
WO2008122212A1 (fr) Procédé et système d'auto-réglage de formats de codage audio d'une émission bluetooth a2dp
TW201246061A (en) Automatic audio configuration based on an audio output device
WO2013167021A2 (zh) 一种HiFi音频输出方法、装置和系统
JP2016024817A (ja) 音声送受信装置
WO2021160040A1 (zh) 音频传输方法及电子设备
JP2006294120A5 (zh)
CN102063908A (zh) 一种pc和手机之间进行音频数据传输的方法
CN204669587U (zh) 音频处理设备及蓝牙音箱
KR102605961B1 (ko) 고해상도 오디오 코딩
CN111225102A (zh) 一种蓝牙音频信号传输方法和装置
TW201532036A (zh) 多媒體卡拉ok混音裝置及其混音方法
CN105516862A (zh) 一种音频转录与无线分发的装置和方法
CN201226236Y (zh) 无线内嵌式点唱装置
CN111385780A (zh) 一种蓝牙音频信号传输方法和装置
WO2019047239A1 (zh) 智能终端及其音频数据多通道传输方法
KR102664768B1 (ko) 고해상도 오디오 코딩
TWI538419B (zh) 藍牙無線音訊傳輸器
CN203070758U (zh) 音频录放装置
CN202694803U (zh) 基于wifi的便携式高保真音频传输装置及系统
TW578095B (en) The wireless broadcast device

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: 11865043

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: 11865043

Country of ref document: EP

Kind code of ref document: A1