Vous êtes sur la page 1sur 66

CHAPTER - 1

INTRODUCTION

Arduino is a computer hardware and software company, project, and


user community that designs and manufactures microcontroller kits for building
digital devices and interactive objects that can sense and control objects in the
physical world. The project's products are distributed as open-source
hardware and software, which are licensed under the GNU Lesser General Public
License (LGPL) or the GNU General Public License (GPL), permitting the
manufacture of Arduino boards and software distribution by anyone. Arduino
boards are available commercially in preassembled form, or as do-it-yourself kits.

Arduino board designs use a variety of microprocessors and


controllers. The boards are equipped with sets of digital and
analog input/output (I/O) pins that may be interfaced to various expansion boards
(shields) and other circuits. The boards feature serial communications interfaces,
including Universal Serial Bus (USB) on some models, which are also used for
loading programs from personal computers. The microcontrollers are typically
programmed using a dialect of features from the programming
languages C and C++. In addition to using traditional compiler toolchains, the
Arduino project provides an integrated development environment (IDE) based on
the Processing language project.

The Arduino project started in 2005 as a program for students at


the Interaction Design Institute Ivrea in Ivrea, Italy, aiming to provide a low-cost
and easy way for novices and professionals to create devices that interact with their
environment using sensors and actuators. Common examples of such devices
intended for beginner hobbyists include simple robots, thermostats, and motion
1
detectors.The name Arduino comes from a bar in Ivrea, Italy, where some of the
founders of the project used to meet. The bar was named after Arduin of Ivrea,
who was the margrave of the March of Ivrea and King of Italy from 1002 to 1014.

History

The origin of the Arduino project started at the Interaction Design


Institute Ivrea (IDII) in Ivrea, Italy. At that time, the students used a BASIC
Stamp microcontroller at a cost of $100, a considerable expense for many students.
In 2004, Colombian student Hernando Barragán created the development
platform Wiring as a Master's thesis project at IDII, under the supervision of
Massimo Banzi and Casey Reas, who are known for work on
the Processing language. The project goal was to create simple, low cost tools for

2
creating digital projects by non-engineers. The Wiring platform consisted of
a printed circuit board (PCB) with an ATmega168 microcontroller, an IDE based
on Processing and library functions to easily program the microcontroller.

In 2005, Massimo Banzi, with David Mellis, another IDII student, and
David Cuartielles, added support for the cheaper ATmega8 microcontroller to
Wiring. But instead of continuing the work on Wiring, they copied the Wiring
source code and renamed it as a separate project, called Arduino.

The initial Arduino core team consisted of Massimo Banzi, David


Cuartielles, Tom Igoe, Gianluca Martino, and David Mellis, but Barragán was not
invited to participate.

Following the completion of the Wiring platform, lighter and less-expensive


versions were distributed in the open-source community.

Adafruit Industries, a New York City supplier of Arduino boards, parts,


and assemblies, estimated in mid-2011 that over 300,000 official Arduinos had
been commercially produced, and in 2013 that 700,000 official boards were in
users' hands.

3
HARDWARE

Arduino is open-source hardware. The hardware reference designs are


distributed under a Creative Commons Attribution Share-Alike 2.5 license and are
available on the Arduino website. Layout and production files for some versions of
the hardware are also available. The source code for the IDE is released under
the GNU General Public License, version 2. Nevertheless, an official Bill of
Materials of Arduino boards has never been released by Arduino staff.

4
Although the hardware and software designs are freely available
under copyleft licenses, the developers have requested that the
name Arduino be exclusive to the official product and not be used for derived
works without permission. The official policy document on use of the Arduino
name emphasizes that the project is open to incorporating work by others into the
official product. Several Arduino-compatible products commercially released have
avoided the project name by using various names ending in -duino.

An Arduino board consists of an Atmel 8-, 16- or 32-bit


AVR microcontroller (ATmega8, ATmega168, ATmega328, ATmega1280,
ATmega2560), but other makers' microcontrollers have been used

since 2015. The boards use single-row pins or female headers that facilitate
connections for programming and incorporation into other circuits. These may
connect with add-on modules termed shields. Multiple, and possibly stacked
shields may be individually addressable via an I C serial bus. Most boards include
a 5V linear regulator and a 16 MHz crystal oscillator or ceramic resonator. Some
designs, such as the LilyPad, run at 8 MHz and dispense with the onboard voltage
regulator due to specific form-factor restrictions.

Arduino microcontrollers are pre-programmed with a boot loader that


simplifies uploading of programs to the on-chip flash memory. The default
bootloader of the Aduino UNO is the optiboot bootloader. Boards are loaded with
program code via a serial connection to another computer. Some serial Arduino
boards contain a level shifter circuit to convert between RS-232 logic levels
and transistor–transistor logic (TTL) level signals. Current Arduino boards are
programmed via Universal Serial Bus (USB), implemented using USB-to-serial
adapter chips such as the FTDI FT232. Some boards, such as later-model Uno
boards, substitute the FTDI chip with a separate AVR chip containing USB-to-
5
serial firmware, which is reprogrammable via its own ICSP header. Other variants,
such as the Arduino Mini and the unofficial Boarduino, use a detachable USB-to-
serial adapter board or cable, Bluetooth or other methods, when used with
traditional microcontroller tools instead of the Arduino IDE, standard AVR in-
system programming (ISP) programming is used.

The Arduino board exposes most of the microcontroller's I/O pins for use
by other circuits. The Diecimila, Duemilanove, and current Uno provide 14 digital
I/O pins, six of which can produce pulse-width modulated signals, and six analog
inputs, which can also be used as six digital I/O pins. These pins are on the top of
the board, via female 0.1-inch (2.54 mm) headers. Several plug-in application
shields are also commercially available. The Arduino Nano, and Arduino-
compatible Bare Bones Board and Boarduino boards may provide male header pins
on the underside of the board that can plug into solderless breadboards.

Arduino-compatible and Arduino-derived boards exist. Some are


functionally equivalent to an Arduino and can be used interchangeably. Many
enhance the basic Arduino by adding output drivers, often for use in school-level
education, to simplify making buggies and small robots. Others are electrically
equivalent but change the form factor, sometimes retaining compatibility with
shields, sometimes not. Some variants use different processors, of varying
compatibility.

Official boards

The original Arduino hardware was produced by the Italian company


Smart Projects. Some Arduino-branded boards have been designed by the
American companies SparkFun Electronics and Adafruit Industries. As of 2016,
17 versions of the Arduino hardware have been commercially produced

6
Software development

A program for Arduino may be written in any programming


language for a compiler that produces binary machine code for the target
processor. Atmel provides a development environment for their microcontrollers,
AVR Studio and the newer Atmel Studio.

The Arduino project provides the Arduino integrated development


environment (IDE), which is a cross-platform application written in the
programming language Java. It originated from the IDE for the
languages Processing and Wiring. It includes a code editor with features such as
text cutting and pasting, searching and replacing text, automatic indenting, brace
matching, and syntax highlighting, and provides simple one-c message area, a text
console, a toolbar with buttons for common functions and a hierarchy

A program written with the IDE for Arduino is called a sketch.


Sketches are saved on the development computer as text files with the file
extension Arduino Software (IDE) pre-1.0 saved sketches with the extension

The Arduino IDE supports the languages C and C++ using special
rules of code structuring. The Arduino IDE supplies a software library from
the Wiring project, which provides many common input and output procedures.
User-written code only requires two basic functions, for starting the sketch and the
main program loop, that are compiled and linked with a program stub main() into
an executable cyclic executive program with the GNU toolchain, also included
with the IDE distribution. The Arduino IDE employs the program avrdude to
convert the executable code into a text file in hexadecimal encoding that is loaded
into the Arduino board by a loader program in the board's firmware.

7
Applications

 Xoscillo, an open-source oscilloscope


 Arduinome, a MIDI controller device that mimics the Monome
 OBDuino, a trip computer that uses the on-board diagnostics interface found in
most modern cars
 Ardupilot, drone software and hardware
 Gameduino, an Arduino shield to create retro 2D video games
 ArduinoPhone, a do-it-yourself cellphone
 Water quality testing platform
 Automatic titration system based on Arduino and stepper motor
 Low cost data glove for virtual reality applications
 Impedance sensor system to detect bovine milk adulteration
 Homemade CNC using Arduino and DC motors with close loop control by
Homofaciens

8
TECHNICAL SPECS

9
CHAPTER 2
Programming
The Arduino/Genuino Uno can be programmed with the
(Arduino Software (IDE)). Select "Arduino/Genuino Uno from the Tools > Board
menu (according to the microcontroller on your board). For details, see
the reference and tutorials.

The ATmega328 on the Arduino/Genuino Uno comes preprogrammed with


a bootloader that allows you to upload new code to it without the use of an external
hardware programmer. It communicates using the original STK500 protocol
(reference, C header files).

You can also bypass the bootloader and program the microcontroller through the
ICSP (In-Circuit Serial Programming) header using Arduino ISP or similar;
see these instructions for details.

The ATmega16U2 (or 8U2 in the rev1 and rev2 boards) firmware
source code is available in the Arduino repository. The ATmega16U2/8U2 is
loaded with a DFU bootloader, which can be activated by:

 On Rev1 boards: connecting the solder jumper on the back of the board (near the
map of Italy) and then rese ing the 8U2.
 On Rev2 or later boards: there is a resistor that pulling the 8U2/16U2 HWB line to
ground, making it easier to put into DFU mode.

You can then use Atmel's FLIP software (Windows) or the DFU
programmer (Mac OS X and Linux) to load a new firmware. Or you can use the

10
ISP header with an external programmer (overwriting the DFU bootloader).
See this user-contributed tutorial for more information.

11
12
Warnings

The Arduino/Genuino Uno has a resettable polyfuse that protects your


computer's USB ports from shorts and overcurrent. Although most computers
provide their own internal protection, the fuse provides an extra layer of protection.
If more than 500 mA is applied to the USB port, the fuse will automatically break
the connection until the short or overload is removed.

Differences with other boards

The Uno differs from all preceding boards in that it does not use the
FTDI USB-to-serial driver chip. Instead, it features the Atmega16U2 (Atmega8U2
up to version R2) programmed as a USB-to-serial converter.

Power

The Arduino/Genuino Uno board can be powered via the USB


connection or with an external power supply. The power source is selected
automatically.

External (non-USB) power can come either from an AC-to-DC adapter


(wall-wart) or battery. The adapter can be connected by plugging a 2.1mm center-
positive plug into the board's power jack. Leads from a battery can be inserted in
the GND and Vin pin headers of the POWER connector.

The board can operate on an external supply from 6 to 20 volts. If


supplied with less than 7V, however, the 5V pin may supply less than five volts
and the board may become unstable. If using more than 12V, the voltage regulator
may overheat and damage the board. The recommended range is 7 to 12 volts.

13
The power pins areas as follows:

 Vin. The input voltage to the Arduino/Genuino board when it's using an external
power source (as opposed to 5 volts from the USB connection or other regulated
power source). You can supply voltage through this pin, or, if supplying voltage
via the power jack, access it through this pin.
 5V.This pin outputs a regulated 5V from the regulator on the board. The board can
be supplied with power either from the DC power jack (7 - 12V), the USB
connector (5V), or the VIN pin of the board (7-12V). Supplying voltage via the 5V
or 3.3V pins bypasses the regulator, and can damage your board. We don't advise
it.
 3V3. A 3.3 volt supply generated by the on-board regulator. Maximum current
draw is 50 mA.
 GND. Ground pins.
 IOREF. This pin on the Arduino/Genuino board provides the voltage reference
with which the microcontroller operates. A properly configured shield can read the
IOREF pin voltage and select the appropriate power source or enable voltage
translators on the outputs to work with the 5V or 3.3V.

Memory

The ATmega328 has 32 KB (with 0.5 KB occupied by the bootloader). It


also has 2 KB of SRAM and 1 KB of EEPROM (which can be read and written
with the EEPROM library).

Input and Output

See the mapping between Arduino pins and ATmega328P ports. The
mapping for the Atmega8, 168, and 328 is identical.

14
Each of the 14 digital pins on the Uno can be used as an input or output, using
pinMode(), digitalWrite(), and digitalRead() functions. They operate at 5 volts.
Each pin can provide or receive 20 mA as recommended operating condition and
has an internal pull-up resistor (disconnected by default) of 20-50k ohm. A
maximum of 40mA is the value that must not be exceeded on any I/O pin to avoid
permanent damage to the microcontroller.

In addition, some pins have specialized functions:

 Serial: 0 (RX) and 1 (TX). Used to receive (RX) and transmit (TX) TTL serial
data. These pins are connected to the corresponding pins of the ATmega8U2 USB-
to-TTL Serial chip.
 External Interrupts: 2 and 3. These pins can be configured to trigger an interrupt on
a low value, a rising or falling edge, or a change in value. See the attachInterrupt()
function for details.
 PWM: 3, 5, 6, 9, 10, and 11. Provide 8-bit PWM output with the analogWrite()
function.
 SPI: 10 (SS), 11 (MOSI), 12 (MISO), 13 (SCK). These pins support SPI
communication using the SPI library.
 LED: 13. There is a built-in LED driven by digital pin 13. When the pin is HIGH
value, the LED is on, when the pin is LOW, it's off.
 TWI: A4 or SDA pin and A5 or SCL pin. Support TWI communication using the
Wire library.

The Uno has 6 analog inputs, labeled A0 through A5, each of which provide
10 bits of resolution (i.e. 1024 different values). By default they measure from
ground to 5 volts, though is it possible to change the upper end of their range using
the AREF pin and the analogReference() function.

15
There are a couple of other pins on the board:

 AREF. Reference voltage for the analog inputs. Used with analogReference().
 Reset. Bring this line LOW to reset the microcontroller. Typically used to add a
reset button to shields which block the one on the board.

Communication

Arduino/Genuino Uno has a number of facilities for communicating


with a computer, another Arduino/Genuino board, or other microcontrollers. The
ATmega328 provides UART TTL (5V) serial communication, which is available
on digital pins 0 (RX) and 1 (TX). An ATmega16U2 on the board channels this
serial communication over USB and appears as a virtual com port to software on
the computer. The 16U2 firmware uses the standard USB COM drivers, and no
external driver is needed. However, on Windows, a .inf file is required. The
Arduino Software (IDE) includes a serial monitor which allows simple textual data
to be sent to and from the board. The RX and TX LEDs on the board will flash
when data is being transmitted via the USB-to-serial chip and USB connection to
the computer (but not for serial communication on pins 0 and 1)

A SoftwareSerial library allows serial communication on any


of the Uno's digital pins. The ATmega328 also supports I2C (TWI) and SPI
communication. The Arduino Software (IDE) includes a Wire library to simplify
use of the I2C bus; see the documentation for details. For SPI communication, use
the SPI library.

Automatic (Software) Reset

Rather than requiring a physical press of the reset button before an upload,
the Arduino/Genuino Uno board is designed in a way that allows it to be reset by

16
software running on a connected computer. One of the hardware flow control lines
(DTR) of the ATmega8U2/16U2 is connected to the reset line of the ATmega328
via a 100 nanofarad capacitor. When this line is asserted (taken low), the reset line
drops long enough to reset the chip. The Arduino Software (IDE) uses this
capability to allow you to upload code by simply pressing the upload button in the
interface toolbar. This means that the bootloader can have a shorter timeout, as the
lowering of DTR can be well-coordinated with the start of the upload.

This setup has other implications. When the Uno is connected to either a computer
running Mac OS X or Linux, it resets each time a connection is made to it from
software (via USB). For the following half-second or so, the bootloader is running
on the Uno. While it is programmed to ignore malformed data (i.e. anything
besides an upload of new code), it will intercept the first few bytes of data sent to
the board after a connection is opened. If a sketch running on the board receives
one-time configuration or other data when it first starts, make sure that the
software with which it communicates waits a second after opening the connection
and before sending this data.

The Uno board contains a trace that can be cut to disable the auto-reset.
The pads on either side of the trace can be soldered together to re-enable it. It's
labeled "RESET-EN". You may also be able to disable the auto-reset by
connecting a 110 ohm resistor from 5V to the reset line; see this forum thread for
details

Revisions

Revision 3 of the board has the following new features:

 1.0 pinout: added SDA and SCL pins that are near to the AREF pin and two other
new pins placed near to the RESET pin, the IOREF that allow the shields to adapt
17
to the voltage provided from the board. In future, shields will be compatible with
both the board that uses the AVR, which operates with 5V and with the Arduino
Due that operates with 3.3V. The second one is a not connected pin, that is
reserved for future purposes.
 Stronger RESET circuit.
 At mega 16U2 replace the 8U2.

Water level sensor LM 324:

Fig3.5.1 .water level sensor LM324

General Description:

18
The LM324 series consists of four independent, high gains; internally
frequency compensated operational amplifiers which were designed specifically to
operate from a single power supply over a wide range of voltages. Operation from
split power supplies is also possible and the low power supply current drain is
independent of the magnitude of the power supply voltage.

Application areas include transducer amplifiers, DC gain blocks and all


the conventional op amp circuits which now can be more easily implemented in
single power supply systems. For example, the LM124 series can be directly
operated off of the standard +5V power supply voltage which is used in digital
systems and will easily provide the required interface electronics without requiring
the additional ±15V power supplies.

Unique Characteristics

In the linear mode the input common-mode voltage range includes


ground and the output voltage can also swing to ground, even though operated

19
from only a single power supply voltage. The unity gain cross frequency is
temperature compensated. The input bias current is also temperature compensated

Advantages

1. Eliminates need for dual supplies

2. Four internally compensated op amps in a single package

3. Allows directly sensing near GND and VOUT also goes to GND

4. Compatible with all forms of logic

5. Power drain suitable for battery operation

Features

1. Internally frequency compensated for unity gain

2. Large DC voltage gain 100 dB

3. Wide bandwidth (unity gain) 1 MHz (temperature compensated)

4. Wide power supply range: Single supply 3V to 32V or dual supplies ±1.5V to
±16V

5. Very low supply current drain (700 μA)—essentially independent of supply


voltage

6. Low input biasing current 45 nA (temperature compensated)

7. Low input offset voltage 2 mV and offset current: 5 nA

8. Input common-mode voltage range includes ground

20
9. Differential input voltage range equal to the power supply voltage

10. Large output voltage swing 0V to V+ − 1.5V

DESCRIPTION:

The LM124LM124/LM224/LM324/LM2902 Low Power Quad


Operational Amplifiers series are op amps which operate with only a single power
supply voltage, have true-differential inputs, and remain in the linear mode with an
input common-mode voltage of 0 VDC. These amplifiers operate over a wide
range of power supply voltage with little change in performance Characteristics. At
25°C amplifier operation is possible down to a minimum supply voltage of 2.3
VDC.

The pinouts of the package have been designed to simplify PC


board layouts. Inverting inputs are adjacent to outputs for all of the amplifiers and
the outputs have also been placed at the corners of the package (pins 1, 7, 8, and
14). Precautions should be taken to insure that the power supply for the integrated
circuit never becomes reversed in polarity or that the unit is not inadvertently
installed backwards in a test socket as an unlimited current surge through the

21
resulting forward diode within the IC could cause fusing of the internal conductors
and result in a destroyed unit. Large differential input voltages can be easily
accommodated and, as input differential voltage protection diodes are not needed,
no large input currents result from large differential input voltages. The differential
input voltage may be larger than V+ without damaging the device. Protection
should be provided to prevent the input voltages from going negative more than
−0.3 VDC (at 25°C). An input clamp diode with a resistor to the IC input terminal
can be used.

To reduce the power supply drain, the amplifiers have a class an


output stage for small signal levels which converts to class B in a large signal
mode. This allows the amplifiers to both source and sinks large output currents.
Therefore both NPN and PNP external current boost transistors can be used to
extend the power capability of the basic amplifiers. The output voltage needs to
raise approximately 1 diode drop above ground to bias the on-chip vertical PNP
transistor for output current sinking applications. For ac applications, where the

22
load is capacitive coupled to the output of the amplifier, a resistor should be used,
from the output of the amplifier to ground to increase the class a bias current and
prevent crossover distortion. Where the load is directly coupled, as in dc
applications, there is no crossover distortion. Capacitive loads which are applied
directly to the output of the amplifier reduce the loop stability margin. Values of 50
pF can be accommodated using the worst-case non inverting unity gain connection.
Large closed loop gains or resistive isolation should be used if larger load
capacitance must be driven by the amplifier.

23
LM124/LM224/LM324/LM2902

The bias network of the LM124 establishes a drain current


which is independent of the magnitude of the power supply voltage over the range
of from 3 VDC to 30 VDC. Output short circuits either to ground or to the positive
power supply should be of short time duration. Units can be destroyed, not as a
result of the short circuit current causing metal fusing, but rather due to the large
increase in IC chip dissipation which will cause eventual failure due to excessive
junction temperatures. Putting direct short-circuits on more than one amplifier at a
time will increase the total IC power dissipation to destructive levels, if not
properly protected with external dissipation limiting resistors in series with the
output leads of the amplifiers. The larger value of output source current which is
available at 25°C provides a larger output current capability at elevated
temperatures (see typical performance characteristics) than a standard IC op amp.

24
The circuits presented in the section on typical applications
emphasize operation on only a single power supply voltage. If complementary
power supplies are available, all of the standard op amp circuits can be used. In
general, introducing a pseudo-ground (a bias voltage reference of V+/2) will allow
operation above and below this value in single power supply systems. Many
application circuits are shown which take advantage of the wide input common-
mode voltage range which includes ground. In most cases, input biasing is not
required and input voltages which range to ground can easily be accommodated.

LM358 (Dual Operational Amplifiers)

LM358 is a low power dual operational amplifier and it is Available


in 8-Bump micro SMD chip sized package. It consists of four independent, high
gain, internally frequency compensated operational amplifiers. which were
designed specifically to operate from a single power supply over a wide range of
voltage. Operation from split power supplies is also possible and the low power
supply current drain is independent of the magnitude of the power supply voltage
Vcc for testing purpose is 30V.

Features:

 Internally frequency compensated for unity gain


 Large DC voltage gain : 100dB
 Wide power supply range : 3V~32V(or dual supply ±1.5V~16V)
 Wide bandwidth (unity gain): 1 MHz
 Input common-mode voltage range includes ground
 Low input offset voltage: 2 mV
 Large output voltage swing : 0V DC to VCC-1.5V DC

25
 Very low supply current drain (500 µA)-essentially independent of supply
voltage
 Power drain suitable for battery operation
 Differential input voltage range equal to the power supply voltage
PIN description:

PIN 1: Output of the first op- amp.

PIN 2: Inverting input of the first op- amp

PIN3: Non-inverting input of the first op- amp

PIN 4: GND

PIN 5: Non inverting input of second op-amp.

PIN 6: Inverting input of second op-amp.

PIN 7: Output of second op-amp.

PIN 8: supply voltage

26
Parametric table:

Gain Bandwidth 1 MHz

Channels 2 Channels

Input Output Type Vcc to V-, Not R-R Out

Slew Rate 0.1 Volts/µsec

Supply Min 3 Volt

Supply Max 32 Volt

Offset Voltage max, 25C 3, 7 Mv

Supply Current Per Channel 0.25 mA

Power Wise Rating 2 250 µA/MHz

Applications: Application areas include transducer amplifier, DC gain blocks and


all the conventional OP amp circuits like single supply inverting amplifier, input
biasing voltage pollower, non inverting amplifier, which now can be easily
implemented in single power supply systems.

27
CHAPTER 3
RELAYS

A relay is an electrically operated switch. Many relays use an electromagnet


to operate a switching mechanism, but other operating principles are also used.
Relays find applications where it is necessary to control a circuit by a low-power
signal, or where several circuits must be controlled by one signal. The first relays
were used in long distance telegraph circuits, repeating the signal coming in from
one circuit and re-transmitting it to another. Relays found extensive use in
telephone exchanges and early computers to perform logical operations. A type of
relay that can handle the high power required to directly drive an electric motor is
called a contactor. Solid-state relays control power circuits with no moving parts,
instead using a semiconductor device triggered by light to perform switching.
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 "protection relays".

28
Types of relays:
1. Simple electromechanical relay:

A simple electromagnetic relay, such as the one taken from a car in the
first picture, is an adaptation of an electromagnet. It consists of a coil of wire
29
surrounding a soft iron core, an iron yoke, which provides a low reluctance path
for magnetic flux, a movable iron armature, and a set, or sets, of contacts; two in
the relay pictured. The armature is hinged to the yoke and mechanically linked to a
moving contact or contacts. It is held in place by a spring so that when the relay is
de-energized there is an air gap in the magnetic circuit. In this condition, one of the
two sets of contacts in the relay pictured is closed, and the other set is open. Other
relays may have more or fewer sets of contacts depending on their function. The
relay in the picture also has a wire connecting the armature to the yoke. This
ensures continuity of the circuit between the moving contacts on the armature, and
the circuit track on the printed circuit board (PCB) via the yoke, which is soldered
to the PCB.

Basic design and operation:

When an electric current is passed through the coil, the resulting


magnetic field attracts the armature and the consequent movement of the movable
contact or contacts either makes or breaks a connection with a fixed contact. If the
set of contacts was closed when the relay was De-energized, then the movement
opens the contacts and breaks the connection, and vice versa if the contacts were
open. When the current to the coil is switched off, the armature is returned by a
force, approximately half as strong as the magnetic force, to its relaxed position.
Usually this force is provided by a spring, but gravity is also used commonly in
industrial motor starters. Most relays are manufactured to operate quickly. In a low

30
voltage application, this is to reduce noise. In a high voltage or high current
application, this is to reduce arcing.

If the coil is energized with DC, a diode is frequently installed


across the coil, to dissipate the energy from the collapsing magnetic field at
deactivation, which would otherwise generate a voltage spike dangerous to circuit
components. Some automotive relays already include a diode inside the relay case.
Alternatively a contact protection network, consisting of a capacitor and resistor in
series, may absorb the surge. If the coil is designed to be energized with AC, a
small copper ring can be crimped to the end of the solenoid. This "shading ring"
creates a small out-of-phase current, which increases the minimum pull on the
armature during the AC cycle.

By analogy with the functions of the original electromagnetic


device, a solid-state relay is made with a thyristor or other solid-state switching
device. To achieve electrical isolation an opt coupler can be used which is a light-
emitting diode (LED) coupled with a photo transistor. Small relay as used in
electronics

2. Latching relay

Latching relay, dust cover removed, showing pawl and ratchet


mechanism. The ratchet operates a cam, which raises and lowers the moving

31
contact arm, seen edge-on just below it. The moving and fixed contacts are visible
at the left side of the image.

A latching relay has two relaxed states (bi stable). These are also
called "impulse", "keep", or "stay" relays. When the current is switched off, the
relay remains in its last state. This is achieved with a solenoid operating a ratchet
and cam mechanism, or by having two opposing coils with an over-center spring or
permanent magnet to hold the armature and contacts in position while the coil is
relaxed, or with a remnant core. In the ratchet and cam example, the first pulse to
the coil turns the relay on and the second pulse turns it off. In the two coil example,
a pulse to one coil turns the relay on and a pulse to the opposite coil turns the relay
off. This type of relay has the advantage that it consumes power only for an instant,
while it is being switched, and it retains its last setting across a power outage. A
remnant core latching relay requires a current pulse of opposite polarity to make it
change state.

3. Reed relay

A reed relay has a set of contacts inside a vacuum or inert gas filled
glass tube, which protects the contacts against atmospheric corrosion. The contacts
are closed by a magnetic field generated when current passes through a coil around
the glass tube. Reed relays are capable of faster switching speeds than larger types
of relays, but have low switch current and voltage ratings.

32
4. Mercury-wetted relay

A mercury-wetted reed relay is a form of reed relay in which the


contacts are wetted with mercury. Such relays are used to switch low-voltage
signals (one volt or less) because of their low contact resistance, or for high-speed
counting and timing applications where the mercury eliminates contact bounce.
Mercury wetted relays are position-sensitive and must be mounted vertically to
work properly. Because of the toxicity and expense of liquid mercury, these relays
are rarely specified for new equipment. See also mercury switch.

5. Polarized relay

A polarized relay placed the armature between the poles of a


permanent magnet to increase sensitivity. Polarized relays were used in middle
20th Century telephone exchanges to detect faint pulses and correct telegraphic
distortion. The poles were on screws, so a technician could first adjust them for
maximum sensitivity and then apply a bias spring to set the critical current that
would operate the relay.

6. Machine tool relay

A machine tool relay is a type standardized for industrial control of


machine tools, transfer machines, and other sequential control. They are
characterized by a large number of contacts (sometimes extendable in the field)
which are easily converted from normally-open to normally-closed status, easily
replaceable coils, and a form factor that allows compactly installing many relays in
a control panel. Although such relays once were the backbone of automation in

33
such industries as automobile assembly, the programmable logic controller (PLC)
mostly displaced the machine tool relay from sequential control applications.

7. Contactor relay

A contactor is a very heavy-duty relay used for switching electric


motors and lighting loads. Continuous current ratings for common contactors range
from 10 amps to several hundred amps. High-current contacts are made with alloys
containing silver. The unavoidable arcing causes the contacts to oxidize; however,
silver oxide is still a good conductor. Such devices are often used for motor
starters. A motor starter is a contactor with overload protection devices attached.
The overload sensing devices are a form of heat operated relay where a coil heats a
bi-metal strip, or where a solder pot melts, releasing a spring to operate auxiliary
contacts. These auxiliary contacts are in series with the coil. If the overload senses
excess current in the load, the coil is de-energized. Contactor relays can be
extremely loud to operate, making them unfit for use where noise is a chief
concern.

8. Solid-state relay

Solid state relay, which has no moving parts

25 A or 40 A solid state contactor

34
A solid state relay (SSR) is a solid state electronic component that
provides a similar function to an electromechanical relay but does not have any
moving components, increasing long-term reliability. With early SSR's, the
tradeoff came from the fact that every transistor has a small voltage drop across it.
This voltage drop limited the amount of current a given SSR could handle. As
transistors improved, higher current SSR's, able to handle 100 to 1,200 Amperes,
have become commercially available. Compared to electromagnetic relays, they
may be falsely triggered by transients.

9. Solid state contactor relay


A solid state contactor is a very heavy-duty solid state relay,
including the necessary heat sink, used for switching electric heaters,
small electric motors and lighting loads; where frequent on/off cycles are
required. There are no moving parts to wear out and there is no contact
bounce due to vibration. They are activated by AC control signals or DC
control signals from Programmable logic controller (PLCs), PCs,
Transistor-transistor logic (TTL) sources, or other microprocessor and
microcontroller controls.
10. Buchholz relay

A Buchholz relay is a safety device sensing the accumulation of gas


in large oil-filled transformers, which will alarm on slow accumulation of gas or
shut down the transformer if gas is produced rapidly in the transformer oil.

35
11. Forced-guided contacts relay

A forced-guided contacts relay has relay contacts that are


mechanically linked together, so that when the relay coil is energized or de-
energized, all of the linked contacts move together. If one set of contacts in the
relay becomes immobilized, no other contact of the same relay will be able to
move. The function of forced-guided contacts is to enable the safety circuit to
check the status of the relay. Forced-guided contacts are also known as "positive-
guided contacts", "captive contacts", "locked contacts", or "safety relays".

12. Overload protection relay

Electric motors need over current protection to prevent damage from


over-loading the motor, or to protect against short circuits in connecting cables or
internal faults in the motor windings. One type of electric motor overload
protection relay is operated by a heating element in series with the electric motor.
The heat generated by the motor current heats a bimetallic strip or melts solder,
releasing a spring to operate contacts. Where the overload relay is exposed to the
same environment as the motor, a useful though crude compensation for motor
ambient temperature is provided.

13. Pole and throw:

36
Circuit symbols of relays. "C" denotes the common terminal in SPDT and DPDT
types.

The diagram on the package of a DPDT AC coil relay

Since relays are switches, the terminology applied to switches is also applied to
relays. A relay will switch one or more poles, each of whose contacts can be
thrown by energizing the coil in one of three ways:

 Normally-open (NO) contacts connect the circuit when the relay is


activated; the circuit is disconnected when the relay is inactive. It is also
called a Form A contact or "make" contact.
 Normally-closed (NC) contacts disconnect the circuit when the relay is
activated; the circuit is connected when the relay is inactive. It is also called
a Form B contact or "break" contact.
 Change-over (CO), or double-throw (DT), contacts control two circuits: one
normally-open contact and one normally-closed contact with a common
terminal. It is also called a Form C contact or "transfer" contact ("break
before make"). If this type of contact utilizes” make before break"
functionality, then it is called a Form D contact.

37
The following designations are commonly encountered:

 SPST – Single Pole Single Throw. These have two terminals which can be
connected or disconnected. Including two for the coil, such a relay has four
terminals in total. It is ambiguous whether the pole is normally open or
normally closed. The terminology "SPNO" and "SPNC" is sometimes used
to resolve the ambiguity.
 SPDT – Single Pole Double Throw. A common terminal connects to either
of two others. Including two for the coil, such a relay has five terminals in
total.
 DPST – Double Pole Single Throw. These have two pairs of terminals.
Equivalent to two SPST switches or relays actuated by a single coil.
Including two for the coil, such a relay has six terminals in total. The poles
may be Form A or Form B (or one of each).
 DPDT – Double Pole Double Throw. These have two rows of change-over
terminals. Equivalent to two SPDT switches or relays actuated by a single
coil. Such a relay has eight terminals, including the coil.

The "S" or "D" may be replaced with a number, indicating multiple


switches connected to a single actuator. For example 4PDT indicates a four pole
double throw relay (with 14 terminals).

Applications of Relays:

 Control a high-voltage circuit with a low-voltage signal, as in some types of


modems or audio amplifiers,
 Control a high-current circuit with a low-current signal, as in the starter
solenoid of an automobile,

38
 Detect and isolate faults on transmission and distribution lines by opening
and closing circuit breakers (protection relays),

A DPDT AC coil relay with "ice cube" packaging

 Isolate the controlling circuit from the controlled circuit when the two are at
different potentials, for example when controlling a mains-powered device
from a low-voltage switch. The latter is often applied to control office
lighting as the low voltage wires are easily installed in partitions, which may
be often moved as needs change. They may also be controlled by room
occupancy detectors in an effort to conserve energy,
 Logic functions. For example, the Boolean AND function is realized by
connecting normally open relay contacts in series, the OR function by
connecting normally open contacts in parallel. The change-over or Form C
contacts perform the XOR (exclusive or) function. Similar functions for
NAND and NOR are accomplished using normally closed contacts. The
Ladder programming language is often used for designing relay logic
networks.

39
o Early computing. Before vacuum tubes and transistors, relays were
used as logical elements in digital computers. See ARRA (computer),
Harvard Mark II, Zuse Z2, and Zuse Z3.
o Safety-critical logic. Because relays are much more resistant than
semiconductors to nuclear radiation, they are widely used in safety-
critical logic, such as the control panels of radioactive waste-handling
machinery.
 Time delay functions. Relays can be modified to delay opening or delay
closing a set of contacts. A very short (a fraction of a second) delay would
use a copper disk between the armature and moving blade assembly. Current
flowing in the disk maintains magnetic field for a short time, lengthening
release time. For a slightly longer (up to a minute) delay, a dashpot is used.
A dashpot is a piston filled with fluid that is allowed to escape slowly. The
time period can be varied by increasing or decreasing the flow rate. For
longer time periods, a mechanical clockwork timer is installed.

Advantages of relays:

 Relays can switch AC and DC, transistors can only switch DC.
 Relays can switch high voltages, transistors cannot.
 Relays are a better choice for switching large currents (> 5A).
 Relays can switch many contacts at once.

Disadvantages of relays:

 Relays are bulkier than transistors for switching small currents.


 Relays cannot switch rapidly (except reed relays), transistors can switch
many times per second.

40
 Relays use more power due to the current flowing through their coil.

 Relays require more current than many ICs can provide, so a low power
transistor may be needed to switch the current for the relay's coil.
Relay Driver:

The current needed to operate the relay coil is more than can be supplied by
most chips (op. amps etc), so a transistor is usually needed, as shown in the
diagram below.

Use BC109C or similar. A resistor of about 4k7 will probably be alright. The
diode is needed to short circuit the high voltage “back emf” induced when current
flowing through the coil is suddenly switched off.

Fig. 7.2 Relay Driver

3.9 LCD DISPLAY

LCD Background:

One of the most common devices attached to a micro controller is an


LCD display. Some of the most common LCD’s connected to the many

41
microcontrollers are 16x2 and 20x2 displays. This means 16 characters per line by
2 lines and 20 characters per line by 2 lines, respectively.

Basic 16x 2 Characters LCD

Figure 1: LCD Pin diagram

Pin description

Pin No. Name Description


Pin no. 1 VSS Power supply (GND)
Pin no. 2 VCC Power supply (+5V)
Pin no. 3 VEE Contrast adjust
0 = Instruction input
Pin no. 4 RS
1 = Data input
0 = Write to LCD module
Pin no. 5 R/W
1 = Read from LCD

42
module
Pin no. 6 EN Enable signal
Pin no. 7 D0 Data bus line 0 (LSB)
Pin no. 8 D1 Data bus line 1
Pin no. 9 D2 Data bus line 2
Pin no. 10 D3 Data bus line 3
Pin no. 11 D4 Data bus line 4
Pin no. 12 D5 Data bus line 5
Pin no. 13 D6 Data bus line 6
Pin no. 14 D7 Data bus line 7 (MSB)

Table 1: Character LCD pins with Microcontroller

The LCD requires 3 control lines as well as either 4 or 8 I/O lines for
the data bus. The user may select whether the LCD is to operate with a 4-bit data
bus or an 8-bit data bus. If a 4-bit data bus is used the LCD will require a total of 7
data lines (3 control lines plus the 4 lines for the data bus). If an 8-bit data bus is
used the LCD will require a total of 11 data lines (3 control lines plus the 8 lines
for the data bus). The three control lines are referred to as EN, RS, and RW.

The EN line is called "Enable." This control line is used to tell the LCD
that we are sending it data. To send data to the LCD, our program should make
sure this line is low (0) and then set the other two control lines and/or put data on
the data bus. When the other lines are completely ready, bring EN high (1) and
wait for the minimum amount of time required by the LCD datasheet (this varies
from LCD to LCD), and end by bringing it low (0) again.

The RS line is the "Register Select" line. When RS is low (0), the data is to
be treated as a command or special instruction (such as clear screen, position

43
cursor, etc.). When RS is high (1), the data being sent is text data which should be
displayed on the screen. For example, to display the letter "T" on the screen we
would set RS high.

The RW line is the "Read/Write" control line. When RSW is low (0), the
information on the data bus is being written to the LCD. When RW is high (1), the
program is effectively querying (or reading) the LCD. Only one instruction ("Get
LCD status") is a read command. All others are write commands--so RW will
almost always be low.

Finally, the data bus consists of 4 or 8 lines (depending on the mode of


operation selected by the user). In the case of an 8-bit data bus, the lines are
referred to as DB0, DB1, DB2, DB3, DB4, DB5, DB6, and DB7

Schematic:

Circuit Description:

Above is the quite simple schematic. The LCD panel's Enable and
Register Select is connected to the Control Port. The Control Port is an open
collector / open drain output. While most Parallel Ports have internal pull-up
44
resistors, there is a few which don't. Therefore by incorporating the two 10K
external pull up resistors, the circuit is more portable for a wider range of
computers, some of which may have no internal pull up resistors.

We make no effort to place the Data bus into reverse direction. Therefore
we hard wire the R/W line of the LCD panel, into write mode. This will cause no
bus conflicts on the data lines. As a result we cannot read back the LCD's internal
Busy Flag which tells us if the LCD has accepted and finished processing the last
instruction. This problem is overcome by inserting known delays into our program.

The 10k Potentiometer controls the contrast of the LCD panel. Nothing
fancy here. As with all the examples, I've left the power supply out. We can use a
bench power supply set to 5v or use an onboard +5 regulator. Remember a few de-
coupling capacitors, especially if we have trouble with the circuit working
properly.

SETB RW

Handling the EN control line:

As we mentioned above, the EN line is used to tell the LCD that we are
ready for it to execute an instruction that we've prepared on the data bus and on the
other control lines. Note that the EN line must be raised/ lowered before/after each
instruction sent to the LCD regardless of whether that instruction is read or write
text or instruction. In short, we must always manipulate EN when communicating
with the LCD. EN is the LCD's way of knowing that we are talking to it. If we
don't raise/lower EN, the LCD doesn't know we're talking to it on the other lines.

45
Thus, before we interact in any way with the LCD we will always bring the
EN line low with the following instruction:

CLR EN

And once we've finished setting up our instruction with the other control
lines and data bus lines, we'll always bring this line high:

SETBEN

This is normally on the order of about 250 nanoseconds, but checks the
datasheet. In the case of a typical microcontroller running at 12 MHz, an
instruction requires 1.08 microseconds to execute so the EN line can be brought
low the very next instruction. However, faster microcontrollers (such as the
DS89C420 which executes an instruction in 90 nanoseconds given an 11.0592
MHz crystal) will require a number of NOPs to create a delay while EN is held
high. The number of NOPs that must be inserted depends on the microcontroller
we are using and the crystal we have selected.

The instruction is executed by the LCD at the moment the EN line is


brought low with a final CLR EN instruction.

Checking the busy status of the LCD:

As previously mentioned, it takes a certain amount of time for each


instruction to be executed by the LCD. The delay varies depending on the
frequency of the crystal attached to the oscillator input of the LCD as well as the
instruction which is being executed.

While it is possible to write code that waits for a specific amount of time to
allow the LCD to execute instructions, this method of "waiting" is not very
flexible. If the crystal frequency is changed, the software will need to be modified.

46
A more robust method of programming is to use the "Get LCD Status" command
to determine whether the LCD is still busy executing the last instruction received.

The "Get LCD Status" command will return to us two tidbits of


information; the information that is useful to us right now is found in DB7. In
summary, when we issue the "Get LCD Status" command the LCD will
immediately raise DB7 if it's still busy executing a command or lower DB7 to
indicate that the LCD is no longer occupied. Thus our program can query the LCD
until DB7 goes low, indicating the LCD is no longer busy. At that point we are free
to continue and send the next command

Applications:

 Medical equipment
 Electronic test equipment
 Industrial machinery Interface
 Serial terminal
 Advertising system
 EPOS
 Restaurant ordering systems
 Gaming box
 Security systems
 R&D Test units
 Climatizing units
 PLC Interface
 Simulators
 Environmental monitoring

47
 Lab development
 Student projects
 Home automation
 PC external display
 HMI operator interface.
3.3 REGULATED POWER SUPPLY:

3.3.1 Introduction:

Power supply is a supply of electrical power. A device or system that


supplies electrical or other types of energy to an output load or group of loads is
called a power supply unit or PSU. The term is most commonly applied to
electrical energy supplies, less often to mechanical ones, and rarely to others.

A power supply may include a power distribution system as well as


primary or secondary sources of energy such as

 Conversion of one form of electrical power to another desired form and voltage,
typically involving converting AC line voltage to a well-regulated lower-
voltage DC for electronic devices. Low voltage, low power DC power supply
units are commonly integrated with the devices they supply, such
as computers and household electronics.
 Batteries.
 Chemical fuel cells and other forms of energy storage systems.
 Solar power.
 Generators or alternators.

48
.3.2 Block Diagram

The basic circuit diagram of a regulated


power supply (DC O/P) with led connected as load is shown in fig: 3.3.3.

Fig 3.3.3 Circuit diagram of Regulated Power Supply with Led


connection

The components mainly used in above figure are

 230V AC MAINS
 TRANSFORMER
 BRIDGE RECTIFIER(DIODES)
 CAPACITOR
 VOLTAGE REGULATOR(IC 7805)
 RESISTOR
 LED(LIGHT EMITTING DIODE)

49
The detailed explanation of each and every component mentioned above is
as follows:

Transformation: The process of transforming energy from one device to


another is called transformation. For transforming energy we use transformers.

Transformers:

A transformer is a device that transfers electrical energy from


one circuit to another through inductively coupled conductors without changing its
frequency. A varying current in the first or primary winding creates a
varying magnetic flux in the transformer's core, and thus a varying magnetic
field through the secondary winding. This varying magnetic field induces a
varying electromotive force (EMF) or "voltage" in the secondary winding. This
effect is called mutual induction.

If a load is connected to the secondary, an electric current will flow in


the secondary winding and electrical energy will be transferred from the primary
circuit through the transformer to the load. This field is made up from lines of
force and has the same shape as a bar magnet.

If the current is increased, the lines of force move outwards from the
coil. If the current is reduced, the lines of force move inwards.

If another coil is placed adjacent to the first coil then, as the field
moves out or in, the moving lines of force will "cut" the turns of the second coil.
As it does this, a voltage is induced in the second coil. With the 50 Hz AC mains
supply, this will happen 50 times a second. This is called MUTUAL INDUCTION
and forms the basis of the transformer.

50
The input coil is called the PRIMARY WINDING; the output coil is the
SECONDARY WINDING. Fig: 3.3.4 shows step-down transformer.

Fig 3.3.4: Step-Down Transformer

The voltage induced in the secondary is determined by the TURNS RATIO.

For example, if the secondary has half the primary turns; the
secondary will have half the primary voltage.

Another example is if the primary has 5000 turns and the secondary
has 500 turns, then the turn’s ratio is 10:1.

If the primary voltage is 240 volts then the secondary voltage will be x 10
smaller = 24 volts. Assuming a perfect transformer, the power provided by the
primary must equal the power taken by a load on the secondary. If a 24-watt lamp
is connected across a 24 volt secondary, then the primary must supply 24 watts.

To aid magnetic coupling between primary and secondary, the coils


are wound on a metal CORE. Since the primary would induce power, called
EDDY CURRENTS, into this core, the core is LAMINATED. This means that it is

51
made up from metal sheets insulated from each other. Transformers to work at
higher frequencies have an iron dust core or no core at all.

Note that the transformer only works on AC, which has a constantly
changing current and moving field. DC has a steady current and therefore a steady
field and there would be no induction.

Some transformers have an electrostatic screen between primary and


secondary. This is to prevent some types of interference being fed from the
equipment down into the mains supply, or in the other direction. Transformers are
sometimes used for IMPEDANCE MATCHING.

We can use the transformers as step up or step down.

Step Up transformer:

In case of step up transformer, primary windings are every less


compared to secondary winding. Because of having more turns secondary winding
accepts more energy, and it releases more voltage at the output side.

Step down transformer:

Incase of step down transformer, Primary winding induces more flux


than the secondary winding, and secondary winding is having less number of turns
because of that it accepts less number of flux, and releases less amount of voltage.

Battery power supply:

A battery is a type of linear power supply that offers benefits that


traditional line-operated power supplies lack: mobility, portability and reliability.

52
A battery consists of multiple electrochemical cells connected to provide the
voltage desired. Fig: 3.3.5 shows Hi-Watt 9V battery

Fig 3.3.5: Hi-Watt 9V Battery

The most commonly used dry-cell battery is the carbon-zinc dry cell
battery. Dry-cell batteries are made by stacking a carbon plate, a layer of
electrolyte paste, and a zinc plate alternately until the desired total voltage is
achieved. The most common dry-cell batteries have one of the following voltages:
1.5, 3, 6, 9, 22.5, 45, and 90. During the discharge of a carbon-zinc battery, the
zinc metal is converted to a zinc salt in the electrolyte, and magnesium dioxide is
reduced at the carbon electrode. These actions establish a voltage of approximately
1.5 V.

The lead-acid storage battery may be used. This battery is


rechargeable; it consists of lead and lead/dioxide electrodes which are immersed in
sulfuric acid. When fully charged, this type of battery has a 2.06-2.14 V potential
(A 12 volt car battery uses 6 cells in series). During discharge, the lead is
converted to lead sulfate and the sulfuric acid is converted to water. When the
battery is charging, the lead sulfate is converted back to lead and lead dioxide
A nickel-cadmium battery has become more popular in recent years. This battery
cell is completely sealed and rechargeable. The electrolyte is not involved in the
electrode reaction, making the voltage constant over the span of the batteries long

53
service life. During the charging process, nickel oxide is oxidized to its higher
oxidation state and cadmium oxide is reduced. The nickel-cadmium batteries have
many benefits. They can be stored both charged and uncharged. They have a long
service life, high current availabilities, constant voltage, and the ability to be
recharged. Fig: 3.3.6 shows pencil battery of 1.5V.

Fig 3.3.6: Pencil Battery of 1.5V

Rectification:

The process of converting an alternating current to a pulsating direct


current is called as rectification. For rectification purpose we use rectifiers.

Rectifiers:

A rectifier is an electrical device that converts alternating current


(AC) to direct current (DC), a process known as rectification. Rectifiers have many
uses including as components of power supplies and as detectors of radio signals.
Rectifiers may be made of solid-state diodes, vacuum tube diodes, mercury arc
valves, and other components.

A device that it can perform the opposite function (converting DC to


AC) is known as an inverter.

54
When only one diode is used to rectify AC (by blocking the negative
or positive portion of the waveform), the difference between the term diode and the
term rectifier is merely one of usage, i.e., the term rectifier describes a diode that is
being used to convert AC to DC. Almost all rectifiers comprise a number of diodes
in a specific arrangement for more efficiently converting AC to DC than is possible
with only one diode. Before the development of silicon semiconductor rectifiers,
vacuum tube diodes and copper (I) oxide or selenium rectifier stacks were used.

Bridge full wave rectifier:

The Bridge rectifier circuit is shown in fig: 3.3.7, which converts an


ac voltage to dc voltage using both half cycles of the input ac voltage. The Bridge
rectifier circuit is shown in the figure. The circuit has four diodes connected to
form a bridge. The ac input voltage is applied to the diagonally opposite ends of
the bridge. The load resistance is connected between the other two ends of the
bridge.

For the positive half cycle of the input ac voltage, diodes D1 and
D3 conduct, whereas diodes D2 and D4 remain in the OFF state. The conducting
diodes will be in series with the load resistance RL and hence the load current flows
through RL.

For the negative half cycle of the input ac voltage, diodes D2 and D4
conduct whereas, D1 and D3 remain OFF. The conducting diodes D2 and D4 will
be in series with the load resistance RL and hence the current flows through RL in
the same direction as in the previous half cycle. Thus a bi-directional wave is
converted into a unidirectional wave.

55
Input Output

Fig 3.3.7: Bridge rectifier: a full-wave rectifier using 4 diodes

DB107:

Now -a -days Bridge rectifier is available in IC with a number of


DB107. In our project we are using an IC in place of bridge rectifier. The picture
of DB 107 is shown in fig: 3.3.8.

Features:

 Good for automation insertion


 Surge overload rating - 30 amperes peak
 Ideal for printed circuit board
 Reliable low cost construction utilizing molded
 Glass passivated device
 Polarity symbols molded on body
 Mounting position: Any
 Weight: 1.0 gram
56
Fig 3.3.8: DB107

Filtration:

The process of converting a pulsating direct current to a pure direct


current using filters is called as filtration.

Filters:

Electronic filters are electronic circuits, which perform signal-


processing functions, specifically to remove unwanted frequency components from
the signal, to enhance wanted ones.

Introduction to Capacitors:

The Capacitor or sometimes referred to as a Condenser is a passive


device, and one which stores energy in the form of an electrostatic field which
produces a potential (static voltage) across its plates. In its basic form a capacitor
consists of two parallel conductive plates that are not connected but are electrically
separated either by air or by an insulating material called the Dielectric. When a
voltage is applied to these plates, a current flows charging up the plates with
electrons giving one plate a positive charge and the other plate an equal and

57
opposite negative charge this flow of electrons to the plates is known as
the Charging Current and continues to flow until the voltage across the plates (and
hence the capacitor) is equal to the applied voltage Vcc. At this point the capacitor
is said to be fully charged and this is illustrated below. The construction of
capacitor and an electrolytic capacitor are shown in figures 3.3.9 and 3.3.10
respectively.

Fig 3.3.9:Construction Of a Capacitor Fig


3.3.10:Electrolytic Capaticor

Units of Capacitance:

Microfarad (μF) 1μF = 1/1,000,000 = 0.000001 = 10-6 F

Nanofarad (nF) 1nF = 1/1,000,000,000 = 0.000000001 = 10-9 F

Pico farad (pF) 1pF = 1/1,000,000,000,000 = 0.000000000001 = 10-12 F

Operation of Capacitor:

58
Think of water flowing through a pipe. If we imagine a capacitor as
being a storage tank with an inlet and an outlet pipe, it is possible to show
approximately how an electronic capacitor works.

First, let's consider the case of a "coupling capacitor" where the


capacitor is used to connect a signal from one part of a circuit to another but
without allowing any direct current to flow.

If the current flow is alternating between zero and


a maximum, our "storage tank" capacitor will allow
the current waves to pass through.

However, if there is a steady current, only the


initial short burst will flow until the "floating ball
valve" closes and stops further flow.

So a coupling capacitor allows "alternating current" to pass through


because the ball valve doesn't get a chance to close as the waves go up and down.
However, a steady current quickly fills the tank so that all flow stops.

A capacitor will pass alternating current but (apart from an initial


surge) it will not pass d.c.

59
Where a capacitor is used to decouple a circuit, the
effect is to "smooth out ripples". Any ripples,
waves or pulses of current are passed to ground
while d.c. Flows smoothly.

Regulation:

The process of converting a varying voltage to a constant regulated


voltage is called as regulation. For the process of regulation we use voltage
regulators.

Voltage Regulator:

A voltage regulator (also called a ‘regulator’) with only three


terminals appears to be a simple device, but it is in fact a very complex integrated
circuit. It converts a varying input voltage into a constant ‘regulated’ output
voltage. Voltage Regulators are available in a variety of outputs like 5V, 6V, 9V,
12V and 15V. The LM78XX series of voltage regulators are designed for positive
input. For applications requiring negative input, the LM79XX series is used. Using
a pair of ‘voltage-divider’ resistors can increase the output voltage of a regulator
circuit.

It is not possible to obtain a voltage lower than the stated rating. You
cannot use a 12V regulator to make a 5V power supply. Voltage regulators are
very robust. These can withstand over-current draw due to short circuits and also

60
over-heating. In both cases, the regulator will cut off before any damage occurs.
The only way to destroy a regulator is to apply reverse voltage to its input. Reverse
polarity destroys the regulator almost instantly. Fig: 3.3.11 shows voltage
regulator.

Fig 3.3.11: Voltage Regulator

RESISTORS

A resistor is a two-terminal electronic component that produces a voltage


across its terminals that is proportional to the electric current passing through it in
accordance with Ohm's law:

V = IR

Resistors are 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 nickel/chrome).

The primary characteristics of a resistor are the resistance, the tolerance,


maximum working voltage and the power rating. Other characteristics include
temperature coefficient, noise, and inductance. Less well-known is critical

61
resistance, the value below which power dissipation limits the maximum permitted
current flow, and above which the limit is applied voltage. Critical resistance is
determined by the design, materials and dimensions of the resistor.

Resistors can be made to control the flow of current, to work as Voltage


dividers, to dissipate power and it can shape electrical waves when used in
combination of other components. Basic unit is ohms.

Theory of operation:

Ohm's law:

The behavior of an ideal resistor is dictated by the relationship


specified in Ohm's law:

V = IR

Ohm's law states that the voltage (V) across a resistor is proportional
to the current (I) through it where the constant of proportionality is the resistance
(R).

Power dissipation:

The power dissipated by a resistor (or the equivalent resistance of a


resistor network) is calculated using the following:

62
Fig 3.3.12: Resistor Fig 3.3.13: Color Bands In
Resistor

3.4. LED:

A light-emitting diode (LED) is a semiconductor light source. LED’s


are used as indicator lamps in many devices, and are increasingly used for lighting.
Introduced as a practical electronic component in 1962, early LED’s emitted low-
intensity red light, but modern versions are available across the visible, ultraviolet
and infrared wavelengths, with very high brightness. The internal structure and
parts of a led are shown in figures 3.4.1 and 3.4.2 respectively.

63
Fig 3.4.1: Inside a LED Fig 3.4.2: Parts of LED

Working:

The structure of the LED light is completely different than that of the
light bulb. Amazingly, the LED has a simple and strong structure. The light-
emitting semiconductor material is what determines the LED's color. The LED is
based on the semiconductor diode.

When a diode is forward biased (switched on), electrons are able to


recombine with holes within the device, releasing energy in the form of photons.
This effect is called electroluminescence and the color of the light (corresponding
to the energy of the photon) is determined by the energy gap of the semiconductor.
An LED is usually small in area (less than 1 mm2), and integrated optical
components are used to shape its radiation pattern and assist in reflection. LED’s
present many advantages over incandescent light sources including lower energy
consumption, longer lifetime, improved robustness, smaller size, faster switching,
and greater durability and reliability. However, they are relatively expensive and
require more precise current and heat management than traditional light sources.
64
Current LED products for general lighting are more expensive to buy than
fluorescent lamp sources of comparable output. They also enjoy use in applications
as diverse as replacements for traditional light sources in automotive lighting
(particularly indicators) and in traffic signals. The compact size of LED’s has
allowed new text and video displays and sensors to be developed, while their high
switching rates are useful in advanced communications technology.

The electrical symbol and polarities of led are shown in fig: 3.4.3.

Fig 3.4.3: Electrical Symbol & Polarities of LED

LED lights have a variety of advantages over other light sources:

 High-levels of brightness and intensity


 High-efficiency
 Low-voltage and current requirements
 Low radiated heat
 High reliability (resistant to shock and vibration)
 No UV Rays
 Long source life
 Can be easily controlled and programmed
65
Applications of LED fall into three major categories:

 Visual signal application where the light goes more or less directly from the
LED to the human eye, to convey a message or meaning.
 Illumination where LED light is reflected from object to give visual response
of these objects.
 Generate light for measuring and interacting with processes that do not
involve the human visual system.

66

Vous aimerez peut-être aussi