Home Automation

Intro

The internet is an essential part of our future infrastructure. Just like electricity, water and gas, the internet will be accessible everywhere, anytime. In such a world, every single device will be able to connect to the internet and to process data simultaneously. This idea is called Internet of Things. Our project Home Automation is a simple adaptation of this concept in lighting technologies.


In our Automation project, our aim was to control electronic devices (lights, fans etc.) with smart phones. The process consists of three main parts, Arduino, web server and mobile connectivity.

Electronics

The electronics for our automation project can be examined in three main parts: The relays that control the lights, The Arduino Board for communication with the Ethernet Shield and the Ethernet shield for the communication with a local url. 

THE RELAY CIRCUIT

  • Each set of lights in the CS Room use 220 volts of electricity. As our arduino board can only supply 5 volts, we obviously needed to use main city electricity. To control the switching of 220 volts, we used a relay board with 2 220v 10A relays. (Relays are basically electronically controlled switches that turn an appliance on and off according to an input signal) The relays are connected to an arduino board which supply the needed inputs and logic voltage(5v).
THE ARDUINO BOARD

  • The arduino board is used for the communication between the relay board and the ethernet shield. The board accepts input from the ethernet shield, interprets it via the software loaded onto it and manages two outputs for the relay boards accordingly. Once the link to close or open a light is closed, the information is transferred to the Arduino board and then to the Relays.
THE ETHERNET SHIELD

  • The ethernet shield is what makes our project connected and a part of the Internet of Things(IoT). The connection is established with an ethernet cable. Wireless connection is also possible, however may be unstable at times due to the frequent changes in our school's network situation. The ethernet board uses the loaded software on the arduino board to create a basic website on a local url. The website has several text fields and buttons. The code in the Arduino detects a state change in the websites URL transfers this information to action. This action being relays switching on or off. The shield also prints data provided by the Arduino Board to the web to update users of the light's status. The web interface and the Arduino code of this project was coded by Can Özdemir and Mehmet Can Alaca.
Mobile Connectivity

Both mobile apps have the same three main parts. Initially a main menu greets the user with all your available rooms. Next part is the adding menu where the user can enter the local ip address for their device and label it. This creates a wireless link between the device and their phone. When a room is added it can be previewed by simply clicking on it at the main menu. This triggers the next main part, the room menu, which enables the user to turn the lights on and off. Whenever a light is switched, the app replicates a click on the web server, causing the Arduino to perform its designated action. The room menu also provides the ability to give each light in the room a distinctive label by simply clicking the edit button. 

  • The Android version of the system is designed in MIT's App Inventor program. This program gives users the capability to design an android app with out any prior coding knowledge. This code was written by Bensu Sicim.
  • The iOS version of the remote system is essentially the same system in the Android version. The app is designed with the sample elements provided in Xcode and written in Swift. The code was written by Mehmet Can Alaca.
 





Comments