Wireless Music Reactive Floor Lamps

51,432

539

56

Introduction: Wireless Music Reactive Floor Lamps

About: We are a couple that loves creative projects, and retro gaming. We will be posting anything that we make related to it, with DIY videos, crafts, projects, retro gaming, build logs and showcases. Make sure to …

In this instructable we'll be making some centrally controlled wireless RGB lamps, that responds to music and sounds in the environment! In addition to instructions, the instructable contains:

  1. Schematics
  2. List of components
  3. Link to the code so you can make and modify your own project

Step 1: Planning Ahead

Here are the major components I have used:

LAMPS:

  1. 4x LED-strips: http://bit.ly/144ledstrip
  2. 4x 5v Power Supply: http://bit.ly/5v50wpower
  3. 4x WeMos Wifi Board: http://bit.ly/5v50wpower
  4. Power plug: http://bit.ly/5v50wpower

CONTROLLER:

  1. Sound Sensor: http://bit.ly/dynosound
  2. Wi-Fi board, I used NodeMCU as I didn't have another WeMos D1. Wemos should work.
  3. Push Button: http://bit.ly/push1button
  4. Power Switch: http://bit.ly/powerswitch32
  5. Colored Diodes (blue): http://bit.ly/powerswitch32
  6. Li-ion battery: http://bit.ly/powerswitch32
  7. Battery holder: http://bit.ly/powerswitch32
  8. Charger module: http://bit.ly/powerswitch32

So I had this very clear idea in my head of what I wanted to create. I wanted a central (but portable) sound detector that could pick up surrounding sounds, and transmit them to lamps that could be placed anywhere inside a room, or even a house. Because all audio will be picked up by the same mic, the lamps should stay synchronous. Moreover, I decided to use a sound detector and not an audio jack (albeit I know many would prefer that option), because I wanted it to be completely wireless and also be able to pick up people singing, clapping, or whatever.


The pictures shows my first initial plans, and the schematics that I ended up using for the lamps, and the one I used for the controller.

Step 2: Creating the Lamp Fixture

The lamp "fixture" consist of two basic components:

* Aluminium channel to hold the LED-strip

* Acrylic glass to diffuse the light

The aluminium channels were 1 meters each, and bought at a hardware store. The acrylic glass I cut on my table saw to the width of the aluminium channel. To get the acrylic to diffuse the light, it had to be sanded down to get that frosted look, and also to smoothen the edges the table saw made. I started on 80 grit and gradually moved up to 600 grit.

Step 3: Adding the LED-strips

For this special purpose I am using an Individually Addressable LED-strip, which is also called a Neopixel. If you're not familiar with it, it's a type of LED-strips that lets you reference each diode separately. This allows for some fancy stuff, like giving different diodes different colors, or only lighting up parts of the strip.

I used the adhesive that comes on the back of the strip to fasten it to the aluminium channel, along with some hot glue to make sure it really stuck in there!

Step 4: Fastening the Acrylic Light Diffuser

Now we have to fasten the acrylic light diffuser to the aluminium light diffuser. This step is harder than it sounds, as the edges of the aluminium channels are quite thin. The best way I found was to use some quick drying epoxy on the edges, and hold it steady for about 5 minutes before attaching some clamps to hold it in place until it was completely cured.

Step 5: Beginning the Wood Base

The wood base will be made out of a slab of glued oak wood I bought at the hardware store. As it is quite thin, I will glue several layers together to make a block. I ripped strips of it on the table saw, and used the miter saw to cut 10x10 cm large squares of wood. Then I glued together pieces of two and pieces of 3 together. Once the glue was dry, I could take the 3-pieces high block and use a chisel to create a hole like a mortise for the light fixture. Here it is important to get a nice and snug fit so the lamp wont have much room to wiggle around.

Step 6: Finishing the Wood Base

For the second half of the wood base, the piece with 2 layers glued together, I used the drill press to cut hols in each corner. This is so I could fit the jigsaw and cut out a square in the room, as to make room for the electronics later in the process.

When I had finished the cutting in the upper and lower part, I glued them together before sanding them on the belt sander. Lastly I applied some oil to get the grain to pop.

Step 7: The Lamp Electronics 1

Wiring the electronics with the WeMos D1 Mini according to the schematic I have made, and then putting most of it on a perf board. I am using a LED-connector to simplify the connection to the LED-strip later.

Note: to get the most reliable signal from the Wemos to the LED strip, there is actually good to use a signal level shifter to up the signal from 3.3 volts to at least 3.5 volts. You can read more about it here: https://hackaday.com/2017/01/20/cheating-at-5v-ws2...
Personally it seemed to work fine without it, but I thought I might mention it in-case somebody runs into issues with my schematic.

Step 8: Power Supply

I will use a 40watt, 5 volt power supply. I used a set of connectors wired to the WeMos and to a power plug, so that power could be connected without any soldering, after the plug is inserted into the wooden base in the next step.

Step 9: Adding the Power Plug

Using a drillbit with the same size as the bottom part of the power plug, I drilled into the bottom of the lamp base. using a mallet i pushed it in place. Now you can see it will be quite easy to connect the power, as we have the power connector already soldered to the plug!

Step 10: Final Touches to the Lamp

Okay, time to add the lamp fixture to the base of the lamp. For this I used some quick drying epoxy around the entire fixture, before placing it into the wooden socket. To fasten the electronics I put a small amount of hot glue on the underside of the perfboard, and mounted it with the USB port facing downwards so it would be easy to program later. I connected the power connectors to each other, and the lamps are done! Next up is the controller!

Step 11: The Controller

The first picture shows all the components I used for the controller. They are all listed in the beginning. I used the same techniques as in the lamp base to create the controller box, except there are only 3 layers of wood, where the bottom 2 are hollowed out, and the top one is solid. It's important that the hole in the controller is big enought to fit the battery holder!

In the top plate I traced the microphone holder and drilled a hole with wings that could fit it smoothly!

Step 12: The Pushbutton

To change modes of the lamps, and to indicate if the controller is on or of, we will use a push button lit by a blue led diode. For this I used a push button component to provide the electrical interface to the Wi-Fi chip, but for the actual thing to push on I used a clear gameboy button. I filed away all unevenness from its surface, and drilled a hole in the middle of it. Then I used some hot glue to attach the led diode. With the drill press I drilled a hole big enough to comfortably fit the button. After soldering the electronic push button component to a piece of perfboard (and according to the schematic in the top), I attached the gameboy button with the LED-diode on top of the push button. This way one can click the gameboy button to trigger the button it is glued to!

This assembly was glued into the hole attaching it from the perfboard, on the underside so that the gameboy button would stick up from the hole.

Step 13: Charger Module and Sound Detector

I wanted the charging module to stay flush with the base of the lamp, so I marked its outline and traced it with a pencil. Then I used the chisel to make it sit flush against the wood. In accordance with the schematic,the battery is wired to the charging module, and connected to the Wi-Fi board through the power switch. The LED and push button is connected to the Wi-Fi board. For the sound detector I used some jumper cables, and also soldered it to the correct pins on the Wi-Fi board.

I put all of this inside the box, and glued the charging module in place using some quick drying epoxy.

Step 14: Finalizing the Controller

On the top of the controller I drilled a large dimple in the wood around the microphone module. I will add some fabric there later to hide the module. To cover up the electronics I traced piece of thin veneered balsa to the size of the wooden block. I marked the corners where I would put some legs for it to stand on. I also traced the outline of the power switch, and chiseled out a hole for it. It was very satisfying to plop the power switch in place!

For legs I am actually using some nice looking drawer knobs. To connect the power switch to the power cables, I used some good old cables shoes and crimped them to the cables. This makes it easier to disconnect the entire bottom plate if there is need for maintenance! I used two small screws to hold the bottom in place, which can easily be removed for quick access to upload new pieces of code to the Wi-Fi board.

Finally I added some oil, and cut 3 layers of insect net to fit into the little dimple I drilled in the beginning. And the controller is complete, all that remains is to upload the code to the lamps and the controller!

Step 15: Code and Finished Pictures!

The code I wrote for this can be viewed here: https://github.com/hansjny/Natural-Nerd/tree/maste...

There is one program for the controller, and one for the lamps. It's not perfect, so feel free to improve it and come with pull requests!

The basic operation procedure is like this:
1. The controller creates a new wireless network and waits for connections.

2. The lamps connect, one by one.

3. The controller detects that all lamps have connected, and begins sending out data. It has different operation modes, which can be changed with the button click. In the sound reactive mode, it sends data from the sound detector.

4. The lamps receive the data, process it and dance a bit. It works pretty good. I'm not all too happy about the colours, so I will probably update it and make it behave a bit more interesting if I have time!

Make it Glow Contest 2018

Second Prize in the
Make it Glow Contest 2018

3 People Made This Project!

Recommendations

  • Mason Jar Speed Challenge

    Mason Jar Speed Challenge
  • Bikes Challenge

    Bikes Challenge
  • Remix Contest

    Remix Contest

56 Discussions

0
Timo010
Timo010

7 months ago

I have upload t he code to wemos and NodeMCU number of client 1(master) and slave lamp_id 1

when I serial monitor and power my wemos with a 5v power supply I received a commands on the NodeMCU ip adress and the changeing modes 1 to 3

my RGB lamps are not on I checked already the pins and thats oke, is there anything else to solve this problem

0
xMarkk
xMarkk

Reply 6 months ago

It is hard to help you with this little information.

But if you checked the serial monitor and it is okay, than it sounds like a wiring problem.

0
Timo010
Timo010

Reply 6 months ago

the serial monitor is okay only my lets do not light up, i think the are defect

0
xMarkk
xMarkk

Reply 6 months ago

You could try one of the pre programmed fastled sketches to test the leds.

0
Timo010
Timo010

Reply 6 months ago

hi everything works , but how can i add more cases? I tried something but it didnt work. do I need to change the buffersize?
and have you maybe an example?

0
xMarkk
xMarkk

Reply 6 months ago

Thats great!

I’m not that ... in coding but I was able to add an extra effect.

In the master you need to add an extra case and in the slave aswell (with the code for the effect)

0
JacksonLGB
JacksonLGB

Reply 14 days ago

can you show me how to add an extra case ? I am waiting for your reply.
please send the detail extra case code to my email VIP1683@163.com.thank you very much!

0
Timo010
Timo010

Reply 6 months ago

Hi I have a last question everything is working but when I am in sound reactive mode the lights are not reaching the top! in the other modes they are.

when I use 1 of them so 1 ID and 1 client in master then the only 1 is reaching the top

20200311_154043.jpg
0
JacksonLGB
JacksonLGB

Reply 22 days ago

i have the same question that in sound reactive mode the lights are not reaching the top! in the other modes they are.
have you solved this problem?

F62C7400-DD73-4228-AF10-EFDA2A17A8D8.png
0
Timo010
Timo010

Reply 6 months ago

yes oke so if have to change the numopmodes to 4

and then I need to add a case in master and slave aswell?
thanks for helping me you are the only one!

0
eaarrestad4
eaarrestad4

5 months ago

Hi. I have been trying to make this project work for some while now and it stops at the same place every time.

I have managed to get the Led Slave to work and it has a green light, but i can't make it connect to the Led Master.
If i change the ssid and password to my home network the led turns blue, but it still wont connect to the master.

I hope that there is someone here that can help me.

led lys.PNG
0
JacksonLGB
JacksonLGB

Reply 14 days ago

i think you should change your ssid to a simple name so that it can be detected and be connected easily.

0
Doriginalsaddis

Hey, first things first. great project and thank you for allowing me the opportunity to get into my first arduino project. That being said I have an issue and would like to get some guidance.

1. on the sound reactive mode it occasionally freezes and resets the controller. I don't know why it does this. all my wiring is free of shorts so i can only assume its something to do with a code problem (which is not my strong suit)

2. in the new cool fade option i have a (personal) issue with the loop. it seems as though it almost flashes from the last colour for a micro second. it feels rather jarring especially since its more of a relaxing fade function.
I am also looking into adding some other workings and ideas into the code aswell to make it unique and also help the "Community" aswell

any information i could provide to make the resolve come about quicker and easier i will provide.
stay safe everyone.

0
pixelfuzzi
pixelfuzzi

5 months ago

Hi There
I build this Project and i am struggle with that Button. It seems that in my case at the d1 Mini (clone) the Button between D1 and GND isnt working. i didnt use the LED. the schematic is a little bit confusing i think

The COM Monitor says:
Connect and the LEDs are doing something.
I Also use direct Audio in to the D1 Mini Master. My Microboard was terrible (check the Youtube Chanel and the comments there, the Red ones are very bad)

what i am planning to do is a "SYNC" LED on Master and Slave to show me, that the connection is setup.

But first: die Button must work

thanks for help and staysafe@home ;-)

0
dss247
dss247

5 months ago

Good day all, I have not been able to get this project running because I can't wrap my head around the Arduino code for the master and slave entries.
I have bought and assembled the exact same parts as Nerdforge's video except I made 4 one meter strips of 144 led's instead of 3.
Is it possible for someone to help me out and post the complete code, or email it to me, so that I can enter it to get this project up and running.
I think once seeing the code when it's running it would help me make more sense of the learning the code.
Thanks in advance
Cheers

0
snowypeaks543
snowypeaks543

Question 7 months ago on Step 3

This project is awesome but I'm having some difficulty and hoping you can help, despite the project being a bit old.

#1; first, the schematics are difficult to understand. I'm assuming you're using the Wemos mini on all parts; lamps as well as microphone. The picture of the wemos board in the 'Sound Reactive Controller Schematic' is not correct. There is no VIN pin, there are not two separate GND pins, D1 and D0 are not next to each other like your photo shows. I'm confused by this, am I using the wrong board? Is this an older board? can you just wire nut the two separate grounds and use one pin?

#2 The push button aspect of the schematic doesn't make sense. I've read through most (if not all) of your different write-ups on this (here, YouTube, etc) and you kind of seem to skip over this part. I'm using the same button you are using, but it has 4 connectors. Can you show an actual (drawing maybe?) picture of exactly how the wiring is?

I'm really intrigued by this project and grateful of the time you've taken to get us all here. You (both) seem really cool. Thanks for any help.

0
xMarkk
xMarkk

Answer 6 months ago

Hi there. I'm also trying to make this awesome project. But i hope i can help you with your questions.

#1; For the 'Sound Reactive Controller Schematic' he is not using a wemos but a: nodemcu. But a wemos will work. Just check the correct pins.

#2; Check these 2 links, hope it make sense.
- Gif 1
- Gif 2

0
snowypeaks543
snowypeaks543

Reply 6 months ago

Thanks for your time! I think I've got the button wired correctly now. When I push the button the tiny blue LED's on the Wemos board turn off/back on. The serial monitor shows this: "⸮⸮⸮⸮⸮ tx⸮hd$⸮xOH⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮⸮" and is continuing to add question marks every second. I'm fairly certain the code is correct, and my issue is a wiring mishap. I'm not sure how to check each direction (transmit/receive) of data and move forward from here.

IMG_0150.JPG
0
snowypeaks543
snowypeaks543

Reply 6 months ago

also, I just had the first LED on one strip light up solid green, but after restarting everything it hasn't come on again.

0
ticasso
ticasso

1 year ago

Hi and thanks a lot for this EXCELLENT project.

I'm just having a little trouble.

The connection is OK between my NodeMCU (master) and the Wemos (slave).
I added a “print” and the wemos detects the change of the button.

By cons, I have no blue or green led to the connection ... and the LEDs do not light. I tested
D2 and D4, for the D-IN led, but nothing n done.

How is it possible to verify that the microphone send well a value in case it would come
from the input ... and not from the output

The wemos serial show in loop : Sending heartbeatReturned: 8, also sizeof hbm: 8

Thanks Again