Professional Documents
Culture Documents
I. Abstract..................................................................................................................2
II. Introduction and overview................................................................................3
B. Purpose of our product:....................................................................................3
III. Approach to the project problem......................................................................4
A. Structure of our system.....................................................................................4
B. Hardware...........................................................................................................5
C. Software............................................................................................................5
IV. Details about partial devices..............................................................................6
A. ATMEGA 8.......................................................................................................6
B. LCD 16x2.........................................................................................................7
C. Relay.................................................................................................................8
D. Transistor BJT NPN C1815..............................................................................9
Features..............................................................................................................9
E. Electronic Lock..............................................................................................10
F. H-bridge circuit with 4 Relays.......................................................................10
V. System design.....................................................................................................12
A. Hardware........................................................................................................12
Block diagram of master unit..............................................................................17
VI. Result of our system design............................................................................24
VII. Conclusion.....................................................................................................24
VII. Reference.......................................................................................................24
Chapter I. Abstract
Digital design is an very important subject on this semester . The subject consist of
many knowledge of other subject like : electronics , microprocessor, algorithm for
engineer . In order to practice what we have learn, the project give us a chance to
get familiar and understand our theory in digital design subject. Because of all that
reason, my group have choose a project required many skill and included many
object in digital design subject. After finished this project , we feel very confident
with our skill, and think that we still can development our project further.
Chapter II.
Digital Code Lock using ATMEGA8 is a basic control system with an ability that
allows the rightful user to deploy platform to any property that require simple
password protection.
This code can be changed by the user. This circuit is eminently suitable as a digital
code lock.
Digital code lock is a type of lock in which a sequence numbers is used to open
the lock.
This type of lock use numerical code for authentication where the correct code
must be entered in order for the lock to deactivate.
The lock can be use with an outdoor gate or a normal door. The functionality of
this lock implemented in software.
There are great varieties of digital code locks. Generally speaking, they can be
classified into scores of type, such as electronic lock, fingerprint lock, card lock
biological lock, etc.
This kind of lock can avoiding the problems caused by the copying of keys.
It is because the keys people carry have become burden most of the time, but by
contrast people need only to remember a set of codes for electronics locks and
dont have to carry any key, thus freeing themselves from worries.
On the premise that its safety is high, its another feature without key is getting
more and more favour of people.
Among them the most practical and the most popularized one come to digital code
lock.
C. Application
The term access control refers to the practice of restricting entrance to a property, a
building or a room to authorized persons. Integrated and controller based access control
numeric and alphabetic keyless entry keypads with programmable features for the access
control of single openings. The various applications are asfollows :
Industrial facilities, Long term care facilities
Commercial buildings,
Airports, civil transportation
Convention halls
Psychiatric care centres, Drug rehabilitation centres
Museums and fine art galleries, Government and military
Ware houses, Technology centres
In our system we design an electronic lock can protect any electrical device. The user
must enter a correct password to gain access . The password is entered using the built in
44 keypad matrix. The main LCD Module is used to display messages to the user. As
soon as correct password is entered the relay is activated. This is indicated by a LED
which is placed near the relay. The relay remains on as long as the user wishes. You just
need to press a key to deactivate the relay.
After typing four digit password you must press the "OK" button . At anytime you may
press the "Cancel" key to clear the input (e.g. when you enter any incorrect digit)
The smart code lock has the feature to change the password too. For this enter a special
password which is 0000, as soon as the system receives this special password it
switches to change password mode. Here you need to enter the old password to gain
permission, then enter the new password.
B. Hardware
ATmega8 microprocessor ( cheap, popular, have many peripheral interface)
LCD 16x2 display
Keypad 4x4
Electronic Lock
4 Relays
Transistor BJT NPN C 1815
C. Software
Complier : AVR studio
PCB designer : Altium design
B. LCD 16x2
Description
- The HD44780U dot-matrix liquid crystal display controller and driver LSI displays
alphanumerics, Japanese kana characters, and symbols. It can be configured to drive a
dot-matrix liquid crystal display under the control of a 4- or 8-bit microprocessor. Since
all the functions such as display RAM, character generator, and liquid crystal driver,
required for driving a dot-matrix liquid crystal display are internally provided on one
chip, a minimal system can be interfaced with this controller/driver.
- A single HD44780U can display up to one 8-character line or two 8-character lines.
Registers
-The HD44780U has two 8-bit registers, an instruction register (IR) and a data register
(DR).
-The IR stores instruction codes, such as display clear and cursor shift, and address
information for display data RAM (DDRAM) and character generator RAM (CGRAM).
The IR can only be written from the MPU.
-The DR temporarily stores data to be written into DDRAM or CGRAM and temporarily
stores data to be read from DDRAM or CGRAM. Data written into the DR from the
MPU is automatically written into DDRAM or CGRAM by an internal operation. The
DR is also used for data storage when reading data from DDRAM or CGRAM. When
address information is written into the IR, data is read and then stored into the DR from
DDRAM or CGRAM by an internal operation. Data transfer between the MPU is then
completed when the MPU reads the DR. After the read, data in DDRAM or CGRAM at
the next address is sent to the DR for the next read from the MPU. By the register
selector (RS) signal, these two registers can be selected (Table 1).
Busy Flag (BF)
-When the busy flag is 1, the HD44780U is in the internal operation mode, and the next
instruction will not be accepted. When RS = 0 and R/W = 1 (Table 1), the busy flag is
output to DB7. The next instruction must be written after ensuring that the busy flag is 0.
C. Relay
the device when turned off. Therefore, the relay usually makes
use of a diode to restrict the flow of the charge, with the cathode
connected at the most positive end of the coil.
Contacts on an electromagnetic relay can take three forms.
Normally opened contacts connect the circuit when the device is
activated and disconnect it when the device is not active, like a
light switch. Normally closed contacts disconnect the circuit when
the relay is magnetized, and a change-over incorporates one of
each type of contact. The configuration of the contacts is
dependant upon the intended application of the device.
The electromagnetic relay is capable of controlling an output of
higher power than the input, and it is often used as a buffer to
isolate circuits of varying energy potentials as a result. When a
low current is applied to the electromagnet, throwing the switch,
the device is capable of allowing a higher current to flow through
it. This is advantageous in some applications, such as tripping
alarms and other safety devices, because a safer low current can
be used to activate an application requiring more energy.
Features
Collector-Emitter Volt (Vceo): 50V
Collector-Base Volt (Vcbo): 60V
Collector Current (Ic): 0.15A
hfe: 70-700 @ 2mA
9
E. Electronic Lock
F. H-bridge circuit with 4 Relays
H-Bridge with switches:
10
11
Hardware
We set up our system into 3 part : Suply , Micro controller , Electronic Lock.
Suply
The LM2576 Series of regulators are monolithic integrated circuits that provide all
the active functions for a step-down (buck) switching regulator, capable of driving
3A load with excellent line and load regulation. These devices are available in
fixed output voltages of 3.3V, 5V, 12V, 15V, and an adjustable output version.
Requiring a minimum number of external components, these regulators are simple
to use and include internal frequency compensation and a fixedfrequency
oscillator.
The LM2576 series offers a high-efficiency replacement for popular three-terminal
linear regulators. It substantially reduces the size of the heat sink, and in some
cases no heat sink is required.
A standard series of inductors optimized for use with the LM2576 are available
from several different manufacturers. This feature greatly simplifies the design of
switch-mode power supplies.
Other features include a specified 4% tolerance on output voltage within
specified input voltages and output load conditions, and 10% on the oscillator
frequency. External shutdown is included, featuring 50 A (typical) standby
current. The output switch includes cycle-by-cycle current limiting, as well as
thermal shutdown for full protection under fault conditions.
12
Micro controller
Microcontroller
Definition:
An embedded microcontroller is chip which has a computer processor with all its support
functions (clock & reset), memory (both program and data), and I/O(including bus
interface) built in to the device. These built in function minimize the need for external
circuitsand devices to be designed in the final application.
Types of Microcontroller
Creating application for microcontrollers is completely different than any other
development job in computing and electronics. In most other application one probably
have a number of subsystems and interface already available for his/her use. This is not
the case with a microcontroller where one is responsible forPower distribution
System clocking
Interface design and wiring
System programming
Application programming
Device programming
13
PCB:
Power Suply Board
14
15
16
17
B. Software
1. KeyPad
18
19
4. Main Program
20
21
22
23
24
Reference
-
www.alldatasheet.com/LCD+datasheet
www.alldatasheet.com/Atmega8+datasheet
www.alldatasheet.com/C1815+datasheet
25