Introduction: Arduino-based Connected Wake Up and Ambient Light

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

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.



SebastiaanJansen made it!(author)2017-01-22

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

berlingozzo made it!(author)2017-01-22

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!


SebastiaanJansen made it!(author)2017-03-16

Indeed, something like that, a linear interpolations the values in between

gluharew.alexandr made it!(author)2017-04-27

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)?

BinhN41 made it!(author)2017-04-21

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 made it!(author)2017-02-20

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!

berlingozzo made it!(author)2017-02-21

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.

JohnnyR53 made it!(author)2017-02-02

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

berlingozzo made it!(author)2017-02-03

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,


About This Instructable



Bio: 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 ... More »
More by berlingozzo:Arduino-based Gyroscope-controlled Glass Desk Light"Paper Heart": a Paper-only Stellated Icosidodecahedron"Heart of Glass": Arduino-based remote bluetooth Heart Rate (HR) display
Add instructable to: