You are on page 1of 46

Summer training report

on

Programmable logic controller

Submitted in partial fulfilment of requirements for the award of the


Degree of
Bachelor of Technology
In
Electrical Engineering

Under the guidance of Ms. Preet kanwal(Asst. Prof., EE)

Submitted By
DEEPAK SHUKLA
(1218775)

DEPARTMENT OF ELECTRICAL ENGINEERING


SETH JAI PARKASH MUKAND LAL INSTITUTE OF ENGINEERING AND
TECHNOLOGY
RADAUR, YAMUNANAGAR
September, 2020
CANDIDATE’S DECLARATION

I hereby declare that the work presented in this report entitled “programmable logic
controller“ in fulfilment of the requirement for the award of the degree Bachelor of
Technology in Electrical Engineering, submitted in Electrical Department, JMIT affiliated to
Kurukshetra University, is an authentic record of my own work carried out during my degree
under the guidance of Ms. Preet kanwal

The work reported in this has not been submitted by me for award of another degree or
diploma.

Date: 17-12-2020
Place: Radaur

i
CERTIFICATE

This is to certify that the Project work entitled “programmable logic controller” submitted by
Deepak shukla in fulfilment for the requirements of the award of Bachelor of Technology
Degree in Electrical Engineering at JMIT, Radaur is an authentic work carried out by him
under my supervision and guidance. To the best of my knowledge, the matter embodied in
the project has not been submitted to any other University / Institute for the award of any
Degree.

Date: 17-12-2020 Ms. Preet kanwal


(Asst. Prof.,
EE)

ii
ACKNOWLEDGEMENT

I express my sincere gratitude to Dr. Rishi swarup (HOD, EE) and Ms. preet kanwal (A.P,
EE) for his valuable guidance and timely suggestions during the entire duration of my
dissertation work, without which this work would not have been possible. I would also like to
convey my deep regards to all other faculty members of department of EE, who have
bestowed their great effort and guidance at appropriate times without which it would have
been very difficult on my part to finish this work. Finally, I would also like to thank my
friends for their advice and pointing out my mistakes.

iii
LIST OF FIGURES

1. Fig. 2.1 Microcontroller


5
2. Fig. 2.2 IC L293D
6
3. Fig. 2.3 IC LM358
7
4. Fig. 2.4 Transistor
8
5. Fig. 2.5 Transistor Circuit
9
6. Fig. 2.6 Diode
9
7. Fig. 2.7 Diode Symbol
10
8. Fig. 2.8 Transformer
10
9. Fig. 2.9 Transformer Circuit
11
10. Fig. 2.10 Types of Transformer
12
11. Fig. 2.11 Step Down Transformer
12
12. Fig. 2.12 Resistor 13
13. Fig. 2.13 Resistor Symbol
13
14. Fig. 2.14 Voltage Regulator
14
15. Fig. 2.15 Capacitor
15
16. Fig. 2.16 Film Capacitor
17
17. Fig. 2.17 Ceramic Capacitor 17
18. Fig. 2.18 Electrolytic Capacitor 18
19. Fig. 2.19 Variable Capacitor 19
20. Fig. 2.20 Relay 19

iv
21. Fig. 2.21 Relay Symbol
20
22. Fig. 2.22 IR Sensor
20
23. Fig. 2.23 PCB
21
24. Fig. 2.24 LED
22
25. Fig. 2.25 Photodiode Sensor
22
26. Fig. 2.26 LCD
23
27. Fig. 2.27 Toggle Switch
24
28. Fig. 2.28 Pushbutton Switch 24
29. Fig. 2.29 Temperature Switch
25
30. Fig. 2.30 Liquid Switch
25
31. Fig. 2.31 MATLAB
26
32. Fig. 3.1 Microcontroller Circuit
28
33. Fig. 3.2 LCD Circuit
28
34. Fig. 3.3 Fan Circuit
29
35. Fig. 3.4 Motor Circuit
29
36. Fig. 3.5 Light Circuit
29
37. Fig. 3.6 IR Sensor Circuit
30
38. Fig. 3.7 Temperature Sensing Circuit
30
39. Fig. 3.8 Power Supply Circuit
31

v
40. Fig. 3.9 Practical Circuit
31
41. Fig. 3.10 Half Wave Rectifier
34
42. Fig. 3.11 Centre Tapped Rectifier
35
43. Fig. 3.12 Bridge Rectifier
35

vi
CONTENTS

Candidate’s declaration i

Certificate ii

Acknowledgement
iii

List of figures
iv

Chapter 1 Introduction 1
1.1 Introduction 1
1.2 Need of Automation 2
1.3 Materials Required 2
Chapter 2 Hardware and Software Description 5

2.1 Components 5
2.2 Software Requirement 24
Chapter 3 Circuit Description 26

3.1 Circuit Diagram 26


3.2 Working
30
Chapter 4 Conclusion and Future scope 34

4.1 Conclusion 34
4.2 Future Scope 34
References 35
i
CHAPTER 1 INTRODUCTION

1.1 Introduction

With advancement of technology things are becoming simpler and easier for us. Automation
is the use of control systems and information technologies to reduce the need for human work
in the production of goods and services. In the scope of industrialization, automation is a step
beyond mechanization. Whereas mechanization provided human operators with machinery to
assist them with the muscular requirements of work, automation greatly decreases the need
for human sensory and mental requirements as well. Automation plays an increasingly
important role in the world economy and in daily experience. Automatic systems are being
preferred over manual system. Through in this project we have tried to show automatic
control of a house as a result of which power is saved to some extent.

Home automation is the control of any or all electrical devices in our home or office, whether
we are there or away. Home/office automation is one of the most exciting developments in
technology for the home that has come along in decades. There are hundreds of products
available today that allow us control over the devices automatically, either by remote control;
or even by voice command. Home automation (also called demotics) is the residential
extension of "building automation". It is automation of the home, housework or household
activity. Home automation may include centralized control of lighting, HVAC (heating,
ventilation and air conditioning), appliances, and other systems, to provide improved
convenience, comfort, energy efficiency and security. Disabled can provide increased quality
of life for persons who might otherwise require caregivers or institutional care. A home
automation system integrates electrical devices in a house with each other. The techniques
employed in home automation include those in building automation as well as the control of
domestic activities, such as home entertainment systems, houseplant and yard watering, pet
feeding, changing the ambiance "scenes" for different events (such as dinners or parties), and
the use of domestic robots. Devices may be connected through a computer network to allow
control by a personal computer, and may allow remote access from the internet.

Typically, a new home is outfitted for home automation during construction, due to the
accessibility of the walls, outlets, and storage rooms, and the ability to make design changes
specifically to accommodate certain technologies. Wireless systems are commonly installed
1
when outfitting a pre-existing house, as they reduce wiring changes. These communicate
through the existing power wiring, radio, or infrared signals with a central controller.
Network sockets may be installed in every room like AC power receptacles. Although
automated homes of the future have been staple exhibits for World's Fairs and popular
backgrounds in science fiction, complexity, competition between vendors, multiple
incompatible standards and the resulting expense have limited the penetration of home
automation to homes of the wealthy or ambitious hobbyists.

1.2 Need of Automation

Earlier, we looked into the face of future when we talked about automated devices, which
could do anything on instigation of a controller, but today it has become a reality.

a) An automated device can replace good amount of human working force, moreover
humans are more prone to errors and in intensive conditions the probability of error increases
whereas, an automated device can work with diligence, versatility and with almost zero error.
Replacing human operators in tasks that involve hard physical or monotonous work.
Replacing humans in tasks done in dangerous environments (i.e. fire, space, volcanoes,
nuclear facilities, underwater, etc.) Performing tasks that are beyond human capabilities of
size, weight, speed, endurance.

b) Economy improvement. Automation may improve in economy of enterprises, society or


most of humankind. For example, when an enterprise that has invested in automation
technology recovers its investment, or when a state or country increases its income due to
automation like Germany or Japan in the 20th Century.

That is way this project looks into construction and implementation of a system involving
hardware to control a variety of electrical and electronics system.

1.3 Materials Required

Control Board Circuit:

1. Microcontroller: Pic16f887
2. Diode: IN4007 (4 pc)

3. Relay: 12V (2 pc)

4. Capacitor: 1000uf/50V (1 pc)

2
5. LCD: 16x2

6. IC: L293D (1 pc)

7. Transistor: BC547 (3 pc)

8. Micro Switch (2 pc)

9. Ceramic Capacitor: 0.1µf (2 pc)

10. Resistor: 1kΩ (5 pc)

11. Resistor: 10kΩ (5 pc)

12. PCB (1 pc)

Power Supply Circuit:

1. Transformer: 0-12 V/1 A (1 pc)


2. Diode: IN4007 (4 pc)
3. Ceramic Capacitor: 0.1µf (2 pc)
4. Electrolyte Capacitor: 100µf (2 pc)
5. Voltage Regulator: LM7805 (1 pc)
6. Zener Diode: 5.1V (2 pc)
7. LED: 2V (1 pc)

8. 1kΩ Resistor (1pc)


9. 2 Pin Connector (1 pc)
10. Shoes Cable (1 pc) IR Sensor Module:

1. IR Sensor (2 pc)

2. Photodiode Sensor (2 pc)

3. IC: LM358 (2 pc)

4. Variable Resistor: 100kΩ (2 pc)

5. Resistor: 1kΩ, 10kΩ (8 pc)

External Peripherals:

1. Water Pump (1 pc)

2. DC Fan: 12V (1 pc)

3
3. Temperature Sensor: LM35 (1 pc)

4. Bulb Holder (1 pc)

5. LED Bulb (1 pc)

6. DVD Loader (1 pc)

4
CHAPTER 2 HARDWARE AND SOFTWARE DESCRIPTION

2.1 Components

2.1.1 Microcontroller (PIC16F887)

Fig. 2.1 Microcontroller

PIC16F887 is a 40-pin (for PDIP package) and 8-bit CMOS PIC Microcontroller that comes
with Nano Watt technology. Economical price and user-friendly architecture make this device
easy to use and easy to configure. It is available in three packages known as PDIP, QFN, and
TQFP. The first one comes with a 40-pin layout design while remaining two contains 44 pins
on each layout. This PIC version, like other models in the PIC community, contains
everything that is required to make an embedded system and drive automation.

The PIC16F887 incorporates 256 bytes of EEPROM data memory, 368 bytes of RAM, and
program memory of 8K. Apart from self-programming capability, it also contains 2
Comparators,10-bit Analog-to-Digital (A/D) converter with 14 channels, and capture,
compare and PWM functions. The asynchronous serial port is added on the chip that can be
configured both ways i.e. the 2-wire Inter-Integrated Circuit (I²C™) Bus or 3-wire Serial
Peripheral Interface (SPI™) The Enhanced Universal Asynchronous Receiver Transmitter
(EUSART) feature makes this chip compatible with the devices where serial communication
is an integral part of the project.

The functions that make this device unique in terms of ease of use include

1. Power-Saving Sleep mode


2. Industrial and Extended Temperature range
3. Wide operating voltage range (2.0V-5.5V)
4. SR Latch mode
5. Power-up Timer (PWRT) and Oscillator Start-up Timer (OST)

5
6. Power-on Reset (POR)
7. Ultra-Low-Power Wake-up (ULPWU)
8. Multiplexed Master Clear with pull-up/input pin
9. Individually programmable weak pull-ups
10. Brown-out Reset (BOR) with software control option
11. Enhanced low-current Watchdog Timer (WDT)

2.1.2 IC (L293D)

L293D is a typical Motor driver or Motor Driver IC which allows DC motor to drive on either
direction. L293D is a 16-pin IC which can control a set of two DC motors simultaneously in
any direction. It means that you can control two DC motor with a single L293D IC. Dual
Hbridge Motor Driver integrated circuit (IC). The L293D can drive small and quiet big
motors as well.

Fig. 2.2 IC L293D

It works on the concept of H-bridge. H-bridge is a circuit which allows the voltage to be
flown in either direction. As you know voltage need to change its direction for being able to
rotate the motor in clockwise or anticlockwise direction, Hence H-bridge IC are ideal for
driving a DC motor. In a single L293D chip there are two h-Bridge circuit inside the IC
which can rotate two dc motor independently. Due its size it is very much used in robotic
application for controlling DC motors There are 4 input pins for l293d, pin 2,7 on the left and
pin 15 ,10 on the right as shown on the pin diagram. Left input pins will regulate the rotation
of motor connected across left side and right input for motor on the right-hand side. The

6
motors are rotated on the basis of the inputs provided across the input pins as LOGIC 0 or
LOGIC 1. In simple you need to provide Logic 0 or 1 across the input pins for rotating the
motor.

2.1.3 IC (LM358)

LM358 consists of two independent, high gain operational amplifiers in one package.
Important feature of this IC is that we do not require independent power supply for working
of each comparator for wide range of power supply. LM358 can be used as transducer
amplifier, DC gain block etc. It has large dc voltage gain of 100dB. This IC can be operated
on wide range of power supply from 3V to 32V for single power supply or from ±1.5V to
±16V for dual power supply and it also support large output voltage swing.

Fig. 2.3 IC LM358

From the above figure you can see that operational amplifier has two inputs and one output in
one independent LM358. Inputs are at pin 2 (negative pin) and 3 (positive pin), positive pin is
used for positive feedback and negative pin is used for negative feedback. In ideal condition
when no feedback is applied, gain of the operational amplifier should be infinite. When
voltage at pin 2 is more than voltage at pin 3 it will raise the output towards the positive
maximum voltage and a slight increase at negative pin compared to positive pin will lower

7
the output towards the negative maximum. This feature of operational amplifier makes it
suitable for the purpose of level detection.

2.1.4 Transistor (BC507)

Fig. 2.4 Transistor

A transistor is a semiconductor device used to amplify or switch electronic signals and


electrical power. It is composed of semiconductor material usually with at least three
terminals for connection to an external circuit. A voltage or current applied to one pair of the
transistor's terminals controls the current through another pair of terminals. Because the
controlled (output) power can be higher than the controlling (input) power, a transistor can
amplify a signal. Today, some transistors are packaged individually, but many more are found
embedded in integrated circuits.

Earlier, the critical and important component of an electronic device was a vacuum tube; it is
an electron tube used to control electric current. The vacuum tubes worked but they are
bulky, require higher operating voltages, high power consumption, yield lower efficiency and
cathode electron-emitting materials are used up in operation. So, that ended up as heat which
shortened the life of the tube itself. To overcome these problems, John Bardeen, Walter
Brattain and William Shockley were invented a transistor at Bell Labs in the year of 1947.
This new device was a much more elegant solution to overcome many of the fundamental
limitations of vacuum tubes.

8
Fig. 2.5 Transistor Circuit

Transistor is a semiconductor device that can both conduct and insulate. A transistor can act
as a switch and an amplifier. It converts audio waves into electronic waves and resistor,
controlling electronic current. Transistors have very long life, smaller in size, can operate on
lower voltage supplies for greater safety and required no filament current. The first transistor
was fabricated with germanium. A transistor performs the same function as a vacuum tube
triode, but using semiconductor junctions instead of heated electrodes in a vacuum chamber.
It is the fundamental building block of modern electronic devices and found everywhere in
modern electronic systems.

2.1.5 Diode

Fig. 2.6 Diode

A diode is defined as a two-terminal electronic component that only conducts current in one
direction (so long as it is operated within a specified voltage level). An ideal diode will have
zero resistance in one direction, and infinite resistance in the reverse direction.

Although in the real world, diode’s can not achieve zero or infinite resistance. Instead, a diode
will have negligible resistance in one direction (to allow current flow), and a very high
resistance in the reverse direction (to prevent current flow). A diode is effectively like a valve
for an electrical circuit.

9
Semiconductor diodes are the most common type of diode. These diodes begin conducting
electricity only if a certain threshold voltage is present in the forward direction (i.e. the “low
resistance” direction). The diode is said to be “forward biased” when conducting current in
this direction. When connected within a circuit in the reverse direction (i.e. the “high
resistance” direction), the diode is said to be “reverse biased”.

A diode only blocks current in the reverse direction (i.e. when it is reverse biased) while the
reverse voltage is within a specified range. Above this range, the reverse barrier breaks. The
voltage at which this breakdown occurs is called the “reverse breakdown voltage”. When the
voltage of the circuit is higher than the reverse breakdown voltage, the diode is able to
conduct electricity in the reverse direction (i.e. the “high resistance” direction). This is why in
practice we say diode’s have a high resistance in the reverse direction – not an infinite
resistance.

A PN junction is the simplest form of the semiconductor diode. In ideal conditions, this PN
junction behaves as a short circuit when it is forward biased, and as an open circuit when it is
in the reverse biased. The name diode is derived from “di–ode” which means a device that
has two electrodes.

Diode Symbol

Fig. 2.7 Diode Symbol

2.1.6 Transformer (Step Down)

Fig. 2.8 Transformer

10
A transformer is a passive electrical device that transfers electrical energy between two or
more circuits. A varying current in one coil of the transformer produces a varying magnetic
flux, which, in turn, induces a varying electromotive force across a second coil wound around
the same core. Electrical energy can be transferred between the two coils, without a metallic
connection between the two circuits. Faraday's law of induction discovered in 1831 described
the induced voltage effect in any coil due to changing magnetic flux encircled by the coil.

Transformers are used for increasing or decreasing the alternating voltages in electric power
applications, and for coupling the stages of signal processing circuits. Since the invention of
the first constant-potential transformer in 1885, transformers have become essential for the
transmission, distribution, and utilization of alternating current electric power. A wide range
of transformer designs is encountered in electronic and electric power applications.
Transformers range in size from RF transformers less than a cubic centimetre in volume, to
units weighing hundreds of tons used to interconnect the power grid.

Fig. 2.9 Transformer Circuit

There are various types of transformer used in the electrical power system for different
purposes, like generation, distribution and transmission and utilization of electrical power.
The different types of transformer are Step up and Step-down Transformer, Power
Transformer, Distribution Transformer, Instrument transformer comprising current and
Potential Transformer, Single phase and Three phase transformer, Auto transformer, etc.

11
Fig. 2.10 Types of Transformer

Step up and Step down Transformer

This type of transformer is categorized on the basis of a number of turns in the primary and
secondary windings and the induced emf.

Step up transformer transforms a low voltage, high current AC into a high voltage, low
current AC system In this type of transformer the number of turns in the secondary winding is
greater than the number of turns in the primary winding. If (V 2 > V1) the voltage is raised on
the output side and is known as Step up transformer

Step down transformer converts a high primary voltage associated with the low current into a
low voltage, high current. With this type of transformer, the number of turns in the primary
winding is greater than the number of turns in the secondary winding. If (V 2 < V1) the voltage
level is lowered on the output side and is known as Step down transformer

Fig. 2.11 Step Down Transformer

12
2.1.7 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.

Fig. 2.12 Resistor

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.
Symbol: - R

Fig. 2.13 Resistor Symbol

Formula: -

13
R = Resistance

V = Voltage Drop

I = Current

ρ = Resistivity conductor

L = Length of conductor

A = Area of cross section of conductor

2.1.8 Voltage Regulator (LM7805)

Fig. 2.14 Voltage Regulator

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


voltage regulator may use a simple feed-forward design or may include negative feedback. It
may use an electromechanical mechanism, or electronic components. Depending on the
design, it may be used to regulate one or more AC or DC voltages.

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. In automobile
alternators and central power station generator plants, voltage regulators control the output of
the plant. In an electric power distribution system, voltage regulators may be installed at a
substation or along distribution lines so that all customers receive steady voltage independent
of how much power is drawn from the line.

14
A simple voltage/current regulator can be made from a resistor in series with a diode (or
series of diodes). Due to the logarithmic shape of diode V-I curves, the voltage across the
diode changes only slightly due to changes in current drawn or changes in the input. When
precise voltage control and efficiency are not important, this design may be fine. Since the
forward voltage of a diode is small, this kind of voltage regulator is only suitable for low
voltage regulated output. When higher voltage output is needed, a Zener diode or series of
Zener diodes may be employed. Zener diode regulators make use of the Zener diode's fixed
reverse voltage, which can be quite large.

Feedback voltage regulators operate by comparing the actual output voltage to some fixed
reference voltage. Any difference is amplified and used to control the regulation element in
such a way as to reduce the voltage error. This forms a negative feedback control loop;
increasing the open-loop gain tends to increase regulation accuracy but reduce stability.
(Stability is avoidance of oscillation, or ringing, during step changes.) There will also be a
trade-off between stability and the speed of the response to changes. If the output voltage is
too low (perhaps due to input voltage reducing or load current increasing), the regulation
element is commanded, up to a point, to produce a higher output voltage–by dropping less of
the input voltage (for linear series regulators and buck switching regulators), or to draw input
current for longer periods (boost-type switching regulators); if the output voltage is too high,
the regulation element will normally be commanded to produce a lower voltage. However,
many regulators have over-current protection, so that they will entirely stop sourcing current
(or limit the current in some way) if the output current is too high, and some regulators may
also shut down if the input voltage is outside a given range.

2.1.9 Capacitor

Fig. 2.15 Capacitor

15
A capacitor is a device that stores electrical energy in an electric field. It is a passive
electronic component with two terminals.

The effect of a capacitor is known as capacitance. While some capacitance exists between any
two electrical conductors in proximity in a circuit, a capacitor is a component designed to add
capacitance to a circuit. The capacitor was originally known as a condenser or condensator.
The original name is still widely used in many languages, but not commonly in English.

Capacitors contain at least two electrical conductors often in the form of metallic plates or
surfaces separated by a dielectric medium. A conductor may be a foil, thin film, sintered bead
of metal, or an electrolyte. The nonconducting dielectric acts to increase the capacitor's
charge capacity. Materials commonly used as dielectrics include glass, ceramic, plastic film,
paper, mica, air, and oxide layers. Capacitors are widely used as parts of electrical circuits in
many common electrical devices. Unlike a resistor, an ideal capacitor does not dissipate
energy. When an electric potential, a voltage, is applied across the terminals of a capacitor,
for example when a capacitor is connected across a battery, an electric field develops across
the dielectric, causing a net positive charge to collect on one plate and net negative charge to
collect on the other plate. No current actually flows through the dielectric. However, there is a
flow of charge through the source circuit. If the condition is maintained sufficiently long, the
current through the source circuit ceases. If a time-varying voltage is applied across the leads
of the capacitor, the source experiences an ongoing current due to the charging and
discharging cycles of the capacitor.

From Coulomb's law a charge on one conductor will exert a force on the charge carriers
within the other conductor, attracting opposite polarity charge and repelling like polarity
charges, thus an opposite polarity charge will be induced on the surface of the other
conductor. The conductors thus hold equal and opposite charges on their facing surfaces, and
the dielectric develops an electric field. An ideal capacitor is characterized by a constant
capacitance C, in farads in the SI system of units, defined as the ratio of the positive or
negative charge Q on each conductor to the voltage V between them:

𝑄
𝐶= 𝑉
A capacitance of one farad (F) means that one coulomb of charge on each conductor causes a
voltage of one volt across the device. Because the conductors (or plates) are close together,
the opposite charges on the conductors attract one another due to their electric fields,
allowing the capacitor to store more charge for a given voltage than when the conductors are
separated, yielding a larger capacitance. In practical devices, charge build-up sometimes
16
affects the capacitor mechanically, causing its capacitance to vary. In this case, capacitance is
defined in terms of incremental changes:

𝑑𝑄
𝐶=
𝑑𝑉

Types of Capacitor: - 1.

Film Capacitors:

Fig. 2.16 Film Capacitors

Film Capacitors are the most normally ready of numerous types of capacitors, comprising of a
generally expansive group of capacitors with the distinction being in their dielectric
properties. They are available in almost any value and voltages as high as 1500 volts. They
come in any tolerance from 10% to 0.01%. Film capacitors additionally arrive in a
combination of shapes and case styles. There are two types of film capacitors, radial lead type
and axial lead type. The electrodes of film capacitors may be metalized aluminium or zinc,
applied on one or both sides of the plastic film, resulting in metalized film capacitors called
film capacitors. The film capacitor is shown in figure below:

2. Ceramic Capacitors:

Fig. 2.17 Ceramic Capacitors

Ceramic capacitors are used in high frequency circuits such as audio to RF. They are also the
best choice for high frequency compensation in audio circuits. These capacitors are also
called as disc capacitors. Ceramic capacitors are made by coating two sides of a small
porcelain or ceramic disc with silver and are then stacked together to make a capacitor. One

17
can make both low capacitance and high capacitance in ceramic capacitors by changing the
thickness of the ceramic disc used. The ceramic capacitor is shown in figure below:

They come in values from a few Pico farads to 1 microfarad. The voltage range is from a few
volts up to many thousands of volts. Ceramics are inexpensive to manufacture and they come
with several dielectric types. The tolerance of ceramics is not great but for their intended role
in life they work just fine.

3. Electrolytic Capacitors:

Fig. 2.18 Electrolytic Capacitors

These are the most prevalently used capacitors which have a wide tolerance capacity.
Electrolytic capacitors are available with working voltages up to about 500V, although the
highest capacitance values are not available at high voltage and higher temperature units are
available, but uncommon. There are two types of electrolytic capacitor, tantalum and
aluminium in common.

Tantalums capacitors have ordinarily better exhibition, higher value, and are ready just in a
more limited extend of parameters. The dielectric properties of tantalum oxide is much
superior to those of aluminium oxide giving an easier leakage current and better capacitance
strength which makes them suitable for obstructing, decoupling, filtering applications.

The thickness of the aluminium oxide film and heightened breakdown voltage gives the
capacitors exceptionally elevated capacitance values for their size. In a capacitor the foil
plates are anodized by a dc current thus setting of the extremity of plat material and
confirming polarity of its side.

The tantalum and aluminium capacitors are shown in figure below:

4. Variable Capacitors:

18
Fig. 2.19 Variable Capacitors

A Variable Capacitor is one whose capacitance may be intentionally and repeatedly changed
mechanically. This type of capacitors utilized to set frequency of resonance in LC circuits, for
instance, to adjust the radio for impedance matching in antenna tuner devices. 2.1.11 Relay

Fig. 2.20 Relay

A relay is an electrically operated switch. It consists of a set of input terminals for a single or
multiple control signals, and a set of operating contact terminals. The switch may have any
number of contacts in multiple contact forms, such as make contacts, break contacts, or
combinations thereof.

Relays are used where it is necessary to control a circuit by an independent low-power signal,
or where several circuits must be controlled by one signal. Relays were first used in
longdistance telegraph circuits as signal repeaters: they refresh the signal coming in from one
circuit by transmitting it on another circuit. Relays were used extensively in telephone
exchanges and early computers to perform logical operations.

Fig. 2.21 Relay Symbol

19
The traditional form of a relay uses an electromagnet to close or open the contacts, but other
operating principles have been invented, such as in solid-state relays which use
semiconductor properties for control without relying on moving parts. Relays with calibrated
operating characteristics and sometimes multiple operating coils are used to protect electrical
circuits from overload or faults; in modern electric power systems these functions are
performed by digital instruments still called protective relays.

2.1.12 IR Sensor

Fig. 2.22 IR Sensor

An infrared (IR) sensor is an electronic device that measures and detects infrared radiation in
its surrounding environment. Infrared radiation was accidentally discovered by an astronomer
named William Herschel in 1800. While measuring the temperature of each colour of light
(separated by a prism), he noticed that the temperature just beyond the red light was highest.
IR is invisible to the human eye, as its wavelength is longer than that of visible light (though
it is still on the same electromagnetic spectrum). Anything that emits heat (everything that
has a temperature above around five degrees Kelvin) gives off infrared radiation. There are
two types of infrared sensors: active and passive. Active infrared sensors both emit and detect
infrared radiation. Active IR sensors have two parts: a light emitting diode (LED) and a
receiver. When an object comes close to the sensor, the infrared light from the LED reflects
off of the object and is detected by the receiver. Active IR sensors act as proximity sensors,
and they are commonly used in obstacle detection systems (such as in robots).

2.1.13 PCB

A printed circuit board (PCB) mechanically supports and electrically connects electronic
components or electrical components using conductive tracks, pads and other features etched
from one or more sheet layers of copper laminated onto and/or between sheet layers of a
nonconductive substrate. Components are generally soldered onto the PCB to both
electrically connect and mechanically fasten them to it.

20
Fig. 2.23 PCB

Generally, PCB is available in given three types: -

• SINGLE SIDED PCBs

As the name suggests in these designs, the conductive pattern is only at in one side i.e. on the
one side of PCB components are mounted and on the other side soldering is performed. The
sizes of PCB’s of this kind are quite larger but these are cheap.

• DOUBLE SIDED PCBs

These are the PCBs on which the conductive pattern is in both sides i.e. soldering and
mounting of the components can be done on either of the two sides. The size of board is small
in this case but it is costlier than that of above.

• MULTILAYER PCBs

In this case, the board consists of alternating layers of conducting pattern and insulating
material. The conductive material is connected across the layers through holes. The size of
this PCB is smaller than that of double-sided PCB but it is very costly.

PCBs may also be either rigid, flexible, or the combination of two (rigid flex). When the
electronic components have mounted on the PCB, the combination of PCB and components is
an electronic assembly also called the PRINTED CIRCUIT ASSEMBLY. This assembly is
the basic building block for all the electronic appliances such as television, computer and
other goods.

21
2.1.14 LED

Fig. 2.24 LED

A light-emitting diode (LED) is a semiconductor light source that emits light when current
flows through it. Electrons in the semiconductor recombine with electron holes, releasing
energy in the form of photons. The colour of the light (corresponding to the energy of the
photons) is determined by the energy required for electrons to cross the band gap of the
semiconductor. White light is obtained by using multiple semiconductors or a layer of
lightemitting phosphor on the semiconductor device.

2.1.15 Photodiode Sensor

Fig. 2.25 Photo Diode Sensor

It is a form of light-weight sensor that converts light energy into electrical voltage or current.
Photodiode is a type of semi conducting device with PN junction. Between the p (positive)
and n (negative) layers, an intrinsic layer is present. The photo diode accepts light energy as
input to generate electric current. It is also called as Photo detector, photo sensor or light
detector. Photo diode operates in reverse bias condition i.e. the p – side of the photodiode is
connected with negative terminal of battery (or the power supply) and n – side to the positive
terminal of battery. Typical photodiode materials are Silicon, Germanium, Indium Gallium
Arsenide Phosphide and Indium gallium arsenide.

22
2.1.16 LCD

Fig. 2.26 LCD

LCD (Liquid Crystal Display) is a type of flat panel display which uses liquid crystals in its
primary form of operation. LEDs have a large and varying set of use cases for consumers and
businesses, as they can be commonly found in smartphones, televisions, computer monitors
and instrument panels. LCDs were a big leap in terms of the technology they replaced, which
include light-emitting diode (LED) and gas-plasma displays. LCDs allowed displays to be
much thinner than cathode ray tube (CRT) technology. LCDs consume much less power than
LED and gas-display displays because they work on the principle of blocking light rather than
emitting it. Where an LED emits light, the liquid crystals in an LCD produces an image using
a backlight. As LCDs have replaced older display technologies, LCDs have begun being
replaced by new display technologies such as OLEDs. A display is made up of millions of
pixels. The quality of a display commonly refers to the number of pixels; for example, a 4K
display is made up of 3840 x2160 or 4096x2160 pixels. A pixel is made up of three sub
pixels; a red, blue and green—commonly called RGB. When the sub pixels in a pixel change
colour combination, a different colour can be produced. With all the pixels on a display
working together, the display can make millions of different colours. When the pixels are
rapidly switched on and off, a picture is created. The way a pixel is controlled is different in
each type of display; CRT, LED, LCD and newer types of displays all control pixels
differently. In short, LCDs are lit by a backlight, and pixels are switched on and off
electronically while using liquid crystals to rotate polarized light. A polarizing glass filter is
placed in front and behind all the pixels, the front filter is placed at 90 degrees. In between
both filters are the liquid crystals, which can be electronically switched on and off.

2.1.17 Switch

The simplest type of switch is one where two electrical conductors are brought in contact with
each other by the motion of an actuating mechanism. Other switches are more complex,
containing electronic circuits able to turn on or off depending on some physical stimulus
(such as light or magnetic field) sensed. In any case, the final output of any switch will be (at

23
least) a pair of wire-connection terminals that will either be connected together by the
switch’s internal contact mechanism (“closed”), or not connected together (“open”). Any
switch designed to be operated by a person is generally called a hand switch, and they are
manufactured in several varieties:

1. Toggle Switches

Fig. 2.27 Toggle Switch

Toggle switches are actuated by a lever angled in one of two or more positions. The
common light switch used in household wiring is an example of a toggle switch. Most
toggle switches will come to rest in any of their lever positions, while others have an
internal spring mechanism returning the lever to a certain normal position, allowing for
what is called “momentary” operation.

2. Pushbutton Switches

Fig. 2.28 Pushbutton Switch

Pushbutton switches are two-position devices actuated with a button that is pressed and
released. Most pushbutton switches have an internal spring mechanism returning the
button to its “out,” or “unpressed,” position, for momentary operation. Some pushbutton
switches will latch alternately on or off with every push of the button. Other pushbutton
switches will stay in their “in,” or “pressed,” position until the button is pulled back out.
This last type of pushbutton switches usually has a mushroom-shaped button for easy
push-pull action.

3. Temperature Switches

24
Fig. 2.29 Temperature Switch

An inexpensive temperature-sensing mechanism is the “bimetallic strip:” a thin strip of


two metals, joined back-to-back, each metal having a different rate of thermal expansion.
When the strip heats or cools, differing rates of thermal expansion between the two
metals causes it to bend. The bending of the strip can then be used to actuate a switch
contact mechanism. Other temperature switches use a brass bulb filled with either a liquid
or gas, with a tiny tube connecting the bulb to a pressure-sensing switch. As the bulb is
heated, the gas or liquid expands, generating a pressure increase which then actuates the
switch mechanism. 4. Liquid Level Switch

Fig. 2.30 Liquid level Switch

A floating object can be used to actuate a switch mechanism when the liquid level in a tank
rises past a certain point. If the liquid is electrically conductive, the liquid itself can be used
as a conductor to bridge between two metal probes inserted into the tank at the required
depth. The conductivity technique is usually implemented with a special design of relay
triggered by a small amount of current through the conductive liquid. In most cases it is
impractical and dangerous to switch the full load current of the circuit through a liquid. Level
switches can also be designed to detect the level of solid materials such as wood chips, grain,
coal, or animal feed in a storage silo, bin, or hopper. A common design for this application is
a small paddle wheel, inserted into the bin at the desired height, which is slowly turned by a
small electric motor. When the solid material fills the bin to that height, the material prevents
the paddle wheel from turning. The torque response of the small motor than trips the switch
mechanism. Another design uses a “tuning fork” shaped metal prong, inserted into the bin

25
from the outside at the desired height. The fork is vibrated at its resonant frequency by an
electronic circuit and magnet/electromagnet coil assembly. When the bin fills to that height,
the solid material dampens the vibration of the fork, the change in vibration amplitude and/or
frequency detected by the electronic circuit.

2.2 Software Requirement

MATLAB

MATLAB is a multi-paradigm numerical computing environment and proprietary


programming language developed by MathWorks. MATLAB allows matrix manipulations,
plotting of functions and data, implementation of algorithms, creation of user interfaces, and
interfacing with programs written in other languages

Fig. 2.31 MATLAB

Hardware and Software Requirements Required MathWorks Products


To use the I/O mode features of the Communications Toolbox™ Support Package for
USRP Embedded Series Radio, the following MathWorks products are required:
®[1] ®

• MATLAB ®

• Communications Toolbox
• Signal Processing Toolbox™
• DSP System Toolbox™

26
To work with the hardware-software co-design workflow, the following MathWorks products
are also required:
• Simulink ®

• To target the FPGA fabric on the device: HDL Coder™ Support Package for
Xilinx Zynq Platform (requires HDL Coder)
® ®

• To target the ARM processor on the device: Embedded Coder Support Package for Xilinx
® ®

Zynq Platform (requires Embedded Coder, Simulink Coder™, and the ARM Cortex -A ®

support package)

Required Third-Party Tools

• Third-party tools required by the I/O mode features are automatically downloaded and
installed during the support package installation.
• To work with the hardware-software co-design and FPGA targeting workflows, you must
manually install the following third-party tools:
o Xilinx Vivado development tools, version 2018.
®

CHAPTER 3

CIRCUIT DISCRIPTION

3.1 Circuit Diagram

27
Fig. 3.1 Microcontroller Circuit

Fig. 3.2 LCD Circuit

Fig. 3.3 Fan Circuit

Fig. 3.4 Motor Circuit


28
Fig. 3.5 Light Circuit

Fig. 3.6 IR Sensor Circuit

29
Fig. 3.7 Temperature Sensing Circuit

Fig. 3.8 Power Supply Circuit

30
Fig. 3.9 Practical Circuit

3.2 Working

In this project we have made a 5v Dc Power supply that operate the microcontroller and other
5v devices in our model. This project is based on home automation with security, i.e. when
you enter in your home then firstly Enter the password through Switch for authentication if
password is correct then Microcontroller send the signal to L293D motor drive IC that Will
operate the gate Open and Close. When Gate is open and Person enter in the room then Lights
will automatically ON i.e., we attached IR sensor module in our project that acts as for
detecting the person in the room. Fan is also operating according to room temperature i.e. we
attached LM358 temp. Sensor with Microcontroller that provide the temperature detail to our
microcontroller for operating the fan. Water pump is also automatically Operate through
water sensor i.e. when your water storage tank is full then microcontroller automatically OFF
the Water pump switch for saving the wastage of water and electricity.

Power Supply:

A power supply is an electrical device that supplies electric power to an electrical load. The
primary function of a power supply is to convert electric current from a source to the correct
voltage, current, and frequency to power the load. As a result, power supplies are sometimes
referred to as electric power converters. Some power supplies are separate standalone pieces
31
of equipment, while others are built into the load appliances that they power. Examples of the
latter include power supplies found in desktop computers and consumer electronics devices.
Other functions that power supplies may perform include limiting the current drawn by the
load to safe levels, shutting off the current in the event of an electrical fault, power
conditioning to prevent electronic noise or voltage surges on the input from reaching the load,
power-factor correction, and storing energy so it can continue to power the load in the event
of a temporary interruption in the source power (uninterruptible power supply).

All power supplies have a power input connection, which receives energy in the form of
electric current from a source, and one or more power output connections that deliver current
to the load. The source power may come from the electric power grid, such as an electrical
outlet, energy storage devices such as batteries or fuel cells, generators or alternators, solar
power converters, or another power supply. The input and output are usually hardwired
circuit connections, though some power supplies employ wireless energy transfer to power
their loads without wired connections. Some power supplies have other types of inputs and
outputs as well, for functions such as external monitoring and control.

Power Supply are of many types. Here we had used Ac to Dc Power Supply DC power
supplies use AC mains electricity as an energy source. Such power supplies will employ a
transformer to convert the input voltage to a higher or lower AC voltage. A rectifier is used to
convert the transformer output voltage to a varying DC voltage, which in turn is passed
through an electronic filter to convert it to an unregulated DC voltage.

The filter removes most, but not all of the AC voltage variations; the remaining AC voltage is
known as ripple. The electric load's tolerance of ripple dictates the minimum amount of
filtering that must be provided by a power supply. In some applications, high ripple is
tolerated and therefore no filtering is required. For example, in some battery charging
applications it is possible to implement a mains-powered DC power supply with nothing
more than a transformer and a single rectifier diode, with a resistor in series with the output to
limit charging current.

Rectifier:

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. Physically, rectifiers
take a number of forms, including vacuum tube diodes, mercury-arc valves, stacks of copper
and selenium oxide plates, semiconductor diodes, silicon-controlled rectifiers and other
32
siliconbased semiconductor switches. Historically, even synchronous electromechanical
switches and motors have been used. Early radio receivers, called crystal radios, used a "cat's
whisker" of fine wire pressing on a crystal of galena (lead sulphide) to serve as a point-
contact rectifier or "crystal detector".

Rectifiers have many uses, but are often found serving as components of DC power supplies
and high-voltage direct current power transmission systems. Rectification may serve in roles
other than to generate direct current for use as a source of power. As noted, detectors of radio
signals serve as rectifiers. In gas heating systems flame rectification is used to detect presence
of a flame.

Depending on the type of alternating current supply and the arrangement of the rectifier
circuit, the output voltage may require additional smoothing to produce a uniform steady
voltage. Many applications of rectifiers, such as power supplies for radio, television and
computer equipment, require a steady constant DC voltage (as would be produced by a
battery). In these applications the output of the rectifier is smoothed by an electronic filter,
which may be a capacitor, choke, or set of capacitors, chokes and resistors, possibly followed
by a voltage regulator to produce a steady voltage.

Rectifier’s are of 2 types:

1. Half Wave Rectifier

Fig. 3.10 Half Wave Rectifier

In half-wave rectification of a single-phase supply, either the positive or negative half of the
AC wave is passed, while the other half is blocked. Mathematically, it is a step function (for
positive pass, negative block): passing positive corresponds to the ramp function being the
identity on positive inputs, blocking negative corresponds to being zero on negative inputs.
Because only one half of the input waveform reaches the output, mean voltage is lower.
Halfwave rectification requires a single diode in a single-phase supply, or three in a three-
33
phase supply. Rectifiers yield a unidirectional but pulsating direct current; half-wave
rectifiers produce far more ripple than full-wave rectifiers, and much more filtering is needed
to eliminate harmonics of the AC frequency from the output.

2. Full Wave Rectifier

A full-wave rectifier converts the whole of the input waveform to one of constant polarity
(positive or negative) at its output. Mathematically, this corresponds to the absolute value
function. 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 tap), are needed.[3] Single semiconductor diodes, double diodes
with common cathode or common anode, and four-diode bridges, are manufactured as single
components.

These are of 2 types: -

1) Center Tapped

Fig. 3.11 Centre Tapped Rectifier 2)

Bridge Rectifier

Fig. 3.12 Bridge Rectifier

34
CHAPTER 4

CONCLUSION AND FUTURE SCOPE

4.1 Conclusion

An automated home can be a very simple grouping of controls, or it can be heavily automated
where any appliance that is plugged into electrical power is remotely controlled. Costs mainly
include equipment, components, furniture, and custom installation.

Ongoing costs include electricity to run the control systems, maintenance costs for the control
and networking systems, including troubleshooting, and eventual cost of upgrading as
standards change. Increased complexity may also increase maintenance costs for networked
devices.

Learning to use a complex system effectively may take significant time and training.

Control system security may be difficult and costly to maintain, especially if the control
system extends beyond the home, for instance by wireless or by connection to the internet or
other networks.

4.2 Future Scope

Future of Automation: Future will be of Automation of all products. Each and every product
will be smart devices that we use daily and that will be controlled through a smart chip called
microcontrollers. Each and Every home appliance will be controlled either by PC or hand
held devices like PDA or mobile handsets. Some examples of it are when you want you can
switch on/off Fan of your home by mobile handset or PC.

35
Smart Grid: Home automation technologies are viewed as integral additions to the Smart
grid. The ability to control lighting, appliances, HVAC as well as Smart applications (load
shedding, demand response, real-time power usage and price reporting) will become
vital as Smart Grid initiatives are rolled out.

The future implications of this project is vast, it can cover entire things to be controlled
around the world. The project we have undertaken it can be taken as a greater level to show
the capabilities of the system it can cover temperature updates, weather forecasting, system
synchronization, etc. The project itself can be modified to achieve a complete Home
Automation System which can create a platform for the user to interface between himself and
his household. In future, the system will be more compact and handier with combining the
microcontroller and Bluetooth module. The electric failure shall not be taken place because
hardware will be self-contained. This appliance will have its own power bank and charging
system. This system is developed for mobile reporting application and many more. The
computer system will also be interfaced to record and process data base.

1. Security Tap your finger to turn on the lights when you get home so you worried about
what’s hiding in the shadows, or in your pathways. Or automate to turn on when you aren’t
home to look like you are to ward off potential robbers. Door locks are another automated
home product that can increase your home security.

2. Energy Efficiency Increase your home’s energy efficiency by remotely powering off
systems and appliances when they aren’t in use. In addition to the standard home automation
products that give you active control, some products actively monitor systems and arm the
homeowner with knowledge, insight and guidance to achieve greater control and energy
efficiency.

3. Savings Home automation literally pays off. When you are able to use home systems and
appliances only when needed, the savings will be apparent in the first utility bill. No more
wasting money on lights left on when you aren’t home, or spending money on gas to drive
home because you forgot to lock the door. Monetary savings are apparent, but you’ll also be
saving time. No wasted trips home, no running through the house turning everything off, no
time spent worrying about what was or wasn’t turned off.

36
4. Convenience Don’t you hate having to rely on neighbours to watch your house when
you’re gone? With home automation, convenient control of your home is at your fingertips.
You don’t have to trust someone else with your most valued possessions.

5. Comfort Ever leave for work in the morning when it was a comfortable 68° outside only
to come home to a sweltering house because the temperature shot up to 90°? Connected home
products like the Sensi™ Wi-Fi Thermostats let you conveniently adjust your home
temperature from the mobile app so your family is always comfortable.

37
REFERENCES
1. www.wikipedia.com
2. www.electronicshub.org
3. www.google.com

38

You might also like