Introduction: Recycled Spool Smart Lamp - With Sound Reactivity, MQTT, Hue & Alexa

I’m Lewis, and this is DIY Machines. In this Instructable I get to show you step-by-step how to build a 3D printable project whilst recycling our empty filament spools into a smart ESP32 powered, low cost lamp.

Over time I have collected a few empty spools which for some reason always seemed to good to just let the local council recycle them. Now it’s time to make something with them.

A filament spool lamp is not a new idea, but I wanted to add some additional features using the ESP32 tucked away inside the base which allows for some cool sound synced shiny shows or MQTT, Hue and Alexa integrations.

Naturally, this can be controlled from any device via wifi using WLEDs web interface or several free apps found on the app stores. Though sometimes it’s easier and quicker to physically adjust a lamp so I’ve integrated a discrete dimmer control right into the top of the project which allows you to easily adjust the brightness or switch the lamp off whilst a hidden button on the underside lets you change between your preferred lighting patterns with a click, whilst a longer hold switches over to sound sensitive party performance mode!

I used broom handles for legs which makes this very affordable, and everything else is 3D printed.

I’ll also show you three ways of dealing with the power cable, leave it free hanging from the centre of the lamp, 3D print some wire clips to hold it alongside one of the legs or hidden (recessed) inside one of the legs for the smartest and cleanest look.


Step 1: Video

As with all my project I have also created a detailed project build video which you can watch above. Below I have also laid out step-by-step instructions with photos as well so you can follow along in your preferred way. 🙂

Step 2: BOM / Supplies

As a fair few people have asked in the past for other projects I created (you can find them all here on Instructables) I have put together a kit of the electronic parts for this project on Etsy: https://www.etsy.com/listing/1444900974

Here is a list of individual items used in this project and where to find them if you're struggling:


12v Power Supply (allow 0.7amps at least for every 10 LEDs):


The Projects PCB can be found on this projects page on PCBWays website: https://www.pcbway.com/project/shareproject/Filament_Spool_Smart_Lamp_Hue_MQTT_Alexa_Sound_Reactivity_ESP32_Fusion_a26b7125.html

Step 3: Parametric Fusion 360 Model

Now you may be thinking correctly that filament spools come in all shapes and sizes. So to accommodate this I have designed and freely published a parametric model which you can download - you then simply update the values for features such as:

  • Spool diameter
  • Spools internal height
  • Leg material thickness
  • Number of spools used
  • Diameter of spool's core

Into a table and the model will adjust and produce the parts you need to print for your own lamp.

You will need copy of Fusion 360 to be able to edit the model for this project. If you already have it, great. If not, you can download a free version for personal use here: https://www.autodesk.co.uk/products/fusion-360/personal

After you have access to Fusion 360 sorted we can go ahead and download the project file for the lamp using the link attached to this step.

Once you have downloaded the project file we will need to upload it to Fusion. This is simply a case of choosing 'File' -> 'Upload' from the main menu

Locate the project file you dowloaded and choose a location in Fusion 360 to save the upload. When the upload process has completed we can go ahead and open the file to begin some super simple editing.

At the top of the menu bar is a button which opens a table for editing parameters - it looks like an italic 'fx'. Pressing this will reveal the table of parametric values.

In this table you can update the value under the column titled 'Expression'. As you update the values you will see the model updating itself to reflect the changes. (All values can be updated but I would not adjust 'AngleOfLegs' or 'DistanceLegsFromEdgeOfBase' unless you are confident in updating features and sketches in the timeline of the model as these are most likely to 'break' the design intent of the model.)

After you have finished updating the dimension in the table you can export individual parts from the model as STLs and then take these to your slicer of choice to prepare for 3D printing. The easiest way to do this is to click on the part / body you wish to export. Then in the hierarchy on the side you will see a squiggle (1) showing you where the part you have selected reads, expand the tree until you find the part nested inside the 'Bodies' folder'. You can then right click the part (2) in the hierarchy and choose to 'Save as Mesh' (3).

Step 4: 3D Printing the Feet

The first part we can print are the the feet for the legs.

Usually I would include an STL model with each step for you to print but I have not done this for the project as it is intended for your to generate your own parts using the Fusion 360 model supplied in Step 3 above.

I used PLA filament for mine. You will need three of them.

If you intend to recess the power cable inside one of the legs then swap out one of the standard feet for the powered foot design included in the Fusion model - this one includes a hole to accept the power cable.

Step 5: Cutting the Legs

Whilst they print you can cut the leg itself down to whatever size you prefer, short ones can make for a nice table top lamp whilst longer ones can make for a more striking floor lamp. I used wooden broom handles, you can use wooden dowel rods, clear acrylic tubes, plastic pipes or anything else you choose.

If you want to conceal your power cable you’ll need to create a rebate in one of the legs (or choose a hollow pipe like material). You could create a temporary jig out of scrap wood to hold an oversized leg whilst grooving it on with great care with a table saw or, as I did for my desktop lamp, 3D print some end holders and have a CNC machine route out the centre line - I used my Snapmaker for this.

This is where the power wire can then be concealed.


Step 6: Attaching the Feet

We can then attach the feet with glue - I’m using hot melt as gravity is working in our favour to help keep them together. It also allows me to rework it if required to keep everything level.

If you're concealing your power cable ensure it is already installed inside the leg with about 15cm of free wire protruding from the other non-footed end of the leg. 🙂  

A quick tip: If you’re using a natural material like wood which may have some blemishes, turn that towards the inside of the leg.

Step 7: Printing the Base of the Lamp

Next up, we can print the base of the lamp. I recommend choosing a concentric infill on your slicer which should improve the finished appearance of the print. This is also the only part which will require supports to be enabled.

Once the print is complete you can carefully remove the support material in preparation for the next step.

Step 8: Attaching the Legs to the Base

Note: If you are concealing the wire inside one of your legs it should go into the leg hole which has an opening to the other side of the base. If not it does not matter which leg goes where. 🙂

To attach your legs to the base we can use some hot melt glue again. Try to ensure you keep everything level as you go (do this be inserting the legs the same amount into the base and and keep the feet correctly rotated so that they sit flat on the surface).

You can verify this with a spirit level.



Step 9: Adding the Power Connection

You have one of two tasks for this step depending on if your using the barrel connector or a concealed wire:

  • If you’re using the barrel connector attach this now by inserting its wires through the central hole from beneath the base of the lamp. The nut and washer and then added from the top side to secure it into place.
  • If your using concealed power then you can now trim your wires coming though to the base from the leg to about 12cm in length.

I’m going to conceal my wire in this lamp so will remove my barrel connector (so you won't see it in the remaining photographs). But for the rest of the project the wiring for the power is identical, you’ll either use the two wires from the power connector, or the two concealed inside your leg.

Let’s set this base aside for a short while and begin work on the lamp itself.

Step 10: Trimming the LEDs to Length

Next we’ll add the LEDs to our spools, but before that I want to impart some wisdom. The WS2811 LED can be cut at certain points marked every three LEDS, this is where you see a stack of three short horizontal copper pads (as shown in the attache images). You’ll also notice little black arrows showing the direction the data will flow from one group of three LED’s to the next. As we re-connect them later the arrows need to consistently be pointing in the same direction though our circuit. The power can flow in both directions through our strips. 

Wrap a length around a spool and then cut it off at the row of copper pads you think is best. I’m going for a slight overlap. Try to cut as evenly through the pads as possible. If there is some solder over the pads where you want to make your cut - this is fine, just cut through the solder as well.

Cut more of the same length for each of your spools. I’m using three spools on my table top lamp so I’ll cut three lengths.


Step 11: Prepping the LEDs

To make soldering the LEDs significantly easier it's a good idea to 'Tin' the ends of LEDs by adding some solder to each of the copper pads.

For the wires between each spools length of LEDs you will need a set of three wires about 13cm in length for each spool you are using. For my three spools that’s three sets of three wires.

Add a set of wires to both ends of your first strip. (If you’re only having one spool, only connect the incoming side of the LED strip.)

Solder a set of your 13cm long wires to the outgoing end your remaining LED strips. (Pay attention to those little black data flow arrows) This will leave you with one strip with no wires. This is fine.

So for my three spools I have one set of LEDs with wires at both ends, one with wires on the outgoing side and one with now wires.

Step 12: Adding the LEDs to the Spools

Attach your first strip around the centre of the first spool - the self adhesive backing was adequate for me. Pass the wires into the inner tube - you may need to carefully drill a hole if your spool has no suitable openings to pass the wires through. If you do need to add holes to access the inner tube I recommend repeating this on the other spools now for simplicity.

Grab your next spool and pass the wires from the first strips outgoing end (keep an eye on the little black arrows!) to the next spool.

Before we add the next rows of LED's we need to fix the spools together. To attach each of our spools you can choose between glue or mechanical fixings such as nuts and bolts. For mine, I’ve chosen Loctites All plastics super glue as it’s rated to work with Polystyrene which is what my spools are manufactured from. Once applied I used some clamps to hold it in place for a few minutes before carrying on with the next stage.

Now the glue has had a few minutes to cure we can remove the clamps and solder outgoing wires from the first strip onto the LED’s for the second spool.

These LEDs can then attached to the spindle of the second spool ensuring the start of this strip is aligned with the previous strips start and end. We can then continue adding spools and LEDs all the way up to your last spool which will use the LED strip with no wires pre-attached. 

Things are starting to take shape. 🙂


Step 13: Installing WLED

We will test the electronics before coming back to tidy the loose wires later. To continue the electronics we can first program the ESP32 with WLED.

The easiest way to do this is to navigate to https://install.wled.me/ in your browser and connect your ESP32 board to your computer via USB.

The version of WLED you install depends on how you want to use your lamp (you can always change your mind later and reprogram your ESP). Install the standard WLED if you prefer to use MQTT, Alexa or Phillips Hue integration. Select WLED-SR if you prefer sound reactive lighting features instead of the integration with MQTT, Alexa and Hue.

I'll be installing the sound reactive version of WLED.

Once you have chosen your version go ahead and press install. You’ll then choose the serial port for your ESP32 from the list presented. Press install, you’ll see a warning pop up - before you confirm the install command hold down the BOOT button on your ESP module. We can then press 'Install' and proceed with the install. When it starts erasing you can release the boot button and wait for it to complete the installation.

When it has completed go ahead and enter your wifi credentials on the following screen. After it has saved and WLED has connected to your wifi choose to ‘Visit Device’ and take note of its IP address as shown in the address bar of your browser as we will need this later.

Step 14: PCB Soldering - Part 1

We’ll be soldering our components to a custom PCB to help make everything incredibly easy to assemble. You can follow the links in the BOM at the top of this article to buy one if you wanted to - it drastically cuts down on wiring and holds everything in just the right place. Of course, if you don’t want to use the PCB you’ll find a wiring diagram in the images above for you to build your own circuit. :)  

Let’s switch our solder iron and start adding components, don’t be afraid, none of this is tricky soldering.

  1. The first component will be our 1k resistor. Simply insert its to legs through the holes on the PCB where it's marked as being for the resistor and solder in place from the reverse side.
  2. Our logic level converter is next, you need to align the semi-circle notch on the chip to the same markings as illustrated on the the PCB. Insert the feet and solder from the other side again
  3. The microphone is attached in the same fashion with the text labels found on both PCBs matching so as to get the correct orientation.
  4. The ESP32 is added with its USB port facing towards the outside of the PCB to make future updates easier.

Step 15: Setting the Buck Converter

Turning to the DC Buck converter next, we need to configure it to output 5v before we solder it into place.

To do this, connect the input (look on the underside of the device to see it's pin labels) to 12v and connect a multimeter to the output. Rotate the small potentiometer on the top side with a screwdriver until your reading is just a teeny tiny bit over 5v.

Done.

Fit it to the PCB and solder the legs on the reverse side again.

Step 16: PCB Soldering - Part 2

The 12mm high tactile button is installed with the outward bowing sides of the device aligning with the top and bottom of the PCB. Insert it on the front face (same side as all the other components so far) and solder on the reverse side.

For the potentiometer - which will allow us to control brightness using a dial at the top later - you will need to prepare three wires each as long as your stack of assembled spools is high plus an additional 20cm in length.

Solder these on reverse side of PCB and the other ends of the wire to the potentiometer paying attention the wire labeled as 'centre' is connected to the centre of the potentiometer - the others can go on either side. (This only effects which way you rotate the dial later to increase or decrease the brightness).





Step 17: Connecting the Power and Data

We can now connect our power wires. These are the ones coming from either the barrel connector or the concealed wires inside one of the legs. Like the Potentiometers wires, these are inserted from the rear of the PCB and soldered on the front side.

Be sure to double check you have the positive and negative wires the correct way around

Alongside these wires, we can also connect the power wires coming from our string of LED’s. Again, double check the polarity.

The final bit of soldering is for the data wire for the LED’s is connected to the hole labelled as 'LED-DATA' at the top. 

Pass the potentiometer though the centre of the lamp all the way out the top of the spool.

Finally, secure the PCB into place with the components facing downwards (so the mice and button can be seen from beneath) using three M3x8mm bolts

Step 18:

Let’s power on the lamp and test it whilst we can see our LED’s and can access our circuit to troubleshoot if required. Plug in your power supply and the lights should power on and light up with a purply colour.

If that's gone well you can go ahead and open web browser and navigate to the IP address we saved from earlier (when programming the ESP32). This should present the web-interface for WLED!

I prepared a config file which will set up most of the settings of your lamp. To do this download the file attached to this step and then in WLED:

  1. Open the config menu then click ‘Security and updates’.
  2. Scroll down and then select ‘choose file’
  3. Under the ‘backup configuration’ heading select the config file and upload it.
  4. Once these settings have been applied go back to the main screen and test different colours to confirm the settings have been applied.

There are a couple more settings to tweak which will be unique to your own build - the number of LED’s and 2D shape settings. 

The 2D Matrix 'Width' box needs to know how many little black IC’s you see on one strip going around a single spool, and then in the box labeled 'Height' we need to enter how many spools we chose to include in our lamp. I had three.

Next, further down towards the bottom of this page, we enter in the total umber of LED’s - in our design they are grouped in threes (so every three real LEDs are only seen as one in WLED) so simply multiply the two numbers we just input above (7 x 3 for me) and that’s what we’ll enter down here at the bottom.

Press save.

You should now be able to adjust the brightness by turning the potentiometer in both directions.

Pressing the discreet button underneath briefly will set the lamp to flow through colours.

If you opted to add sound reactivity to your lamp, then pressing and holding the discrete button for just over 2 seconds will set the lamp to a Sound Reactive pattern. Make some noise - if the lamp reacts we know our microphone and software is correctly set up.

Step 19: Assemble to Top of the Lamp

We can now print the top of the lamp and its associated dial cover which goes inside of this. As with the other large circular parts I recommend printing these with a concentric infill pattern to achieve the best top layer finish.

We can then install the potentiometer. This is inserted from the underside of the printed part so that the wires coming from the pot do not block the adjacent smaller hole. This hole is to be used to help remove the dial later if we need to. Secure the potentiometer with a washer and nut.

To attach the dial align the 3D printed divider on the underside in the hole with the slot in the top of potentiometer. This is then simply push fitted in place.

If it sits proud of the top surface and/or wobbles we can improve it. Use a tool to pop of the dial using that hole I mentioned earlier to you - remove the potentiometer and then use some washers or 3D print a ring to got onto of the potentiometer to space it away from the surface before reinstalling it - this will have the effect of lowering the dial.

You can reattach he dial and check it again - making further adjustments if required.

This entire assembly can be fixed to the top of our stack of spools with a suitable adhesive. I’m using superglue and some clamps to hold it in place for about 10 minutes.

Step 20: Attach the Spools and Base

We can then glue the base and legs to the stack of spools in the same manner as the top. You're an expert at this by now! :)

Step 21: Printing and Installing the Diffusers

Whilst that glue cures we’ll print the shades - one for each spool.You may need to try a few different filament materials and colours to find the optimum for your liking. It's surprising how much different manufactures, colours and materials can affect the quality and style of diffusion. I went for 3D Jakes PETG white.

Once the glue is cured again we take the diffusers and gently bend them open and pop them into position around each spool. You can glue these in place if you want to. I have only used glue to hold mine tighter together where they overlap.

Step 22: Managing the Power Wire

If you’ve not built your power wire inside one of the legs then you have a choice when it comes to managing it. You can either leave it hanging from the centre of the lamp - I chose a white power cable cable in this example to complement the other white parts.

Or, if you prefer you can print the cable clips included in the Fusion 360 model which will allow you to pin it along one of the legs as shown above.


Step 23: Project Completed!

If you have enjoyed this project please consider subscribing and liking this Instructable - It helps me out a lot. You may also be interested in my Geoleaf project or giant hidden shelf edge clock.

Thank you so much for joining me to the end, until the next project, take care, do some good, and ciao for now! :D


If your looking for more information on Alexa, Philips Hue and MQTT integration then you’ll find a link to WLED’s informative website where you can follow their up-to-date guides for integrations: https://kno.wled.ge/interfaces/mqtt/


Repair and Reuse Contest

Second Prize in the
Repair and Reuse Contest