0% found this document useful (0 votes)
36 views46 pages

PROJECT

Uploaded by

Samist Fabusiwa
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
36 views46 pages

PROJECT

Uploaded by

Samist Fabusiwa
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 46

CHAPTER ONE

1.0 INTRODUCTION

In this modern era of development, automation of everything is the necessity of the

hour. The rudimentary purpose of this development is to ease the human way of life, home

automation aims at automating the way human lives. Triggering the home appliances without

conventional switch, but by using a smart phone is known as home automated system. Home

automation is the use of one or more computerized remotes to control basic home functions

and features remotely and sometimes automatically (Pandya et al. 2016). An automated home

is sometimes called a smart home. In present-day world, more emphasis is put on wireless

technology as a means of communication between one points to another without the use of

cables, which makes the system to be more secure.

A home automation system will control lighting, climate, entertainment systems, and

appliances. It may also include home security such as access control and alarm systems. In

modern day, the attractiveness of controlling electrical device through phone has been

increasing due to high performance and reduce work by connecting through smartphone

which is useful most especially for the elderly and physically disabled people, who can

access and control the appliances by staying at some place and access them remotely without

the help of others. Time is a very valuable thing; everybody wants to save time as much as

they can. New technologies are being introduced to save our time. To save peoples time,

developing a Home Automated System using Bluetooth and an Android app with a voice

prompt capability will save a stitch in time. With the help of this system, the user can turn

on/off homes and offices appliances.

Nowadays, people are unavoidably and inseparable from their smartphones. A group of more

than 5000 people from the US, UK, China, India, South Korea, South Africa, Indonesia,

Brazil and Nigeria took a smartphone usage survey which was organized by Time magazine.

1
This survey shows that the majority were highly attached to their phones, whereby 84%

claimed that they could not go a single day without their phones.

1.1 BACKGROUNG OF THE PROJECT

In the early days, home automation started with labor-saving machines. Self-contained

electric or gas powered appliances became viable in the 1900s with the introduction of

electric power distribution, introduction of washing machines (1904), refrigerators, clothes

dryers. sewing machines, dishwashers. In 1975, the first general purpose home automation

network technology, X10, was developed. It was a communication protocol for electronic

devices. It predominantly uses electric power transmission and wiring for signaling and

control, where the signals involve brief radio frequency bursts of most widely available

digital data. By 1978, X10 products included a 16 channel command console, a lamp

module, and an appliance module. Soon after came the wall switch module and the first X10

timer.

According to a data from a research firm Statistic, more than 45 million smart home

devices had been installed in U.S. homes by the end of the year 2018 (statista, 2019). This

had not been the case for Nigeria, although few had access to smart devices in Nigeria but, it

has not got across all.

According to Li et al. (2016) there are three generations of home automation:

1) First generation: wireless technology with proxy server, e.g. Bluetooth automation.

2) Second generation: artificial intelligence controls electrical devices, e.g. google assistant.

3) Third generation: robot buddy who interacts with humans, e.g. Robot Rovio, Roomba.

The system been proposed falls under the first generation of home automated system.

2
1.2 STATEMENT OF THE PROBLEM

It had become imperative for us to automate our daily routine in our various homes

and offices. Given the fast-paced lifestyles that most of us lead, the technological

advancements readily available at our fingertips are here to make things simpler for us. With

almost everyone owning a smartphone nowadays, making our homes a bit more tech savvy is

frankly the next logical step. Take note that several great strides are made in this sense for the

past few years and today, we have various devices and technologies at your disposal to

automate your home into a smart house. Conventionally electrical appliances or devices are

found in our various homes and offices, they are controlled by using manual method of

opening and closing the switches by an individual. This is a time and energy consuming

method for people that are busy with various work at homes and offices and this does not

make work to be more flexible. It is a difficult task for aged, handicap, incapacitate or

paralytic and asthmatic patient at dying state to be opening and closing the switches of the

electrical appliances, below are reasons why we should automate our home.

 Good for the Environment

In a time when we are all becoming more environmentally aware, home automation

provides a good solution to help preserve our natural resources. Home automation

products can reduce power consumption and automatically turn off lights and

appliances when they aren’t in use.

 Enhanced safety and peace of mind

Thanks to customizable adjustment systems available in the form of apps, now you

can control everything from the small appliances to the lighting with a simple tap of

your smartphone’s screen. In case you have a lot on your mind and simply can’t

3
remember whether you turned the curling iron off, automation permits you to verify

this information instantly and close the appliance to prevent an accident.

 Improved security

How often do we leave for work in a hurry only to realize half way that we forgot the

front door open? If the answer is rather often, then an automated system that allows

us to control the locking and unlocking of doors might come in handy. Because we

can control this detail directly from our devices, now we can focus on our day’s work

rather than worrying that someone might be entering your home. It goes without

saying that this is an especially useful service when we need to head to work before

your kids leave for school. Moreover, a home automation system permits us to install

security cameras and easily supervise what’s going on while you’re away. Modern

security cameras are designed to increase our family’s security by detecting

movement at any specific time of the day.

 Increased convenience

If you leave in a temperate climate, then we don’t need to tell you just how much

effort you have to put in, in order to have the right temperature when you get home.

Home automation renders this issue obsolete. Irrespective of the season, the system

permits you to turn the AC or heating on and off as desired. Moreover, by adjusting

your thermostat to the optimal temperature, you can even save some money on bills.

 Saving money by reducing utility bills

By far the most noteworthy reasons to install an automation system are our monthly

utility bills. As previously mentioned, the system helps us to control every appliance in the

house, so we can easily verify and close machines left on in our absence. This proposed

Home Automated System using Bluetooth and an android app will allow the user to perform

4
other task with their phones while working. Also it will potentially reduce stress and time

consumption.

1.3 MOTIVATION

I was motivated to carry out these project to fill the gap in making the home

automation system readily available to solve problem especially with the elderly and

physically challenged individuals with little or no mobility. Almost every house has smart

phones, smart television, smart watch, smart refrigerator, smart washing machine, smart

garage which eventually leads to a smart home. From there it is predictable that one day,

almost every house will be a smart house with automatic control system.

1.4 SIGNIFICANCE OF THE STUDY

This study is undertaken to create a home automated system at low cost and easy to

create using the available materials and component, this will benefit both the manufacturers

and the users of the system. It will help the manufacturer by making it easier and cheaper to

apply the procedure therein, and it will also benefit the users by making it cost effective and

the most important advantage is that, it will make the house a much more convenient place

for the users especially for the elders and the handicapped.

1.5 AIM

The aim of this project is to design and construct of an Arduino based home

automated system to fully satisfy the aim of this project, as a minimum the following

outlined objectives are to be met.

1.6 OBJECTIVES

1) To design and construct home automated system.

2) To construct the design using a hardware prototype.

5
3) To create a user friendly and responsive android app and system that focus

extensively to help the elders and handicapped.

4) To communicate with different electrical device within the home wirelessly.

1.7 SCOPE OF THE PROJECT

This project concentrates on the development of an automated system using

Bluetooth and an android app with the ability to communicate with the electrical appliances

using voice prompt. To develop the whole project, the project is divided into two phases,

which are the concept of the program/code structure and the construction of physical

prototype. The concept of code structure will be handled using Arduino IDE.

6
CHAPTER TWO

LITERATURE REVIEW

2.0 HOME AUTOMATION SYSTEM (H.A.S)

Home automation system refers to the use of a computer to control home functions

and other features of the home remotely and is also sometimes known as smart home. The

home automation system can be utilized in the controlling of various process in the home

such as turning on and off lighting point, various appliances such as fridge, blender, air-

conditioner among others remotely. Currently, installing a simple home automation system is

still expensive, but it is believed that there may be a decrease with it as the home medium

devices continue to become cheaper and therefore more people will opt-in for the system.

Home automation is very much important in many broad areas such as security, automation

of electrical appliance such as air conditioner, pumping machine, blender, lighting point, fan

and to a greater extent, it can be used to improve the “quality of life in people”. Another use

of home automation system is in the elderly who have been impaired with physical mobility

which makes simple tasks harder for people who are less mobile. The automation system can

link up the tasks performed on a simple control panel thereby easing work for the elderly. For

instance, turning on and off various lighting point in our home can be eased using a relay that

is controlled remotely using a smart phone or a computer.

2.1 CONVENTIONAL HOME CONTROLLED SYSTEM

Conventional home controlled systems and its components are all wired to the same

cable that connects them to the home control panel. The control panel displays a signal when

these components are activated. These types of systems are inexpensive and they are

common in our various homes. The main problem with conventional home controlled

systems is that, it requires mobility of the user in order to operate it. This is foreseen as a

7
problem especially in the early and physically challenged occupant of such home. A home

automation system can be deemed to provide a solution in such a home.

2.2 THE COMMUNICATION CHANNEL

Different communication channel has been used in many works that has to do with

transfer of signal or information from one point to another point and the channel of

transmission within an entire system. It also includes transmission from system to another.

There are majorly two ways of communication channel. The first is wired transmission

channel which is made with wire or cables while wireless transmission channel is without

any wired connection, but a logical connection layer is establish. It may also be a

combination of both medium. But the wireless channel has taken over the wired channel

because of the improvement in technology.

Wireless communication channel has more advantages than wired medium in terms of cost,

size, speed, power and distance range, wireless communication medium has greater merits.

2.3 ARDUINO

Arduino is an open-source hardware and software company, project and user community that

designs and manufactures single-board microcontrollers and microcontroller kits for building

digital devices. Arduino board designs use a variety of microprocessors and controllers. The

boards are equipped with sets of digital and analogue input/output (I/O) pins that may be

interfaced to various expansion boards or breadboards (shields) and other circuits. The

boards feature serial communications interfaces, including Universal Serial Bus (USB) on

some models, which are also used for loading programs from personal computers. The

microcontrollers can be programmed using C and C++ programming languages. In addition

to using traditional compiler toolchains, the Arduino project provides an integrated

development environment (IDE) based on the Processing language project

8
Figure 2: ARDUINO LOGO

2.4 REVIEW OF RELATED WORKS

There has been a significant increase in home automation in recent years due to higher

affordability and advancement in Smart phones and tablets which allows vast connectivity of

the system.

Y Chiranjeevi (2017). Present a reliable, compact, fast and low cost smart home automation

system, based on Arduino (Microcontroller) and Android app. Bluetooth chip has been used

with Arduino Uno, thus eliminating the use of personal computers (PCs). This system is

based on Arduino Uno ATMEGA328 microcontroller board. Arduino Integrated

Development Environment (IDE) is used for developing the necessary software. The

Bluetooth technology for controlling the devices when users are at home. It uses a HC-05

Bluetooth Module and Bluetooth Controller mobile application for switching ON or OFF the

Electrical Appliances. Relays and CFL Lights are used as a load to demonstrate the working

of the system but, the system was not design to control the speed of fan and also does not

incorporate voice prompt capability.

A ElShafee, and K. A. Hamed (2012), present a design and prototype implementation of new

home automation system that uses Wi-Fi technology as a network infrastructure connecting

its parts. Their proposed system consists of two main components; the first part is the server

(web server), which presents system core that manages, controls, and monitors user's home.

But the system design is not secure because local Wi-Fi is use as a mean of communication

9
this makes the system to be hackable in which someone else can access the home without the

user acknowledgement.

Similar designs have also been presented in [(Alkar, AZ; Buhur, U (2005), Sharma, U;

Reddy, SRN (2012), Liang et al., (2002) and Rajabzadeh et al., (2010)], where a dedicated

web server, database and a web page have been developed to interconnect and manage the

devices with the

Internet. The design is built for the sole purpose of efficient control of electrical appliances,

part of its objectives is to embed a user friendly control interface for electrical device using

internet device, and it is a fast and efficient approach to control electrical appliances. The

design is a viable one in the sense that it will go a long way in helping to checkmate

unnecessary wastage of voltage and making it more convenient to control electrical

appliances from even a remote area. In a case of local community where web server signal is

poor the system will not be able to function, it is also not cost effective.

Shivanda et al. (2017). Presents the design and implementation of a low cost but yet flexible

and secure cell phone based home automation system. The design is based on a standalone

Arduino BT board and the home appliances are connected to the input/ output ports of this

board via relays. This system is designed to be low cost and scalable allowing variety of

devices to be controlled with minimum changes to its core. The system is secured for access

from any user or intruder. The users are expected to acquire pairing password for the

Arduino BT and the cell phone to access the home appliances. This adds a protection from

unauthorized users. This system can be used as a test bed for any appliances that requires on-

off switching applications without any internet connection. The system was however not

design to control the speed of some devices and also it software does not have an

understandable graphical user interface.

10
CHAPTER THREE

3.0 METHODOLOGY

This project will be implemented using the hardware and software approach, a co-

integrated system where a hardware will be prototype, while the software (an android app)

will be develop using App Inventor 2

Several steps were taken in developing this project and are stated thus:

1) Understanding the problem and gathering of information.

2) Choosing the appropriate methods suitable for solving the problem based on the

information gathered.

3) Hardware construction and testing.

4) Software and hardware integration

5) Final testing.

3.1 REQUIREMENTS SPECIFICATION

In the course of the implementation of the proposed design, the system implementation

had been divide into two

1) Hardware implementation 2)

Software Implementation

11
Figure 4: GENERAL SYSTEM ARCHITECHURE

3.1.1 HARDWARE IMPLEMENTATION

This section discusses about the various hardware component to be use in developing the

physical prototype of the research in other to achieve the proposed aims and objective, the

prospective hardware components that will be used in this work, their names and descriptive

terms are explained vividly .

12
3.1.1.1 ARDUINO UNO

Figure 5: ARDUINO SPECIFICATION

Table: Arduino Uno Technical Specifications

Microcontroller ATmega328

Operating-Voltage(OV) 5Volts

Recommended input voltage 7 to 12 Volts

Limits of inputs voltage voltage 6 to 20 Volts

Digital I/O Pins 14 (of which 6 provides PWM output)

Analog Input Pins 6

DC Current per I/O Pin 40 Ma

DC Current for 3.3V Pi 50 Ma

SRAM 2 KB (ATmega328)

13
EEPROM 1 KB (ATmega328)

Clock Speed 16 MHz

3.1.1.2 POWER SUPPLY

3.1.1.2.1 TRANSFORMER

Figure 6: CENTER-TAPPED TRANSFORMER

A transformer is a static piece of apparatus by means of which electric power in one

circuit is transferred into electric power of the same frequency in another circuit. It can raise

or lower the voltage in a circuit but with a matching decrease or increase in current. The

physical basis of a transformer is mutual induction between two circuits linked by common

magnetic flux. In its simple form, it consists of two inductive coils which are electrically

separated but magnetically linked through a path of low reluctance. The two coils retain high

mutual inductance. If one coil is connected to a source of alternating voltage, an alternating

flux is set up in the laminated core, most of which is linked with the uses mutually induced

other coil in which it produces e.m.f. if the second coil circuit is closed, a current flow in it

14
and so electric energy is transferred (entirely magnetically) from the first coil to the second

coil. The first coil, in which electric energy is fed from the AC supple mains, is called

primary winding and the other from which energy is drawn out, is called secondary winding.

3.1.1.2.2 RECTIFICATION

A rectifier is an electrical device that converts alternating current (AC), which

periodically reverses direction, to direct current (DC), which flows in only one direction. The

process is known as rectification, since it "straightens" the direction of current. Rectifiers

have many uses, but are often found serving as components of DC power supplies and high-

voltage direct current power transmission systems. Because of the alternating nature of the

input AC sine wave, the process of rectification alone produces a DC current that, though

unidirectional, consists of pulses of current. Many applications of rectifiers, such as power

supplies for radio, television and computer equipment, require a steady constant DC current

(as would be produced by a battery). In these applications the output of the rectifier is

smoothed by an electronic filter (usually a capacitor) to produce a steady current.

Full-wave rectification

Figure 7: RECTIFICATION OUTPUT

15
A full-wave bridge rectifier converts the whole of the input waveform to one of constant

polarity (positive or negative) at its output. Full-wave rectification converts both polarities of

the input waveform to pulsating DC (direct current), and yields a higher average output

voltage. Two diodes and a centre-tapped transformer, or four diodes in a bridge configuration

and any AC source (including a transformer without centre-tapped), are needed. Single

semiconductor diodes, double diodes with common cathode or common anode, and four-

diode bridges, are manufactured as single components.

Rectifier output smoothing

While half-wave and full-wave rectification can deliver unidirectional current, neither

produces a constant voltage. Producing steady DC from a rectified AC supply requires a

smoothing circuit or filter. In its simplest form this can be just a smoothing capacitor, placed

at the DC output of the rectifier. There is still an AC ripple voltage component at the power

supply frequency for a half-wave.

3.1.1.2.3 VOLTAGE REGULATOR

A voltage regulator is designed to automatically maintain a constant voltage level.

Electronic voltage regulators are found in devices such as computer power supplies where

they stabilize the DC voltages used by the processor and other elements. Due to low-cost

fabrication technique, many commercial integrated-circuit (IC) regulators are available since

the past two decades. These include fairly simple, fixed-voltage types of high-quality

precision regulators. These regulators have much improved performance as compared to

those made from discrete components. They have a number of unique build-in features such

as current limiting, self-protecting against over temperature, and remote control operation

over a wide range of input voltages.

16
3.1.1.2.4 RESISTOR

A resistor is a passive two-terminal electrical component that implements electrical

resistance as a circuit element. In electronic circuits, resistors are used to reduce current flow,

adjust signal levels, to divide voltages, bias active elements, and terminate transmission lines,

among other uses. High-power resistors that can dissipate many watts of electrical power as

heat may be used as part of motor controls, in power distribution systems, or as test loads for

generators. Fixed resistors have resistances that only change slightly with temperature, time

or operating voltage. Variable resistors can be used to adjust circuit elements (such as a

volume control or a lamp dimmer), or as sensing devices for heat, light, humidity, force, or

chemical activity.

Resistors are common elements of electrical networks and electronic circuits and are

ubiquitous in electronic equipment. Practical resistors as discrete components can be

composed of various compounds and forms. Resistors are also implemented within

integrated circuits. The electrical function of a resistor is specified by its resistance: common

commercial resistors are manufactured over a range of more than nine orders of magnitude.

The nominal value of the resistance falls within the manufacturing tolerance, indicated on the

component.

Figure 8: RESISTORS

17
3.1.1.2.5 CAPACITOR

A capacitor or condenser is a passive electronic component consisting of a pair of

conductors separated by a dielectric. When a potential difference exists across the

conductors, an electric field is present in the dielectric. This field stores energy and produces

a mechanical force between the conductors. The effect is greatest when there is a narrow

separation between large areas of conductor; hence capacitor conductors are often called

plates. An ideal capacitor is characterized by a single constant value, capacitance, which is

measured in farads. This is the ratio of the electric charge on each conductor to the potential

difference between them. In practice, the dielectric between the plates passes a small amount

of leakage current. The conductors and leads introduce an equivalent series resistance and the

dielectric has an electric field strength limit resulting in a breakdown voltage. Capacitors are

widely used in electronic circuits to block the flow of direct current while allowing

alternating current to pass, to filter out interference, to smooth the output of power supplies,

and for many other purposes. They are used in resonant circuits in radio frequency equipment

to select particular frequencies from a signal with many frequencies. Electrolytic capacitors

derive a large part of their capacitance from the formation of a gaseous layer on one plate

when proper polarity is applied. This gaseous layer and greater dielectric effect gives an

electrolytic capacitor a much larger capacitance by volume than other types of capacitors can

achieve. Because of their higher capacitance values, electrolytic capacitors are most often

used in lower-frequency applications such as in power supply filters. Because of their

construction and polarity-sensitive operation, electrolytic capacitors require more careful use

than other capacitors. If installed improperly (reverse polarized), electrolytic capacitors will

not achieve correct capacitance and may build internal gas pressure, leading to an (minor)

explosion.

18
Figure 9: CAPACITORS

3.1.1.4 RELAY

Figure 10: RELAYS

An electromagnetic relay is an electrically operated switch. Many relays use an

electromagnet mechanism to mechanically operate a switch, but other operating principles

are also used, such as solid-state relays. Relays are used where it is necessary to control a

circuit by a separate lowpower signal, or where several circuits must be controlled by one

signal. In this project electromagnet relays will be used, with 12volt input electromagnetic

relay is able to provide switch for up to 30A.

In this project 10A and 30A electromagnetic relay will be used to provide the switching from

the microcontroller with the help of a relay driver.

3.1.1.5 TRIACS

19
Figure 11: TRIACS

TRIACs are a subset of thyristors, and are related to silicon controlled rectifiers (SCRs).

TRIACs differ from SCRs in that they allow current flow in both directions, whereas an SCR

can only conduct current in a single direction. Most TRIACs can be triggered by applying

either a positive or negative voltage to the gate (an SCR requires a positive voltage). Once

triggered, SCRs and TRIACs continue to conduct, even if the gate current ceases, until the

main current drops below a certain level called the holding current. TRIACs' bi-

directionality makes them convenient switches for alternating-current (AC). In addition,

applying a trigger at a controlled phase angle of the AC in the main circuit allows control of

the average current flowing into a load (phase control). This is commonly used for

controlling the speed of a universal motor, dimming lamps, and controlling electric heaters.

3.1.1.6 DIAC

Figure 12 : DIACS

The DIAC is a bi-directional semiconductor switch that can be switched on in both polarities.

The full form of the name DIAC is diode alternating current. Diac is connected back to back

20
using two zener diodes and the main application of this DIAC is that, it is widely used to help

even activating of a TRIAC when used in AC switches, dimmer applications and starter

circuits for florescent lamps. The Diac are designed for interfacing between electronic

controls and power triac to control resistive and inductive loads for Vac operations. MOC’s

are promptly available in integrated circuit form and don’t require very complex circuitry to

make them work. Simply give a small pulse at the right time to the LED in the package. The

light produced by the LED activates the light sensitive properties of the diac and the power is

switched on. The isolation between the low power and high power circuits in these optically

connected devices is typically few thousand volts. In the proposed design the diac is use for

triggering triacs

3.1.1.7 RELAY DRIVER (DARLINGTON ARRAY TRANSISTOR)

Figure1 : RELAY DRIVER( ULN2003A


)

The ULN2003 is a high voltage, high current Darlington array containing seven open

collector Darlington pairs with common emitters. Each channel rated at 500 mA and can

withstand peak currents of 600 mA. Suppression diodes are included for inductive load

driving and the inputs are pinned opposite the outputs to simplify board layout. These useful

chips allow you to drive high current loads like relays and motors which require more power

than a microcontroller can supply or sink. A high voltage (5V) on an input pin will turn on

21
the Darlington pair transistor pulling down the output pin. The load goes between the output

pin and the load supply voltage which can be up to 50V. This makes them great for

controlling 12V relays, electric motors, unipolar stepper motors and other high voltage or

high current loads. Outputs can be connected in parallel to allow higher current loads.

Specifications

• Package: 16 pin DIP

• No of Darlington Pairs: 7

• Output Current: 500mA per Darlington pair

• Output Voltage (load voltage): Max 50V

• Input voltage: 5V (works at 3.3V)

• Outputs can be connected in parallel for higher current loads

3.1.2 SOFTWARE IMPLEMENTATION

This section discusses about the various software and algorithm to be use in

developing the android application and programming of the Arduino board to be use for the

project in other to achieve the proposed aims and objectives, the prospective software’s that

will be used in this work, their names and descriptive terms are explained vividly. Two major

(Integrated Development Environment) software will be used in this work: Arduino IDE and

Proteus IDE.

DESIGN TOOLS

3.1.2.1 ARDUINO IDE

Arduino IDE is an open Source software which is mainly used for writing, compiling and

uploading directly into the microcontroller. There are several Arduino versions both in

22
software and hardware modules. The hardware modules include Arduino Uno, Arduino

Nano, Arduino Mega and many more. The software version also varies based on software

evolution. The version to be used in this work is version 1.8.9, this is one of the recent

updated versions from developers and all other versions are open source. Arduino IDE

environment mainly contains two main part know as Editor: for writing the desire software

code; and Compiler: for compiling and uploading code into the given Arduino module. Its

environment support both C and C++ language. Furthermore, Arduino IDE is mainly divide

into three sections called Menu Bar, Text Editor and Output Pane as shown in figure 3.3. The

Arduino IDE runs on operating system such as windows, MAC, Linux OS (Operating

Systems) and runs on java platform, it is also used for debugging, editing, compiling and

uploading code in its environment to

Physical hardware modules

Figure 15:ARDUINO IDE INTERFACE

3.1.2.2 PROTEUS IDE

Proteus IDE is a virtual system modelling (VSM) and circuit simulation application software.

It also has virtual system studio, a free universal IDE for Proteus. In addition, Proteus VSM

can be used for advanced embedded simulation, offering system level simulation based on

23
schematic circuit. It has a wide range of components in its database or library. In addition to

its own database component, more components can be designed in addition as part of the

library component if they are not part of the original software library. Such library

component includes: Arduino and Bluetooth Library for Proteus etc.

Both software IDEs (Arduino and Proteus) are selected to be used because of their following

criteria:

 Compatibility

 Hardware representation

 Hardware Simulation before real implementation

 Several Libraries

 Easy to use

 Direct hardware programming and many more

3.1.2.3 APP INVENTOR 2

In designing the android app, app inventor 2, which is the latest version of the online app

developing platform was used, the platform makes it easy for new enthusiast to create

android app without prior knowledge of computer programming

App inventor does not need any coding like Java or PHP. MIT app inventor contains blocks.

We can drag and drop the desired blocks in the corresponding place. This App inventor

needs internet connection during the creation of App. Once App is created, the App can be

used even in the off line mode. It is user-friendly compare to other Apps and eliminates the

complicated java coding procedure. This App can be installed to An-droid phone/Tablet with

Bluetooth module.

In creating the android app, we make use of the following component on the app inventor 2

24
• Button
• Label
• slider
• Clock
• Text to speech
• Speech recognizer
• Time picker
• List picker
• Scrollable horizontal layout
• Icons
• Text box

3.2.1 OPERATIONAL FLOWCHART

25
3.2.2 OPERATIONAL PROGRAM

The steps below describe the precise rule of operation the system will undergo.

Step 1: Start microcontroller

Step 2: click on the require function

Step 3: click on the voice button

Step 4: input your voice command

Step 5: If voice command is true (activate the required command)

Step 6: repeat the required function as desire.

3.2.3 CIRCUIT DIAGRAM

Two circuit diagrams have been used in the project. The circuit diagrams are as follows:-

3.2.1.1 Power Supply Unit Circuit Diagram:

26
3.2.1.2 SCHEMATIC DIAGRAM

Figure 19: SCHEMATIC DIAGRAM OF AN ARDUINO BASED HOME AUTOMATED

SYSTEM

3.2.6 CONSTRUCTION PROCESS

The project hardware was laid and soldered on a Vero Board (dotted) according to the

schematic simulated on the computer.

The construction procedure includes:

3.2.7 DESIGN CALCULATION

V=IR

For the Arduino digital pin voltage is 4volt

27
plate 1: system set-up

plate 2:complete packaged device

CHAPTER FOUR

28
4.0 TESTING, ANALYSIS OF RESULTS AND DISCUSSION

During the course of developing the project, every step and component set up were tested,

and the component were soldered onto the Vero board. In ensuring proper functioning of

components used which include resistor, triacs, diac, transformer, and relay and relay driver,

voltage regulators, capacitor and diodes. All the components were tested using a digital

multi-meter (DMM) so as to check that they conform to their data sheet. Below are the

considerable measures that was followed during the construction process

1) testing of each component using the digital multimeter

2) drafting out of a concise schematic diagram which is used to set up the various

component

3) Testing of the entire project to see if it conforms to the desire outcome.

4.1 TESTING

All assembled and soldered component connection were tested for any wrong connection.

The following test were carried out

1) continuity test

2) polarity test

3) connection test

4.1.1 CONTINUITY TEST

Continuity test is the checking of an electric circuit flow of current within the circuit during

the course of soldering, many of the closed solder joint might overlap or joint together,

continuity test was used to detect such an error which occur unavoidably. These test was

used to:

29
1) to detect if there are faulty components

2) to detect breakage in the circuit

4.1.2 POLARITY TEST

These test was carried out in order to ensure that there are no mixed up of the live and ground

wires. These help to decrease the risk of damage the component set- up.

Connection test: during the process of interfacing the hardware and the software, the set up

was power on, the necessary light indicators and Arduino were turned on, which was

successful with the light indicator.

4.1.3 ARDUINO CODE SECTION

#include <EEPROM.h>
#include <SoftwareSerial.h>
SoftwareSerial eniitan(0, 1); // RX & TX configured using software serial
int light=2; int securitylight=4; int airconditioner=6; int
pumpingmachine=7; int blender=10; int dimmerlight = 3; int fanspeeder
= 5; int optocouplerdimmerlight = 8; int optocouplerfanspeeder = 9; int
ad1=1; //address for storing relay 1 status in the EEPROM int ad2=2;
//address for storing relay 2 status in the EEPROM int ad3=3; //address
for storing relay 3 status in the EEPROM int ad4=4; //address for storing
relay 4 status in the EEPROM int ad5=5; //address for storing relay 5
status in the EEPROM
byte h; // Variables to store relay condition byte i; //
Variables to store relay condition byte j; // Variables to
store relay condition byte k; // Variables to store relay
condition byte l; // Variables to store relay condition
int powerled=12; // connection to power led int
statusled=13; // LED indicating BT connection status
char BluetoothData; // For recieving BT input int
detected1 = 0; int detected2 = 0; int value1=0; int

30
value2=0; int last_CH1_state = 0; int last_CH2_state =
0; void setup()
{
Serial.begin(9600);
eniitan.begin(9600); pinMode
(light,OUTPUT); pinMode
(securitylight,OUTPUT); pinMode
(airconditioner,OUTPUT); pinMode
(pumpingmachine,OUTPUT); pinMode
(blender,OUTPUT); pinMode
(powerled,OUTPUT); pinMode
(statusled,OUTPUT);
digitalWrite(powerled,HIGH); h =
EEPROM.read(ad1); i =
EEPROM.read(ad2);
j = EEPROM.read(ad3);
k = EEPROM.read(ad4);
l = EEPROM.read(ad5);
PCICR |= (1 << PCIE0); //enable PCMSK0 scan
PCMSK0 |= (1 << PCINT0); //Set pin D8 trigger an interrupt on state change. Input from
optocoupler pinMode(dimmerlight,OUTPUT); //Define D3 as output for the DIAC
pulse
PCICR |= (1 << PCIE1); //enable PCMSK0 scan
PCMSK0 |= (1 << PCINT1); //Set pin D8 trigger an interrupt on state change. Input from
optocoupler
pinMode(fanspeeder,OUTPUT); //Define D3 as output for the DIAC pulse
// RELAY - 1
if(h==1)
{
digitalWrite(light,HIGH);
}
else if(h==0)
{
digitalWrite(light,LOW);
31
}
// RELAY - 2
if(i==1)
{
digitalWrite(securitylight,HIGH);
}
else if(i==0)
{
digitalWrite(securitylight,LOW);
}
// RELAY - 3
if(j==1)
{
digitalWrite(airconditioner,HIGH);
}
else if(j==0)
{
digitalWrite(airconditioner,LOW);
}
// RELAY - 4
if(k==1)
{
digitalWrite(pumpingmachine,HIGH);
}
else if(k==0)
{
digitalWrite(pumpingmachine,LOW);
}
// RELAY - 5
if(l==1)
{
digitalWrite(blender,HIGH);
}
else if(k==0)
32
{
digitalWrite(blender,LOW);
} } void
loop() {
if (eniitan.available())
{
digitalWrite(statusled,HIGH);
delay(100);
digitalWrite(statusled,LOW);
BluetoothData=eniitan.read();
switch(BluetoothData) { //
RELAY - 1 case 'A' :
digitalWrite(light,HIGH);
EEPROM.write(ad1,1);
break;
case 'B' :
digitalWrite(light,LOW);
EEPROM.write(ad1,0);
break;
// RELAY - 2
case 'C' :
digitalWrite(securitylight,HIGH);
EEPROM.write(ad2,1);
break;
case 'D' :
digitalWrite(securitylight,LOW);
EEPROM.write(ad2,0); break; //
RELAY - 3 case 'E' :
digitalWrite(airconditioner,HIGH);
EEPROM.write(ad3,1);
break;
case 'F' :
digitalWrite(airconditioner,LOW);
EEPROM.write(ad3,0);
33
break;
// RELAY - 4
case 'G' :
digitalWrite(pumpingmachine,HIGH);
EEPROM.write(ad4,1);
break;
case 'H' :
digitalWrite(pumpingmachine,LOW); EEPROM.write(ad4,0);
break;
// RELAY - 5
case 'I' :
digitalWrite(blender,HIGH);
EEPROM.write(ad5,1);
break;
case 'J' :
digitalWrite(blender,LOW);
EEPROM.write(ad5,0);
break;
// OVERALL MASTER SWITCH
case 'V' :
digitalWrite(light,HIGH);
EEPROM.write(ad1,1);
digitalWrite(securitylight,HIGH);
EEPROM.write(ad2,1);
digitalWrite(airconditioner,HIGH);
EEPROM.write(ad3,1);
digitalWrite(pumpingmachine,HIGH);
EEPROM.write(ad4,1);
break;
case 'U' :
digitalWrite(light,LOW);
EEPROM.write(ad1,0);
digitalWrite(securitylight,LOW);
EEPROM.write(ad2,0);
34
digitalWrite(airconditioner,LOW);
EEPROM.write(ad3,0);
digitalWrite(pumpingmachine,LOW);
EEPROM.write(ad4,0);
break; default :
for(int i=0;i<5;i++)
{
digitalWrite(statusled,HIGH);
delay(100);
digitalWrite(statusled,LOW);
delay(100);
if(eniitan.available()>0)
if(Serial.available()>0)
{
value1 = map(Serial.read(),0,1024,7000,10);
if (detected1)
{
delayMicroseconds(value1); //This delay controls the power
digitalWrite(dimmerlight,HIGH); delayMicroseconds(100);
digitalWrite(dimmerlight,LOW); detected1=0;
}
{
value2 = map(Serial.read(),0,1024,7000,10);
if (detected2)
{
delayMicroseconds(value2); //This delay controls the power
digitalWrite(fanspeeder,HIGH); delayMicroseconds(100);
digitalWrite(fanspeeder,LOW);
detected2=0;
}
} { if(PINB & B00000001){ //We make an AND with the pin state
register, We verify if pin 8 is HIGH??? if(last_CH1_state == 0){ //If the
last state was 0, then we have a state change... detected1=1; //We
have detected a state change! }
35
}
else if(last_CH1_state == 1){ //If pin 8 is LOW and the last state was HIGH
then we have a state change detected2=1; //We have detected a
state change! last_CH1_state = 0; //Store the current state into the last
state for the next loop
}
}
//This is the interruption routine
{
///////////////////////////////////// //Input from optocoupler if(PINB & B00000001){
//We make an AND with the pin state register, We verify if pin 9 is HIGH???
if(last_CH2_state == 0){ //If the last state was 0, then we have a state
change...
detected2=1; //We have detected a state change!
}
}
else if(last_CH2_state == 1){ //If pin 9 is LOW and the last state was HIGH
then we have a state change detected2=1; //We have detected a
state change! last_CH2_state = 0; //Store the current state into the last
state for the next loop
}
}
}
{
} }

4.3 PROJECT MANAGEMENT

The following subsections shows how this project is managed. From the project modelling

idea to construction to sourcing of required component both from within and outside the

country to testing of the desire design specification.

4.3.1 PROBLEM ENCOUNTER

36
1) sourcing of component

2) soldering

3) interconnection of the main circuit

4) non availability of power source

4.3.2 PROJECT SCHEDULE

The chart below shows the tasks involved in this project and the time period to complete

each of this task. The project schedule was represented using a Gantt chart as shown below:

Table

2:PROJECT SCHEDULE

AUGUST 2019 OCTOBER, 2019 NOVEMBER, 2019 DECEMBER, 2019 JANUARY,

2020
SEPTEMBER,2019

WK WK WK WK WK WK WK WK WK WK WK WK WK WK WK WK WK WK WK WK WK WK

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22

MODELLING OF

IDEA

PROPOSAL

PROJECT WRITE-

UP

DESIGNING OF

CIRCUITRY

GATHERING OF

COMPONENT

HARDWARE

CONSTRUCTION

AND TESTING

SOFTWARE

IMPLEMENTATION

AND TESTING

INTERFACING OF

37
SOFTWARE AND

HARDWARE

TESTING OF THE

PROJECT

SUPERVISOR

OVERVIEW

SUBMISSION OF

PROJECT

4.3.2 RISK MANAGEMENT


In the design and implementation of this project, the following outward conditions were
encounter
i. Electrical Hazard in connecting with the mains
ii. Components Failure during the testing
iii. Wrong connection
iv. Communication with the software these threats are
being moderated by:
(i) It was ensured that the datasheet of each component was well understood and
tested before soldering them together.
(ii) I ensured I put on my safety wears such as glove, nose mask in order to avoid
burnt and inhaling of smoke during soldering procedure.

CHAPTER FIVE

5.0 CONCLUSION AND RECOMMENDATIONS

In this project a reliable, compact, fast and low cost home automation system using

Arduino and android app has been proposed, implemented and tested. The proposed system

utilizes Bluetooth module for fast and reliable communications in between the remote user

and devices. In order to provide safety protection to the user, a low voltage activating

switches is replaced current electrical switches. Moreover, implementation of the wireless

38
Bluetooth connection in control board allows the system install in more simple way. The

control board is directly installed between the electrical switches where by the switching

connection is controlled by relay. The complete application software has been designed using

android, using MIT app inventor 2.

The experimental setup which has been designed has its focal point on controlling

different home appliances which provides 100% efficiency. Due to advancement in

technology, Bluetooth is easily available on all smart phone devices especially android this

had been our focal point of control. It can be concluded that the objectives of this project

were achieved, i.e. to develop a low cost and high reliable home automation system. In

addition, a user-friendly Android application which is use as the control terminal of a home

automation system has also been created. The prime objective of this project is to assist

handicapped/old aged people in our community. The design consists of mainly Android

phone home automation application, a Bluetooth module, Arduino UNO board and other

components. User can interact with the android phone and send control signals to the

Arduino UNO which in turn will control embedded actuators. This system can be easily

manufactured on a large scale for mass production and adoption owing to its simplicity and

ease of design. Another advantage of is the fact that application software is based on

Android, which today has the largest smart phone base, any Android based Smart phone with

built in support for Bluetooth/Wi-Fi can be used to access and control the devices at home.

Also this system can be used as a test bed for any appliances that requires on-off switching

applications without any internet connection.

5.1 RECOMMENDATIONS

In the light of the setbacks encountered by the researchers through the course of conducting

this project successfully, and the general findings, the following recommendations are hereby

made.

39
 Higher institution students studying technology related courses should be

encouraged to undertake design and construction projects, not just in their final year

but also through the course of their program. This should also be used as a means to

grade

them. In the long run this will develop the educational system and the drive for

technological advancement in Nigeria.

 Universities, Polytechnics, Research institutes and individuals alike should be

encouraged and supported by the government and the general public in technological

pursuits. This can be done in terms of funding, provision of basic/advanced

equipment, and recognition.

5.2 CONTRIBUTION TO KNOWLEDGE

This project has immensely broadened our bank of knowledge in electrical and electronics

engineering, computing engineering, designing strategy, project management which had help

in the success of the project

5.3 LIMITATIONS

During the developmental stage, interfacing the Bluetooth module with the Arduino

and android app was very difficult. Designing and testing of the android app is the most

difficult and time consuming, which leads much internet data cost been incur during the

process. Also there are hard times face in getting some of the component needed in setting

the project due to our locality, this gravely affected the timely delivery and completion of the

project. Furthermore, we have a difficult time learning how to make use of the various IDEs

which include Arduino ide, proteus ide.

40
REFERENCES

A. ElShafee and K. A. Hamed "Design and Implementation of a Wi-Fi Based Home

Automation System", World Academy of Science, Engineering and Technology, Vol:6

2012-08-28

41
Abdul Kareem Kasim and Abdul Raheem “Bluetooth Based Smart Home Automation

System using Arduino UNO Microcontroller” Al-Mansour Journal/ Issue (27)

2017) pp 139

Al-Ali and M. AL-Rousan, “Java-Based Home Automation System R.” IEEE Transactions

on Consumer Electronics, Vol. 50, No. 2, MAY 2004.

Alkar, AZ and Buhur, U (2005).” An Internet based wireless home automation system for

multifunctional devices”, IEEE Transactions on Consumer Electronics,

51:1169-1174.

Alper Gurek, Caner Gur, Mustafa Akdeniz, Senem Kumova Metin and Ilker Korkmaz,

“An Android Based Home Automation System”, 2013 10th International Conference on

High Capacity Optical Networks and Enabling Technologies(HONET-CNS),

December 2013.

Amirah Aisha Badrul Hishama, Mohamad Hafis Izran Ishaka, and Chan Kok: “Bluetooth

Based Home Automation System Using an Android Phone” Jurnal Teknologi

(Sciences & Engineering) 70:3 (2014) 57–61

B.Shivanda, Rohit Sharanappa, M.Basavaraj, Basavaling Swamy “A Smart Home

Automation Device Control Using Bluetooth and Android Phone" International

Journal of Innovative Research in Computer and Communication Engineering

Vol.5 , Special Issue 4, June 2017

Baris Yuksekkaya, A. Alper Kayalar, M. Bilgehan Tosun, M. Kaan Ozcan, and Ali Ziya

Alkar,

(2006) “A GSM, Internet and Speech Controlled Wireless Interctive Home Automation

42
System”, IEEE Transac-tions on Consumer Electronics, Vol. 52, Issue 3, pp. 837-843.

Chandra Shakher Tyagi, Mega Agarwal, and Renu Gola (2016) “Home Automation Using

Voice Recognition and Arduino” IJRTER, Vol 2, Issue 7, ISSN: 2455.1457

David N. et al. “Design of Home Automation”, International Journal of Scientific &

Engineering Research, Volume 6, Issue 6, 2015, ISSN 2229-5518

Dinesh Suresh Bhadane, Monali D.Wani, Sanjeev.A.Shukla and Aniket R.Yeole,(2015) “ A

Review on Home control Automation using GSM and Blue-tooth” International

Journal of Advanced Research in Computer Science and Software Engineering,

Vol.5,Issue 2.

E. Yavuz, B. Hasan, I. Serkan and K. Duygu. “Safe and Secure PIC Based Remote Control

Application for Intelligent Home”. International Journal of Computer, vol.1

Gill K. et al.” A ZigBee-Based Home Automation System” in IEEE Transactions on

Consumer Electronics, Vol. 55, No. 2, 2009, DOI: 10.1109/TCE.2009.5174403.

Jella Sandeep et al. international journal of innovative technology and research Volume

No.5, Issue No.1, December – January 2017, 5557-5559.

K. Venkatesan and Dr. U. Ramachandraiah, “Networked Switching and Polymorphing

Control of Electrical Loads with Web and Wireless Sensor Network”, 2015

International Conference on Robotics, Automation, Control and Embedded

Systems (RACE), Chennai, (2015), 1-9.

43
Kannapiran S and Arvind Chakrapani: “A Novel Home Automation System using Bluetooth

and Arduino” International Journal of Advances in Computer and Electronics

Engineering Volume: 01 Issue: 05, September 2016, pp. 41 – 44

Liang, NS; Fu, LC; and Wu, CL (2002). “An integrated, flexible, and Internet-based

control architecture for home automation system in the Internet era”, IEEE

International Conference in Robotics and Automation Proceedings, 2: 1101-1106.

N.Sriskanthan and Tan Karande, (2002) “Bluetooth Based Home Automation Systems,”

Journal of Micro-processors and Microsystems, Vol.26, pp. 281-289.

Neng- Shiang Liang; Li-Chen Fu; Chao-Lin Wu. “An integrated, flexible, and Internet-based

control architecture for home automation system in the internet era”. Proceedings

ICRA

`02. IEEE International Conference on Robotics and Automation, Vol. 2, pp.1101 1106,

2002.

Nikita Wanjale, Rejoy Mathews, Blossom Mendes, And Manali Navale “Bluetooth Based

Home Automation” international journal of scientific engineering and technology

research

ISSN 2319-8885 Vol.03, Issue.12 June-2014, Pages:2645-2650

Pandya B. et al., “Android based Home Automation System using Bluetooth & Voice

Command” International Research Journal of Engineering and Technology (IRJET)

Volume: 03 Issue: 03, 2016, ISSN: 2395-0072

Piyare R, Tazil M (2011). “Bluetooth based home automation system using cell phone”,

IEEE15th International Symposium on consumer electronics,192-195.

44
Pooja N.Pamar, Shruthi Ramachandran, Nisha P.Singh and Varsa V.Wagh (2016) “A Home

Automation System using Internet of Things” IJIRCCE, Vol.4, Issue 4, pp. 6555-6563

Science and Network Security, Vol. 7, No. 5, May 2007.

Sharma, U and Reddy SRN (2012).” Design of Home/Office Automation Using Wireless

Sensor Network”, Inter. J. Computer Applications, 43: 53-6

45
|Page

You might also like