Beruflich Dokumente
Kultur Dokumente
BELAGAVI
2018-2019
A mini project report
On
“Password Based Door Lock System”
Submitted by
KARTHIK BHARADWAJ H.S
USN: 1JB17EC032
Semester: 04(Batch: 2017-2021)
CERTIFICATE
Certified that the mini project work entitled " Password Based Door Lock System
using 8051 Microcontroller" is a bonafide work carried out by KARTHIK BHARADWAJ
H.S Student of 6th semester in Electronics and communication engineering of the
Visvesvaraya Technological University, Belagavi, during the year 2018-2019.The report
has been approved as it satisfies the requirements in respect of mini project work prescribed
by the institution.
(Dr. PUTTARAJU)
Principal
PASSWORD SECURITY 2018-19
ACKNOWLEDGEMENT
I would like to express my profound grateful to His Divine Soul Sri Sri Sri Jagadguru Dr.
Balagangadharanatha Maha Swamiji and His Holiness Jagadguru Sri Sri Sri Dr.
Nirmalanandanatha Maha Swamiji for providing me an opportunity to pursue my studies in this
esteemed institution.
I would also like to express my profound thanks to his holiness Reverend Sri Sri Prakashnath
Swamiji, Managing Director, SJB Institute of Technology, for his continuous support in providing
amenities to carry out this project in this admired institution.
I express my gratitude to Dr. Puttaraju, Principal, SJB Institute of Technology, for providing me an
excellent facilities and academic ambience; which have helped me in satisfactory completion of
project work.
I extend my sincere thanks to Dr. K.V. Mahendra Prashanth, Head of the Department of ECE, for
providing me an invaluable support throughout the period of my project work.
I wish to express my heartfelt gratitude to our guide Dr..Mahantesh .K Prof, for his valuable
guidance, suggestions and cheerful encouragement during the entire period of my project work.
Finally, I take this opportunity to extend my earnest gratitude and respect to my parents, Teaching &
Non teaching staffs of the department, the library staff and all my friends, who have directly or
indirectly supported me during the period of my project work.
Regards
KARTHIK BHARADWAJ H.S
USN: 1JB17EC032
PASSWORD SECURITY 2018-19
ABSTRACT
The main objective of this project is to provide a security system having the provision to
change the password by the authority only. The security of any organization or house is
of prime importance always. The concern is for the physical property and also for the
intellectual property in case of any organization. This proposed system provides a user
friendly security system for organizations and homes. This system is password based and
allows only authorized person to access it with a password. It also has the provision of
changing the password. The system is fully controlled by the 8 bit microcontroller of
8051 family. The password is stored in an EEPROM, interfaced to the microcontroller
and the password can be changed any time unlike a fixed one burnt permanently on to
the microcontroller. A keypad is used to enter the password and a relay to lock or unlock
the electric door, which is indicated by a lamp. Any wrong attempt to open the door (by
entering the wrong password) an alert will be actuated, indicated by another lamp.
PASSWORD SECURITY 2018-19
TABLE OF CONTENTS
Chapter 1: Introduction………………………………………………………….1-2
1.1 Overview………………………………………………………………………1
2.1 Objective……………………………………………………………..………. .3
4.1 ...……………………..……………………………………................................... 13
5.4 Limitations…………………………………………………………………..…. 15
5.4 Scope…………………………………………………………………………….16
Conclusion ……………………………………………………….……..………… 17
Reference………………………………………………………………………….. 18
CHAPTER 1
INTRODUCTION
1.1 OVERVIEW
Password Based Door Lock System using 8051 Microcontroller is a simple project where a
secure password will act as a door unlocking system. Traditional lock systems using
mechanical lock and key mechanism are being replaced by new advanced techniques of
locking system. These techniques are an integration of mechanical and electronic devices and
are highly intelligent. One of the prominent features of these innovative lock systems is their
simplicity and high efficiency. Such an automatic lock system consists of electronic control
assembly, which controls the output load through a password. This output load can be a motor
or a lamp or any other mechanical/electrical load.
Here, we developed an electronic code lock system using 8051 microcontroller (a Password
based Door Lock System using 8051 Microcontroller), which provides control to the
actuating the load. It is a simple embedded system with input from the keyboard and the
output being actuated accordingly. This system demonstrates a Password based Door Lock
System using 8051 Microcontroller, wherein once the correct code or password is entered, the
door is opened and the concerned person is allowed access to the secured area. Again, if
another person arrives, it will ask to enter the password. If the password is wrong, then door
would remain closed, denying access to the person.
Over the years, various control systems have beendesigned to prevent access to unauthorized
user. Themain reason for providing locks for our buildings (home,office, church, school, etc)
is for security of our lives andproperty. It is therefore important to have a stress free
andconvenient means of achieving this purpose. Automaticdoors have become a standard
feature on many differenttypes of buildings and they are becoming increasinglypopular every
day with respect to developing an effectiveelectronic devices geared towards providing
adequatesecurity.
Home security has been a major issue of concern because of the dramatic increase in crime
rateand everybody wants to take proper measure to preventintrusion or unwanted /
unauthorized user. In addition,there was a need to automate home so that user can
takeadvantage of the technological advancement in GSMtechnology and computer control
system. It is alsointeresting to know that commonly used devices like atelephone land line or
the Global System of Mobilecommunication (GSM) can possess features which can beused
domestically by individuals or industries to operateappliances like; door, electric bulb,
television, refrigerator,air condition, robotic arm, etc.
.
CHAPTER 2
LITERATURE SURVEY
It was operated by a wooden key with pegs that raised the number of tumblers sufficiently to
clear the bolt so that it could be pulled back. The major disadvantage with it is that it was
wholly made of wood as in [1].With the fast growing of technology, the lock has evolved
from only pure mechanical type into electrical and electronic type. With the assemblage of
electronic and mechanic at system, the lock has developed into a high-tech style which uses
some special authentication method. Usually, it is called electronic lock or smart lock as it
can operate based on the given information. In the current market, there are many
authentication methods to trigger the electronic lock including, button sequence, radio
frequency identification (RFID), biometric, security token and etc.
Generally, these kinds of authentication use the embedded system to process or verify
password or data entered by the users. The intruders have to spend quite a time to crack these
kinds of high tech lock as in .Is about the electronic code lock, which is designed to respond
to an electronic logicsignal mechanism, with a digit sequence counter performing the
function of a key. They areoperated by inputting the correct code by external means through a
keypad into a microcontrollerwhich already have a pin number in its EEPROM memory
(internal) to compare with, so that if its correct (that is the pin number inputted by the user), It
activates the port to which the LED disconnected (the load that represents the door) as in.
However, password seems to be the main authentication method for some period due tothe
consideration of dependability, safety, user friendly of the technologies and confidentiality.
But there will always a conflict between safety and user friendly as in.
When we think of locks, we think of a bolt containing a notch known as a talon, which is
operated by moving the bolt backwards or forward by engaging a key in the talon. But there
ismore to locks than just a bolt or latch. A lock is a mechanical device that can be use for
securing doors, cabinets, lid of brief cases or other luggage as in
2.1 OBJECTIVE
To design a device that opens and closes the door with 4-digit number lock.
To develop a program using keil version 3 ide, which performs the task of
opening and closing the door.
METHODOLOGY
.Reset Circuit Design: The reset pin of the microcontroller is kept active till the power supply
is in the specified range and a minimum oscillation level is maintained. In other words to
ensure the supply voltage does not falls below the threshold level of 1.2V and the reset pulse
width is greater than 100ms (recommended for 89C52), we need to select the values of
resistor and capacitor such that RC >=100ms. Hence, we selected a 10KΩ resistor and a
10µF electrolytic capacitor.
Oscillator Circuit Design: An 11.0592MHz crystal oscillator is used to provide external
clock signal to the microcontroller. To ensure smooth operation, we need to connect two
ceramic capacitors in the range of 30pF to 40pF. This crystal oscillator is connected between
pin 18 and 19 of the microcontroller. Here, we used two 33pF capacitors.
Interfacing LCD, Keypad and Motor Driver: First, a 10KΩ Potentiometer is connected to
the LCD Display’s Contrast Adjust Pin (Pin 3). RS, RW and E of LCD are connected to P3.0,
GND and P3.2 pins respectively. The eight data lines of the LCD are connected to PORT1.
The four ROW pins of the Keypad are connected to P2.0 to P2.3 and the four COLUMN pins
of the Keypad are connected to P2.4 to P2.7 pins respectively. The IN1 and IN2 of (1A and
2A) of the L293D Motor Driver are connected to PORT0 pins P0.0 and P0.1. Motor is
connected between OUT1 and OUT2 (1Y and 2Y) pins of L293D.
Compilation of Microcontroller Code: Once the circuit is designed and drawn on a piece of
paper, the next step is to write and compile the code. Here, we used the Keil µVision software
to write the program in C language.
Prior to writing the code, general steps needs to be followed like creating a new project and
selecting the target device or the required microcontroller. Once the code is written, we need
to save it with .c extension and then add it to the source file group under the target folder.
The code is then compiled by pressing F7 key.
Once the code is compiled, a hex file is created. In the next step, we use Proteus software to
draw the circuit. The code is dumped into the microcontroller using an external programmer
and Willar Software.
3.2 HARDWARE COMPONENTS
8051 Microcontroller
The 8051 Microcontroller was designed in 1980’s by Intel. Its foundation was on Harvard
Architecture and was developed principally for bringing into play in Embedded Systems. At
first it was created by means of NMOS technology but as NMOS technology needs more
power to function therefore Intel re-intended Microcontroller 8051 employing CMOS
technology and a new edition came into existence with a letter ‘C’ in the title name, for
illustration: 80C51. These most modern Microcontrollers need fewer amount of power to
function in comparison to their forerunners.
There are two buses in 8051 Microcontroller one for program and other for data. As a result,
it has two storage rooms for both program and data of 64K by 8 size. The microcontroller
comprise of 8 bit accumulator & 8 bit processing unit. It also consists of 8 bit B register as
majorly functioning blocks and 8051 microcontroller programming is done with embedded C
language using Keil software. It also has a number of other 8 bit and 16 bit registers.
It is an 8-bit microcontroller. It is built with 40 pins DIP (dual inline package), 4kb of
ROM storage and 128 bytes of RAM storage, 2 16-bit timers. It consists of are four
parallel 8-bit ports, which are programmable as well as addressable as per the
requirement. An on-chip crystal oscillator is integrated in the microcontroller having
crystal frequency of 12 MHz.
Let us now discuss the architecture of 8051 Microcontroller.In the following diagram, the
system bus connects all the support devices to the CPU. The system bus consists of an 8-bit
data bus, a 16-bit address bus and bus control signals. All other devices like program
memory, ports, data memory, serial interface, interrupt control, timers, and the CPU are all
interfaced together through the system bus.
16x2 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), animations and 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.
Step 1: Supplies
8051 Microcontroller
8051 Development Board
8051 Programmer
4×4 Matrix Keypad
16×2 LCD
L293D Motor Driver Board
DC Motor
10KΩ Potentiometer
Connecting wires
Power Supply
If 8051 Development Board is not used, then the following components are needed.
which is burn inside the microcontroller IC 8051. The AT89C51 IC is heart of the given
circuitry because this Ic is programmable 40pin dip IC in which we burn the program in
ROM[8]. This Ic has a 32 I/O lines through which we take the output pin no 9 is used for
reset the microcontroller and make it in a initial condition pin no 31 is enable pin, It required
low pulse for activating the microcontroller depends on the crystal connected to the xtal1 &
xtal2. Pin no 18&19 is used for providing the vcc of +5v pin 20 is grounded . The operating
frequency of the controller is set by the external oscillator of crystal oscillator of crystal
having frequency of 12MHZ. Capacitor having 33pF in parallel connection with ground is for
the proper undammed frequency. Reset for the controller is normally ground and 10uf 10v
electrolytic capacitor is also connected on reset for the slowly on and off to the controller
during the supply is turning on and off. The keypad used to give input signal is been
interfaced with the microcontroller are port0 (p0.1- p0.7).
The controller fetches the hex code according to the instruction. The LCD is used for display
device it is a 16 slots device usually used to show output status from the microcontroller . The
output signal which be fetched by relay status followed by on/off status of electronic lock.
CHAPTER 4
SOFTWARE REQUIREMENT
The µVision IDE combines project management, run-time environment, build facilities,
source code editing, and program debugging in a single powerful environment. µVision is
easy-to-use and accelerates your embedded software development. µVision supports multiple
screens and allows you to create individual window layouts anywhere on the visual surface.
The µVision Debugger provides a single environment in which you may test, verify, and
optimize your application code. The debugger includes traditional features like simple and
complex breakpoints, watch windows, and execution control and provides full visibility to
device peripherals.
With the µVision Project Manager and Run-Time Environment you create software
application using pre-build software components and device support from Software Packs.
The software components contain libraries, source modules, configuration files, source code
templates, and documentation. Software components can be generic to support a wide range
of devices and applications.
The Functions window gives fast access to the functions in each C/C++ source code
module.
The Code Completion list and Function Parameter information helps you to keep
track of symbols, functions, and parameters.
Dynamic Syntax Checking validates the program syntax while you are typing and
provides real-time alerts to potential code violations before compilation.
Keil MicroVision is a free software which solves many of the pain points for an embedded
program developer. This software is an integrated development environment (IDE), which
integrated a text editor to write programs, a compiler and it will convert your source code to
hex files too.
Here is simple guide to start working with Keil uVision which can be used for
CHAPTER 5
RESULT AND DISCUSSION
5.1 Outcome
We have designed a device that opens and closes the door when the correct password is
entered. Here we used 4x4 matrix keyboard to input the password and the 8051
microcontroller to check and give the control signal to the motor driver board to open.
A program was compiled using keil version 3, which is then loaded to 8051 to perform
the task.
5.2Advantages
This project provides security
Power consumption is less
Used commonly available components
Project is simple and easy
5.3Disadvantages
This simple circuit can be used at residential places to ensure better safety.
It can be used at organizations to ensure authorized access to highly secured places.
With a slight modification this Project can be used to control the switching of loads
through password
5.4 Limitations
It is a low range circuit, i.e. it is not possible to operate the circuit remotely.
If you forget the password it is not possible to open the door
We can add fingerprint sensor so entry will be allowed for the authorized
person using their fingerprints.
We can add fire, wind and LPG sensors so that, the doors will automatically
open
CONCLUSION
Thus we have concluded that we can secure our residential places as well as industrial places
using 8051 micro controller by just connecting the components to interface and to drive the
locking system. In today’s technologically advanced world, autonomous systems are gaining
rapid popularity so the advancement in latest technology is continuously and rapidly made on
different latest automatic door lock security systems. The need for an advanced door lock
security systems using new technologies is increases day by day as security become a very
important or serious issue for everybody. Due to the recent trends in various methods of
security for home, buildings, companies‟ vehicles etc, there is no need to worry about this
security any longer, as automatic security systems are here to deal with it. This paper tries to
focus all recent door lock security systems in a comprehensive way. The work was done
successfully. It is evidence that the use of keypad with the right circuitry can be used to
operate a security system. These systems have the ability to accesses a secure place (house,
ATM, industries, office etc.). A password based recognition system can easily perform
variation. In variation the system compare an input password to the enrolled password of a
specific user to determine, if they are form the same password. Now the security of our home,
office etc.
REFERENCE
[1] Oke Alice O., Adigun Adebisi A., Falohun Adeleye S., and Alamu F. O. ,
“DEVELOPMENT OF A PROGRAMMABLE ELECTRONIC DIGITAL CODE LOCK
SYSTEM” , International Journal of Computer and Information Technology (ISSN: 2279
– 0764) Volume 02– Issue 01, January 2013 .
[5] Annie P. Oommen, Rahul A P, Pranav V, Ponni S, Renjith Nadeshan, “DESIGN AND
IMPLEMENTATION OF A DIGITAL CODE LOCK”, International Journal of
Advanced Research in Electrical, Electronics and Instrumentation Engineering, Vol. 3,
Issue 2, February 2014