7400 Logic Combination Lock

Reading Hackaday the other day I came across this article about a combination lock built from logic gates only. This reminded me of a similar circuit I designed and built at school for my electronics AS-Level and spurred me enough to dig it out and share it here :-)

The Circuit:

7400 Logic Combination Lock

 

Inputs:

  1. A bank of momentary switches represents a keypad with ten digits (0-9), a ‘Reset’ and an ‘Enter’. This is similar to many mechanical door locks available.
  2. A bank of simple SP-ST switches act as a memory block and are used to store the combination. For the combination ‘1234’ simply close switches 1, 2, 3 and 4.

Output:

Inputting the correct combination and hitting ‘Enter’ will result in the output going high for around 5 seconds. In the circuit above the output is represented by an LED although in a real application this would most likely go to a transistor or relay to drive a solenoid for the lock mechanism.

How it works:

  1. A latch comprising of an Or and an AND on each input digit which holds high once the digit is pushed until the reset is triggered.
  2. An XNOR for each digit compares the value of the latch with the value of the corresponding ‘memory’ switch.
  3. A tree of AND gates evaluates the outputs of all digit blocks (the output of each XNOR) and outputs high if the combination was correctly entered.
  4. When the ‘Enter’ button is pressed:
    1. If the combination was incorrect an XOR gate is used to trigger the reset.
    2. If the combination was correct the a 555 monostable is triggered which holds the output high long enough for the user to enter the door.
  5. The moment the output of the monostable goes high, the reset is triggered.

Limitations:

The only real flaw that I see with this design is that you can enter the code in any order. However since many commercial mechanical locks have the same limitation I think I can live with it.

Does it work in real life?

I did actually build this thing many years ago, but I cannot for the life of me find any photos of it. I can confirm however that it did work.

Additionally for those interested, you can download the circuit simulation from here and run it yourself in the quite fantastic Yenka simulation suite. Yenka is a free download and is free for home use.

About these ads

13 thoughts on “7400 Logic Combination Lock

  1. Pingback: Hackaday Links: Sunday, May 12th, 2013

  2. Pingback: Hackaday Links: Sunday, May 12th, 2013 - RaspberryPiBoards

  3. Pingback: Hackaday Links: Sunday, May 12th, 2013 | Blog of MPRosa

  4. Pingback: Hackaday Links: Sunday, May 12th, 2013 | Daily IT News on IT BlogIT Blog

  5. This is a 10-bit code, so with 1024 combinations a determined intruder could probably try every combination in about half an hour. On average he would be successful within 15 minutes.

    • Yes…. assuming the intruder was able to keep track of what codes he entered and did so with no mistakes (Wait, am I on 0011001101 or 0011001001?). Also, any actual criminal would just use a sledgehammer rather than try and solve the lock.

      Either way, very nice work and I encourage you to build this for real. Perhaps a lock on your shed or a hidden safe in your closet?

  6. Pingback: Hackaday Links: Sunday, May 12th, 2013 | Arduino collector blog

  7. Pingback: Hackaday Links: Sunday, May 12th, 2013 | Make, Electronics projects, electronic Circuits, DIY projects, Microcontroller Projects - makeelectronic.com

  8. Pingback: Hackaday Links: Sunday, May 12th, 2013 | Skyless Drives

  9. Great circuit! Im in my first digital class this semester. Im doing a 4 year electrical engineering tech degree. Im going to put this on a breadboard this evening and check it out.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s