Design considerations for high quality Bluetooth audio

This article refers to the address: http://

Bluetooth has come true to people's lives. We used to wonder "how many Bluetooth devices can be connected around", but now we are thinking about "how will I connect with your Bluetooth device?"

Until recently, Bluetooth audio transmission was relatively simple. The Bluetooth specification only defines one transport mechanism, and there is little choice for more complex applications. Today, the release of the Bluetooth Specification 1.2 and a new high-quality audio protocol enriches once monotonous Bluetooth audio capabilities. Since all digital audio transmissions are based on data streams, the available transmission methods vary in terms of transmission mechanism, coding method, data rate, packet length, and error detection/correction.

Bluetooth technology is a frequency hopping protocol based on data packets and time slots of 625 milliseconds. Among every two Bluetooth devices that are paired, one is the connected master and the other is the slave. In general, the slave device transmits data to the master device in a time slot after receiving a packet from the autonomous device. Bluetooth technology defines two basic mechanisms for audio data transmission.

The original Bluetooth audio transmission mechanism was a synchronous directed connection (SCO) channel, which supported full-duplex transmission at a data rate of 64 kbps. In the absence of radio frequency interference, SCO's sound quality can be close to the sound quality of standard mobile phones. This result is also expected, because the development of Bluetooth technology itself has the idea of ​​being applied to Bluetooth headsets. The SCO data is transmitted in a specified time slot, which guarantees both bandwidth and guarantees that the data packet arrives within a certain time.

Bluetooth devices use the Logical Link Control and Adaptation Protocol (L2CAP) to transmit unsynchronized data. Logical Link Control and Adaptation Protocol multiplexes all unsynchronized data transfers onto valid Bluetooth bandwidth, including serial data (such as AT commands and responses), service discovery data, and for providing audio and video Isochronous data of the stream channel. Figure 1 is a block diagram of the protocol layer.

The Bluetooth Specification 1.2 improves the quality of service (QoS) of Bluetooth devices and greatly improves the utility of isochronous data. These improvements enable applications to request bandwidth and latency guarantees for transporting data streams.

Bluetooth audio design considerations

Choose the correct SCO channel

The SCO channel provides very little in terms of customizable features. The bit rate is fixed, and when three codecs are determined, only one continuous variable slope increment (CVSD) is actually used. Other codecs (A-Law and L-law) offer better sound quality, but they are as fault-tolerant as CVSD. Since the SCO channel only provides limited error detection/correction and no packet retransmission, CVSD is a safer option.

Bluetooth technology defines four packet types for transporting SCO

SCO provides full-duplex audio. The master device in the Bluetooth connection sends a data packet to the slave device, and the slave device responds in the next time slot. Although a particular package type can be selected, this particular packet type is symbolically left in the connection management firmware within the Bluetooth chipset. Bluetooth technology defines four packet types for transporting SCOs (see table).

Whether it is selected by the chipset or selected by the system designer, compromises are required when selecting the SCO package type. The HV1 packet has better error correction than other types of packets, but it takes up the entire bandwidth in the Bluetooth 1.1 specification. The HV3 packet type does not provide error detection, but only takes up 2 of every 6 slots. The Bluetooth device is then able to establish other connections while maintaining the SCO connection, which is not possible when the SCO data uses HV1 packets. Figure 2 is a timing diagram of an SCO.

SCO timing chart

Ideally, the packet type does not affect the audio quality, and the data transmitted is identical in all three cases. The HV1 and HV2 packets allow for correction of some errors. However, in general, the error does not significantly reduce the audio quality. The difference in sound quality is most likely due to packet loss.

A Bluetooth packet consists of an access code, a start code and a payload. When the 1/3 forward error correction code and the error detection code protect the start code, low signal strength or local interference may cause the start code in the arriving packet to be invalid. In this case, the packet will be discarded because the packet is lost because there is no resending request mechanism for the SCO packet.

If the connection uses HV1 packets, the data will be lost less, so the audio bounce energy will be less in a lost packet. If the packet is lost due to narrow bandwidth or short-term interference, HV1 can provide better sound quality than HV2 or HV3 packets. Of course, this is not static, because HV1 transmits more packets, so the possibility of packet loss is higher in noisy environments.

Bluetooth Specification 1.2 adds the ability to improve SCO sound quality in the presence of local interference. A good example of this is IEEE-802.11b, which occupies approximately 22 MHz of bandwidth in ISM (bandwidth for industrial, scientific, and medical) bandwidth, or 22 channels in the Bluetooth spectrum.

The interval between the 79 channels used by Bluetooth technology is 1 MHz. Bluetooth version 1.2 incorporates Adaptive Frequency Hopping (AFH) technology, which allows paired Bluetooth devices to avoid collisions. The paired devices can generate a channel map in real time or be provided to wireless signals from the upper layer software. The latter mode allows devices that include both Bluetooth and 802.11b nodes to coexist better. The device's software provides a new frequency map for the Bluetooth module to prevent Bluetooth devices from using channels that are occupied by 802.11b nodes. The sound quality is improved due to less packet loss due to interference. The frequency hopping algorithm used by AFH works with only 20 good channels. The disadvantage of reducing the working channel to the AFH is that the likelihood of interference from nearby Bluetooth connections increases.

Extended SCO channel

The extended SCO channel is another addition to the Bluetooth 1.2 release that provides greater flexibility in channel parameters and allows retransmission of corrupted packets. These extensions, combined with AFH, provide better performance in terms of audio transmission than the standard SCO channel of Bluetooth version 1.1.

As a simple example, the eSCO channel works very similarly to the SCO channel, despite the new type of packet. Audio data is spread in a single gap packet, which contains 1 to 30 data bytes, but eSCO has made two improvements. First, a CRC code is added to the packet to verify the validity of the data (this is not available in the HV3SCO packet). Second, if the receiving device detects that the packet is faulty, it can request to resend the erroneous packet. This depends on how the channel is set, because the information frame must be preserved for retransmission.

The disadvantage is that resending the data packet increases the power consumption of the transceiver device. This effect can be minimized with AFH. If the packet loss is due to fixed bandwidth interference, such as 802.11b, etc., AFH allows the Bluetooth device to avoid known bad channels to reduce data retransmissions. Designers also need to consider the data latency issue because the resent data is at least 1.2ms later than the planned arrival time.

As mentioned earlier, the SCO channel uses CVSD audio coding due to the greater likelihood of data loss or corruption. Other codecs provide better fidelity but perform poorly when receiving erroneous data. With the better data integrity of eSCO, it is possible to use other encoders to improve the sound quality without increasing the basic data rate of 64 kbps. The .SCO data has a fixed data rate of 64 kbps and is symmetrical and supports full duplex. Using eSCO will add two multi-slot packets and support asymmetric data rates. In fact, there is no data at all for transmission. If an eSCO channel is unidirectional, such as an audio museum guide, the receiving device sends a small packet called NULL to acknowledge the receipt after receiving a packet. Based on the negotiated parameters, with multi-slot packets, the data rate on the eSCO channel can be as high as 288 kbps, which makes it possible to support higher order codecs including video transmission.

Interestingly, eSCO has these rich options, but instead becomes the biggest obstacle to the effective application of its functions. Channel options, such as data rate and codec, must be negotiated at the application layer. The Bluetooth working groups responsible for developing protocol specifications that use SCO connections are developing a way to integrate eSCO into these protocols.

A recommended solution is to introduce these features in stages. The first phase limited eSCO to a 64 kbps CVSD channel, which has the same effect as SCO channel limiting hardware and software support. With this experience, more features will be introduced. If this seems too cautious, don't forget that there are news that "about 55 different configurations have reached symmetric 64kbps with eSCO.

The specification for broadband voice is currently under development, and the driving force behind it is the derivation of a similar technology in 3G mobile communication technology. If a large number of Bluetooth products are targeted at mobile phone headset accessories and car hands-free kit accessories, the quality of the audio connection between the phone and the accessory must at least be the quality of the connection between the mobile phone network and the mobile phone. The details of the Bluetooth Broadband Voice Specification have not yet been released, but it is clear that eSCO will be used as its transport mechanism.

Advanced Audio Distributed Transmission Protocol

As the name implies, the recently adopted Audio Distributed Transmission Protocol (A2DP) is designed for the transmission of high quality audio data. A one-way audio stream may use any type of codec. However, to ensure interoperability, A2DP mandates a codec. As specified by the data source and codec, the data stream can contain a single audio channel or mixed stereo coding.

As mentioned earlier, Bluetooth technology provides both synchronous and asynchronous data transmission services. A2DP uses an isochronous data channel loaded on the L2CAP layer. Between A2DP and L2CAP is an audio/video distributed transmission protocol. This protocol layer defines the transport mechanism for audio and video streams.

A2DP and AVDTP regulate the decoding, transmission and decoding of data streams. There is also a protocol that controls the content of the data stream. This protocol is the audio and video remote control protocol, which specifies the basic elements needed to implement a remote control device.

By combining these elements, users can bring Bluetooth-enabled digital audio players to their cars and take advantage of the car's built-in audio system to control the player while enjoying the player. Bluetooth has sufficient bandwidth to support high-quality audio streams with stereo encoding, which brings high-fidelity wireless audio to users. As these functions or gizmos are quickly ported to electronic assistant devices, mobile phones or PDAs will be a good source of audio. A2DP is currently used in devices such as wireless stereo headphones and remote speakers in home audio systems.

Application-based considerations

We know that Bluetooth technology offers multiple options for the transmission of audio data. Which one to choose depends on the application first. If the application is based on the standard Bluetooth protocol, then the protocol specifies what type of audio transmission mechanism is available.

For simpler Bluetooth devices, such as mono phone headsets, a simple SCO audio channel is fine. Unless in a special environment, all SCO audio packet types can be used on such devices, leaving the exact choice to the Bluetooth chip's connection management code.

If the Bluetooth headset supports higher quality audio, such as wideband voice, you must add the appropriate codec and eSCO. It should be noted that the protocol layer coding must control the channel characteristics negotiation, which is different from the SCO channel at the protocol layer.

If two devices cannot agree on a set of eSCO parameters, then the two devices must be able to retreat to the SCO channel. This additional negotiation feature increases the complexity of the encoding and adds to the difficulty of interoperability. When developing Bluetooth products with eSCO capabilities, manufacturers have worked hard on product interoperability testing, including testing with Bluetooth 1.1-based products that do not support eSCO at all.

The operating environment of the test must also take into account many factors. If there is known interference, such as 802.11b nodes, combined with adaptive frequency hopping technology and eSCO's packet retransmission mechanism, it can greatly reduce packet loss and improve sound quality. If the device has both 802.11b and Bluetooth nodes, the designer should pay attention to the transport mechanism in the hardware and software to achieve coexistence.

The Bluetooth channel mask can be set by software to avoid the frequency occupied by the local 802.11b. This allows the AFH software to know the bad channels without actually having to do so. There are other mechanisms that attempt to assign a transmission time to each device in turn. This scheme works well when dealing with data that is not critical to time, but it does not have much value in the face of synchronous or isochronous data streams. Since these characteristics vary from chip manufacturer to chip manufacturer, interested designers should figure out which ones are available from their preferred supplier.

Pay more attention to the choice of codec. For SCO and eSCO channels, CVSD combines acceptable sound quality with robustness in the face of potentially flawed data. Using different codecs can improve sound quality at the same data rate, but must take into account data stability and device interoperability.

If the application requires a high quality one-way audio path, A2DP will be a reasonable choice. This again reminds the designer to pay more attention when choosing a codec. For dedicated paired devices, any codec, such as a speaker, can be used, which simply connects to its partner node (sound source). If the device will be paired with multiple devices, the best option is to use the default codec.

I hope this article can provide some guidance for choosing Bluetooth audio transmission. For more information, interested readers can refer to the Bluetooth specification or specific implementation details.

Education Projector

Educational projectors are mainly aimed at classroom teaching by school teachers; traditional projectors are not easy to carry. Due to the naughty students in school classrooms, projectors are not safe to place in classrooms and are easily damaged by students. The portability of educational micro-projectors makes up for teaching Vacancy, it is convenient for teachers to give lectures and only need to store the materials in the projector and show them to students for teaching, saving the trouble of textbooks and handwriting with pens and chalks. Its general weight will not exceed 0.2Kg, and some do not even need fan cooling or ultra-small silent fan cooling.

Educational projectors need to have:

1. Clear handwriting Educational projectors most often display text and images, at least a resolution of 1024*768 or more, and a contrast ratio of more than 3000 lumens, so that students in the back row can see the projection clearly

2. Short-focus large screen;

3. Accurate color;

4. Easy operation;

5. Features such as multiple connection methods.

education projector,education use projector,smart education projector,best education projectors,projector for education

Shenzhen Happybate Trading Co.,LTD , https://www.happybateprojectors.com