You are on page 1of 46

Rajagiri School of Engineering &

Technology, Kakkanad

ACKNOWLEDGMENT

I thank God almighty for His bountiful mercy and graces showered on us during the
period of project, without which nothing could have been possible. I thank the Principal
and the Management for lending us a helping hand & providing us lab and other technical
assistances. I would like to thank the Head of the Department, Prof. Madhava Panicker
and Ex-Head of the Department, Prof. S. Ramkumar, who have been our sources of
motivation and guidance at all times, especially throughout the period of project. I would
like to thank our project guide, Mr. Joval P.G. who always stood by us during the course
of the project and especially during the tougher times, motivating and guiding us in our
project. I extend sincere gratitude to all the Faculty of RASET who have helped us in our
project. I would also like to thank our Lab Assistant, Mr. Jince Mon. it would never have
been possible to accomplish whatever we have, without his ever helping hands.

1
Rajagiri School of Engineering &
Technology, Kakkanad

INDEX

CHAPTER Page
TITLE
No. No.
1. INTRODUCTION 3

2. TRANSMITTER/ RECEIVER DESIGN& DEVELOPMENT 6

3. MICRO CONTROLLER PROGRAMMING & LOGIC DESIGN 16

MOTOR DRIVE MECHANISM AND HARDWARE


4. 22
IMPLEMENTATION.

5. CONCLUSION. 34

6. APPENDIX - A: MODULAR DIVISION OF WORK 37

7. APPENDIX – B: PROGRAM CODE 38

8. APPENDIX C: THE 8051 IDE 42

9. APPENDIX D: THE PCB DESIGN 44

2
Rajagiri School of Engineering &
Technology, Kakkanad

CHAPTER – 1

INTRODUCTION

1.1) AIM ……………………..………………………………...Pg 4

1.2) CONCEPTUAL DESIGN-BLOCK SCHEMATIC


1.2.1) TRANSMITTING UNIT………………..……..Pg 4

1.2.2) RECEIVING UNIT….…………………………Pg 5

CHAPTER 1:

3
Rajagiri School of Engineering &
Technology, Kakkanad

INTRODUCTION

1.1) Aim :

To develop a Personalized Automated Garage Door Opener, that uses key less entry to
one’s home’s garage, every time the owner initiates the remote.

The microcontroller unit (at the transmitter) services an interrupt service routine
when an interrupt (key press on remote) is being signaled. The microcontroller serially
outputs a specific code, preset in the microcontroller. The code that is been serially output
is then given as an input to the ASK transmitter module. The ASK transmitter module
now converts the digital output to an analog RF signal that is transmitted.

The ASK receiver module at the base station receives the ASK signal and the
decoded (digital) signal is input to the microcontroller at the receiver part. On being
interrupted by the serial input interrupt, the microcontroller services a routine that checks
whether the received code is an authorized (preset look up table) code. If the code is an
authorised code, then the motor is driven.

1.2) Conceptual Design-Block Schematic:

4
Rajagiri School of Engineering &
Technology, Kakkanad

1.2.1) Transmitting Unit

Micro Serial
Trigger Signal output A. S. K. RF
Controller
Module I Transmitter
Unit I

1.2.2) Receiving Unit

Serial
RF input Micro
A. S. K
Receiver Controller
Module II
Unit II

Motor Drive
Unit

5
Rajagiri School of Engineering &
Technology, Kakkanad

CHAPTER – 2

TRANSMITTER/ RECEIVER DESIGN, DEVELOPMENT

AND INTEGRATION.

2.1) INTRODUCTION ……………………………………………...……….Pg 7

2.1.1) ANALOG MODULATION TECHNIQUES….………………Pg 8

2.1.2) DIGITAL MODULATION TECHNIQUES…………………..Pg 8

2.1.3) BLOCK SCHEMATIC - AMPLITUDE SHIFT KEYING…..Pg 10

2.2) ON OFF KEYING:………………………………….…………………..Pg 10

2.3) SCHEMATIC DIAGRAM OF A.S.K…………….……………………..Pg 11

2.4) TRANSMITTER & RECEIVER MODULE FEATURES

2.4.1) FEATURES OF TRANSMITTER……………………………Pg 11

2.4.2) FEATURES OF RECEIVER……..…………………………..Pg 12

2.4.3) ISSUES ENCOUNTERED ……………………………….…..Pg 12

2.5) INTERFACING WITH AT89C51……………..…………………….Pg 14

6
Rajagiri School of Engineering &
Technology, Kakkanad

CHAPTER 2

TRANSMITTER/ RECEIVER DESIGN, DEVELOPMENT AND

INTEGRATION.

2.1) I n t r o d u c t i o n

Modulation is the process of varying a carrier signal in order to use that signal to
convey information. The three key parameters of a sinusoid are its amplitude, its phase
and its frequency, all of which can be modified in accordance with an information signal
to obtain the modulated signal. There are several reasons to modulate a signal before
transmission in a medium. These include the ability of different users sharing a medium
(multiple access), and making the signal properties physically compatible with the
propagation medium. A device that performs modulation is known as a modulator and a
device that performs the inverse operation of demodulation is known as a demodulator. A
device that can do both operations is a modem (a contraction of the two terms).

In digital modulation, the changes in the signal are chosen from a fixed list (the
modulation alphabet) each entry of which conveys a different possible piece of
information (a symbol). The alphabet is often conveniently represented on a constellation
diagram.
In analog modulation, the change is applied continuously in response to the data
signal. The modulation may be applied to various aspects of the signal as the lists below
indicate.
Modulation is generally performed to overcome signal transmission issues such as
to allow
• Easy (low loss, low dispersion) propagation as electromagnetic waves

7
Rajagiri School of Engineering &
Technology, Kakkanad
• Multiplexing — the transmission of multiple data signals in one frequency band,
on different carrier frequencies.
• Smaller, more directional antennas
Carrier signals are usually high frequency electromagnetic waves.
2 . 1 . 1 ) Analog mo dula tion techniques :

• Angular modulation
o Phase modulation (PM)
o Frequency modulation (FM)
• Amplitude modulation (AM)
o Single-sideband modulation (SSB, or SSB-AM), very similar to
single-sideband suppressed carrier modulation (SSB-SC)
o Vestigial-sideband modulation (VSB, or VSB-AM)
• Sigma-delta modulation (∑Δ)

2.1.2) Digital modulation techniques

Any form of digital modulation necessarily uses a finite number of distinct signals
to represent digital data.
• In the case of PSK, a finite number of phases are used.
• In the case of FSK, a finite number of frequencies are used.
• In the case of ASK, a finite number of amplitudes are used.

Each of these phases, frequencies or amplitudes are assigned a unique pattern of


binary bits. Usually, each phase, frequency or amplitude encodes an equal number of bits.
This number of bits comprises the symbol that is represented by the particular phase.

These are the general steps used by the modulator to transmit data:
1. Accept incoming digital data;
2. Group the data into symbols;

8
Rajagiri School of Engineering &
Technology, Kakkanad
3. Use these symbols to set or change the phase, frequency or amplitude of the
reference signal appropriately;
4. Pass the modulated signal on for further processing, such as filtering and channel-
coding, before transmission.

At the receiver, the demodulator

1. Is passed the de-filtered and de-channel-coded signal;


2. Determines its phase, frequency or amplitude;
3. Maps the phase, frequency or amplitude to its corresponding symbol;
4. Translates the symbol into its individual bits;
5. Passes the resultant bit stream on for further processing such as removal of any
error-correcting codes.

As is common to all digital communication systems, the design of both the modulator
and demodulator must be done simultaneously. Digital modulation schemes are possible
because the transmitter-receiver pair have prior knowledge of how data is encoded and
represented in the communications system. In all digital communication systems, both
the modulator at the transmitter and the demodulator at the receiver are structured so that
they perform inverse operations.

The principal classes of modulation are:


• Phase-shift keying (PSK)
• Frequency-shift keying (FSK) and audio frequency-shift keying (AFSK)
o Minimum-shift keying (MSK)
o Gaussian minimum-shift keying (GMSK)
o Very minimum-shift keying (VMSK)
• Amplitude-shift keying (ASK) and its most common form, on-off keying (OOK)
• Quadrature amplitude modulation

9
Rajagiri School of Engineering &
Technology, Kakkanad

2.1.3) Block Schematic - Amplitude Shift Keying

2.2) ON OFF KEYING:

10
Rajagiri School of Engineering &
Technology, Kakkanad
On-off keying (OOK) is a type of modulation that represents digital data as the
presence or absence of a carrier wave. In its simplest form, the presence of a carrier for a
specific duration represents a binary one, while its absence for the same duration
represents a binary zero. Some more sophisticated schemes vary these durations to
convey additional information.

In ASK, the two binary values are represented by two different amplitudes of the
carrier frequency. Commonly, one of the amplitude is zero; that is, one binary digit is
represented by the presence, at constant amplitude, of the carrier, the other by absence of
carrier. Resulting signal is ASK

S{t} = Acos(2Πfct){binary=0}
= 0 {binary=1}

2.3) Schematic diagram of A.S.K

2.4) Transmitter & Receiver Module Features:

2.4.1) Features of transmitter

11
Rajagiri School of Engineering &
Technology, Kakkanad

Features: Frequency: 433.92MHz • Operating Voltage: 2 to 12 Vdc • Data Rate: Up to


200K bps • Works directly with HT12E or similar encoder • Dimensions: Width -
10.3mm; Height - 13.3mm (Excluding Pins.)

2.4.2) Features of Receiver

Operating supply voltage range: 3.3 - 6.0 V


Typical=5v
Operating Current - 4.5 mA
Channel Width=10khz
Receiver Turn On Time= 5 ms
Baseboard Data Rate= 4.8 KHz

2.4.3) Issues encountered in this module of the project:

12
Rajagiri School of Engineering &
Technology, Kakkanad
The initial idea was to make use of Frequency Shift Keyed modulation scheme
transmission, due to the advantages of FSK over ASK. The major advantage would have
been the least noise transmission and reception. The non-availability of the FSK
transmission circuits and associated accessories, our hopes of incorporating FSK
mechanism in our projects, were all in vain.

The ASK module (TLP/RLP 434A) couldn’t faithfully transmit the 8 bit code that
was serially output from the microcontroller, due to poor noise rejection. The
experimental study conducted on the module revealed that pulse wave forms generated
from the function generated was more or less faithfully transmitted.

To improve the noise rejection ,a band pass filter was designed and connected at
the reception part, but the filter was unable to satisfy our need.

The failure of SAW based ASK module to faithfully transmit our code forced us
to replace the SAW model with a CRYSTAL based ASK module.

The crystal based ASK module and its features are as follows:

13
Rajagiri School of Engineering &
Technology, Kakkanad

2 . 5 ) I n t e r f a c i n g w i t h AT 8 9 C 5 1 :
The receiver module output was found to have insufficient current driving capability, due
to which the received signal was not properly received at the microcontroller. The
transistor interface using the 2N2222 catered to the current requirements.

14
Rajagiri School of Engineering &
Technology, Kakkanad

15
Rajagiri School of Engineering &
Technology, Kakkanad

CHAPTER – 3

MICROCONTROLLER PROGRAMMING, LOGIC DESIGN


A N D G E N E R A L C I R C U I T R Y.

3.1) TRANSMISSION PART.………………………………………...Pg 17


3.2) RECEPTION PART………………………………………...…….Pg 17
3.3) MOTOR DRIVE………………………………………………….Pg 17
3.4) A BRIEF HISTORY OF AT89C51………………………………Pg 18
3.5) FEATURES AND ARCHITECTURE OF AT89C51
3.5.1) FEATURES OF 8051………………………………..….Pg 19
3.5.2) ARCHITECTURE OF 8051………………………….…Pg 20
3.6) PROGRAMMING THE MICROCONTROLLER……………..…Pg 21

16
Rajagiri School of Engineering &
Technology, Kakkanad

CHAPTER 3:

MICROCONTROLLER PROGRAMMING & LOGIC DESIGN

The major objective is to program the microcontroller so as to perform the desired


applications, listed below:

3 . 1 ) Tr a n s m i s s i o n p a r t : the microcontroller plays a very significant part at the


transmitter part. The microcontroller senses a key press on the remote (as an interrupt)
and accordingly sends a particular initiating signal to the RF module (ASK) that transmits
it. The project also imitates a RC (rolling code) algorithm, so that it is hack proof. The
rolling code algorithm is a defined random number generator algorithm that generates
and sends a particular code each time the user initiates the remote key press.

The imitation of the rolling code is being done be presetting a set of ten codes in
consecutive address locations of the RAM. Each time the code has to be sent, one of the
ten codes are selected and sent.

The output of the microcontroller to the RF module is done serially and the
microcontroller program has to deal with the serial communication also.

3.2) Reception part: The microcontroller has a role to play, which is no less significant
than in any other part. The microcontroller receives the digital output from the RF

17
Rajagiri School of Engineering &
Technology, Kakkanad
module and then checks the code received from the receiver with the preset look up table
that stores all the valid codes. The authorisation is hence the job of the microcontroller at
the reception part.

3.3) Motor Drive: The motor is a dc motor and hence has to be driven by providing
proper sequences ( 1 0 or 0 1 for clockwise or anti-clockwise, respectively), properly
delayed, so as to control the time duration of rotations. The microcontroller program code
also takes care of the number of rotations etc.

3.4) A brief history of the 8051

In 1981, Intel Corporation introduced an 8-bit microcontroller called the 8051.


This microcontroller had 128 bytes of RAM, 4K bytes of on-chip ROM, two timers, one
serial port, and four ports (each 8-bits wide) all on a single chip. At the time it was also
referred to as a "system on a chip." The 8051 is an 8-bit processor, meaning that the
CPU can work on only 8 bits of data at a time. Data larger than 8 bits has to be broken
into 8-bit pieces to be processed by the CPU. The 8051 has a total of four I/O ports, each
8 bits wide. Although the 8051 can have a maximum of 64K bytes of on-chip ROM,
many manufacturers have put only 4K bytes on the chip.

The 8051 became widely popular after Intel allowed other manufacturers to
make and market any flavor of the 8051 they please with the condition that they remain
code-compatible with the 8051. This has led to many versions of the 8051 with different
speeds and amounts of on-chip ROM marketed by more than half a dozen manufacturers.
There are different flavors of the 8051 in terms of speed and amount of on-chip ROM;
they are all compatible with the original 8051 as far as the instructions are concerned.
This means that if you write your program for one, it will run on any one of them
regardless of the manufacturer.

3.5) Features and architecture of AT89C51

18
Rajagiri School of Engineering &
Technology, Kakkanad
The selection of the micro controller is based on a number of factors like size,
power consumption, packaging, number of pins, availability of assemblers, availability of
programmers to burn the codes onto the chip etc. The micro controller chosen as per the
afore said criterion was the Atmel89C51. The features that led to choosing the
microcontroller are:

3.5.1) Features of 8051:

Feature Quantity

ROM 4K bytes
RAM 128 bytes
Timer 2
I/O Pins 32
Power Supply 5V DC
Serial Port 1
Interrupt Sources 6

This popular 8051 chip has on-chip ROM in the form of flash memory. This is ideal for
fast development since flash memory can be erased in seconds compared to the twenty
minutes or more needed for the 8751. For this reason the AT89C51 is used in place of the
8751 to eliminate the waiting time needed to erase the chip and thereby speed up the
development time. To use the AT89C51 to develop a microcontroller-based system
requires a ROM burner that supports flash memory; however, a ROM eraser is not
needed. Notice that in flash memory you must erase the entire contents of ROM in order
to program it again. This erasing of flash is done by the PROM burner itself and this is

19
Rajagiri School of Engineering &
Technology, Kakkanad
why a separate eraser is not needed. To eliminate the need for a PROM burner Atmel is
working on a version of the AT89C51 that can be programmed via the serial COM port of
an IBM PC.

3.5.2) The Architecture Of AT89C51:

20
Rajagiri School of Engineering &
Technology, Kakkanad

3.6) Programming the microcontroller:

The micro controllers at the transmission part and the reception part were
programmed as per the requirements cited in sections 3.1 and 3.2. Yet another issue that
had to be taken care of was the time delay for which the motor drive mechanism was to
be excited. The delay was found out by trial and error method done on the prototype of
the garage prepared, and the micro controller was programmed as required. The detailed
coding involved in each section of the project has been given in the Appendix (Refer
Appendix B.)

The programming of the micro controller was done using 8051IDE, which is a
text editor cum assembler cum software simulator. The screen snap shots of the 8051 IDE
has also been detailed in Appendix. (Refer Appendix C).

21
Rajagiri School of Engineering &
Technology, Kakkanad

CHAPTER – 4

M O T O R D R I V E M E C H A N I S M A N D H A R D WA R E
I M P L E M E N TAT I O N .

4.1) PRINCIPLE OF WORKING OF DC MOTOR……………………….….……….Pg 23


4.2) LOAD TEST OF DC SHUNT MOTOR…………………………………………....Pg 24
4.3) CHARACTERISTICS OF DC SHUNT MOTOR
4.3.1) VOLTAGE – SPEED CHARACTERISTICS………………………..……...Pg 25
4.3.2) TORQUE – CURRENT CHARACTERISTICS………………………..…..Pg 26
4.4) GEAR ARRANGEMENT……………………………….………………..…..Pg 27
4.5) INTERFACING THE DC MOTOR WITH 89C51…………………..……....Pg 28
4.6) T Y P E S O F R E L AY S & C O N TA C T S :
4.6.A.) ELECTROMECHANICAL RELAYS……………………..Pg 30
4.6.B.) SOLID STATE RELAYS………………………………...…Pg 30
4.6.1) CONTACT ARRANGEMENTS…………………………………………….Pg 31
4.7) DRIVER IC USED FOR DRIVING THE RELAY……………………………Pg 32
4.8) ISSUES ENCOUNTERED ……………………………………………………Pg 32

22
Rajagiri School of Engineering &
Technology, Kakkanad

CHAPTER 4:

MOTOR DRIVE MECHANISM AND HARDWARE


IMPLEMENTATION.

4.1) Principle of Working of Dc Motor:


An Electric motor is a machine, which converts electric energy into mechanical energy.
Its action is based on the principle that when a current-carrying conductor is placed in a
magnetic field, it experiences a mechanical force whose direction is given by Fleming's
Left-hand Rule and whose magnitude is given by F = BIl newton.
As regard to the construction, there is no basic difference between a d.c. Generator
and a d.c. Motor. In fact, the same d.c, machine can be used interchangeably as a generator or
as a motor. d.c. motors are also like generators, shunt-wound or series-wound or
compound-wound.
The figure shown below is a part of multi polar d.c motor. When its field magnets
are excited and its armature conductors are supplied with current from the supply mains, they
experience a force tending to rotate the armature. Armature conductors under N-pole are
assumed to carry current downwards (crosses) and those under S-poles, to carry current
upwards (dots). By applying Fleming's Left-hand Rule, the direction of the force on each
conductor can be found. It is shown by small arrows placed above each conductor. It will be
seen that each conductor experiences a force F which tends to rotate the armature in the
anticlockwise direction. These forces collectively produce a driving torque, which sets the
armature rotating.

23
Rajagiri School of Engineering &
Technology, Kakkanad
By reversing current in each conductor as it passes from one pole to another, the
commutator helps to develop a continuous and unidirectional torque.

4.2) Load Test Of Dc Shunt Motor

In order to determine the maximum torque and speed of a shunt motor, the load test is
performed. The motor is mounted and fixed on to a rigid base (wooden plank). A long thread tied on to
the shaft is suspended and the other end, tied onto a one-end fixed spring balance. For different voltages
the force is calculated and the current drawn correspondingly is noted. The reading of the spring balance
gives the weight and the weight multiplied by the acceleration due to gravity, gives the forces. The radius
of the shaft is now found out and the torque calculated as follows:

Torque, ( T ) = Weight x 9.8 x r Newton meter (N-m) ,

where r = radius of the shaft (3mm)

24
Rajagiri School of Engineering &
Technology, Kakkanad

Fixed end

4.3) Characteristics Of Dc Shunt Motor

4.3.1) Voltage – Speed Characteristics:

25
Rajagiri School of Engineering &
Technology, Kakkanad
The motor is rated for 150 rpm @ 12V. The plot shows the variation of
speed of the motor with input voltage at no load condition. It is seen that it is a
straight line varying linearly with the input voltage.

Voltage (v) Speed (rpm)


5 70
6 75
7 90
8 100
9 115
10 128
11 140graph
voltage-speed
12 150
160

140

120
Speed (rpm)

100

80

60

40

20

0
0 2 4 6 8 10 12 14
Voltage (V)

4.3.2) Torque – Current Characteristics:

26
Rajagiri School of Engineering &
Technology, Kakkanad
Assuming the Φ to be practically a constant, we find that Torque ∝ Armature
Current. Hence the electrical characteristics are as shown as in the plot. It is a straight line
through the origin.

Current (A) Torque (KNm)


0.5 .1176
0.55 .1176
0.6 .1176
0.68 .1323
0.77 .147
0.85 .1764
0.91 .2058
1.01 .2352

current-torque graph

0.3

0.25

0.2
Torque(Nm)

0.15

0.1

0.05

0 0.2 0.4 0.6 0.8 1 1.2


current(A)
4.4) Gear Arrangement:

27
Rajagiri School of Engineering &
Technology, Kakkanad

Examination itself reveals the transfer functions. The (right) driving gear with 20 teeth,
1 inch radius and 2 ounce-inches torque rotates counter clockwise at 200 RPM and exerts
a 2 ounce force on the driven gear with forty teeth for a ratio of 2:1.
If the teeth are of equal size to permit proper mesh, the driven gear must have 2 inch
radius. During one revolution of the driver, 20 teeth pass 20 teeth on the driven, resulting
in only one half a revolution clock wise, which means the driver must turn twice for the
driven to turn once. This produces 100 RPM or a 2:1 speed reduction.
Since the driver output force is at a radius of 1 inch:
F = T / R = 2 / 1 = 2 oz.

This same force is applied to the driven at a radius of 2 inches:


T = F x R = 2 x 2 = 4 oz-in.

Thus the torque ratio is 2:1 increase.

28
Rajagiri School of Engineering &
Technology, Kakkanad

The basic rules of gear systems are:


• RPM is divided by the gear ratio.
• TORQUE is multiplied by the gear ratio.
• POWER does not change during the transfer.

4.5) Interfacing the DC Motor With The Micro Controller:


The motor on/off control by the micro controller is done by the help of electro-
magnetic relays. (with driver/buffer IC provided to drive the relays, as per the
microcontroller program.)
The relay used is JRC-27F/ 005 H where the explanation to the corresponding parts of
the part number is as per given below:

A relay is usually an electromechanical device that is actuated by an electrical


current. The current flowing in one circuit causes the opening or closing of another

29
Rajagiri School of Engineering &
Technology, Kakkanad
circuit. Relays are like remote control switches and are used in many applications
because of their relative simplicity, long life, and proven high reliability. Relays are used
in a wide variety of applications throughout industry, such as in telephone exchanges,
digital computers and automation systems. Highly sophisticated relays are utilized to
protect electric power systems against trouble and power blackouts as well as to regulate
and control the generation and distribution of power. In the home, relays are used in
refrigerators, washing machines and dishwashers, and heating and air-conditioning
controls. Although relays are generally associated with electrical circuitry, there are many
other types, such as pneumatic and hydraulic. Input may be electrical and output directly
mechanical, or vice versa. All relays contain a sensing unit, the electric coil, which is
powered by AC or DC current. When the applied current or voltage exceeds a threshold
value, the coil activates the armature, which operates either to close the open contacts or
to open the closed contacts. When a power is supplied to the coil, it generates a magnetic
force that actuates the switch mechanism. The magnetic force is, in effect, relaying the
action from one circuit to another. The first circuit is called the control circuit; the second
is called the load circuit.

4.6) Typ e s o f R e l a ys & C o n t a c t s :

There are two basic classifications of relays: Electromechanical and Solid State.
Electromechanical relays have moving parts, whereas solid-state relays have no moving
parts. Advantages of Electromechanical relays include lower cost, no heat sink is
required, multiple poles are available, and they can switch AC or DC with ease.

30
Rajagiri School of Engineering &
Technology, Kakkanad

4.6.A.) Electromechanical Relays


General Purpose Relay: The general-purpose relay is rated by the
amount of current its switch contacts can handle. Most versions of the
general-purpose relay have one to eight poles and can be single or double
throw. These are found in computers, copy machines, and other consumer
electronic equipment and appliances. Power Relay: The power relay is
capable of handling larger power loads – 10-50 amperes or more. They are
usually single-pole or double-pole units. Contactor: A special type of high
power relay, it’s used mainly to control high voltages and currents in
industrial electrical applications. Because of these high power
requirements, contactors always have double-make contacts. Time-Delay
Relay: The contacts might not open or close until some time interval after
the coil has been energized. This is called delay-on-operate. Delay-on-
release means that the contacts will remain in their actuated position until
some interval after the power has been removed from the coil. A third
delay is called interval timing. Contacts revert to their alternate position at
a specific interval of time after the coil has been energized. The timing of
these actions may be a fixed parameter of the relay, or adjusted by a knob
on the relay itself, or remotely adjusted through an external circuit.

4.6.B.) Solid State Relays:


These active semiconductor devices use light instead of magnetism
to actuate a switch.

31
Rajagiri School of Engineering &
Technology, Kakkanad
4.6.1) Contact Arrangements:

The arrangement of contacts on a relay includes a form factor and a number of


poles. Each form factor is explained below:

4.6.1.A) Form A is a contact that is Normally Open (NO), or “make” contact. It is


open when the coil is de-energized and closes when the coil is energized. Form A
contacts are useful in applications that must switch a single power source of high current
from a remote location. An example of this is a car horn, which cannot have a high
current applied directly to the steering wheel. A Form A relay can be used to switch the
high current to the horn. Form B is a contact that is Normally Closed (NC), or “break”
contact. It is closed in the de-energized position and opens when the coil is energized.

4.6.1.B) Form B contacts are useful in applications that require the circuit to remain
closed, and when the relay is activated, the circuit is shut off. An example of this is a
machine’s motor that needs to run at all times, but when the motor must be stopped, the
operator can do so by activating a Form B relay and breaking the circuit.

4.6.1.C) Form C is a combination of Form A and B arrangement, sharing the same


movable contact in the switching circuit. Form C contact are useful in applications that
require one circuit to remain open; when the relay is activated, the first circuit is shut off,
and another circuit is turned on. An example of this is on a piece of equipment that runs
continually; when the relay is activated, it stops that piece of equipment and opens a
second circuit to another piece of equipment.

4.6.1.D) Make-before-break Contact: a contact arrangement in which part of the


switching section is shared between both a Form A and a Form B contact. When the relay
operates or releases, the contact that closes the circuit operates before the contact that
opens the circuit releases. Thus both contact are closed momentarily at the same time.
The inverse of a Make-before break contact is a Break-before-make contact. Poles are the
number of separate switching circuits within the relay.

32
Rajagiri School of Engineering &
Technology, Kakkanad
4.7) Driver IC Used For Driving The Relay:

The output of the micro controller being in the range of a few mA, the output as
such becomes in sufficient to drive the relay. Hence the output of the microcontroller has
to be buffered so as to make the relay work. The driver IC used is, ULN2003A. The
ULN2003 are high voltage, high current Darlington arrays each containing seven open
collector Darlington pairs with common emitters. Each channel rated at 500mA and can
withstand peak currents of 600mA.

This versatile device is useful for driving a wide range of loads including
solenoids, relays, LED displays filament lamps, thermal print heads and high power
buffers.
The ULN2003A are supplied in 16 pin plastic DIP packages with a copper lead
frame to reduce thermal resistance.

4.8) ISSUES ENCOUNTERED IN THIS MODULE OF THE PROJECT:

• Initially the motor chosen was SMJ 404880A, a stepper motor, to open the garage
door. The motor was so chosen because of many factors which are that, the
number of steps could be well controlled, by controlling the stepping sequence
generated by the microcontroller, for the stepper motor drive. The stepper motor
was known to have a reasonably good torque, which was another reason. The easy
availability and our little know-how also contributed to our procurement of the
stepper motor.

• The advantages and features, that were the selection criteria, never met the
required specifications.
o The torque offered was too less to lift even the gate of the pro-type garage.
o The current requirement was very high, which the driver IC (L293D)
couldn’t source, which resulted in heating up of the driver IC as well as
the motor.

33
Rajagiri School of Engineering &
Technology, Kakkanad
o The poor torque characteristics, called for addition of gears to the stepper
motor shaft, which was not viable, taking into consideration the cost as
well as the time frame.
o The usage of the stepper motor would imply that a separate supply be
designed for the operating voltage (12V) and the microcontroller. (5V).

• The above said disadvantages were overcome by using the geared dc motor of
Sanko Electrical Co., Ltd. The motor is rated at 12V offering 150 rpm. The
current drawn were in the range of 100 mA.

• Another issue, was the heating up of the driver IC (already mentioned above).
Substituting L293D with ULN2003A solved the issue. The substitution with
ULN2003A made way for another issue, which was insufficient torque, due to the
poor output characteristics. The new issue was finally resolved by using
electromagnetic relays for controlling the On/Off of the motor, so that the current
required could easily be sourced.

34
Rajagiri School of Engineering &
Technology, Kakkanad

CHAPTER – 5

CONCLUSION

5.1) CONCLUSION………………………………………………..Pg. 35

5.2) FAILURE MODE EVALUATION…………………………...Pg. 35

5.3) SCOPE FOR FURTHER DEVELOPMENT………………….Pg. 36

5.4) BIBLIOGRAPHY……………………………………………..Pg. 36

35
Rajagiri School of Engineering &
Technology, Kakkanad

CHAPTER - 5

CONCLUSION

The Mini Project was completed within constraints of time, availability of


resources and the scope of the subjects covered in the curriculum till the present semester.
A proto type model was made and the working of the Personalized Automatic Garage
Door Opener was implemented on it.

5.2) FAILURE MODE EVALUATION

ISSUE 1 : Stepper motor not catering to the required torque and getting excessively
heated up.

The issue was diagnosed as the incapacity of the driver IC to source the
required current.
Solution: Replaced ULN2003 with a higher capacity driver, L293D

ISSUE 2: Stepper motor not providing the required torque.


Solution: DC motor was tested for torque and selected.

ISSUE 3: RF transmission not performing faithful transmission/reception of the


microcontroller generated code.

The error was diagnosed as high noise and unwanted pick up. The
experimental study revealed that the RF module transmitted and received
pulses moreover faithfully. Hence the initial idea of transmitting the code has
been modified as transmitting a particular sequence of pulses, characteristic to
each transmitter and detecting the received pulses and checking them with the
value stored in the look up table of the receiver micro controller.

36
Rajagiri School of Engineering &
Technology, Kakkanad

5.3) SCOPE FOR FURTHER DEVELOPMENT:

1. The mini project can be implemented on a real garage door,


provided a better communication module is devised, with better
range and noise rejection.

2. The project may be extended to a Digital Image Processing project


where the number plate is sensed and checked for authentication,
thereby reducing the noise & errors, as no RF Communication is
involved.

5.4) BIBLIOGRAPHY:

1. The 8051 Microcontroller and embedded Systems


 Muhammed Ali Mazidi
 Janice Gillispie Mazidi

2. The 8051 Microcontroller Architecture, Programming &


Application
 Kenneth J. Ayala

3. Data & Computers Communications


 William Stallings

4. Electric Machines
 BL Theraja
5. The World Wide Web.

37
Rajagiri School of Engineering &
Technology, Kakkanad
APPENDIX – A

Modular Division of Work

Module I:
Transmitter/ receiver design, development and
integration.
Module II:
Microcontroller programming, logic
Development and general circuitr y.
Module III:
Motor drive mechanism and hardware
implementation.

Team Member Module Allocated

1) Francis Scaria Module III (Chapter – 4))

2) George Teddy K. C. Module I (Chapter – 2)

3) Renjit Kurian Module II (Chapter – 3)

38
Rajagiri School of Engineering &
Technology, Kakkanad
APPENDIX – B: PROGRAM CODE

THE TRANSMITTER MICROCONTROLLER CODE:


ORG 0000H
SJMP MAIN
ORG 0003H
JMP ISR2
ORG 0030H
MAIN:
MOV 55H,#01H
MOV IE,#91H
MOV 40H,#0AH
MOV 41H,#0BH
MOV 42H,#0CH
MOV 43H,#0DH
MOV 44H,#0EH
MOV 45H,#0FH
MOV 46H,#1AH
MOV 47H,#1BH
MOV 48H,#1CH
MOV 49H,#1DH
MOV R0,#40H
SETB TCON.0
THERE: JMP THERE

ISR2: MOV SCON,#40H


MOV TMOD,#20H
MOV TH1,#0FDH
SETB TR1
MOV A,@R0

39
Rajagiri School of Engineering &
Technology, Kakkanad
MOV SBUF,A
HERE:JNB TI HERE
CLR P1.4
CLR TI
INC R0
CJNE R0,#4AH,EXT
MOV R0,#40H
EXT: RETI

THE RECEIVER MICROCONTROLLER CODE:

ORG 0000H
SJMP MAIN
ORG 0003H
AJMP FORWARD
ORG 0023H
SJMP ISR
ORG 0040H
MAIN: MOV P1,#00H
MOV 60H,#0AAH
MOV 40H,#0AH
MOV 41H,#0BH
MOV 42H,#0CH
MOV 43H,#0DH
MOV 44H,#0EH
MOV 45H,#0FH
MOV 46H,#1AH
MOV 47H,#1BH
MOV 48H,#1CH
MOV 49H,#1DH

40
Rajagiri School of Engineering &
Technology, Kakkanad
MOV IE,#91H
MOV SCON,#50H
MOV TMOD,#20H
MOV TH1,#0FDH
SETB TR1
TH: JMP TH

ISR: MOV IE,#00H


HERE: JNB RI HERE
CLR RI
MOV A,SBUF
MOV 50H,A
MOV R2,#0BH
MOV R0,#40H
THERE: DEC R2
MOV A,R2
JZ EX
MOV A,@R0
INC R0
CJNE A,50H,THERE
ACALL FORWARD
EX: MOV IE,#91H
RETI

FORWARD:CLR IE0
MOV IE,#00H
MOV A,60H
MOV P1,A
CPL A
MOV 60H,A
ACALL DELAY

41
Rajagiri School of Engineering &
Technology, Kakkanad
MOV P1,#00H
MOV P3,#0FFH
MOV IE,#91H
RETI

DELAY: MOV R2,#40H


L2:MOV R3,#0FFH
L3: MOV R4,#0FFH
L6: DJNZ R4,L6
DJNZ R3,L3
DJNZ R2,L2
RET

42
Rajagiri School of Engineering &
Technology, Kakkanad

APPENDIX – C: THE 8051 IDE

8051 IDE window screen snapshot

The 8051 Integrated Development Environment (IDE) combines a text editor,


assembler and software simulator into a single program. All components needed to
develop 8051 programs (and its various derivatives) available and controllable from this
single IDE.

The steps that have to be performed for the 8051 programming are as follows:
Enter and modify the program source code from within the built in editor. Then assemble
the source code by selecting the Assemble command. If any errors are located the

43
Rajagiri School of Engineering &
Technology, Kakkanad
appropriate source module can be automatically loaded and the cursor placed on the line
containing the error. Fix the error and move to the next error (if any). Once all errors
have been fixed reassemble the code.

After successfully assembling the source code use the simulator to step through
the program. Check the registers, flags, ports and memory locations change as the
program progresses. The flow of program can be viewed and can be verified whether it
operates as intended. If it does not, then return to the editor, reassemble and go back to
the simulator. The 8051 Integrated Development Environment (IDE) is a Windows 95
based application. It operates with the same look and feel of other Windows based
application.

44
Rajagiri School of Engineering &
Technology, Kakkanad

APPENDIX – D: THE PCB DESIGN

The overall circuitry laid on a bread board was too bulky, which led us to design a
‘printed circuit board’. The design of the circuit to be printed was done on the software
called, Express PCB.

The ExpressPCB window

45
Rajagiri School of Engineering &
Technology, Kakkanad
The PCB designs of the Transmitter, Receiver and the Motor Drive circuit are given
below:

Transmitter

Receiver

Motor Drive Circuitry

46