Professional Documents
Culture Documents
PROJECT DESCRIPTION
BLOCK DIAGRAM
ROBOT UNIT
INTERFACIING DRIVER MOTOR
INTERFACING PIR
INTERFACING GSM
POWER SUPPLY SOURCE:
Automatic mains changeover switch for uninterrupted power supply is an integral part of
the power control process, allowing smooth and immediate transfer of electrical current between
multiple sources and the load. Here we are using two transformers TF1 (Main transformer) and
TF2 (Backup transformer). The transfers switch senses when utility power is interrupted, and
starts up the transformer TF2 which acts as a backup transformer. If the utility power remains
absent, the transfer switch disconnects the load from the utility and connects it to the
Transformer TF2, restoring electricity to the load. The transfer switch continues to monitor
utility power, and when it is restored, switches the load from the Transformer TF2 back to the
Main transformer TF1. Once the Transformer TF2 is disconnected, it goes through a cool-down
routine and is automatically shut down.
The present system is designed around two transformers. One transformer (TF1) is used
as the main supply and the other transformer (TF2) is used in the place of the generator (for
demo purpose). These two transformers are connected with the relay which is controlled by the
embedded controller. The loads are connected to the main line (TF1) and as well as to the TF2.
Initially TF1 is connected to the load, the loads run with this power. Due to any reason
this power is interrupted, then it is identified by the controller and it immediately switches ON to
the TF2 through the relay. The controller continuously monitors the TF1 (main line). When it
finds the power on it again switches the loads connection to the main line.
A power supply is a device that supplies electric power to an electrical load. The term is
most commonly applied to electric power converters that convert one form of electrical energy to
another, though it may also refer to devices that convert another form of energy (mechanical,
chemical, solar) to electrical energy. A regulated power supply is one that controls the output
voltage or current to a specific value; the controlled value is held nearly constant despite
variations in either load current or the voltage supplied by the power supply's energy source.
Every power supply must obtain the energy it supplies to its load, as well as any energy it
consumes while performing that task, from an energy source. Depending on its design, a power
supply may obtain energy from:
TRANSFORMER
coupling between its winding circuits. A varying current in the primary winding
creates a varying magnetic flux in the transformer's core and thus a varying
magnetic flux through the secondary winding. This varying magnetic flux induces
wide range of transformer designs are used in electronic and electric power
The transformer is based on two principles: first, that an electric current can
produce a magnetic field and second that a changing magnetic field within a coil of
wire induces a voltage across the ends of the coil (electromagnetic induction).
Changing the current in the primary coil changes the magnetic flux that is
developed. The changing magnetic flux induces a voltage in the secondary coil.
through the primary coil creates a magnetic field. The primary and secondary coils
are wrapped around a core of very high magnetic permeability, such as iron, so that
most of the magnetic flux passes through both the primary and secondary coils.
If a load is connected to the secondary winding, the load current and voltage
will be in the directions indicated, given the primary current and voltage in the
The ideal transformer model assumes that all flux generated by the primary
winding links all the turns of every winding, including itself. In practice, some flux
traverses paths that take it outside the windings.[46] Such flux is termed leakage
flux, and results in leakage inductance in series with the mutually coupled
and discharged from the magnetic fields with each cycle of the power supply. It is
not directly a power loss (see Stray losses below), but results in inferior voltage
plays an essential part in the operation of the transformer. The combined effect of
the leakage flux and the electric field around the windings is what transfers energy
transformers may be used to supply loads that exhibit negative resistance, such as
electric arcs, mercury vapor lamps, and neon signs or for safely handling loads that
Air gaps are also used to keep a transformer from saturating, especially
are operated in parallel. It can be shown that if the percent impedance (Z) and
were hypothetically exactly the same, the transformers would share power in
proportion to their respective volt-ampere ratings (e.g. 500 kVA unit in parallel
with 1,000 kVA unit, the larger unit would carry twice the current). However, the
Cicuit Diagram:
Energy losses:
An ideal transformer would have no energy losses, and would be 100% efficient.
In practical transformers, energy is dissipated in the windings, core, and
surrounding structures. Larger transformers are generally more efficient, and those
rated for electricity distribution usually perform better than 98%.
Core losses
1. Hysteresis losses
Each time the magnetic field is reversed, a small amount of energy is lost
due to hysteresis within the core. According to Steinmetz's formula, the heat
energy due to hysteresis is given by
, and,
Ferromagnetic materials are also good conductors and a core made from
such a material also constitutes a single short-circuited turn throughout its
entire length. Eddy currents therefore circulate within the core in a plane
normal to the flux, and are responsible for resistive heating of the core
material. The eddy current loss is a complex function of the square of supply
frequency and inverse square of the material thickness.[31] Eddy current
losses can be reduced by making the core of a stack of plates electrically
insulated from each other, rather than a solid block; all transformers
operating at low frequencies use laminated or similar cores.
3. Stray losses
A regulated power supply is an embedded circuit, or stand alone unit, the function of
which is to supply a stable voltage (or less often current), to a circuit or device that must be
operated within certain power supply limits. The output from the regulated power supply may be
alternating or unidirectional, but is nearly always DC (Direct Current). The type of stabilization
used may be restricted to ensuring that the output remains within certain limits under various
load conditions, or it may also include compensation for variations in its own supply source. The
latter is much more common today.
The variable dc power supply and the main working principle of this project is
full wave rectification which is done by bridge configuration in which we are using 4 diodes
which rectifies the output of the step-down transformer which step-down the 220 AC
v to 9 AC volts .here we are using a voltage regulator which give constant voltage, here
we are using 7805 which give 5 volts .
Now the main task is to get variable output for this we use the pair of voltage divider
resistors to increase the output of the regulator and in which of resistance is variable so when we
increase or d e cr e as e t h e v al u e o f t h a t r esi st o r t h e o ut p ut v ol t a g e o f t h e
r e gu l a t o r wi l l a l s o change and we get a range of 5 to 12 v , here we can’t get less than 5
volts because of this is the output of the regulator In this circuit we use three capacitor , c1 and
c2are use to get constant input to the regulator moreover it also help to reduce the
sharp peaks in the output connect the 0.27uF capacitor to close to the input of the
regulator and the 10uf capacitor to the output because these capacitor reduce the noise
and also help to reduce the ripples produce by the regulator so that regulated output has less
ripples.
In this project, we are using two transformers instead of one transformer. Whenever
applying the more loads on one transformer exceeding the particular limit then it will not broke
down but the excess load must be shared by the another transformer. Therefore, no failure of
transformers will occurs.
Relay:
A relay is an electrically operated switch. Many relays use an electromagnet to operate a
switching mechanism mechanically, but other operating principles are also used. Relays are used
where it is necessary to control a circuit by a low-power signal (with complete electrical isolation
between control and controlled circuits), 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 were used extensively in telephone
exchanges and early computers to perform logical operations.
A type of relay that can handle the high power required to directly control an electric
motor or other loads is called a contactor. Solid-state relays control power circuits with no
moving parts, instead using a semiconductor device 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 "protective relays".
A simple electromagnetic relay consists of a coil of wire wrapped around a soft iron core,
an iron yoke which provides a low reluctance path for magnetic flux, a movable iron armature,
and one or more sets of contacts (there are two in the relay pictured). The armature is hinged to
the yoke and mechanically linked to one or more sets of moving 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.
When an electric current is passed through the coil it generates a magnetic field that
activates the armature, and the consequent movement of the movable contact(s) either makes or
breaks (depending upon construction) 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-voltage
application this reduces noise; in a high voltage or current application it reduces arcing.
When the coil is energized with direct current, a diode is often placed across the coil to
dissipate the energy from the collapsing magnetic field at deactivation, which would otherwise
generate a voltage spike dangerous to semiconductor circuit components. Some automotive
relays include a diode inside the relay case.
Alternatively, a contact protection network consisting of a capacitor and resistor in series
(snubber circuit) may absorb the surge. If the coil is designed to be energized with alternating
current (AC), a small copper "shading ring" can be crimped to the end of the solenoid, creating a
small out-of-phase current which increases the minimum pull on the armature during the AC
cycle.[1]
A solid-state relay uses a thyristor or other solid-state switching device, activated by the
control signal, to switch the controlled load, instead of a solenoid. An optocoupler (a light-
emitting diode (LED) coupled with a photo transistor) can be used to isolate control and
controlled circuits.
Types of Relay:
Latching relay
Read relay
Mercury-wetted relay
Mercury relay
Polarized relay
Machine tool relay
Ratchet relay
Coaxial relay
Contactor
Solid state relay
Solid state contactor relay
Overload protection relay
Vacuum relay
Pole and Throw:
Since relays are switches, the terminology applied to switches is also applied to relays; a relay
switches 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. NO contacts may also be distinguished as "early-make" or NOEM, which means
that the contacts close before the button or switch is fully engaged.
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. NC contacts may also be distinguished as "late-break" or NCLB, which
means that the contacts stay closed until the button or switch is fully disengaged.
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 a "make before break" functionality, then it is called a Form D contact.
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.
Applications:
Amplifying a digital signal, switching a large amount of power with a small operating
power. Some special cases are:
o A telegraph relay, repeating a weak signal received at the end of a long wire
o Controlling a high-voltage circuit with a low-voltage signal, as in some types of
modems or audio amplifiers,
o Controlling a high-current circuit with a low-current signal, as in the starter
solenoid of an automobile.
Detecting and isolating faults on transmission and distribution lines by opening and
closing circuit breakers (protection relays),Switching to a standby power supply.
An infrared sensor is an electronic device, which emits in order to sense
some aspects of the surroundings. An IR sensor can measure the heat of an object
as well as detects the motion. These types of sensors measures only infrared
radiation, rather than emitting it that is called as a passive IR sensor. Usually in the
infrared spectrum, all the objects radiate some form of thermal radiations. These
types of radiations are invisible to our eyes, that can be detected by an infrared
sensor. The emitter is simply an IR LED (Light Emitting Diode) and the detector is
simply an IR photodiode which is sensitive to IR light of the same wavelength as
that emitted by the IR LED. When IR light falls on the photodiode, The resistances
and these output voltages, change in proportion to the magnitude of the IR light
received.
LCD (liquid crystal display):
LCD stands for liquid crystal display. They come in many sizes 8x1 , 8x2 , 10x2 , 16x1 ,
16x2 , 16x4 , 20x2 , 20x4 ,24x2 , 30x2 , 32x2 , 40x2 etc. Many multinational companies
like Philips Hitachi Panasonic make their own special kind of LCD’s to be used in their products.
All the LCD’s performs the same functions (display characters numbers special
characters ASCII characters etc).Their programming is also same and they all have same 14 pins
(0-13) or 16 pins (0 to 15). Eight (8) of them all are data pins that takes data from the external
unit and display it on the screen. One vcc takes 5 volts to turn on the LCD and GND a ground
and one is contrast (we use it to set the contract colour of the alphabets (with respect to LCD)
that appears on the LCD).
LCD (Liquid Crystal Display) screen is an electronic display module and find a wide
range of applications. A 16x2 LCD display is very basic module and is very commonly used in
various devices and circuits. These modules are preferred over seven segments and other multi
segment LEDs. The reasons being: LCDs are economical; easily programmable; have no
limitation of displaying special & even custom characters (unlike in seven segments),
animationsand so on.
A 16x2 LCD means it can display 16 characters per line and there are 2 such lines. In this
LCD each character is displayed in 5x7 pixel matrix. This LCD has two registers, namely,
Command and Data.
The command register stores the command instructions given to the LCD. A command is
an instruction given to LCD to do a predefined task like initializing it, clearing its screen, setting
the cursor position, controlling display etc. The data register stores the data to be displayed on
the LCD. The data is the ASCII value of the character to be displayed on the LCD. Click to learn
more about internal structure of a LCD.
PIN DIAGRAM:
Circuit diagram:
The renaming three are very important pins RS (register set), RW(read write), and EN(enable
signal).
RS(register set):
Is used to distinguish between commands and data. When it is 1 it means that some data
is coming to LCD (by data i mean some characters or ASCII characters) and when it is 0 it
means that some command is approaching to LCD from external unit (usually a micro
controller) by commands i mean that a instruction for LCD is coming for example move cursor
one step back or forward turn on or off cursor etc.
RW(read-write):
This pin most often remains 0 because when it is 0 it means we are writing to LCD
module writing anything data or command. When it is 1 it means we are reading from LCD.
EN(Enable signal):
This enable signal is very important. When it is 1 it provides an extra beem to LCD to
display the character that the data pins are caring. After displaying the character it then comes
back to normal state 0. Two extra pins on some LCD are for background display one pin
represents background display apply 5 volts to turn on background display or 0 volts to turn off
background display.
The data which we send to our LCD can be any alphabet (small or big), digit or ASCII character.
We cannot send an integer,float,long,double type data to LCD because LCD is designed
to display a character only. The 8 data pins on LCD carries only ASCII 8-bit code of the
character to LCD. However we can convert our data in character type array and send one by one
our data to LCD. Data can be sent using 8-bit 0r 4-bit mode. If 4-bit mode is used, two nibbles of
data (First high four bits and then low four bits with an E Clock pulse with each nibble) are sent
to complete a full eight-bit transfer.8-bit mode is best used when speed is required in an
application and at least ten I/O pins are available. 4-bit mode requires a minimum of six bits. In
4-bit mode, only the top 4 data bits (DB4-7) are used.
LCD Commands:
The command 0x30 means we are setting 8-bit mode LCD having 1 line and we
are initializing it to be 5x7 character display. Now this 5x7 is something which everyone should
know what it stands for. Usually the characters are displayed on LCD in 5x8 matrices form.
Where 5 is total number of coulombs and is number of rows. Thus the above 0x30 command
initializes the LCD to display character in 5 coulombs and 7 rows the last row we usually leave
for our cursor to move or blink etc.
The command 0x38 means we are setting 8-bit mode LCD having two lines and
character shape between 5x7 matrixes.
The command 0x20 means we are setting 4-bit mode LCD having 1 line and
character shape between 5x7 matrixes.
The command 0x28 means we are setting 4-bit mode LCD having 2 lines and
character shape between 5x7 matrixes.
The command 0x06 is entry mode it tells the LCD that we are going to use you.
The command 0x08 display cursor off and display off but without clearing DDRAM
contents.
The command 0x0E displays cursor on and dispaly on.
The command 0x0c display on cursor off(displays cursor off but the text will appear
on LCD)
The command 0x0F dispaly on cursor blink (text will appear on screen and cursor
will blink).
The command 0x18 shift entire dispaly left (shift whole off the text on the particular
line to its left).
The command 0x1C shift entire dispaly right (shift whole off the text on the particular
line to its right).
The command 0x10 Moves cursor one step left or move cursor on step ahead to left
whenever new character is displayed on the screen.
The command 0x14 Moves cursor one step right or move cursor on step ahead to
right whenever new character is displayed on the screen.
The command 0x01 clear all the contents of the DDRAM and also clear the LCD
removes all the text from the screen.
The command 0x80 initialize the cursor to the first position means first line first
matrix (start point) now if we add 1 in 0x80+1=0x81 the cursor moves to second
matrix for example 16x1 LCD displays 16 characters only the first will appear on
0x80 second 0x81 third 0x82 and so on until last the 16 once on address 0xFF.
‘
Analog to Digital Convertor:
An ADC is defined by its bandwidth (the range of frequencies it can measure) and its
signal to noise ratio (how accurately it can measure a signal relative to the noise it introduces).
The actual bandwidth of an ADC is characterized primarily by its sampling rate, and to a lesser
extent by how it handles errors such as aliasing. The dynamic range of an ADC is influenced by
many factors, including the resolution (the number of output levels it can quantize a signal to),
linearity and accuracy (how well the quantization levels match the true analog signal) and jitter
(small timing errors that introduce additional noise). The dynamic range of an ADC is often
summarized in terms of its effective number of bits (ENOB), the number of bits of each measure
it returns that are on average not noise. An ideal ADC has an ENOB equal to its resolution.
ADCs are chosen to match the bandwidth and required signal to noise ratio of the signal to be
quantized. If an ADC operates at a sampling rate greater than twice the bandwidth of the signal,
then perfect reconstruction is possible given an ideal ADC and neglecting quantization error. The
presence of quantization error limits the dynamic range of even an ideal ADC, however, if the
dynamic range of the ADC exceeds that of the input signal, its effects may be neglected resulting
in an essentially perfect digital representation of the input signal.
An ADC may also provide an isolated measurement such as an electronic device that
converts an input analog voltage or current to a digital number proportional to the magnitude of
the voltage or current. However, some non-electronic or only partially electronic devices, such as
rotary encoders, can also be considered ADCs. The digital output may use different coding
schemes. Typically the digital output will be a two's complement binary number that is
proportional to the input, but there are other possibilities. An encoder, for example, might output
a Gray code.
Electrical Symbol:
Commercial analog-to-digital converters
Most converters sample with 6 to 24 bits of resolution, and produce fewer than 1 megasample
per second. Thermal noise generated by passive components such as resistors masks the
measurement when higher resolution is desired. For audio applications and in room
temperatures, such noise is usually a little less than 1 μV (microvolt) of white noise. If the MSB
corresponds to a standard 2 V of output signal, this translates to a noise-limited performance that
is less than 20~21 bits, and obviates the need for any dithering. As of February 2002, Mega- and
giga-sample per second converters are available. Mega-sample converters are required in digital
video cameras, video capture cards, and TV tuner cards to convert full-speed analog video to
digital video files.
Commercial converters usually have ±0.5 to ±1.5 LSB error in their output.
In many cases, the most expensive part of an integrated circuit is the pins, because they make the
package larger, and each pin has to be connected to the integrated circuit's silicon. To save pins,
it is common for slow ADCs to send their data one bit at a time over a serial interface to the
computer, with the next bit coming out when a clock signal changes state, say from 0 to 5 V.
This saves quite a few pins on the ADC package, and in many cases, does not make the overall
design any more complex (even microprocessors which use memory-mapped I/O only need a
few bits of a port to implement a serial bus to an ADC).
Commercial ADCs often have several inputs that feed the same converter, usually through an
analog multiplexer. Different models of ADC may include sample and hold circuits,
instrumentation amplifiers or differential inputs, where the quantity measured is the difference
between two voltages.
Applications:
1. Music recording:
The current crop of analog-to-digital converters utilized in music can sample at rates up to 192
kilohertz. Considerable literature exists on these matters, but commercial considerations often
play a significant role. Most[citation needed]
high-profile recording studios record in 24-bit/192-
176.4 kHz pulse-code modulation (PCM) or in Direct Stream Digital (DSD) formats, and then
downsample or decimate the signal for Red-Book CD production (44.1 kHz) or to 48 kHz for
commonly used for radio and television broadcast applications.
People must use ADCs to process, store, or transport virtually any analog signal in digital form.
TV tuner cards, for example, use fast video analog-to-digital converters. Slow on-chip 8, 10, 12,
or 16 bit analog-to-digital converters are common in microcontrollers. Digital storage
oscilloscopes need very fast analog-to-digital converters, also crucial for software defined radio
and their new applications.
3. Scientific instruments:
Some radar systems commonly use analog-to-digital converters to convert signal strength to
digital values for subsequent signal processing. Many other in situ and remote sensing systems
commonly use analogous technology.
The number of binary bits in the resulting digitized numeric values reflects the resolution, the
number of unique discrete levels of quantization (signal processing). The correspondence
between the analog signal and the digital signal depends on the quantization error. The
quantization process must occur at an adequate speed, a constraint that may limit the resolution
of the digital signal.
Many sensors produce an analog signal; temperature, pressure, pH, light intensity etc. All these
signals can be amplified and fed to an ADC to produce a digital number proportional to the input
signal.
BUZZER:
A buzzer or beeper (BUZZERS) is a signaling device, usually electronic, typically used
in automobiles, household appliances such as a microwave oven, or game shows. It most
commonly consists of a number of switches or sensors connected to a control unit that
determines if and which button was pushed or a preset time has lapsed, and usually illuminates a
light on the appropriate button or control panel, and sounds a warning in the form of a
continuous or intermittent buzzing or beeping sound. Initially this device was based on an
electromechanical system which was identical to an electric bell without the metal gong (which
makes the ringing noise). Often these units were anchored to a wall or ceiling and used the
ceiling or wall as a sounding board. Another implementation with some AC-connected devices
was to implement a circuit to make the AC current into a noise loud enough to drive a
loudspeaker and hook this circuit up to a cheap 8-ohm speaker.
Nowadays, it is more popular to use a ceramic-based piezoelectric sounder which makes
a high-pitched tone. Usually these were hooked up to "driver" circuits which varied the pitch of
the sound or pulsed the sound on and off.
A Piezo buzzer is made from two conductors that are separated by Piezo crystals. When a
voltage is applied to these crystals, they push on one conductor and pull on the other. The result
of this push and pull is a sound wave. These buzzers can be used for many things, like signaling
when a period of time is up or making a sound when a particular button has been pushed. The
process can also be reversed to use as a guitar pickup. When a sound wave is passed, they create
an electric signal that is passed on to an audio amplifier.
Circuit Diagram:
The simple buzzer circuit described here actually works in a quite unique way. Instead of the
normal working concept employed by other forms of oscillators which require resistor and
capacitor networks for generating the oscillations, this circuit use inductive feedback for the
required operations.
Referring to the above simple piezo buzzer circuit we find that the transistor T1 along with the
inductor forms the heart of the circuit. Basically the coil which is specifically called the buzzer
coil, is in fact positioned for amplifying the created oscillations while the actual feed back is
provided by the center tap of the three terminal piezo element used for the present application.
When a voltage is introduced in the circuit, the transistor conducts, operating the piezo element
across the buzzer coil, however this also leads to the grounding of the base of the transistor
through the center tap of the piezo element, this instantly switches off the transistor and in turn
the piezo also switches off, releasing the base of the transistor. The transistor reverts to its
original state and the cycle repeats, generating oscillations or the required “buzzing” frequency.
The center tap from the piezo transducer plays an important role in sustaining the oscillations
and therefore in this particular design we need a three terminal piezo rather than a two terminal
one. The oscillations produced at the collector of the transistor is dumped into the coil, saturating
the coil with magnetic inductions. The coil kicks back the stored energy during the oscillations,
magnifying the generated AC across it. This stepped up AC is applied across the anode and the
cathode of the piezo element, which starts vibrating sharply according the pitch of the frequency,
generating a shrill, ear piercing sound in the air. However to make the sound audible at
maximum intensity, the piezo transducer needs to be stuck or installed in a special way inside its
housing.
For this particular application the piezo element needs to be stuck at the base of its housing
which must consist of a hole having a diameter of about 7 mm. The piezo element cannot be
stuck directly over the base of the housing, rather it must stuck and positioned over a soft, pure
rubber ring, having diameter 30 % less than that of the piezo transducer.
Only if the above fixing procedure is followed, the buzzer will sound, otherwise the sound may
get choked and fail to reproduce.
APPLICATIONS:
Annunciator panels
Electronic metronomes
Game shows
Microwave ovens and other household appliances
Sporting events such as basketball games
PIR Sensor:
A motion detector is a device that detects moving objects, particularly
people. A motion detector is often integrated as a component of a system that
automatically performs a task or alerts a user of motion in an area. Motion
detectors form a vital component of security, automated lighting control, home
control, energy efficiency, and other useful systems.
ARDUINO MICROCONTROLLER
The Arduino microcontroller is an easy to use yet powerful single board
computer that has gained considerable traction in the hobby and professional
market. The Arduino is open-source, which means hardware is reasonably priced
and development software is free. This guide is for students in ME 2011, or
students anywhere who are confronting the Arduino for the first time. For
advanced Arduino users, prowl the web; there are lots of resources.
The Arduino project was started in Italy to develop low cost hardware for
interaction design. An overview is on the Wikipedia entry for Arduino. The
Arduino hardware comes in several flavors. In the United States, Sparkfun
(www.sparkfun.com) is a good source for Arduino hardware. The Arduino board,
you can write programs and create interface circuits to read switches and other
sensors, and to control motors and lights with very little effort. Many of the
pictures and drawings in this guide were taken from the documentation on the
Arduino site, the place to turn if you need more information. The Arduino section
covers more on interfacing the Arduino to the real world.
Some shields communicate with the Arduino board directly over various pins,
but many shields are individually addressable via an I²C serial bus—so many shields
can be stacked and used in parallel. Prior to 2015 Official Arduinos had used the
AtMel megaAVR series of chips, specifically
the ATmega8, ATmega168, ATmega328, ATmega1280, and ATmega2560 and in
2015 units by other manufacturers were added. A handful of other processors have
also been used by Arduino compatibles. Most boards include a 5 V linear
regulator and a 16 MHz crystal oscillator (or ceramic resonator in some variants),
although some designs such as the LilyPad run at 8 MHz and dispense with the
onboard voltage regulator due to specific form-factor restrictions.
Some boards, such as later-model Uno boards, substitute the FTDI chip with a
separate AVR chip containing USB-to-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 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.10-inch (2.5 mm) headers. Several plug-in application shields are also
commercially available.
The Arduino Nano, and Arduino-compatible Bare Bones Board[9] and Boarduino
boards may provide male header pins on the underside of the board that can plug
into solderless breadboards.
Digital Pins
In addition to the specific functions listed below, the digital pins on an
Arduino board can be used for general purpose input and output via the pinMode(),
digitalRead(), and digitalWrite() commands. Each pin has an internal pull-up
resistor which can be turned on and off using digitalWrite() (w/ a value of HIGH or
LOW, respectively) when the pin is configured as an input. The maximum current
per pin is 40 mA.
ARDUINO
The universal languages for Arduino are C and C++, thus the software is fit for
professionals who are familiar with these two. Features such as syntax
highlighting, automatic indentation and brace matching makes it a modern
alternative to other IDEs.Wrapped inside a streamlined interface, the software
features both the looks and the functionality that appeal to Arduino developers,
paving the way to a successful output via the debugging modules.
All of its features are hosted inside a few buttons and menus that are easy to
navigate and understand, especially for professional programmers. Also, the built-
in collection of examples might be of great help for Arduino first timers.Provided
that you’ve connected the Arduino board to the computer and installed all the
necessary drivers, one of the first steps we see fit is to choose the model you’ll be
working with using the Tools menu of the application.
Then, you can start writing the programs using the comfortable environment
that Arduino offers. The program includes a rich array of built-in libraries such as
EEPROM, Firmata, GSM, Servo, TFT, WiFI, etc, but adding your own is also
possible. Designs can be verified and compiled, with an error log displayed in the
lower part of the UI that allows you to review the code.
If the debugging process returns no errors, you can start the upload process
and have your program delivered to the board so you can proceed with further
testing.All in all, Arduino comes across as an extremely useful asset, providing the
essentials that Arduino developers need in order to streamline the testing process.
The Arduino IDE supports the C and C++ programming languages using
special rules of code organization. The Arduino IDE supplies a software
library called "Wiring" from the Wiring project, which provides many common
input and output procedures. A typical Arduino C/C++ sketch consists of two
functions that are compiled and linked with a program stub main () into an
executable cyclic program:
setup(): a function that runs once at the start of a program and that can initialize
settings.
loop(): a function called repeatedly until the board powers off.
After compilation and linking with the GNU tool chain, also included with
the IDE distribution, the Arduino IDE employs the programavrdude to convert the
executable code into a text file in hexadecimal coding that is loaded into the
Arduino board by a loader program in the board's firmware
OVERVIEW
A number of things have to happen for your Arduino code to get onto the
Arduino board. First, the Arduino environment performs some small
transformations to make sure that the code is correct C or C++ (two common
programming languages). It then gets passed to a compiler (avr-gcc), which turns
the human readable code into machine readable instructions (or object files). Then,
your code gets combined with (linked against), the standard Arduino libraries that
provide basic functions like digitalWrite() or Serial.print().
The result is a single Intel hex file, which contains the specific bytes that
need to be written to the program memory of the chip on the Arduino board. This
file is then uploaded to the board: transmitted over the USB or serial connection
via the bootloader already on the chip or with external programming hardware.
Multi-file sketches
A sketch can contain multiple files (tabs). To manage them, click on the
right-facing arrow just above the scroll bar near the top of the environment. Tabs
have one of four extensions: no extension, .c, .cpp, or .h (if you provide any other
extension, the period will be converted to an underscore). When your sketch is
compiled, all tabs with no extension are concatenated together to form the "main
sketch file". Tabs with .c or .cpp extensions are compiled separately. To use tabs
with a .h extension, you need to #include it (using "double quotes" not <angle
brackets.
Next, the environment searches for function definitions within your main
sketch file and creates declarations (prototypes) for them. These are inserted after
any comments or pre-processor statements (#includes or #defines), but before any
other statements (including type declarations). This means that if you want to use a
custom type as a function argument, you should declare it within a separate header
file. Also, this generation isn't perfect: it won't create prototypes for functions that
have default argument values, or which are declared within a namespace or class.
TARGETS
The Arduino environment supports multiple target boards with different
chips (currently, only AVRs), CPU speeds, or bootloaders. These are defined in a
board preferences file. Relevant variables include:
Note: that in Arduino 0004 and later, build.extension is unused - the main sketch
file is always treated as a .cpp file.
Build process
Sketches are compiled by avr-gcc.
The include path includes the sketch's directory, the target directory
(<ARDUINO>/hardware/core/<CORE>/) and the avr include directory
(<ARDUINO>/hardware/tools/avr/avr/include/), as well as any library directories
(in <ARDUINO>/hardware/libraries/) which contain a header file which is
included by the main sketch file.
When you verify a sketch, it is built in a temporary directory in the system temp
directory (e.g. /tmp on the Mac). When you upload it, it is built in the applet/
subdirectory of the sketch's directory (which you can access with the "Show Sketch
Folder" item in the "Sketch" menu).
The .c and .cpp files of the target are compiled and output with .o extensions
to this directory, as is the main sketch file and any other .c or .cpp files in the
sketch and any .c or .cpp files in any libraries which are #included in the sketch.
These .o files are then linked together into a static library and the main sketch file
is linked against this library. Only the parts of the library needed for your sketch
are included in the final .hex file, reducing the size of most sketches.
The .hex file is the final output of the compilation which is then uploaded to
the board. During a "Verify" the .hex file is written to /tmp (on Mac and Linux) or
\Documents and Settings\<USER>\Local Settings\Temp (on Windows). During
upload, it's written to the applet sub-directory of the sketch directory (which you
can open with the "Show Sketch Folder" item in the Sketch menu).
Upload process
Sketches are uploaded by avrdude. The upload process is also controlled by
variables in the boards and main preferences files. Those in the boards file include:
<BOARD>.upload. Protocol: the protocol that avrdude should use to talk to the
board (typically "stk500").
<BOARD>.upload. Speed: the speed (baud rate) avrdude should use when
uploading sketches (typically "19200").