21311A04M1,4R9,22315A0420 MPMC PROJECT

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 14

21311A04M1,4R9,420

A MPMC Lab Project Report


On

“Password based Password based door lock system in 8051microprocessor”

Submitted in Partial Fulfilment of the Requirements For the award of the


Degree of

Bachelor of Technology
In
Electronics & Communication Engineering (ECE)

G. AKSHAY REDDY - 21311A04M1

S. SHIVA PRASAD REDDY - 21311A04R9

B. SANDEEP REDDY - 22315A0420

Under the Supervision of

Mr. VSGN Raju

DEPARTMENT OF ELECTRONICS & COMMUNICATION ENGINEERING

SREENIDHI INSTITUTE OF SCIENCE & TECHNOLOGY

(AUTONOMOUS)
Yamnampet, Ghatkesar, R.R District, Hyderabad – 501301(Affiliated to JNT University
Hyderabad, Hyderabad and Approved by AICTE - New Delhi)

2023 – 2024

1
21311A04M1,4R9,420

SREENIDHI INSTITUTE OF SCIENCE AND TECHNOLOGY


(AUTONOMOUS)

Yamnampet, Ghatkesar, Hyderabad-501301

CERTIFICATE

This is to certify that the MPMC Lab Project work entitled “Password based door lock
system in 8051microprocessor”, submitted by
G. AKSHAY REDDY - 21311A04M1
S. SHIVA PRASAD REDDY - 21311A04R9
B. SANDEEP REDDY - 22315A0420

In fulfilment for the award of Bachelor of Technology in Electronics and


Communication Engineering [ECE], Sreenidhi Institute of Science & Technology,
Ghatkesar, Hyderabad, is a record of bonafide work done by him/ her during the academic
year 2023-2024 under our guidance and evaluation.

The results embodied in the report have not been submitted to any other
University or Institution for the award of any degree or diploma.

Mr. VSGN Raju Dr.S.P.V. SUBBA RAO


Associate Professor, ECE. Professor & HOD, ECE

2
21311A04M1,4R9,420

DECLARATION AND ACKNOWLEDGEMENT

We hereby declare that the work described in the Microprocessors and Microcontrollers
lab project, entitled “Password based door lock system in 8051microprocessor” which
is being submitted by us in partial fulfilment for the award of Bachelor of Technology in
the Dept. of Electronics & Communication Engineering, Sreenidhi Institute of
Science & Technology affiliated to Jawaharlal Nehru Technological University
Hyderabad, (Telangana) is the work on our own effort and has not been submitted
elsewhere.

We are very thankful to Mr. VSGN Raju, ECE Dept, Sreenidhi Institute of Science and
Technology, Ghatkesar for providing an initiative to this lab project and giving valuable
timely suggestions over the work.

We convey our sincere thanks to Dr. S.P.V. SubbaRao, Head of the Department (ECE),
Sreenidhi Institute of Science and Technology, Ghatkesar, for his kind cooperation in the
completion of this work.

NAME Roll. No:

G. AKSHAY REDDY - 21311A04M1


S. SHIVA PRASAD REDDY - 21311A04R9
B. SANDEEP REDDY - 22315A0420

3
21311A04M1,4R9,420

Password based door lock system in 8051microprocessor

ABSTRACT:
Safety is the most crucial concern of human. We always try to keep our things
between ourselves. For this reason, we still use various methods to lock our precious
items like a locked diary. And when it comes to our daily life, we are more serious.
In the modern age, there are so many ways to lock the door; one of them is password-
based lock system—a system where you are the only one to know how to access it.
It saves our daily life from the various malicious problem like a thief. This system
will give us the security that we want. To make our life more secure, we are going
to build the password-based door lock system. This system is easy to assemble and
very easy to use in our daily life. Anyone can use it to secure themselves.

AIM:
The aim of the project is to perform Password based door lock system in 8051
microprocessors.

THEORY:
The Digital Door Lock in general is a password-based electronic code lock.
In this project, we have designed the digital door lock using an 8051 microcontroller,
a keypad, and a 12-volt dc relay. In this article, we have designed a simple digital

4
21311A04M1,4R9,420

door lock using 8051 -which can be used as a security checking system to limit
access to an area/room only for certain individuals with the password. So our digital
door lock project can be called with a very wide range of names like a digital
combination lock using 8051 or a digital security code lock using 8051
microcontrollers or a password security system using 8051 or an electronic code lock
or a digital code lock using 8051. People call this kind of a “security system” with

different names, though all of them mean to build a basic password-based security
system using a microcontroller like 8051 or AVR or PIC or Arduino (a controller of
choice) with extra features like automatic door lock/opening facility, sound alarm,
GSM based SMS alert, etc.

SOFTWARE REQUIREMENTS:

• Proteus (for circuit diagram and simulation)

• Keil uVision5 IDE (for c code)

Hardware requirements:

• 8051 microcontroller (80C51)

• Phone keypad

• LCD – LM016L

• DC Motor (re-present as a door-lock motor)

5
21311A04M1,4R9,420

BLOCK DIAGRAM:

WORKING PRINCIPLE:
1. The main component in the circuit is 8051 microcontrollers. This control
everything in the device.
2. We connect the 4x3 keypad with the microcontroller. In the keypad there is 4
rows which is indicated the letters (A-D) and the 3 columns which is indicated
the number (1-3).
3. In the 8051 controller, pin P2.0 to P2.3 are connected to the keypad rows and
pin P3.0 to P3.2 are connected to the keypad columns.
4. Then we connect the door lock motor pins in the P3.3 and P3.4. This motor
only work when the password is right.

6
21311A04M1,4R9,420

5. LCD’s points are connected with P3.5 to P3.7 in 8051. LCD help us to show
the inputs and error messages.
6. All devices are connected with each other. In the simulation we use the hex
code to run the program. The hex code is generated from the embedded C
code. This code only works on any 8051-microcontroller system.
7. To run the simulation, we set the clock frequency at 11.0592 MHZ for 8051.
This is allowed us to run the simulation without getting any errors.
8. We pre-define the password 12345 for the program.
9. If user input wrong password it will give another chance to input the password
again with an error message. When the password is right it will show the
welcome message and lock motor will move to open the door.

CODE:
#include<reg51.h> void display (char *lcd)

#include<string.h> {

sbit RS = P3^0; While (*lcd != '\0')

sbit EN = P3^1; {

sbit IN1 =P3^2; dat(*lcd);

sbit IN2 = P3^3; lcd++;

void delay(int a) }

{ }

int i,j; void lcdint()

for(i=0;i<a;i++) { cmd(0x01);

for(j=0;j<255;j++); cmd(0x38);

7
21311A04M1,4R9,420

} cmd(0x0E);

void cmd(char cm) cmd(0x80);

{ }

P2 = cm; void main()

RS = 0; { char pass[5] = "5678";

EN = 1; char pass2[5];

delay(1); int i=0;

EN = 0;} char *ptr;

display("Password-"); ptr = pass2;lcdint();

pass2[4]='\0'; else if(P1==0xBE)

while(1) *(ptr+i)='9';

{ dat('9');

while(i<4) delay(200);

{ cmd(0x06);

P1=0xFE; i++;

if(P1==0xEE) }

{ else if(P1==0x7E)

*(ptr+i)='7'; {

dat('7'); *(ptr+i)='/';

delay(200); dat('/');

8
21311A04M1,4R9,420

cmd(0x06); delay(200);

cmd(0x06);

i++; i++;

} }

else if(P1==0xDE) P1=0xFD;

{ if(P1==0xED)

*(ptr+i)='8'; {

dat('8'); *(ptr+i)='4';

delay(200); dat('4');

cmd(0x06);i++; delay(200);

} cmd(0x06);

else if(P1==0xDD) i++;}

{ P1=0xFB;

*(ptr+i)='5'; if(P1==0xEB)

dat('5'); {

delay(200); *(ptr+i)='1';

cmd(0x06); dat('1');

delay(200);

i++; cmd(0x06);

} i++;

else if(P1==0xBD) }

9
21311A04M1,4R9,420

{ else if(P1==0xDB)

*(ptr+i)='6'; {

dat('6'); *(ptr+i)='2';

delay(200); dat('2');

cmd(0x06); delay(200);

i++; cmd(0x06);

} i++;

else if (P1==0x7D) }

{ else if(P1==0xBB)

*(ptr+i)='*'; {

dat('*'); *(ptr+i)='3';

delay(200); dat('3');

cmd(0x06); delay(200);

i++;} cmd(0x06);

else if(P1==0x7B) i++;}

{ else if(P1==0xB7)

*(ptr+i)='-'; {

dat('-'); *(ptr+i)='=';

delay(200); dat('=');

cmd(0x06); delay(200);

cmd(0x06);

10
21311A04M1,4R9,420

i++; i++;

} }

P1=0xF7; else if(P1==0x77)

if(P1==0xE7) {

{ *(ptr+i)='+';

*(ptr+i)='C'; dat('+');

dat('C'); delay(200);

delay(200); cmd(0x06);

cmd(0x06); i++;

i++; }

} }

else if(P1==0xD7) while(i==4)

{*(ptr+i)='0'; {

dat('0'); if ((strcmp(pass, pass2)) == 0)

delay(200); {

cmd(0x06); cmd(0xC0);

i++; display("Correct");

} IN1 = 1;IN2 = 0;
delay(100);

11
21311A04M1,4R9,420

else

cmd(0xC0);

display(" wrong password");

IN1 = 0;

IN2 = 0;

delay(100);

12
21311A04M1,4R9,420

CIRCUIT DIAGRAM:

APPLICATIONS:
The password-based lock system can install any door of any rooms. This system also
can be integrated with the existing system. This electric combination lock system
uses a five-digit password. The system collects five-digit user input and compares
the user input with the preset password inside the program. If the password matches,
access will be granted, and if not match the entry will be denied. The system can be
used at residential places to ensure better safety. It can be used at organizations to
ensure authorized access to highly secured places.

CONCLUSION:
So that’s all about the Password-based Security System using 8051. If you would
like to learn more interesting and similar projects like this electronic password
lock,here are some:

RFID-based security system using 8051

Digital code lock advanced using arduino

13
21311A04M1,4R9,420

RESULTS:

REFERENCES:
• GitHub - kmhmubin/Password-based-doorlock-system-in-8051-
microprocessor: Password-based door lock system using 8051/PIC
microcontroller
• Password Based Door Lock System using 8051 Microcontroller
(electronicshub.org)
• Digital Door Lock-Password Security Code Lock using 8051
(circuitstoday.com)

14

You might also like