Introduction: Control Your Room Light With Your Mobile

This instructable will show you how to connect your light bulb to your mobile phone, and control it via IR sensor.

You can control any electrical thing at your home after this instructable, if you understand the main concepts.

The hardware you will need for this project are:

1- Arduino.

2- Light bulb with socket.

3- 1 channel Relay, 5V.

4- TSOP4830, IR sensor.

5- wires.

6- remote control mobile app.

Step 1: Make the Circuit

First of all you should connect the circuit elements like show in the picture.

Step 2: Make Relay Circuit

Rely has 3 inputs and the outputs.

One side, the three inputs are:

1- Vcc

2- Gnd

3- Signal, (Pin 13)

The the other side, is the light bulb wire, you cut it ind pull the wire into it

Step 3: The Full Circuit

Sorry for my bad Drawing :3

Step 4: The Sketch: Part 1

First, download the library from here, and import it like in the picture:

Library

Step 5: The Sketch: Part 2

Download this sketch:

IR button code.

and upload it to your arduino, and get your mobile phone.

Open the IR remote app, then open your serial monitor.

Press the button you want it to turn on your light bulb.

Copy the number from the serial monitor.

Step 6: The Sketch: Part 3

Now, download this:

Control code.

and paste the number you get from the serial monitor, and upload your code.

Now you can control it very easy.

BE CAREFUL FROM ELECTRIC.

Comments

author
clauculo (author)2016-05-31

Nice tutorial!

Can you make a photo how the light bulb is connected to the relay? Thank you.

author
WaleedKhader (author)clauculo2016-05-31

The blue are the light bulb wires, and the pink is the wires that connected to arduino

13288696_10210022779425333_1036443878_o.png
author
DIY Hacks and How Tos (author)2016-05-31

This is a really fun project. But it works for more than just lights. You can control any appliance that can turn on when power is connected. For instance, you can control your coffee maker.

author

Yeah sure, you just need more relays and IR sensors, and everything will be awesome then