Arduino-based Connected Wake Up and Ambient Light




About: The opinions in my posts are personal and not necessarily shared by the company I work for. Sometimes I don't agree with myself either. PhD in Computer Science and Engineering.

Hi all,
Hope you like this Instructable. If you do, please consider voting for it using the "Vote!" Button that you see on the top right of this frame (if you are on a computer), or on the bottom of the page before the comments (if you are on a mobile device). Then click on "Vote" for each of the three contests where I'm involved.

For the "Arduino" contest, please assess the use of the microcontroller and the automation.

For the "Make it glow" one, please assess the overall glowing result (check the videos as well).

For the "Remix", please assess the re-use of other projects and ideas, mainly taken from this other project: plus the concept of the Philips wake up lights:

Thanks! :)



Arduino-based connected wake up and ambient light. I can set an alarm and a duration, and the lamp will mimic the sunrise starting at (alarm-duration).

As for my first Instructable, I wanted to build a project having in mind three objectives:

1) it must be useful: many projects we can find on Internet are scientifically challenging, and many times they are cool&fun. But they may miss the long-term usefulness, or large audience impact. I wanted to build something me and my family would use everyday, so that readers would find it useful too.

2) it must look cool: I didn't want to end up with something which looks patchy, ugly, that nobody would like to show in his/her own house. Something as close as possible to a real product.

3) it must be fun: this is really for the builder :) something which you'd enjoy replicating and playing with, while meeting the criteria above. I tried to fulfill the above as much as possible, you're the judges, your views, favorites, and votes will be my measure of success! :) enjoy!


I like the idea of being gradually awakened by a combination of light and sounds, instead of by a loudly buzzing alarm that I'd only want to throw out of the window every time :) Then, why not adding some other features, like making it an ambient light, controllable by a mobile app (via http) ?


I used the following components, scroll down for the building steps:

1) 1m ws2813 rgb LED strips:

get the non waterproof version, with 60 leds/m. Note you can do this with ws2812 and ws2812b LEDs as well, the light will be exactly the same and these are cheaper. The ws2813 are just more reliable, as they have a redundant data connection, so if you break one LED, the rest of the strip will keep working.

2) an Ikea Fado lamp:

This was 15€, roughly 18$.

3) as wifi-enabled micro-controller, I have used a Wemos D1 mini:

4$, or roughly 3.5€

4) one 5v, 2a power supply, soon to be replaced with a 3a on

This was 3.5$. Note that you'll have to reduce the maximum brightness unless you use a power supply with at least 4A.

5) some spare dupont cables

Teacher Notes

Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.

Step 1: Bring the Correct Current Inside the Lamp

Remove the plug at the end of the electric cable from the Fado lamp. This will expose the two cables that you can plug in a barrel adaptor that you'll attach to the power supply.

Inside the lamp, place (read: solder) two dupont cables to the positive and negative of the lightbulb holder. Put the other ends of the dupont cable inside the positive and negative of a barrel jack where you'll insert the other cables as in the next step.

Step 2: A Bit of Wiring

Take the Wemos D1 mini. It comes with no soldered headers. You can go ahead and solder them, or you can do like me: place the headers from the bottom, and insert the dupont cables from the top. There is enough friction to keep everything in place.

With dupont cables, connect the 5v pin of the Wemos to the positive of the barrel jack, and the GND pin of the Wemos to the negative of the barrel jack.

Do the same for the LED strip.

Then connect the green data cable from the LED strip to pin D2 of the Wemos.

Place a capacitor (mine is 1000uf) in the barrel jack, baring in mind the positive and negative pins.

Step 3: Fit the Led Strip

This is the most "difficult" part. After securing the Wemos to the side of the lightbulb holder, you need to roll the LED strip in a way that it will stay together, and that it distributes the light. You can use the bi-adhesive behind the strip to do this.

I made the first lap by sticking the adhesive to the base of the Fado. Then I started going up. On the top, I inserted a spare long screw I had into the lightbulb holder, so it can hold the top of the LED strip.

Insert everything into the glass top and double check that it held all the connections.

Step 4: Program the Wemos

Upload the attached file to your Wemos via the Arduino IDE.

Replace these two lines with your appropriate credentials:

const char* ssid     = "YOUR_WIFI_HERE";
const char* password = "YOUR_PASS_HERE";

You can then control the lamp via http, using the parameters in the url, as specificed in the code, for example:


will turn on the light with a fixed color (color #17). Now, I send the controls via the mobile app I have created for this lamp, and another two from other two projects of mine, though the mobile app is out of scope for this tutorial.

You'll see the mobile app in the video.


Arduino Contest 2016

Runner Up in the
Arduino Contest 2016

Make it Glow Contest 2016

Participated in the
Make it Glow Contest 2016

Remix Contest 2016

Participated in the
Remix Contest 2016

Be the First to Share


    • Made with Math Contest

      Made with Math Contest
    • Multi-Discipline Contest

      Multi-Discipline Contest
    • Robotics Contest

      Robotics Contest

    13 Discussions


    2 years ago

    Very cool project. One thing you can add is a lerp function to switch between colors more smoothly.

    2 replies

    Reply 2 years ago

    Hey, I haven't thought about it, it's a nice and simple idea! you mean like a 500ms animation where I first compute the difference in each of the R,G,B values, then I divide it by 50, and every 10ms I make one step of morphing.
    I should try this asap!



    Question 1 year ago

    The phone has to be connected to the system somehow to wake you up?
    Or if you programmed once, it will wake you up without the phone?

    I am maybe new for the instructables site, but I also have problems finding the program what I could upload to the Wemos, and the application for the phone to control the light.

    Thanks forward!



    1 year ago

    Hi Thanks for your tutorial. Where can we find the ino file? I am struggling with defining the port, seems that arduino and wemos port don't match the pin. Thanks for your help


    1 year ago

    Hi, this could be an interesting project - could you give the link for your code too perhaps?


    1 year ago


    First of all, a very good project,I love it.

    The question, where can I find the *.ino file?

    Thank you very much.


    2 years ago

    Hello, cool project, I really liked. I want to try to make a home. Tell me where you can download the mobile application and the program code for the controller (sketch for Arduino IDE)?


    2 years ago

    Is there an instruction for how to write the mobile app for this project? Or where can I find the app? Nice project btw!

    Maker Saga

    2 years ago

    Red light doesn't mess with the natural sleepiness inducing hormone, melatonin much. Blue light does, in an unhealthy way as a stimulant. Maybe that knowledge could be utilized somehow. Just putting that out there. Nice work!

    1 reply
    berlingozzoMaker Saga

    Reply 2 years ago

    Thanks! Indeed, the waking-up color used in this project is a kind of white, so it contains all the R, G, and B components, while at night we usually use it in warmer colors like red / pink / orange, anything not containing blue.


    2 years ago

    hello i really like your project but i have a few questions any chance you cans show better pictures of the conections, also did you use the entire 1m of leds? can the WEMO handle so much current? i have been reading and everywhere it says that the LEDs need to be connected separatly. thanks

    1 reply

    Reply 2 years ago

    Hi, thanks!

    What connections in particular are you interested in? Yes I have used the entire meter of leds, but I set the max brightness to half in the sketch. 60(leds) * 60(max milliampere per led) * 0.5 (half brightness) = 1800 milliampere max, i.e. 1.8A. My power supply is rated for 2A, plus I never really use pure white (which would be 60 milliampere per led), so I'm usually at around 45-50 milliampere max per led. That makes it 1.5A max used. The Wemos probably takes another 500mA max (only when using wifi), so I'm below my limits. Plus, I'm waiting for a 4A power supply to arrive, that would change the story anyway :)

    In terms of power to the led strip, I don't give it through the Wemos. I only connect the data cable to the Wemos. The power is taken directly from the power supply. Look at the picture, there is a barrel jack adaptor where I stick all the power and ground cables (plus the capacitor).

    Hpoe it helps,