Wireless Earphones to Bluetooth Speakers

by Saiyam in Circuits > Speakers

13209 Views, 78 Favorites, 0 Comments

Wireless Earphones to Bluetooth Speakers

Share from Pixlr.jpg
DSCN6535.JPG
DSCN6536.JPG
DSCN6540.JPG
DSCN6559.JPG
DSCN6520.JPG

A year ago I had bought these bluetooth earphones from amazon for around $17. They were working just fine for the first 6 months when one of ear pieces stopped working. From then, they've just been lying around. While cleaning my room, I found these and decided to reuse the bluetooth receiver chip inside which was still working.

I came up with this idea of making a Bluetooth speaker with an addition of music reactive disco lights controlled via arduino. This is my 27th instructable and I am finally back after a long gap, being too busy with exams and school work.

So this project used a TDA7297 15W amplifier board along with a 10W speaker. You can even play music via aux. The bluetooth part also consists of voice calling, playback options, redialling, picking up phone or hanging up which were already present in the wireless earphones.

There are 4 RGB LEDs installed in the front, which change their color on every beat of music. There is a set threshold of the amplitude. The arduino takes audio signal as input. If it goes above the threshold, the color of the LED sets to a random one.

I used to hardwood to make the enclosure and 3x 18650 rechargeable lithium ion batteries to power the project. I haven't yet calculated the time for which the battery lasts.

It will take you almost 2 days to complete the project. This is also a budget build. How better can it be to listen to music on your homemade speakers!

_____________________

I have tried my best to make the instructions clear. If there is any doubt, just mention it in the comment section below.

Support the project by voting in the contests entered, following and sharing with your friends. This always motivates a maker to make better.

_____________________

Here a step by step tutorial video for building the entire project:

Subscribe to my channel:

Parts and Tools Required

DSCN5055.JPG
DSCN5936.JPG
588514b745571439ff000634.jpeg
DSCN6434.JPG
DSCN5938.JPG
DSCN5078.JPG
DSCN6024.JPG
DSCN5969.JPG
DSCN6429.JPG
DSCN5967.JPG
DSCN5965.JPG
DSCN6443.JPG

The following parts and tools are required for making this project:

Parts:

  • 1x Good quality speaker (10-15W)
  • 1x TDA7297 amplifier board
  • 1x Old bluetooth earphones (the chip should work) OR Bluetooth receiver chip
  • 1x Arduino nano or pro mini
  • 3x 18650 Lithium-ion batteries
  • 4x RGB LEDs
  • 1x On/Off toggle switch
  • 1x 6-pin 2 way switch
  • 1x Female audio jack
  • 2x 10K ohm potentiometers
  • 1x IN4007 diode
  • 4x Nuts and bolts
  • Sufficient hardboard
  • Rainbow wire
  • Female headers
  • Safety pins

Tools:

  • Soldering iron + solder
  • Hot glue gun + glue sticks
  • A bottle of super glue
  • Hack saw
  • Multipurpose rotatory tool with necessary attachments
  • Wire cutter
  • Screwdriver
  • Pliers

Total Cost: $15 (1000 INR) approx. excluding the earphones

Cut the Wooden Panels

DSCN6405.JPG
vlcsnap-error123.png
vlcsnap-error824.png
vlcsnap-error578.png
DSCN5721.JPG
DSCN5733.JPG

So the first step is to cut the six wooden panels that will make up the body of the speaker. The measurements are given above. We want 2 nos. 12x12cm, 2 nos. 12x9.5cm and 2 nos. 11x9.5cm panels.

I used hardboard which was cheap and easy to cut. Use a hacksaw to do so. Before that just mark everything up with a pencil and a ruler.

Drill and Cut the Speaker Mount

DSCN5759.JPG
DSCN5764.JPG
DSCN5761.JPG
vlcsnap-error074.png
DSCN5770.JPG
vlcsnap-error599.png
vlcsnap-error264.png
DSCN5778.JPG
DSCN5789.JPG
vlcsnap-error706.png
DSCN5793.JPG
DSCN5800.JPG
vlcsnap-error142.png
DSCN5824.JPG

You will now have to cut a large circle in the front panel to mount the speakers. First get the speaker, mark and drill 4 holes for the screws. Now using a compass or a circular object with the same radius as the speaker, mark a circle around the drilled holes.

I currently don't have professional woodworking tools, so used a rotatory tool with the cutter attachment first. Then I sanded and smoothed the circle.

You may use whatever tools you can. Just make sure you ensure proper safety.

Sand the Panels

vlcsnap-error359.png
vlcsnap-error589.png
DSCN5838.JPG

The cuts made with a hacksaw are not perfect. To make them plain, use a sand paper to smoothen the edges and the sides so they can be stuck easily. Use a dust mask while doing so.

Cut Interlocking Parts for the Back Panel

DSCN6421.JPG
DSCN6410.JPG
vlcsnap-error158.png
DSCN5842.JPG
vlcsnap-error551.png
DSCN5857.JPG
DSCN5849.JPG
DSCN6412.JPG
vlcsnap-error975.png
DSCN5870.JPG
vlcsnap-error096.png
vlcsnap-error259.png
vlcsnap-error488.png
vlcsnap-error425.png
DSCN5882.JPG
DSCN5889.JPG

I wanted to make the back panel removable to repair or make any necessary modifications. For this, the best way is to cut make an interlocking system as shown in the picture above. The back panel should be cut as per the figure. Be accurate with the measurements.

The 2 side panels and top+bottom panel will have a socket cut for each for the back panel to fit into. Again, which is mentioned in the figure provided above. I used a hacksaw and a sharp cutter/xacto knife.

Stick 3 of the Pieces

DSCN5904.JPG
vlcsnap-error106.png
vlcsnap-error152.png
vlcsnap-error922.png
DSCN5913.JPG

We are not going to attach all the 5 pieces in one go. To make the connections more easier, stick the lower, front and the right panel first.

You may use wood glue or even super glue, which would dry instantly.

Put the Speakers in Place

DSCN5917.JPG
vlcsnap-error985.png
vlcsnap-error809.png
DSCN5925.JPG

Using some nuts and bolts, fix the speaker in place and tighten the screws. You can have the speaker fixed outside or even inside.

From now on, you will see the speaker has been fixed from outside. That was when I took the pictures before, and changed the position later.

Mark and Drill Holes for Different Components

DSCN5972.JPG
DSCN5974.JPG
vlcsnap-error358.png
DSCN5977.JPG
DSCN5982.JPG
vlcsnap-error838.png
vlcsnap-error454.png
DSCN5996.JPG

Since we have stuck the right panel only, we will have the on/off switch, 2 potentiometers and the 2-way switch mounted on it. The placements may differ from the picture.

Drill the marked holes and largen them. For the switch, you will need to make it much bigger.

Mark and Drill Holes for the RGB LEDs

DSCN6094.JPG
vlcsnap-error737.png
vlcsnap-error778.png
DSCN6106.JPG

Now first decide the position of the 4 RGB LEDs and mark it. I just chose the 4 corners of the front panel. Be very accurate and drill the holes with the same width as that of the LEDs. Check if they fit easy. They must not come out.

Solder Wires to the Amplifier Board

588781eaf9ff19a6ed0010d1.jpeg
DSCN5080.JPG
vlcsnap-error847.png
vlcsnap-error845.png
vlcsnap-error771.png

Now you need to solder 6 pieces of wires to the amplifier board where 2 are for power and 2-2 for input and output. I soldered 1-1 extra each initially for the right output and input but since we're using only one speaker, we won't be need two inputs and outputs so I later cut them off.

If you're using the same board, the pads where the wires need to be soldered are marked above. After soldering, secure all the connections with some hot glue.

Hack Open a Bluetooth Earphones and Replace the Output Wires

DSCN6045.JPG
vlcsnap-error269.png
DSCN6052.JPG
DSCN6057.JPG
DSCN6067.JPG
DSCN6073.JPG
DSCN6082.JPG
DSCN6090.JPG

This is important step. The main aim of this project was to reuse an old bluetooth earphone to make a bluetooth speaker. Still, if you don't have one, go for a USB bluetooth music receiver. You can skip this step if you got a receiver.

Find a weak spot in your earphones and open the main housing. You'll usually find a small chip and a rechargeable lithium polymer battery. Now search for the solder pads where the two earpieces are connected. De-solder those wires.

Take some thin wire and re-solder on the pads from where the wires were removed. Secure the connections. I chose not to remove the battery and let the bluetooth chip be powered with a separate one and not the main power supply. Finally place the chip and the housing back to their positions.

Making Connections With the Arduino

DSCN6160.JPG
DSCN6166.JPG
vlcsnap-error025.png
DSCN6214.JPG

Since we're going to place the arduino permanently inside the speaker enclosure, I am not going to use a shield. I had the male headers soldered already to the board to couldn't directly solder the wires.

I decided to use female headers and place them on pins that are going to be used, which in this case were Vcc, Gnd, 5v, A0, A1, D9, D10 and D11. After placing them, solder the respective wires and secure the connections, first with heat shrink tube and then with a little bit of hot glue.

Solder RGB LEDs in Parallel and Glue Them in Place

DSCN5941.JPG
vlcsnap-error493.png
DSCN5952.JPG
DSCN6120.JPG
DSCN6127.JPG
vlcsnap-error497.png
vlcsnap-error486.png
DSCN6146.JPG
DSCN6155.JPG

We'll have 4 RGB LEDs in the front which will be connected to arduino and will react to music for the disco light effect. So take some rainbow wire and start soldering them in parallel as show in the pictures above. Parallel means the common lead of all LEDs should be connected together. Similarly, the red, blue and the green leads are also to be connected together. Add an extra piece of wire on the first LED for each lead.

You will also have to make sure if your LEDs are common cathode or common anode. In my case they were the latter.

Do All the Necessary Wiring

BT speakers.png
DSCN6232.JPG
DSCN6198.JPG
DSCN6236.JPG
DSCN6194.JPG
DSCN6239.JPG
DSCN6248.JPG
DSCN6265.JPG
DSCN6185.JPG
DSCN6180.JPG

This one is a long process. After you have set everything up, start wiring the components. The switches, potentiometers, speaker, arduino and amplifier should be in place. The audio jack has to be soldered and will be placed later on the left panel.

Look carefully at the schematics provided above. Things can get messy, so use hot glue to secure each and every connection. Also, use heat shrink tubing to protect any joints. Some wires have to be kept open, which will be connected later. The bluetooth chip will also be wired later.

Prepare the Upper and the Left Panel

DSCN6306.JPG
DSCN6308.JPG
vlcsnap-error986.png
DSCN6268.JPG
vlcsnap-error611.png
vlcsnap-error346.png
vlcsnap-error729.png
DSCN6275.JPG
DSCN6290.JPG
DSCN6297.JPG

With most of the wiring done, you can now proceed towards placing the upper and the left panels. But first you need a drill a hole in the left panel for the audio jack. Make it big enough so the jack fits easily.

Next, mark the placement of the bluetooth chip on the upper panel. I chose to expose it because it had the buttons for on/off, play/pause/call pickup, volume control and next/previous song + a built in microphone. You can even place the chip inside the enclosure. I had to drill 2 holes for the wires to pass through. Stick it in place using some hot glue.

Stick Both the Panels

DSCN6321.JPG
vlcsnap-error335.png
vlcsnap-error393.png
DSCN6335.JPG
vlcsnap-error560.png
vlcsnap-error515.png
DSCN6324.JPG
DSCN6350.JPG
DSCN6357.JPG

Stick both the panels on their respective places using super glue or wood glue.

Connect the Bluetooth Board to the Main Circuitry

DSCN6364.JPG
DSCN6374.JPG
vlcsnap-error933.png
vlcsnap-error597.png
vlcsnap-error934.png
vlcsnap-error481.png
vlcsnap-error567.png
DSCN6401.JPG

Now we have the bluetooth chip in place, so connect the L and R wires to the top 2 pins of the switch.

The solder the Gnd wires to the Gnd of amplifier board and the Gnd pin of the audio jack.

Fix the audio jack as well, to its respective place.

Upload the Code

DSCN6493.JPG

Upload the code attached below to your arduino board. Make sure you choose the correct board, processor and the com port. You need not disconnect anything. Just plug in a USB cable.

<p>int threshold = 0  ;</p><p>void setup()
{
  pinMode(9, OUTPUT); // set all the pins as output
  pinMode(10, OUTPUT);
  pinMode(11, OUTPUT);
  }</p><p>void loop() 
{  // enter the loop</p><p>threshold= map(analogRead(A0), 0, 1023, 0, 100);</p><p>if(analogRead(A1) > threshold) // check if audio signal goes above threshold
 {
   int a = random(1, 6); // store a random number
   
   if(a == 1) // glow red
   {
     digitalWrite(9, HIGH);
     digitalWrite(10, LOW);
     digitalWrite(11, LOW);
   }
   if(a == 2) // glow green
   {
     digitalWrite(9, 0);
     digitalWrite(10, 1);
     digitalWrite(11, 0);
   }
   if(a == 3) // glow orange
   {
     analogWrite(9, random(100, 255));
     analogWrite(10, random(100, 255));
     digitalWrite(11, 0);
   }
   if(a == 4) // glow cyan
   {
     digitalWrite(9, 0);
     analogWrite(10, random(100, 255));
     analogWrite(11, random(100, 255));
   }
   if(a == 5) // glow purple
   {
     analogWrite(9, random(100, 255));
     digitalWrite(10, 0);
     analogWrite(11, random(100, 255));
   }
   if(a == 6) //glow blue
   {
     digitalWrite(9, 0);
     digitalWrite(10, 0);
     digitalWrite(11, 1);
   }
   delay(100); // wait for 100ms
 }
 else
 digitalWrite(9, HIGH); // if audio signal is less than threshold, set all the pins low
 digitalWrite(10, HIGH);
 digitalWrite(11, HIGH);
 // again reach the top and start
 
}</p>

Make a DIY Battery Holder

DSCN6438.JPG
DSCN6443.JPG
DSCN6448.JPG
DSCN6453.JPG
DSCN6466.JPG
vlcsnap-error296.png
DSCN6478.JPG
DSCN6486.JPG

The 18650 battery holder was not available at my local electronics store, so I decided to make my own. I didn't opt for battery packs as the batteries have to be removed for re-charging.

I found this video on YouTube and tried making my own, which turned out to be perfect. Use a safety pin to make a coil out of the sharp end. Since we have three batteries, make 2 such connectors where the positive terminal of one battery will be connected to the negative terminal of the other one.

Be accurate with your measurements. Cut 4 wooden pieces for the borders and stick them to the back panel.

By cutting a pin into two halves, one has to be used as the positive terminal and the other one as the negative one. Solder a wire to each one of them.

Paint

DSCN6496.JPG
vlcsnap-error491.png
vlcsnap-error353.png
DSCN6503.JPG
vlcsnap-error148.png

I used brown enamel paint to give it a glossy touch. The finish is good but it takes too much time to dry up.

It will take atleast 2-3 coats of paint.

Finishing

vlcsnap-error028.png
vlcsnap-error881.png
DSCN6561.JPG
vlcsnap-error823.png
DSCN6511.JPG
DSCN6515.JPG
vlcsnap-error470.png

The last step is, to add a knob to both of the potentiometers.

Finish the project by soldering male jumper wires to the power input wires and female jumper wires to the battery pack so that the wires may be disconnected at any time. This will also make the back panel easily removable.

The End

DSCN6674.JPG

This brings the 27th instructable to an end. The paint had not dried completely when I took the pictures so sorry if they're looking bad.

I will try to be more active now onward, with more cool DIY projects.

Share this project with your friends and hit the follow button if you like it. Be creative and try making modifications.

Leave a suggestion or feedback in the comment section below.

Thanks for watching :)

Adios!