Bone Conduction Speaker Experiment using I2C

The more things I studied about TPA2016, the further curiosity I had got such as what is going to happen what if I connect bone conduction speaker instead of a speaker. In addition, while reading the data sheet of TPA2016D2, I had been stuck on some words which were Automatic Gain Control (AGC) and Dynamic Range Compression (DRC) because I have never heard of these words before. However, these words DRC and AGC seem to be really important to know to do the further experiment like the aim of this tutorial which is the experiment of bone conduction speaker using I2C.


About AGC and DRC

Automatic Gain Control is able to make an output signal constant despite its input signal. For example, when multiple people use a microphone at the same time, the sound input levels are different because some of them might be farther than other people, but some of them might be using the microphone closer. In this case, AGC automatically adjusts the input level and makes the output level constant. The point is, the weaker input signal is, the stronger output signal is, and the stronger input signal is, the weaker output signal is. In addition, the gain on the TPA2016D2 can be selected -28dB to +30dB. Of course, -28dB outputs a silent sound and +30dB can output a louder sound.

Dynamic Range Compression is able to prevent a clipping noise when the sound volume is extremely high by compressing the dynamic range of audio signal and speaker. In addition, DRC can automatically adjust the audio signal level for the sound range that you want.


Once you understood these words, let’s get started with bone conduction speaker using I2C experiment.

Requirements

・Bone Conduction Transducer

img_3669

・TPA2016

s__41000966

・3.5mm Headphone Jack

s__40984581

・3.5mm Audio Cable

s__40984584

・Arduino Uno

s__40984579

・A breadboard

s__40984582

・Some Jumper Wires

img_3670


Circuit Diagram

bone-conduction-speaker-circuit-diagram

Assembly the components by following this circuit diagram. Remember that the goal of this experiment is to use I2C. I2C pins on the Arduino are A4 pin (SDA) and A5 pin (SCL), so connect each pin to the pins on TPA2016.


Programming

Before you look up the code below, you should download two libraries which are wire library and TPA2016 library. (Go to Arduino IDE -> Sketch -> Include library -> Manage Libraries -> Search these libraries and download them). After restarting Arduino IDE, go to File -> Example -> then you see “Adafruit TPA2016 Library and click on it. You will get the exactly same code below.

In the serial monitor, you should get this result.

 


Result

The sound from bone conduction speaker worked well! While the gain increases from -28dB to +30dB, the sound correspondingly becomes louder and when the speaker does not touch anywhere, you cannot hear any sound. Which means I2C also worked well between TPA2016 and Arduino. Pretty cool!

Lastly, check and watch the result video below.

Related Post

Leave a Reply

Your email address will not be published. Required fields are marked *

CAPTCHA