Automatic Led Stairs Controller





Introduction: Automatic Led Stairs Controller

This instruction is how I assembled my Automatic Led Stairs Controller.  

What Is a LED stairs controller?
The video shows how it works!


Step 1: The Idea

Many of you have already seen such controllers and a lot of people assembled something similar to it, but I will show you my version.

The main idea was taken from  Alan's Parekh video, many thanks to him.

The idea was this: When I get up at the middle of the night to get some food, I have to go down the stairs from the top floor and then up the stairs again. One day I've decided I need an automatic backlight so I don't  turn all the lights on and wake my family up. Plus I wanted a nice smooth turning on and off so it doesn't irritate sleepy eyes. Also the device had to be error-resistand, ignore sunlight, remotes and other things.

And so in order.

Step 2: Electronic Components

At first I was going  to use an Arduino, but then I've decided to make an individual device.
The heart of the controller is an atmega16a-pu chip which has a lot of outputs.
As for load control (12V 1W or more), I've used transisters 2sc2655 as they are powerful enought for what I needed.
For LCD i'm use LCD 16x2 (HD44780 chip)

The sensors I first thought to use was version of the IR lED and IR Transistor, but the distance within it's sight could not get more than 1 meter, so it was decided to use TSOP1838 + Modulation 38kHz .

To power this all up I've used the converter LM7805 + Heat Sink.

Resistors and capacitors you can see on the motherboard of the device.

Step 3: The Algorithm Works

The algorithm itself is quite simple.

The task was as follows.
When crossing the infrared beam at the bottom of the stairs - the LEDs smoothly light on upwards.
When crossing the infrared beam at the top of the stairs - the LEDs light on down smoothly.
In case when both beams are crossed at the same time- all the LEDs light on smoothly

After a certain time, preset using the display and the keyboard the LEDs light down smoothly in the same direction, in which it has been turned on.

All the delays are set and controlled by the display.
Several iluminating effects can be find in the menu. 
And the choice of outputs (1 to 16)

The program was written in CodeVisionAVR.
I will not post the whole code , but here are some main points:

unsigned char mask;

void processUp(){
if(datUp==0) {
    for (mask = 0x01; mask; mask <<= 1)
        PORTC |= mask;
        wait1();   /

    // delay
    wait1();   // delay before lighting down

    //now lights off (in the same direction)
    for (mask = 0x01; mask; mask <<= 1)
//   for opposite direction:
    //for (mask = 0x80; mask; mask >>= 1)
        PORTC &= ~mask;

Step 4: Finish

Here is how the completed device lookes like. Originally I was going to order two PCBs, but the minimum order quantity was equal to 10, so I am happy to sell the rest. For details please visit link ( .

Thank you for looking , I now have my first instruction posted! If you have any questions , please feel free to write it in a comment section below. I will answer to all of you!  



    • Pocket-Sized Contest

      Pocket-Sized Contest
    • Pro Tips Challenge

      Pro Tips Challenge
    • Paper Contest 2018

      Paper Contest 2018

    We have a be nice policy.
    Please be positive and constructive.




    I ordered this board and started my project ..

    However I wanted
    to wire RGB LED strips lights rather than individual LEDs for each
    step, the board will light the steps when it is set to program 3 (manual
    - ALL stairs on all the time) but seems to be having all kinds of
    problems - the sensors do not seem to work at all and the program will
    not light the LED strips (with RGB controllers attached to them) in a
    consistent order or manner ... some times they all come on some times
    they don't - some times they come on in sequence but in different
    colours... some times they don't come on in sequence.

    However the sensors are certainly not working right at all from the get go... no matter what LED lights I use - RGB or regular. No matter what i do to break the beam or trip the sensor they do not respond as expected...

    NOTICE- this does NOT work with LED strip lights attached to RGB strip
    light controllers... ) My set up is 16 stairs with 16 separate 36" long RGB LED
    strip lights (one for each stair) and each led strip light is wired to a
    RGB controller (that came with them) and each LED RGB controller is
    wired to a channel on the board +/- )

    Now it work. You can buy rgb controller with memory function and use with my controller and choose color you need .

    Best regards

    Hello. No problem, i can sale kit for you. Please send me email to for more details.
    Best regards

    whats the point of buying your boards if you dont post the code?

    Hi. i have wewbsite there you can buy it
    Best regars

    For any one interested in one of these controllers I currently have mine for sale. I purchased it but does not work for my project ...