Beruflich Dokumente
Kultur Dokumente
info@hbeonlabs.com
training@hbeonlabs.com
www. hbeonlabs.com
INTRODUCTION
panels
toward
it.
engineering and
technology
students
to
have
an
energy.
The pin diagram of the 8051 shows all of the input/output pins unique
to microcontrollers:
BLOCK DIAGRAM
POWER SUPPLY
OPAMP
L293D
LDR
8051
MICROCONTR
OLLER
RTC SECTION
DC
MOTOR
SOLAR
PANEL
CIRCUIT DIAGRAM
COMPONENT LIST
HARDWARE DESCRIPTION:
1. POWER SUPPLY:
TRANSFORMER:
transformer is a device that transfers electrical energy from one
circuit to another through inductively coupled conductors the
transformer's coils or "windings". Except for air-core transformers, the
conductors are commonly wound around a single iron-rich core, or
around separate but magnetically-coupled cores. A varying current in
the first or "primary" winding creates a varying magnetic field in the
core (or cores) of the transformer. This varying magnetic field induces
Two coils of wire (called windings) are wound on some type of core
material. In some cases the coils of wire are wound on a cylindrical or
rectangular cardboard form. In effect, the core material is air and the
transformer is called an AIR-CORE TRANSFORMER. Transformers
used at low frequencies, such as 60 hertz and 400 hertz, require a core
of low-reluctance magnetic material, usually iron. This type of
transformer is called an IRON-CORE TRANSFORMER. Most power
transformers are of the iron-core type. The principle parts of a
transformer and their functions are:
The CORE, which provides a path for the magnetic lines of flux.
BRIDGE RECTIFIER
A bridge rectifier makes use of four diodes in a bridge arrangement to
achieve full-wave rectification. This is a widely used configuration,
Basic operation
terminal
via
the
blue
(negative)
path.
When
the
input connected to the left corner is negative, and the input connected
to the right corner is positive, current flows from the lower supply
terminal to the right along the red path to the output, and returns to
the upper supply terminal via the blue path.
In each case, the upper right output remains positive and lower right
output negative. Since this is true whether the input is AC or DC, this
circuit not only produces a DC output from an AC input, it can also
provide what is sometimes called "reverse polarity protection". That
is, it permits normal functioning of DC-powered equipment when
batteries have been installed backwards, or when the leads (wires)
REGULATOR IC (78XX)
When this filter is used, the RC charge time of the filter capacitor (C1)
must be short and the RC discharge time must be long to eliminate
ripple action. In other words, the capacitor must charge up fast,
preferably with no discharge at all. Better filtering also results when
the input frequency is high; therefore, the full-wave rectifier output is
easier to filter than that of the half-wave rectifier because of its higher
frequency.
For you to have a better understanding of the effect that filtering has
on Eavg, a comparison of a rectifier circuit with a filter and one without
a filter is illustrated in views A and B of figure 4-16. The output
waveforms in figure 4-16 represent the unfiltered and filtered outputs
of the half-wave rectifier circuit. Current pulses flow through the load
resistance (RL) each time a diode conducts. The dashed line indicates
the average value of output voltage. For the half-wave rectifier, Eavg is
less than half (or approximately 0.318) of the peak output voltage.
This value is still much less than that of the applied voltage. With no
capacitor connected across the output of the rectifier circuit, the
waveform in view A has a large pulsating component (ripple)
compared with the average or dc component. When a capacitor is
connected across the output (view B), the average value of output
voltage (Eavg) is increased due to the filtering action of capacitor C1.
UNFILTERED
As you can see from the calculations, by doubling the frequency of the
rectifier, you reduce the impedance of the capacitor by one-half. This
allows the ac component to pass through the capacitor more easily. As
a result, a full-wave rectifier output is much easier to filter than that of
a half-wave rectifier. Remember, the smaller the XC of the filter
capacitor with respect to the load resistance, the better the filtering
action. Since
DIODE
The diode is a p-n junction device. Diode is the component used to
control the flow of the current in any one direction. The diode widely
works in forward bias.
fall in three categories , only two of which are color coded which are
metal film and carbon film resistor .the third category is the wire
wound type ,where value are generally printed on the vitreous paint
finish of the component. Resistors are in ohms and are represented in
Greek letter omega, looks as an upturned horseshoe. Most electronic
circuit require resistors to make them work properly and it is
obliviously important to find out something about the different types
of resistors available. Resistance is measured in ohms, the symbol for
ohm is an omega ohm. 1 ohm is quite small for electronics so
resistances are often given in kohm and Mohm.
Resistors used in electronics can have resistances as low as 0.1 ohm or
as high as 10 Mohm.
FUNCTION
Resistor restrict the flow of electric current, for example a resistor is
placed in series with a light-emitting diode(LED) to limit the current
passing through the LED.
TYPES OF RESISTORS
TESTING
Resistors are checked with an ohm meter/millimeter. For a defective
resistor the ohm-meter shows infinite high reading.
CAPACITORS
In a way, a capacitor is a little like a battery. Although they work in
completely different ways, capacitors and batteries both store
electrical energy. If you have read How Batteries Work , then you
know that a battery has two terminals. Inside the battery, chemical
reactions produce electrons on one terminal and absorb electrons at
the other terminal.
BASIC
Like a battery, a capacitor has two terminals. Inside the capacitor, the
terminals connect to two metal plates separated by a dielectric. The
dielectric can be air, paper, plastic or anything else that does not
conduct electricity and keeps the plates from touching each other. You
can easily make a capacitor from two pieces of aluminum foil and a
piece of paper. It won't be a particularly good capacitor in terms of its
storage capacity, but it will work.
In an electronic circuit, a capacitor is shown like this:
TESTING
To test the capacitors, either analog meters or specia
l digital meters with the specified function are used. The nonelectrolyte capacitor can be tested by using the digital meter.
One end
Faulty OK
LED
LED falls within the family of P-N junction devices. The light
emitting diode (LED) is a diode that will give off visible light when it
is energized. In any forward biased P-N junction there is, with in the
structure and primarily close to the junction, a recombination of hole
and electrons. This recombination requires that the energy possessed
by the unbound free electron be transferred to another state. The
process of giving off light by applying an electrical source is called
electroluminescence.
Display Section:
LIQUID CRYSTAL DISPLAY
The liquid - crystal display (LCD) consist of a liquid crystal material
(normally organic for LCDs) that will flow like a liquid but whose
molecular structure has some properties normally associated with
solids.
The LCD does not generate its own light but depends on an external
or internal source.
Under dark conditions, it would be necessary for the unit to have its
own internal light source either behind or to the side of the LCD.
During the day, or in the lighted areas, a reflector can be put behind
the LCD to reflect the light back through the display for maximum
intensity.
The LCD has the distinct advantage of having the lower power
requirement than the LED. It is typical in the order of microwatts for
the display, as compared to the same order of milliwatts for LEDs.
LCD is limited to a temperature range of about 0 to 60 C. Lifetime is
an area of concern because LCDs can chemically degrade.
and a few
characters.
In corporation of a refreshing controller into the LCD , thereby
relieving the CPU of the task of refreshing the LCD in contrast, the
LED must be refreshed by the CPU (or in some other way) to keep
displaying the data.
Ease of programming for characters and graphics.
The LCD used here has 14 pins. The functions of each pin is given
below:
While Vcc and Vss provide +5V and ground, respectively, VEE is used
for controlling LCD contrast.
There are two very important registers inside the LCD. The RS pin is
used for their selection as follows .If RS = 0 , then instruction
command code register is selected , allowing the user to send the
command such as clear display, cursor at home, etc. If RS = 1 the data
register is selected, allowing the user to send data to be displayed on
the LCD.
R/W, READ/WRITE:
R/W input allows the user to write information to the LCD or read
information from it.
R/W =1 when reading ; R/W = 0 when writing.
E, ENABLE:
The enable pin is used by the LCD to latch information presented to
its data pins. When data is supplied to data pins, a high to low
pulse must be applied to this pin in order for the LCD to latch in the
data present at the data pins. This pulse must be a minimum of 450
ns wide.
D0 D7:
The 8 bit data pins , D0 D7, are used to send information to the
LCD or read the contents of the LCD's internal registers.
To display letters and numbers, we send ASCII codes for the letters AZ, a-z, and 0-9 to these pins while making RS = 1.
There are also instruction command codes that can be send to the
LCD to clear the display or force to cursor to the home position or
blink the cursor.
We also use RS=0 to check the busy flag bit to see if the LCD is ready
to receive information. The busy flag is D7 and can be read when
R/W=1.RS=0, as follows: if R/W=1 and RS=0.When D7=1 (busy
flag=1), the LCD is busy taking care of internal operations and will not
accept any new information. When D7 = 0, the LCD is ready to
receive new information.
Pi
Sym I/O
bol
Vss
--
Ground
Vcc
--
VEE --
RS
Description
data register
5
R/W I
Enable
DB0 I/O
DB1 I/O
I/O
DB2 I/O
10 DB3 I/O
11 DB4 I/O
12 DB5 I/O
13 DB6 I/O
14 DB7 I/O
Code (Hex)
Command
to
LCD
Instruction
Register
1
Return home
Display on
10
14
18
1C
80
C0
38
WORKING:
The interface used by LCD is a parallel bus, allowing simple and fast
reading/writing of data to and from the LCD.
This waveform will write an ASCII Byte out to the LCD's screen. The
ASCII code to be displayed is eight bits long and is sent to the LCD
either four or eight bits at a time. If four bit mode is used, two
"nibbles" of data (Sent high four bits and then low four bits with an
"Enable" Clock pulse with each nibble) are sent to make up a full
eight bit transfer. The "Enable" Clock is used to initiate the data
transfer within the LCD.
Sending parallel data as either four or eight bits are the two primary
modes of operation. While there are secondary considerations and
modes, deciding how to send the data to the LCD is most critical
decision to be made for an LCD interface application.
Eight bit mode is best used when speed is required in an application
and at least ten I/O pins are available. Four bit mode requires a
minimum of six bits. To wire a microcontroller to an LCD in four bit
mode, just the top four bits (DB4-7) are written to.
The "RS" bit is used to select whether data or an instruction is being
transferred between the microcontroller and the LCD. If the Bit is set,
then the byte at the current LCD "Cursor" Position can be read or
written. When the Bit is reset, either an instruction is being sent to the
LCD or the execution status of the last instruction is read back
(whether or not it has completed).
Reading Data back is best used in applications which required data to
be moved back and forth on the LCD (such as in applications which
scroll data between lines).In our Project we have permanently
grounded R/W pin which means we are not retrieving any data from
LCD.
The LCD can be thought of as a "Teletype" display because in normal
operation, after a character has been sent to the LCD, the internal
"Cursor" is moved one character to the right. The "Clear Display" and
"Return Cursor and LCD to Home Position" instructions are used to
reset the Cursor's position to the top right character on the display.
To move the Cursor, the "Move Cursor to Display" instruction is used.
For this instruction, bit 7 of the instruction byte is set with the
remaining seven bits used as the address of the character on the LCD
the cursor is to move to. These seven bits provide 128 addresses,
which matches the maximum number of LCD character addresses
available.
LDR
A photo
resistor or light
dependent
resistor (LDR)
is
the conduction
band.
The
resulting
free
electron
(and
are
among
infrared detectors
and
are
available,
the
used
best
far-
for infrared
Device consists of a pair of metal film contacts separated by a snakelike track of cadmium sulphide film, designed to provide the
maximum possible contact area with the two metal films. The
structure is housed in a clear plastic or resin case, to provide free
access to external light. Practical LDRs are available in a variety of
sizes and package styles, the most popular size having a face diameter
of roughly 10 mm.
LDRs are sensitive, inexpensive, and readily available devices. They
have good power and voltage handling capabilities, similar to those of
a conventional resistor. Their only significant defect is that they are
fairly low acting, taking tens or hundreds of mille-seconds to respond
to sudden changes in light level. Useful practical applications of LDR
include light and dark-activated switches and alarms, light beam
alarms and reflective smoke alarms etc. LDRs or Light Dependent
Resistors are very useful especially in light/dark sensor circuits.
Normally the resistance of an LDR is very high, sometimes as high as
1000 000 ohms, but when they are illuminated with light resistance
drops dramatically
RTC DS1307
PIN DESCRIPTION
VCC
X1, X2
VBAT
GND
- Ground
SDA
- Serial Data
SCL
- Serial Clock
SQW/OUT
DESCRIPTION
The DS1307 Serial Real-Time Clock is a low-power,
full binary-coded decimal (BCD) clock/calendar plus 56 bytes of NV
SRAM. Address and data are transferred serially via a 2-wire, bidirectional bus. The clock/calendar provides seconds, minutes, hours,
day, date, month, and year information. The end of the month date is
automatically adjusted for months with fewer than 31 days, including
corrections for leap year. The clock operates in either the 24-hour or
VISION
The Vision IDE is, for most developers, the easiest way to
create embedded system programs. This chapter describes
commonly used Vision features and explains how to use them.
Positioning Windows
The Vision windows may be placed onto any area of the
screen, even outside of the Vision frame, or to another physical
screen.
Click and hold the Title Bar1 of a window with the left mouse
button
Keil software converts the C-codes into the Intel Hex code.
PRO 51
Features of PRO51
PC with at least one serial and one USB ports and at least
600x800 VGA resolution.
If USB port is not available you need a regulated +5V supply.
Windows operating system
Package Contents
PRO51 unit
Interface Cable between PC and PRO51
CD containing PROG51 software
Getting Started
1. Install PROG51 programs using setup from the CD. This would
normally create these programs in a program group INFONICS.
You may like to create a separate folder like INFONICS on your
disk where these programs will be installed.
2. Connect PRO51 to COM port and USB on your PC using the Y
cable provided with PRO51. Follow instruction given in the
following sections.
1. Connect the PRO51 to COM port and USB port on your PC.
USB is used for +5V power supply only. You can use regulated
5V supply and connect it on pin 4 of the 9 Pin connector.
2. Start PROG51 from your program menu.
3. Select appropriate com port on your PC.
4. Insert desired device in the ZIF socket on PRO51. 20 Pin
devices like 89C2051 should be aligned with the bolltom side,
11.
3
2
6
8
4
5
Power
Supply
RST
RXD
Programmer
ZIF Socket
TXD
Pin Name
Description
NC
Not connected
RXD
TXD
VCC
GND
RXDEN
NC
Not connected
RESET
NC
Not connected
PRECAUTIONS
SOLDERING PRECAUTIONS
The construction was carried out with care. The precautions
taken during the soldering were:
The tip of soldering iron was kept clean with the help of a file
from time to time.
The solder wire was of smaller thickness.
COMPONENTS PRECAUTION:
TESTING OF PROJECT
ASSEMBLING
The whole system was packed in a plastic casing and provision
was made for the IR to sense light from the outside.
REFERENCES