Keypad Base Lock with PIC

Description
This Keypad base electronic lock is able to use for security systems. You can add Electromagnetic lock through transistor to output (pin 4) and alarm devise to Emergency output (pin 5) of the circuit. This project made using MikroC PRO C compiler. If you want to change Master Code, can change it using C code (see Tutorial Guide 01). This project has two codes, first is Manual reactivate lock and second is Auto reactivate lock. You are able to use any of them.

  v Manual Reactivate Lock – Password need to both deactivate and   reactivate lock. (see Video Guide)

  v Auto Reactivate Lock – Password need only to deactivate lock. Lock is auto reactivating after 10-15 seconds. You are able to change this time period. (see Tutorial Guide 02)

Tutorial Guide 01


Tutorial Guide 02
(for more information follow Video Guide or download project)

Circuit Diagram


Parts List 

  • PIC Programmer
  • 16F877A PIC Microcontroller
  • 16x2 LCD Display
  • 4x4 Keypad
  • 4MHz Crystal
  • 10K Resistors
  • 470/330 Resistors
  • 22pF Capacitors
  • Push button
  • LEDs or Output Devises 
Video guide


Final Project 





You can Download Full Project with Proteus Simulator file and Video Guide 


Update 01
Manual & Auto reactivate keypad base lock
New Features
  • Switching Manual and Auto reactivate using simple switch
  • More indicate LEDs 
Video guide


Final Project






                                          You can Download Full Project with Proteus Simulator file

51 comments:

  1. hello sir. why when i try to rebuild the program, its show so many errors.
    this one of the errors :
    Undeclared identifier 'Keypad_Key_Click'

    ReplyDelete
    Replies
    1. 1. Check, you are using right compiler.(MikroC Pro)
      2. Check, library s are properly activated. (Ticked)
      3. Do one change per time, If you try to change code.

      Delete
  2. hello sir, i am having problem in code when i implemented on hardware can you help me

    ReplyDelete
  3. hi WHERE IS THE CODE

    ReplyDelete
  4. This comment has been removed by the author.

    ReplyDelete
  5. Sir,
    I need to know when we power off the curcit,The newly entered password is stored in the chip.When we give power back to the curcit can we use that password.....

    ReplyDelete
    Replies
    1. Yes, you can use new password after power failure, because password stored in EEPROM memory (Electrically Erasable Programmable Read Only Memory) in micro-controller. EEPROM memory can be read and write electrically, can be accessed through program. It can be used to store data such as sensor logs, device parameters which should not be loss during power loss or CPU reset.

      Delete
  6. program runs on simulatons fine, but hass error when programming to the chip. need help ASAP.

    ReplyDelete
    Replies
    1. Pl check your programmer(software & hardware) and micro-controller, because programming failure can't occurred after code successfully compiled.

      Delete
  7. if i modify "by hashita" the all project get's stuck ...it gets stuck on " press *" and if you press it ... nothing is happening!

    ReplyDelete
  8. am trying to program one microcontroller and one keypad to control an electronic lock, but i want 6 passwords for 6 users. i have tried setting the passwords in an array in my C code but it doesnt work. any help?

    ReplyDelete
  9. Sir can yot teach me how to interface keypad to pic16f877a,i connect a keypad to PORTD,but it is not respond.....
    I'm usimg 8Mhz crystal..

    ReplyDelete
  10. Could you pass the code is that the link doesn't work?

    ReplyDelete
  11. plz give me the link to download ISIS+MIKROC

    ReplyDelete
  12. Hey in which file do i open the link in??

    ReplyDelete
  13. how can i talk too you
    i need help in my mini project

    ReplyDelete
  14. This comment has been removed by the author.

    ReplyDelete
  15. hi,
    thank you for sharing your knowledge,
    very nice project..
    i use it to study basic microntroller right now..i
    hope you can still continue sharing code and hardware of your project done..
    GOD BLESS YOU ALWAYS

    ReplyDelete
  16. pls bro how can i interface keypad code with another code(flowmeter code or fingerprint code )thekeypad will be controlling it

    ReplyDelete
  17. Hello, am having a problem with the simulation, when i add the resistors to the keypad it doesn't work but works well without the resistors. Then when i implement the hardware the keypad doesn't work.

    ReplyDelete
  18. Muy buen proyecto, didáctico y práctico para quienes nos inicamos en este mudo de la programación...bendiciones

    ReplyDelete
  19. Good Project. Thanks. But how to add Buzzer this project. Key press short beep. Correct code one long beep. Error Two beep. Alarm 4 long beep. etc.

    ReplyDelete
  20. HI DEAR Hasitha Gamage
    I'm so interested by yr project 'Keypad Base Lock with PIC 'and it's code in MicroC language and it seems to be very simple and clear to whom are in higher level of knowledge then me and my request is that: can you send me the same code but with more explanation line by line as detailed comments because a lot off a new words, functions, etc. are used on it and it takes to me a long time to assimilate without help
    REGARDS

    ReplyDelete
  21. Why the keypad is not working!

    ReplyDelete
  22. Dear sir,
    Can u please make the program codes using mplab xc8? Because our project is based on this software. And could u please send the codes to the below mentioned mail.

    munaveer00@gmail.com

    ReplyDelete
  23. I cannot open the code can U help me? please give the link of the Mikro C code:(

    ReplyDelete
  24. no need for answering. Thanks problem solved:)

    ReplyDelete
  25. Sir

    may you please send me the code cause I didnt find it

    ReplyDelete
  26. Excelente trabajo, me ha servido de mucha ayuda especialmente para un proyecto de seguridad... Saludos y muchas bendiciones

    ReplyDelete
  27. ı cant access to this page can someone help me about it

    ReplyDelete
  28. Download link is not available. Could you please share the native file to email id:phanikumargaddam@gmail.com

    ReplyDelete
  29. Hasitha Suneth could you update the link please?

    ReplyDelete