SUBMITTED TO
SUBMITTED BY:
Amit
Pathak
Banish
(BTL306137)
Gupta
Himanshu
(13135)
Jyoti
(BTL306139)
Negi
Sharma
Kalyani (13137)
1
INFOWIZ also provides Technical Support & Consultancy to Software Companies like
JIA Group, Newzealand, Sagitech solutions Panchkula, Jarc infotech Mohali, Infonet
Solution, Delhi etc.
URLs
1) Viva Sales
COUNTRY
www.infowiz.in/vivasales
UK
2) Mds Creative
Germany
www.mdscreative.com
3) Liddle TV
UK
4) Paradigms(
Australia
www.filmon.com
Android)
5) Printcost
6) PSTDO Bootstrap
USA
7) Essencesoftwares
Australia
8) Dashboard(Wordpress)
USA
running
www.popgraphics.net
UK
www.bootstrap.achieversperfect.com
www.essencesoftwares.com
running
9) Realstate
Russia
10) Dealpartners(WordPress)
11) Littletonvineyard
USA
12) Gpakoffshore
UK
www. realestate.infowiz.in
www.dealpartners.co.uk.gridhosted.co.uk
UK
www.littletonvineyard.net
www.gpakoffshore.com
OUR TEAM:-
Our Technical team of professionals handing, designing & delivering of projects has a
strong presence in the North India & the US. Our engineers are already working on the
latest technologies like I-Phone & Android Applications, Robotics, VLSI-VHDL,
Embedded System, Networking and Cloud computing.
1)
Dr. Seema
(Managing Director)
She is the backbone of INFOWIZ and a woman with more than 9 year rich practical
experience
who believes in taking up new ventures and projects.
2)
A man who strongly feel that Nothing is Impossible. A very committed team
leader who has
been professionally attached with Multinational companies for more than 18 years
and has lead
5
3)
A man who believes that Honour Time & Place, then you will be honoured. he has
more
than 4 years solid industrial experience in a software companies & is very dashing
and innovative
in his technical approach.
4) Ms. Urvashi
(Dean Academics)
A woman who believes that Challenges are what make life interesting and
overcoming them is
what makes life meaningful. She has more than 3years experience in business
development.
5) Ms. Amita
(Manager)
A woman believes that dont wait for extra ordinary opportunities, seize common
occasions and
make them great. She has more than 4 years experience in marketing field.
6
6)
More than 10 years industrial experience in US and smooth handling of the entire US
business.
COURSES Offered :For CSE/IT/MCA Professionals:1) Web Development in PHP with LIVE Projects
2) Web Development in .NET with LIVE Projects
3) JAVA (Core as well as Advance ) with LIVE Projects
4) Android Applications with LIVE Projects
5) Web Designing (Photoshop, Coral Draw)
7
For INFOWIZ
Address:SCO 118-119-120
Basement Sub City Centre
Sector 34-A Chandigarh (160022)
0172-456-7888
9
Training Coordinator
Er. Banish Gupta
(R&D Engineer)
(CEO)
Contact No. 0981580033
Email Id:-
info@infowiz.co.in
Website:-
www.infowiz.co.in
banishgupta123@gmail.com
CONTENTS
PAGE NO.
1. ABSTRACT
2. INTRODUCTION
3. HARDWARE REQUIREMENTS
3.1 TRANSFORMERS
11
3.3 RECTIFIER
13
3.4 FILTER
14
10
15
3.6 LED
22
3.7 BC 547
27
3.8 1N4007
28
3.9 RESISTOR
30
3.10 CAPACITOR
33
37
3.12 RELAY
38
4. SCHEMATIC DIAGRAM
39
4.1 DESCRIPTION
40
44
5. SOFTWARE IMPLEMENTATION
46
46
52
6. HARDWARE TESTING
52
52
53
7. MANUAL
54
59
9. CONCLUSION
60
10. BIBLIOGRAPHY
61
11
ABSTRACT
Automation is a trending topic in the 21st century making it play an important
role in our daily lives. The main attraction of any automated system is reducing human
labour, effort, time and errors due to human negligence. With the development of
modern technology, smart phones have become a necessity for every person on this
planet. Applications are being developed on Android systems that are useful to us in
various ways. Another upcoming technology is natural language processing which
enables us to command and control things with our voice. Combining all of these, our
paper presents a micro controller based voice controlled home automation system using
smartphones. Such a system will enable users to have control over every appliance in
his/her home with their voice. All that the user needs is an Android smartphone, which
is present in almost everybodys hand nowadays, and a control circuit. The control
circuit consists of an microcontroller, which processes the user commands and controls
the switching of devices. The connection between the microcontroller and the
12
INTRODUCTION
The foremost aim of technology has been to increase efficiency and decrease effort. With
the advent of Internet of Things in the last decade, we have been pushing for ubiquitous
computing in all spheres of life. It thus is of extreme importance to simplify human interfacing
with technology. Automation is one such area that aims that achieves simplicity whilst increasing
efficiency. Voice controlled House Automation System aims to further the cause of automation so
as to achieve the goal of simplicity.
The primitive man realized that an effective way to communicate with one another is
through voice. With minimum effort, ideas could be narrated with relative ease. When the first
computers came around, achieving the level of sophistication so as to narrate commands using
voice to a machine was only realized in science fiction. However with tremendous breakthroughs
in the field, we are at the precipice of truly using voice to interface with devices.
Using this effective yet ingrained form of communication we would humanize
technology to a great extent. Voice controlled House Automation System deploys the use of
voice to control devices.
13
The advantages of using voice as an interfacing medium are multifold. Firstly we would
do away with or significantly decrease the need of training for operating technology. Secondly,
the simplification of services would entail a wider adoption of existing technology and would
help people with varied disabilities access the same technology. We have deployed an Android
Application as user front end primarily because of the ease at which the platform provides us
with means to use complex technology and due to the widespread adoption in the mobile
industry. Android is being used as the operating system for over 80% of the smartphones.
Voice controlled House Automation System leverages the power of Microcontroller to
provide a holistic voice controlled automation system. Using Natural Language Processing and
the available hardware in most smartphones, it translates voice to be used for controlling
electrical devices.
Block Diagram
14
The Voice-operated Android Home automation system uses an Android based Bluetooth
enabled phone for its application and the 8051 as the microcontroller. The key components of
this system are:
Android based phone
Bluetooth module
Relay boards
We have used the Android platform because of its huge market globally and its easy to
use user interface. Applications on the Android phones extend the functionality of devices
and are written primarily in the Java programming language using the Android software
development kit (SDK). The voice recognizer which is an in built feature of Android
phones is used to build an application which the user can operate to automate the
appliances in his house. The user interface of the application is shown below:
The microphone button is tapped and the voice command is given to switch the corresponding
device on/off. The voice recognizer listens and converts what is said to the nearest matching
words or text. The Bluetooth adapter present in the phone is configured to send this text to the
Bluetooth module on the Microcontroller board that would in turn control the electrical
appliances through the relay boards.
16
Bluetooth Module
Bluetooth is a wireless technology standard for exchanging data over short distances (using
short-wavelength UHF radio waves in the ISM band from 2.4 to 2.485 GHz) from fixed and
mobile devices, and building personal area networks (PANs). The Bluetooth module being used
allows us to transmit and receive signals. It receives the text from the Android phone and
transmits it to the serial port of the Microcontroller.
The Bluetooth module being used here is the HC05 module. It is an easy to use Bluetooth SPP
(Serial Port Protocol) module, designed for transparent wireless serial connection setup. Serial
port Bluetooth module is fully qualified Bluetooth V2.0+EDR (Enhanced Data Rate) 3Mbps
Modulation with complete 2.4GHz radio transceiver and baseband. It uses CSR Bluecore 04
External single chip Bluetooth system with CMOS technology and with AFH (Adaptive
Frequency Hopping Feature). It has a slave default Baud rate of 9600. It auto connects to the last
device on power as default. Pairing pin code is 1234 as default.
Relay Boards
A relay is an electromagnetic switch. In other words it is activated when a current is applied to it.
Normally a relay is used in a circuit as a type of switch there are different types of relays and
they operate at different voltages. When a circuit is built the voltage that will trigger it has to be
considered. In this project the relay circuit is used to turn the appliances on/off. The high/low
signal is supplied from the microcontroller. When a low voltage is given to the relay of an
appliance it is turned off and when a high voltage is given it is turned on. The relay circuit to
drive three appliances in the Voice operated Android Home automation system is shown below.
The number of appliances can be modified according to the users requirements.
3. HARDWARE REQUIREMENTS
HARDWARE COMPONENTS
17
3.1 - TRANSFORMER
18
Transformers convert AC electricity from one voltage to another with a little loss of power. Stepup transformers increase voltage, step-down transformers reduce voltage. Most power supplies
use a step-down transformer to reduce the dangerously high voltage to a safer low voltage.
Description
The LM78XX/LM78XXA series of three-terminal positive regulators are available in the
TO-220/D-PAK package and with several fixed output voltages, making them useful in a Wide
range of applications. Each type employs internal current limiting, thermal shutdown and safe
operating area protection, making it essentially indestructible. If adequate heat sinking is
provided, they can deliver over 1A output Current. Although designed primarily as fixed voltage
regulators, these devices can be used with external components to obtain adjustable voltages and
currents.
21
22
3.3 -
RECTIFIER
23
3.4 - FILTER
Capacitive filter is used in this project. It removes the ripples from the output of rectifier and
smoothens the D.C. Output received from this filter is constant until the mains voltage and load
is maintained constant. However, if either of the two is varied, D.C. voltage received at this point
changes. Therefore a regulator is applied at the output stage.
The simple capacitor filter is the most basic type of power supply filter. The use of this
filter is very limited. It is sometimes used on extremely high-voltage, low-current power supplies
for cathode-ray and similar electron tubes that require very little load current from the supply.
24
This filter is also used in circuits where the power-supply ripple frequency is not critical and can
be relatively high. Below figure can show how the capacitor changes and discharges.
a versatile 8-bit CPU with in-system programmable Flash on a monolithic chip, the Atmel
AT89S52 is a powerful microcontroller which provides a highly-flexible and cost-effective
solution to many embedded control applications. The AT89S52 provides the following standard
features: 8K bytes of Flash, 256 bytes of RAM, 32 I/O lines, Watchdog timer, two data pointers,
three 16-bit timer/counters, a six-vector two-level interrupt architecture, a full duplex serial port,
on-chip oscillator, and clock circuitry. In addition, the AT89S52 is designed with static logic for
operation down to zero frequency and supports two software selectable power saving modes. The
Idle Mode stops the CPU while allowing the RAM, timer/counters, serial port, and interrupt
system to continue functioning. The Power-down mode saves the RAM contents but freezes the
oscillator, disabling all other chip functions until the next interrupt or hardware reset.
Features:
Compatible with MCS-51 Products
8K Bytes of In-System Programmable (ISP) Flash Memory
Endurance: 10,000 Write/Erase Cycles
4.0V to 5.5V Operating Range
Fully Static Operation: 0 Hz to 33 MHz
Three-level Program Memory Lock
256 x 8-bit Internal RAM
32 Programmable I/O Lines
Three 16-bit Timer/Counters
Eight Interrupt Sources
Full Duplex UART Serial Channel
Low-power Idle and Power-down Modes
Interrupt Recovery from Power-down Mode
Watchdog Timer
Dual Data Pointer
Power-off Flag
Fast Programming Time
26
27
Pin Description:
VCC:
Supply voltage.
GND:
Ground.
28
Port 0:
Port 0 is an 8-bit open drain bidirectional I/O port. As an output port, each pin can sink
eight TTL inputs. When 1s are written to port 0 pins, the pins can be used as high-impedance
inputs. Port 0 can also be configured to be the multiplexed low-order address/data bus during
accesses to external program and data memory. In this mode, P0 has internal pull-ups. Port 0 also
receives the code bytes during Flash programming and outputs the code bytes during program
verification. External pull-ups are required during program verification.
Port 1:
Port 1 is an 8-bit bidirectional I/O port with internal pull-ups. The Port 1 output buffers
can sink/source four TTL inputs. When 1s are written to Port 1 pins, they are pulled high by the
internal pull-ups and can be used as inputs. As inputs, Port 1 pins that are externally being pulled
low will source current (IIL) because of the internal pull-ups. In addition, P1.0 and P1.1 can be
configured to be the timer/counter 2 external count input (P1.0/T2) and the timer/counter 2
trigger input (P1.1/T2EX).
Port 2:
Port 2 is an 8-bit bidirectional I/O port with internal pull-ups. The Port 2 output buffers
can sink/source four TTL inputs. When 1s are written to Port 2 pins, they are pulled high by the
internal pull-ups and can be used as inputs. As inputs, Port 2 pins that are externally being pulled
low will source current (IIL) because of the internal pull-ups. Port 2 emits the high-order address
byte during fetches from external program memory and during accesses to external data memory
that use 16-bit addresses (MOVX @ DPTR). In this application, Port 2 uses strong internal pullups when emitting 1s. During accesses to external data memory that use 8-bit addresses (MOVX
@ RI), Port 2 emits the contents of the P2 Special Function Register.
Port 3:
Port 3 is an 8-bit bidirectional I/O port with internal pull-ups. The Port 3 output buffers
can sink/source four TTL inputs. When 1s are written to Port 3 pins, they are pulled high by the
internal pull-ups and can be used as inputs. As inputs, Port 3 pins that are externally being pulled
low will source current (IIL) because of the pull-ups.
29
RST:
Reset input. A high on this pin for two machine cycles while the oscillator is running
resets the device. This pin drives high for 98 oscillator periods after the Watchdog times out. The
DISRTO bit in SFR AUXR (address 8EH) can be used to disable this feature. In the default state
of bit DISRTO, the RESET HIGH out feature is enabled.
ALE/PROG:
Address Latch Enable (ALE) is an output pulse for latching the low byte of the address
during accesses to external memory. This pin is also the program pulse input (PROG) during
Flash programming.
In normal operation, ALE is emitted at a constant rate of 1/6 the oscillator frequency and may be
used for external timing or clocking purposes. Note, however, that one ALE pulse is skipped
during each access to external data memory.
PSEN:
Program Store Enable (PSEN) is the read strobe to external program memory. When the
AT89S52 is executing code from external program memory, PSEN is activated twice each
machine cycle, except that two PSEN activations are skipped during each access to external data
memory.
EA/VPP:
External Access Enable. EA must be strapped to GND in order to enable the device to
fetch code from external program memory locations starting at 0000H up to FFFFH. Note,
however, that if lock bit 1 is programmed, EA will be internally latched on reset. EA should be
strapped to VCC for internal program executions. This pin also receives the 12-volt
programming enable voltage (VPP) during Flash programming.
30
XTAL1:
Input to the inverting oscillator amplifier and input to the internal clock operating circuit.
XTAL2:
Output from the inverting oscillator amplifier.
Oscillator Characteristics:
XTAL1 and XTAL2 are the input and output, respectively, of an inverting amplifier
which can be configured for use as an on-chip oscillator, as shown in Figure 1. Either a quartz
crystal or ceramic resonator may be used. To drive the device from an external clock source,
XTAL2 should be left unconnected while XTAL1 is driven as shown in Figure 6.2. There are no
requirements on the duty cycle of the external clock signal, since the input to the internal
clocking circuitry is through a divide-by-two flip-flop, but minimum and maximum voltage high
and low time specifications must be observed.
31
Idle Mode
In idle mode, the CPU puts itself to sleep while all the on chip peripherals remain active. The
mode is invoked by software. The content of the on-chip RAM and all the special functions
registers remain unchanged during this mode. The idle mode can be terminated by any enabled
interrupt or by a hardware reset.
Power down Mode
In the power down mode the oscillator is stopped, and the instruction that invokes power
down is the last instruction executed. The on-chip RAM and Special Function Registers retain
their values until the power down mode is terminated. The only exit from power down is a
hardware reset. Reset redefines the SFRs but does not change the on-chip RAM. The reset should
not be activated before VCC is restored to its normal operating level and must be held active
long enough to allow the oscillator to restart and stabilize.
32
3.6 - LEDS
LEDs are semiconductor devices. Like transistors, and other diodes, LEDs are made out of
silicon. What makes an LED give off light are the small amounts of chemical impurities that are
added to the silicon, such as gallium, arsenide, indium, and nitride.
When current passes through the LED, it emits photons as a byproduct. Normal light
bulbs produce light by heating a metal filament until it is white hot. LEDs produce photons
directly and not via heat, they are far more efficient than incandescent bulbs.
Not long ago LEDs were only bright enough to be used as indicators on dashboards or
electronic equipment. But recent advances have made LEDs bright enough to rival traditional
lighting technologies. Modern LEDs can replace incandescent bulbs in almost any application.
Types of LEDS
LEDs are produced in an array of shapes and sizes. The 5 mm cylindrical package is the most
common, estimated at 80% of world production. The color of the plastic lens is often the same as the
actual color of light emitted, but not always. For instance, purple plastic is often used for infrared
LEDs, and most blue devices have clear housings. There are also LEDs in extremely tiny packages,
such as those found on blinkers and on cell phone keypads. The main types of LEDs are miniature,
high power devices and custom designs such as alphanumeric or multi-color.
33
White LEDS
Light Emitting Diodes (LED) have recently become available that are white and bright,
so bright that they seriously compete with incandescent lamps in lighting applications. They are
still pretty expensive as compared to a GOW lamp but draw much less current and project a
fairly well focused beam.
The diode in the photo came with a neat little reflector that tends to sharpen the beam a
little but doesn't seem to add much to the overall intensity.
When run within their ratings, they are more reliable than lamps as well. Red LEDs are
now being used in automotive and truck tail lights and in red traffic signal lights. You will be
able to detect them because they look like an array of point sources and they go on and off
instantly as compared to conventional incandescent lamps.
34
LEDs are monochromatic (one color) devices. The color is determined by the band gap of
the semiconductor used to make them. Red, green, yellow and blue LEDs are fairly common.
White light contains all colors and cannot be directly created by a single LED. The most
common form of "white" LED really isn't white. It is a Gallium Nitride blue LED coated with a
phosphor that, when excited by the blue LED light, emits a broad range spectrum that in addition
to the blue emission, makes a fairly white light.
There is a claim that these white LED's have a limited life. After 1000 hours or so of
operation, they tend to yellow and dim to some extent. Running the LEDs at more than their
rated current will certainly accelerate this process.
There are two primary ways of producing high intensity white-light using LEDS. One is
to use individual LEDS that emit three primary coloursred, green, and blueand then mix all
the colours to form white light. The other is to use a phosphor material to convert
monochromatic light from a blue or UV LED to broad-spectrum white light, much in the same
way a fluorescent light bulb works. Due to metamerism, it is possible to have quite different
spectra that appear white.
35
Efficiency:
LEDs produce more light per watt than incandescent bulbs; this is useful in
battery powered or energy-saving devices.
Size:
LEDs can be very small (smaller than 2 mm2) and are easily populated onto
printed circuit boards.
On/Off time:
LEDs light up very quickly. A typical red indicator LED will achieve full
brightness in microseconds. LEDs used in communications devices can have even
faster response times.
Cycling:
LEDs are ideal for use in applications that are subject to frequent on-off cycling,
unlike fluorescent lamps that burn out more quickly when cycled frequently, or
HID lamps that require a long time before restarting.
Cool light:
In contrast to most light sources, LEDs radiate very little heat in the form of IR
that can cause damage to sensitive objects or fabrics. Wasted energy is dispersed
as heat through the base of the LED.
Lifetime:
36
LEDs can have a relatively long useful life. One report estimates 35,000 to 50,000
hours of useful life, though time to complete failure may be longer.
No Toxicity:
LEDs do not contain mercury, unlike fluorescent lamps.
High price:
LEDs are currently more expensive, price per lumen, on an initial capital cost
basis, than most conventional lighting technologies.
Temperature dependence:
LED performance largely depends on the ambient temperature of the operating
environment. Over-driving the LED in high ambient temperatures may result in
overheating of the LED package, eventually leading to device failure.
Voltage sensitivity:
LEDs must be supplied with the voltage above the threshold and a current below
the rating. This can involve series resistors or current-regulated power supplies.
Blue Hazard:
There is increasing concern that blue LEDs and cool-white LEDs are now capable
of exceeding safe limits of the so-called blue-light hazard as defined in eye safety.
3.7 - BC547
TECHNICAL SPECIFICATIONS:
The BC547 transistor is an NPN Epitaxial Silicon Transistor. The BC547 transistor is a
general-purpose transistor in small plastic packages. It is used in general-purpose switching and
amplification BC847/BC547 series 45 V, 100 mA NPN general-purpose transistors.
emitter current Ie is the product of a very small base current to a very large collector current the
value of this parameter is very close to unity, and for a typical low-power signal transistor this
value ranges from about 0.950 to 0.999.
3.8 - 1N4007
Diodes are used to convert AC into DC these are used as half wave rectifier or full wave
rectifier. Three points must he kept in mind while using any type of diode.
1.
2.
3.
39
Diodes of number IN4001, IN4002, IN4003, IN4004, IN4005, IN4006 and IN4007 have
maximum reverse bias voltage capacity of 50V and maximum forward current capacity of 1
Amp.
Diode of same capacities can be used in place of one another. Besides this diode of more
capacity can be used in place of diode of low capacity but diode of low capacity cannot be used
in place of diode of high capacity. For example, in place of IN4002; IN4001 or IN4007 can be
used but IN4001 or IN4002 cannot be used in place of IN4007.The diode BY125made by
company BEL is equivalent of diode from IN4001 to IN4003. BY 126 is equivalent to diodes
IN4004 to 4006 and BY 127 is equivalent to diode IN4007.
40
3.9 - RESISTORS
41
42
Resistors are common elements of electrical networks and electronic circuits and are
ubiquitous in most electronic equipment. Practical resistors can be made of various compounds
and films, as well as resistance wire (wire made of a high-resistivity alloy, such as nickelchrome). Resistors are also implemented within integrated circuits, particularly analog devices,
and can also be integrated into hybrid and printed circuits.
The electrical functionality of a resistor is specified by its resistance: common
commercial resistors are manufactured over a range of more than 9 orders of magnitude. When
specifying that resistance in an electronic design, the required precision of the resistance may
require attention to the manufacturing tolerance of the chosen resistor, according to its specific
application. The temperature coefficient of the resistance may also be of concern in some
precision applications. Practical resistors are also specified as having a maximum power rating
which must exceed the anticipated power dissipation of that resistor in a particular circuit: this is
mainly of concern in power electronics applications. Resistors with higher power ratings are
physically larger and may require heat sinking. In a high voltage circuit, attention must
sometimes be paid to the rated maximum working voltage of the resistor.
The series inductance of a practical resistor causes its behavior to depart from ohms law;
this specification can be important in some high-frequency applications for smaller values of
resistance. In a low-noise amplifier or pre-amp the noise characteristics of a resistor may be an
issue. The unwanted inductance, excess noise, and temperature coefficient are mainly dependent
on the technology used in manufacturing the resistor. They are not normally specified
individually for a particular family of resistors manufactured using a particular technology. A
43
family of discrete resistors is also characterized according to its form factor, that is, the size of
the device and position of its leads (or terminals) which is relevant in the practical manufacturing
of circuits using them.
Units
The ohm (symbol: ) is the SI unit of electrical resistance, named after Georg Simon
Ohm. An ohm is equivalent to a volt per ampere. Since resistors are specified and manufactured
over a very large range of values, the derived units of milliohm (1 m = 103 ), kilohm (1 k =
103 ), and megohm (1 M = 106 ) are also in common usage.
The reciprocal of resistance R is called conductance G = 1/R and is measured in Siemens
(SI unit), sometimes referred to as a mho. Thus a Siemens is the reciprocal of an ohm: S = 1.
Although the concept of conductance is often used in circuit analysis, practical resistors are
always specified in terms of their resistance (ohms) rather than conductance.
VARIABLE RESISTORS
Adjustable resistors
A resistor may have one or more fixed tapping points so that the resistance can be
changed by moving the connecting wires to different terminals. Some wire wound power
resistors have a tapping point that can slide along the resistance element, allowing a larger or
smaller part of the resistance to be used.
Where continuous adjustment of the resistance value during operation of equipment is
required, the sliding resistance tap can be connected to a knob accessible to an operator. Such a
device is called a rheostat and has two terminals.
3.10 - CAPACITORS
44
A capacitor (formerly known as condenser) is a device for storing electric charge. The
forms of practical capacitors vary widely, but all contain at least two conductors separated by a
non-conductor. Capacitors used as parts of electrical systems, for example, consist of metal foils
separated by a layer of insulating film.
45
Capacitors are widely used in electronic circuits for blocking direct current while
allowing alternating current to pass, in filter networks, for smoothing the output of power
supplies, in the resonant circuits that tune radios to particular frequencies and for many other
purposes.
A capacitor is a passive electronic component consisting of a pair of conductors separated
by a dielectric (insulator). When there is a potential difference (voltage) across the conductors, a
static electric field develops in the dielectric that stores energy and produces a mechanical force
between the conductors. An ideal capacitor is characterized by a single constant value,
capacitance, measured in farads. This is the ratio of the electric charge on each conductor to the
potential difference between them.
The capacitance is greatest when there is a narrow separation between large areas of
conductor, hence capacitor conductors are often called "plates", referring to an early means of
construction. In practice the dielectric between the plates passes a small amount of leakage
current and also has an electric field strength limit, resulting in a breakdown voltage, while the
conductors and leads introduce an undesired inductance and resistance.
Theory of operation
Capacitance
46
Sometimes charge build-up affects the capacitor mechanically, causing its capacitance to vary. In
this case, capacitance is defined in terms of incremental changes:
47
Energy storage
Work must be done by an external influence to "move" charge between the conductors in a
capacitor. When the external influence is removed the charge separation persists in the electric
field and energy is stored to be released when the charge is allowed to return to its equilibrium
position. The work done in establishing the electric field, and hence the amount of energy stored,
is given by:
Current-voltage relation
The current i(t) through any component in an electric circuit is defined as the rate of flow of a
charge q(t) passing through it, but actual charges, electrons, cannot pass through the dielectric
layer of a capacitor, rather an electron accumulates on the negative plate for each one that leaves
the positive plate, resulting in an electron depletion and consequent positive charge on one
electrode that is equal and opposite to the accumulated negative charge on the other. Thus the
charge on the electrodes is equal to the integral of the current as well as proportional to the
voltage as discussed above. As with any antiderivative, a constant of integration is added to
represent the initial voltage v (t0). This is the integral form of the capacitor equation,
.
Taking the derivative of this, and multiplying by C, yields the derivative form,
48
The dual of the capacitor is the inductor, which stores energy in the magnetic field rather than the
electric field. Its current-voltage relation is obtained by exchanging current and voltage in the
capacitor equations and replacing C with the inductance L.
HC-05 module is an easy to use Bluetooth SPP (Serial Port Protocol) module, designed for transparent wireless
serial connection setup.
Serial port Bluetooth module is fully qualified Bluetooth V2.0+EDR (Enhanced Data Rate) 3Mbps Modulation
with complete 2.4GHz radio transceiver and baseband. It uses CSR Bluecore 04-External single chip Bluetooth
system with CMOS technology and with AFH(Adaptive Frequency Hopping Feature).
Hardware Features
49
PIO control
Software Features
Default Baud rate: 38400, Data bits:8, Stop bit:1,Parity:No parity, Data control: has.
PIO10 and PIO11 can be connected to red and blue led separately. When master and slave
are paired, red and blue led blinks 1time/2s in interval, while disconnected only blue led blinks 2times/s.
3.12 - RELAY
50
4. SCHEMATIC DIAGRAM
51
52
Power supplies made from these blocks are described below with a circuit diagram and a
graph of their output:
Transformer only
The low voltage AC output is suitable for lamps, heaters and special AC motors. It
is not suitable for electronic circuits unless they include a rectifier and a smoothing capacitor.
53
Transformer + Rectifier
The varying DC output is suitable for lamps, heaters and standard motors. It is not suitable
for electronic circuits unless they include a smoothing capacitor.
The smooth DC output has a small ripple. It is suitable for most electronic circuits.
54
The regulated DC output is very smooth with no ripple. It is suitable for all electronic
circuits.
STANDARD
CONNECTIONS
TO
8051
SERIES
MICRO
CONTROLLER
ATMEL series of 8051 family of micro controllers need certain standard connections.
The actual number of the Microcontroller could be 89C51 , 89C52, 89S51, 89S52, and
as regards to 20 pin configuration a number of 89C2051. The 4 set of I/O ports are used based
on the project requirement. Every microcontroller requires a timing reference for its internal
program execution therefore an oscillator needs to be functional with a desired frequency to
obtain the timing reference as t =1/f.
A crystal ranging from 2 to 20 MHz is required to be used at its pin number 18 and 19 for
the internal oscillator. It may be noted here the crystal is not to be understood as crystal oscillator
It is just a crystal, while connected to the appropriate pin of the microcontroller it results in
oscillator function inside the microcontroller. Typically 11.0592 MHz crystal is used in general
for most of the circuits using 8051 series microcontroller. Two small value ceramic capacitors of
33pF each is used as a standard connection for the crystal as shown in the circuit diagram.
RESET
55
External Access(EA):
Pin no 31 of 40 pin 8051 microcontroller termed as EA is required to be connected to 5V for
accessing the program form the on-chip program memory. If it is connected to ground then the
controller accesses the program from external memory. However as we are using the internal
memory it is always connected to +5V.
56
58
5. SOFTWARE IMPLEMENTATION
59
#include<reg52.h>
//header 8051
#include<string.h>
sbit relay1=P2^7;
/////declarations
sbit relay2=P2^6;
sbit relay3=P2^5;
sbit led1=P2^3;
sbit led2=P2^2;
sbit led3=P2^1;
sbit led_dat=P1^6;
void delay(int);
char store[30],q=0;
bit a;
void serial(void) interrupt 4
{
RI=0;
if((store[0]=='*') || (SBUF=='*' && q==0))
{
store[q]=SBUF;
q++;
led_dat=0;
}
60
if(store[q-1]=='#')
{
a=1;
q=0;
delay(500);
led_dat=1;
}
}
void main()
{
char cmp=0;
TMOD=0X20;
SCON=0X50;
IE=0X90;
TH1=-3;
TR1=1;
IT0=1;
relay1=relay2=relay3=0;
led1=led2=led3=led_dat=0;
// check signal
61
delay(2000);
led1=led2=led3=led_dat=1;
while(1)
{
if(a==1)
{
a=0;
//// comparing recived string with number of possibilies
if((memcmp(store,"*1 on#",5)==0)||(memcmp(store,"*one on#",7)==0))
{
relay1=1;
led1=0;
}
else if((memcmp(store,"*2 on#",5)==0)||(memcmp(store,"*two on#",7)==0)
||(memcmp(store,"*to on#",6)==0)||(memcmp(store,"*too on#",7)==0))
{
relay2=1;
// relay 2 on
led2=0;
}
{
relay3=1;
led3=0;
}
else if((memcmp(store,"*1 off#",6)==0)||(memcmp(store,"*one off#",8)==0)
||(memcmp(store,"*1 of#",5)==0)||(memcmp(store,"*one of#",7)==0))
{
relay1=0;
led1=1;
}
else if((memcmp(store,"*2 off#",6)==0)||(memcmp(store,"*two off#",8)==0)
||(memcmp(store,"*to off#",7)==0)||(memcmp(store,"*too off#",8)==0)
||(memcmp(store,"*2 of#",5)==0)||(memcmp(store,"*two of#",7)==0)
||(memcmp(store,"*to of#",6)==0)||(memcmp(store,"*too off#",7)==0))
{
relay2=0;
led2=1;
}
else if((memcmp(store,"*3 off#",6)==0)||(memcmp(store,"*three off#",10)==0)
||(memcmp(store,"*free off#",9)==0)||(memcmp(store,"*tree off#",9)==0)
||(memcmp(store,"*3 of#",5)==0)||(memcmp(store,"*three of#",9)==0)
||(memcmp(store,"*free of#",8)==0)||(memcmp(store,"*tree of#",8)==0))
63
{
relay3=0;
led3=1;
}
else if((memcmp(store,"*all on#",7)==0)||(memcmp(store,"*call on#",8)==0))
{
relay1=relay2=relay3=1;
led1=led2=led3=0;
}
else if((memcmp(store,"*all off#",8)==0)||(memcmp(store,"*all off#",8)==0)
||(memcmp(store,"*call of#",8)==0)||(memcmp(store,"*call of#",8)==0))
{
relay1=relay2=relay3=0;
led1=led2=led3=1;
}
}
}
}
int i=0,j=0;
for(i=0;i<itime;i++)
for(j=0;j<125;j++);
}
65
6. HARDWARE TESTING
6.1. CONTINUITY TEST:
In electronics, a continuity test is the checking of an electric circuit to see if current flows
(that it is in fact a complete circuit). A continuity test is performed by placing a small voltage
(wired in series with an LED or noise-producing component such as a piezoelectric speaker)
across the chosen path. If electron flow is inhibited by broken conductors, damaged components,
or excessive resistance, the circuit is "open".
Devices that can be used to perform continuity tests include multi meters which measure
current and specialized continuity testers which are cheaper, more basic devices, generally with a
simple light bulb that lights up when current flows.
An important application is the continuity test of a bundle of wires so as to find the two
ends belonging to a particular one of these wires; there will be a negligible resistance between
the "right" ends, and only between the "right" ends.
This test is the performed just after the hardware soldering and configuration has been
completed. This test aims at finding any electrical open paths in the circuit after the soldering.
Many a times, the electrical continuity in the circuit is lost due to improper soldering, wrong and
rough handling of the PCB, improper usage of the soldering iron, component failures and
presence of bugs in the circuit diagram. We use a multi meter to perform this test. We keep the
multi meter in buzzer mode and connect the ground terminal of the multi meter to the ground.
We connect both the terminals across the path that needs to be checked. If there is continuation
then you will hear the beep sound.
66
MANUAL
67
70
5. Give voice commands through mobile microphone. The commands should be as follows:
1. 1 On To Turn on first relay.
2. 2 On To Turn on second relay
3. 3 On To Turn on third relay
4. 1 Off To Turn off first relay.
5. 2 Off To Turn off second relay
6. 3 Off To Turn off third relay
7. All On To Turn on all relays.
8. All Off To Turn off all relays.
71
6. Now the data LED will glow for 1 sec and the command will be executed and respected
operation will be done. For E.g. for command 3 on the 3rd LED will be turned on,
which indicate that the third relay is on. Any device connected to the relay 3 will be
turned on lets say a bulb in the picture.
72
73
CONCLUSION
The proposed project undertakes a viable solution the need of automation at the very basic level,
that is, in our homes. The project will enable us to bring every appliance at every corner of our
home under our control from a single point without having to get up and manually switch on or
off the appliance. The use of a Bluetooth module assists the use of this system from various
locations in our house.
The system is further simplified by allowing appliances to be controlled by our voice. The user
need not have to have to immense knowledge over the language of English. Just by saying the
appliance name and the corresponding number assigned to that particular appliance, and telling it
to switch on or off will enable the user to have complete control over any appliance without any
effort.
Android applications are very simple and user friendly allowing the user to understand its
functionalities in very little time. Hence, the use of android application in this system allows a
user to easily learn the process and get accustomed to the functions. Moreover, the entire system
is very flexible and scalable. Any number of appliances can be added as and when required.
Hence, the systems finds use not only in houses but also in many offices where appliances such
as fans or lights on multiple floors can be controlled by a person on any of the floors, saving
manual labour and human effort to switch on or off the electronic appliances, thereby saving
time.
This system, though primarily aimed to reduce human effort, will be of much importance to old
aged people and physically handicapped people. It will enable them to control their home
devices with ease, without going through much pressure or stress of moving about.
74
Due to the inexpensive materials used in the construction and further cost optimization if the
device is taken to the market, it finds application in a wide area. Scalability of the project would
be considerably easier as the device can be used in every building using electrical appliances and
devices.
BIBLIOGRAPHY
TEXT BOOKS REFERED:
1. The 8051 Microcontroller and Embedded systems by Muhammad Ali Mazidi and Janice
Gillispie Mazidi , Pearson Education.
2. ATMEL 89S52 Data Sheets.
http://electronicsclub.info/powersupplies.htm
http://wiki.iteadstudio.com/Serial_Port_Bluetooth_Module_(Master/Slave)_:_HC-05
http://research.ijcaonline.org/volume121/number15/pxc3904904.pdf
75