-This week we had to do something with Arduino, and i was given the task to do Home Automation.
-I had to control the home apliances with bluetooth as well as GSM(Text messages).
How does the Home Automation work?
-Simple Home Automation works between smart phone, internet and microcontroller which help in transmitting the power to the different appliances.
-The Microcontroller
(Arduino UNO Board) is a chip which transmits the data and work under specified instruction.
-
Bluetooth module(HC-05) is used to connect the smartphone and the arduino board to give commands.
-Bluetooth module is controlled by the bluetooth application in smartphone which is available on playstore and we can make one of our own with personal configuration on
MIT app inventor.
-For more information visit the given link
Here.
REQUIRED COMPONENTS
ARDUINO UNO
USB CABLE
BREAD BOARD
2 MODULE RELAY
BLUETOOTH (HC-05)
SCREW DRIVER
JUMPER CABLES
EXECUTION
Research:-
-After collecting all the components i started my research for the project.
-There are many projects available on internet showing us many different methods but all their aim is samen to automate their home.
-I started with the search of controlling the light with bluetooth and relay directly. Which i found very difficult to understand.
-After few trials in which i failed to complete the circuit i decided to separate two parts of the project in which i first made the LED blink with bluetooth and then blink LED with bluetooth and relay.
-After many research and failed attempts to find the correct video,i asked for help to my friend maharshi and he gave me one link of the video which i found very helpful. You can find the link
here.
Prototyping:-
Step:1
-After watching few videos and surfing some website i made one schematic diagram of the circuit i needed which could be helpful to understand the system.
-This is my trial of the first half in which i controlled LED with the help of bluetooth.
-You can find the source code and other information on this project in the below given
link.
-Now i can blink led through mobile.
Step:2
-After the success of this i connected relay to blink the led with command from serial monitor just to be sure of the working of relay with turning lights on/off.
-Below you can find the picture of my relay model and connections as well.
-Connect Int(relay) pin with Digital pin7.
-GND & VCC to GND & +5V of arduino board respectively.
-Connect +ve of 9V battery to common port of Relay and -v of battery to led.
-Connect NC port of Relay and +ve leg of LED.
Step:3 (Combining both the circuits)
-Now as the main aim was to control LED with bluetooth i connected both the circuits.
- Components you need for this - Arduino, Bluetooth(HC-05), 5v relay, jumper cables, B-Type usb, 9V battery.
Step:4 Make the circuit work with home appliance
-Now was the hard part in which i had to connect the 240V AC supply of house to my circuit.
-After the design i just started to open the switchboard of my house to look into it for wire connections, how they are connected with each other and how will i connect my model with it.
-This in process was a failure for me. I didn’t understood anything and all the process done went in vain.
-For that i took help from my friend Maharshi and my Mentor Tapan sir. All they did was just to guide me to the right direction in which i did research about the colour codes of wire and found the simple design of connecting those wires to the relay.
-Below is the circuit diagram for the final prototype working on 240V AC supply and controlling light through bluetooth.
-You can get the link i referred for connection
here.
-And here is my final working prototype image.
Step:5 (GSM based home automation.)
-Now there was a modification in my task. I had to make the same home automation work with the help of GSM module.
-GSM based automation means that you can control your home appliances from thousands of miles away. You just have to send a text message with appropriate command and the electricity will turn ON/OFF.
Difficulties:-
-First problem was that it was not detecting the sim card. I Just tried like 5 to 6 times removing the sim card and inserting it again and again but nothing happened.
-Then after asking to my friend i got to know that the module cannot detect the 4G sim card, it is feasible uptill 2G/3G only. And there was a little mistake i made (starting out the project without research)
-You can simply check if the card is working in the module by calling on the number.
Trials:-
-After simplifying the starting problem i ran the code to send a text message from GSM module to the desired mobile number.
-You can check whole process from this
link.
Step:6 (connecting GSM with Relay)
-Components required
Arduino UNO,
GSM sim800a,
12V dc supply for GSM module,
relay bulb connection same as used in Bluetooth.
-As i already did the circuit with Bluetooth and relay doing this was quite simple. I just Searched for the code online and applied it to
- Here is the link for automation with
GSM and Relay.
Step:7
-Now the hardest task was to control the voltage/ current flow.
-With this we can regulate the speed of fan or change the brightness of light as per we wanted.
-So i started my research but did not found any proper material to which i can refer for my project.
-After investing lots of my time on research i called up Tapan sir and he got me a name of component which could be helpful for me on the project.
-’TRIAC’ was the component and with that i found one video on youtube in which they explained whole process and thus i carried the same method with my project.
-You can see the video from this
link.
-After watching the video i listed down all the components used in circuit making and writing the properties of each one of them.
-Then i bought all the components required because i was not having the one which the circuit wanted. (i.e 47K ohm resistors, TRIAC, DIAC, Optocoupler, 4 circuit rectifier)
Step:8
-I started making of circuit by watching the video. Placed the components one by one and connecting them to each other with the help of jumper cables.
-In result i ended up having the complex circuit.
Failure:-
-Yes clearly this one was a big failure for me. Though i completed the circuit by myself as the data were not given properly.
-While trying the circuit for the first time firstly the light intensity was not being low/high when i rotated the potentiometer but instead of the fluctuation the 10K PWM got burned.
-Then i used another PWM of 470k which also got burned due to direct high voltage of 240V AC current.
-After constantly working for 2 days on research i was still not able to make the speed regulation work.
Final Research about the failure:-
-I found that the speed regulation circuit for such high AC power supply cannot be done on breadboard. Special PCB needs to be designed for this purpose.
-I found new schematic diagram through my friend of this field for the circuit and compared it with the old one i used.
-I need to design the PCB which i have to learn and collect proper components for the circuit and try once again.
- Another problem i discovered with my self assessment was that, if we detach the given switch of home and connect it to our circuit.
Q:- What if your mobile went off? The bluetooth application is not working? The network of the sim card you are using is down?
Sol:- We can use the touch IC and place it in the place if old switch so when there is some kind of problem arises we can manually control the system.
Working Video of my Project:-
Model 1-
Bluetooth Controlled Home Automation.
Model 2-
GSM module controlled Home automation.