Basic Level     Skills: Not specified    
Author email
[email protected]
Author website


Project tested and working perfectly

Digital Lock Using AT89C2051 with LCD and Keypad - Assembly

A Brief Description:
This project is a rewrite of previously made project "Digital Code Lock using keypad and LCD"
I got many requests from student's side who want this project in Assembly language. So i spent some time making this project.

You will find working of this project same as that of original project. Nothing has been changed as such.

Its a simple project with efficient hacking prevention from Brute Force etc. The basic user lock is of 5 Digits and Master Lock is of 10 digits so its not easy for an intruder to break the lock unless you keep the code simple.
The input is taken from a 4x3 Keypad (please see the schematic for more information) and Display the user input on a 2x16 LCD. A pin is assigned as output for activating and deactivating the lock. For demonstration i have connected an LED to that pin.

User Side working:
The user has two options either he/she can use its own 5 digit code or use the default 5 digit code. If user has to do setup his own code, then he has to enter "12345" and press '#'. After this.. controller will ask for 10 Digit master password which is preprogrammed in the controller. Entering master lock, user can enter the new 5 digit code for the lock and press '#' to save it.

Using the Keypad:
Keypad has 12 keys (4x3) starting from 1,2,3,4,5,6,7,8,9,*,0,# (please see the schematic for layout). Numeric keys are used for entering numbers. '*' is used as the Cancel key and '#' is used as the Enter key.

Download File Information:
LCD.asm - Project Code
LCD.hex - Final Hex file
Digital Code Lock Schematic - PDF file of orcad schematic

If any problem Please post in the forum

17.46 kB





30 Oct 2014: 11:54 AM
i want you to help me in a program for interfatcing hex key pad with8051 and then make a digital lock
Kindly guide me as to how to combine the two different programs. thanks
02 Nov 2014: 07:10 AM
Just down the project and go through the code yourself. If you need help, just post a question. You can also look into our tutorial section for keypad tutorial.
24 Apr 2015: 18:24 PM
sir in the above shown program where are you going to dtore new password.
as you have not shown any memory ic
29 Apr 2015: 18:55 PM
@navig, This project does not store password in non-volatile memory. It just stores the password in RAM and if controller resets password also resets. You can add an EEPROM to add saving password to EEPROM.
(Required; Min length 5)
(Required; will not be displayed)


Mon Nov 23 2015, 06:32 PM
طريقة عمل مشروع dtmf على الماتلاب بالتفصيل
Mon Nov 23 2015, 02:26 PM
Muhammad Naveed kayani
principal of Electrical circuits 8th Edition, by Thomas L. Floyd , Prentice Hall please send me ... ??
Sun Nov 22 2015, 03:20 AM
@Naresh Jain ..hex file for what ?
Thu Nov 19 2015, 04:16 PM
Naresh Jain
can u arrange hex file
Thu Nov 19 2015, 04:14 PM
Naresh Jain
where is PCB file ? there is error.
Thu Nov 19 2015, 02:25 PM
hello all
Thu Nov 19 2015, 03:31 AM
@Bhaveen Lodaya.. can you rejoin as a new user
Wed Nov 18 2015, 03:39 PM
Bhaveen Lodaya
@Ajay... I forgot my username and password as I haven't used this site for a very long time. Please help me reset it. I am not receiving the password reset emails too.
Sun Nov 15 2015, 04:31 AM
@Phil, please check my PM and reply.
Thu Nov 12 2015, 08:50 PM
@Ajay.. PM sent.. just routine stuff



Sat Nov 21 2015, 09:19 PM
Sat Nov 21 2015, 07:05 PM
Mon Nov 16 2015, 11:49 PM
Wed Nov 11 2015, 09:02 PM
Wed Nov 11 2015, 09:20 AM
Tue Nov 10 2015, 11:12 PM
Thu Nov 05 2015, 06:27 PM
Thu Nov 05 2015, 01:03 PM


Guests: 30, Members: 0 ...

most ever online: 182184
(Members: , Guests: 182184) on 06 Aug 2010: 05:37 AM

Members: 37715
Newest member: emreaydogmus06
Forum Activity
ExperimenterUK Avatar
Posted By ExperimenterUK
Thu Nov 12 2015, 08:58 PM
Your problem may be the mismatch of a 3.7 volt mic...
ajay_bhargav Avatar
Posted By ajay_bhargav
Thu Nov 12 2015, 04:21 PM
Length of tracks or wires depends on drive strengt...
ajay_bhargav Avatar
Posted By ajay_bhargav
Thu Nov 12 2015, 04:13 PM
Sure, we will be interested in discussing your pro...
ajay_bhargav Avatar
Posted By ajay_bhargav
Thu Nov 12 2015, 04:09 PM
For AC devices, power = area under the curve so if...
gauravkothari23 Avatar
Posted By gauravkothari23
Wed Nov 11 2015, 09:10 PM
HI all,I am making a small project in which i am u...
csedwards1965 Avatar
Posted By csedwards1965
Tue Nov 10 2015, 11:20 PM
Hello.I am struggling to get the project lab going...
ExperimenterUK Avatar
Posted By ExperimenterUK
Fri Nov 06 2015, 01:21 AM
Mains fan motors are generally meant to only run a...
ExperimenterUK Avatar
Posted By ExperimenterUK
Fri Nov 06 2015, 01:12 AM
The key thing is the length of the interrupt code....
bobster Avatar
Posted By bobster
Thu Nov 05 2015, 06:39 PM
Hi all,I am using an atmel 89c5131 microcontroller...
ajay_bhargav Avatar
Posted By ajay_bhargav
Thu Nov 05 2015, 12:20 PM
8086 is a microprocessor with only a CPU. It does ...