Introduction: Smart Wall Lamp (That Swivels and Changes Shades Controlled by Your Smart Phone

About: I am a tech enthusiast and like making electronics stuffs and I basically like experiments with circuits and electronics

Hello and welcome back ;

As I like fiddling with leds and basically we all like leds to some extent . The main part where the leds come into picture is Home Decor and to go even deeper Wall Lamps .

But what if we can control Wall lamps with our smart phone change the color anytime and rotate to any desired degree .

SO HANG ON THIS ARTICLE IS FOR YOU !!!

And I will fulfill every requirements mentioned above .

SO LETS START THE BUILD.

Step 1: FIRST WATCH THE VIDEO !!

FOR better understanding watch the video !!! FIRST

Step 2: BUILDING THE ENCLOSURE - 1

First lets start with the enclosure for wall lamp I took around 6 old useless so called use and throw pens the adjusted the scale at the middle point around 6.5cm marked the point then repeated the process for the remaining ones .

Then started ripping them apart as per the markings .

Step 3: BUILDING THE ENCLOSURE - 2

Then I took a 5mm thick plywood marked a square of around 7cm* 7cm leaving some margin for the pens to fit in and started slaughtering it apart

After that was complete I placed 4 of the pieces of earlier cut pens on the plywood piece and then glued them together firmly !!

Step 4: BUILDING THE ENCLOSURE - 3

Then I replicated the same process for another 4 pen structure glued them together and took the distance measurement between the top and the bottom before fixed all the pens in a cubical structure .

I glued pillars between the top and bottom squares and well the enclosure of the lamp was complete and would be not an exact cube but somewhere between cube and cuboid .

Step 5: BASE OF THE LAMP

Heading towards the base of the lamp which has to be sturdier and firm so that the lamp does not fall of the wall

And instead of wall lamp become a mere lamp LOL!!

Anyways I had cut the wooden pieces earlier and then took a small piece of sand paper and started furnishing the surface as well as the sharpening the edges .

Step 6: FIXING THE SERVO MOTOR

Now the question arises which motor to use for angle control and the best choice seem to be Servo motor and even better is a heavy duty one like MG995.

Servos are widely used for angle control due to their closed loop control .

Then took a circular blade fixed it with the screw tightly at the top . Marked the position exactly at the center drilled a hole and glued it firmly and then checked the distance between the side plates and motor so the microcontroller fits perfectly inside .

Step 7: WRAPPING ACRYLIC SHEET

Then I cut a small piece of wood fixed it on the servo motor which will rotate our lamp .

Fixed the lamp enclosure on it . So it looks good now .And now it was time to use some wrapping for our enclosure .

So I took a acrylic sheet marked according to the dimensions of lamp enclosure and fragmented some pieces of acrylic sheet .

Step 8: BASE READY!!!!

After tapping and gluing everything together the mechanical build was complete

Step 9: DEGREE / ANGLE CONTROL TESTING

You can see in the pictures as well as in the video that the test is successful and it covers the entire degree range from 0 to 180 degree which will be perfectly suited for wall lamps .

With this feature you can adjust wall lamp at any desired degree remotely without touching it !!!

Step 10: ELECTRONICS USED

let's dive into the electronics

To make it automated the main role is played by the HC-05 Bluetooth module which will use a serial communication to communicate with our smart phone and controlling unit is obviously an arduino.

Step 11: BUILDING THE APP

The application build here in is easy to interpret and does not require any rocket science .

The application is the same as the one in my earlier article as well as earlier video which you can understand by watching it . Anyways there is one change there is an enhanced feature of degree control . We can adjust the lamp to 30 45 90 120 150 or 180

Step 12: FIXING THE RGB LEDS

Then inside the enclosure we will fix some RGB leds and wire all the red blue and green together according to the wiring scheme in my previous video !!

Step 13: ENJOY THE SHADES

SO now the last test which is shade adjustment test also works fine !!!

Step 14: PROGRAMMING PART

#include

Servo butServo;

const int redPin = 3; const int bluePin = 6; const int greenPin = 5; char color = 0;

void setup() { // put your setup code here, to run once: butServo.attach(9); butServo.write(0); pinMode(redPin,OUTPUT); pinMode(bluePin,OUTPUT); pinMode(greenPin,OUTPUT); Serial.begin(9600);

analogWrite(redPin,0); analogWrite(bluePin,0); analogWrite(greenPin,0);

}

void loop() { // put your main code here, to run repeatedly: if(Serial.available()>0){ color = Serial.read(); char value = char(color); if(value != '0') { Serial.println(value); } }

if(color == 'Y'){ analogWrite(redPin,0); analogWrite(bluePin,255); analogWrite(greenPin,0); } if(color == 'W'){ analogWrite(redPin,0); analogWrite(bluePin,0); analogWrite(greenPin,0); } if(color == 'R'){ analogWrite(redPin,0); analogWrite(bluePin,255); analogWrite(greenPin,255); } if(color == 'P'){ analogWrite(redPin,0); analogWrite(bluePin,80); analogWrite(greenPin,70); } if(color == 'O'){ analogWrite(redPin,0); analogWrite(bluePin,255); analogWrite(greenPin,90); } if(color == 'M'){ analogWrite(redPin,0); analogWrite(bluePin,0); analogWrite(greenPin,255); } if(color == 'C'){ analogWrite(redPin,255); analogWrite(bluePin,0); analogWrite(greenPin,0); } if(color == 'G'){ analogWrite(redPin,255); analogWrite(bluePin,255); analogWrite(greenPin,0); } if(color == 'B'){ analogWrite(redPin,255); analogWrite(bluePin,0); analogWrite(greenPin,255); } if(color == ':'){ butServo.write(30); delay(250); } if(color == ';'){ butServo.write(45); delay(250); } if(color == '<'){ butServo.write(90); delay(250); } if(color == '='){ butServo.write(120); delay(250); } if(color == '>'){ butServo.write(150); delay(250); } if(color == '?'){ butServo.write(180); delay(250); } }

Step 15: FINAL WORKING

ALL IN ALL THIS WALL LAMP IS VERSATILE ROBUST AND EASY TO BUILD HAS MANY FEATURES LIKE ANGLE ADJUSTMENT AND COLOR ADJUSTMENT USING YOUR SMART PHONE AND SOME COOL LOOK FOR HOME DECOR!!!!

THANY YOU FOR READING IF YOU LIKE THE ARTICLE FOLLOW ME ON YOUTUBE AND SUBSCRIBE TO MY CHANNEL