Posts | Comments

Planet Arduino

Archive for the ‘door lock’ Category

There are many ways to lock a door. You could use a keypad, an RFID card, a fingerprint or retina scan, Wi-Fi, Bluetooth, the list goes on. You could even use a regular old metal key. But none of these may be as secure as [mircemk]’s Arduino-based door lock that employs a smartphone’s flashlight as a pass code.

At first blush, this seems horribly insecure. Use a plain old flashlight to open a door? Come on. But the key is in the software. In fact, between the typed-in pass code and the flash of light it generates, this lock kind of has two layers of security.

Here’s what’s going on: inside the accompanying smart phone application, there’s a list of passwords. Each of these passwords corresponds to a flash of light in milliseconds. Enter the correct password to satisfy the Arduino, and the phone’s flashlight is activated for the appropriate number of milliseconds to unlock the door.

As you’ll see in the video below, simply flashing the light manually doesn’t unlock the door, and neither does entering one of the other, bogus passwords. Although it does activate the flashlight each time, they don’t have the appropriate light-time length defined.

Hardware-wise, there is an Arduino Nano Every in charge of the LDR module that reads the flashlight input and the 12 V relay that unlocks the door. Be sure to check it out it the video after the break.

If you want to keep your critters from bringing wild critters back inside, check out this Wi-Fi cat door that lets you have a look at what might be dangling from their jaws before unlocking the door.

Watch any movie about the years of prohibition, and you’ll probably see character gain admittance to a speakeasy by using a secret knock on the door. In the old movies, a little sliding door would open so the doorman could check you out and let you in. With [‘s] electronic lock, the secret knock automatically unlocks the door. You can see a video of how it works, below.

The device uses a piezoelectric speaker to detect the knocking. A speaker is a transducer and like many transducers, it will work — to some extent — in either direction. A servo motor manages the deadbolt. An Arduino runs the whole thing.

The code is relatively simple. It holds an array of projected delays between knocks and compares what it hears to those delays. If you complete the sequence, the door unlocks. We probably would add some extra security if we were locking up the country’s gold supply, but for a light-duty lock, it should be fine.

The circuit is simple, too. There is an analog input tied to a resistor and the sensor. The Arduino is perfectly capable of driving a small servo directly. Add a battery and it is done.

It’s been a while since we’ve seen knock-operated locks around here, but they used to be all the rage. Here is a nice simple one, one that uses logic chips, and of course one built from 555s. If knocking isn’t your style, try replacing the piezo with a button or even a capacitive sensor. You can’t knock it!

If you don’t want to carry keycard or memorize a passcode, this build from Electronoobs might be just the thing. 

The system uses a fingerprint reader to check to see if you have access, and if approved, the device’s Arduino Mega unlocks the theoretical door using a micro servo motor. Three push buttons and a 16×2 LCD screen complete the user interface, and allow more authorized fingers to be added with the main person/finger’s permission.

While you might question the security gained by a hobby servo, the video notes that this could trigger any sort of security device, perhaps via a relay or electromagnetic coil lock. Besides security, the build gives a good introduction to Arduino fingerprint scanning, as well as the use of an SD card for data logging functions.

In the dark ages, you had to use a key to lock and unlock your car doors. Just about every car now has a remote control on the key that lets you unlock or lock with the push of a button. But many modern cars don’t even need that. They sense the key on your person and usually use a button to do the lock or unlock function. That button does nothing if the key isn’t nearby.

[Pierre Charlier] wanted that easy locking and unlocking, so he refitted his car with a Keyduino to allow entry with an NFC ring. What results is a very cool fistbump which convinces your car to unlock the door.

Keyduinio is [Pierre’s] NFC-enabled project, but you can also use a more conventional Arduino with an NFC and relay shield. The demo also works with a smartphone if you’re not one for wearing an NFC ring. Going this round, he even shows how to make it work with Bluetooth Low Energy (BLE).

In the video below, you can see how he removed the car’s internal lock switch and modified the wire harness to take the connection to the Arduino. He’s also included all the code. About the only tricky part is doing the actual wiring in your car and finding a suitable source of power. That varies from car to car, so it isn’t easy to give specific instructions.

Opening doors of one kind or another is a popular project theme. While [Pierre’s] project might open the door on a coupe, we’ve seen another project that works on a coop.


Filed under: Arduino Hacks, car hacks, wireless hacks

homemade RFID Door Locks

[Shawn] recently overhauled his access control by fitting the doors with some RFID readers. Though the building already had electronic switches in place, unlocking the doors required mashing an aging keypad or pestering someone in an adjacent office to press a button to unlock them for you. [Shawn] tapped into that system by running some wires up into the attic and connecting them to one of two control boxes, each with an ATMega328 inside. Everything functions as you would expect: presenting the right RFID card to the wall-mounted reader sends a signal to the microcontroller, which clicks an accompanying relay that drives the locks.

You may recall [Shawn's] RFID phone tag hack from last month; the addition of the readers is the second act of the project. If you’re looking to recreate this build, you shouldn’t have any trouble sourcing the same Parallax readers or building out your own Arduino on a stick, either. Check out a quick walkthrough video after the jump.


Filed under: Arduino Hacks, Microcontrollers
Jul
15

Door Lock Provides Peace of Mind With Real-Time Security

arduino hacks, arduino mega, door lock, EEPROM, HD44780, lock Comments Off on Door Lock Provides Peace of Mind With Real-Time Security 

arduino door lock

[HSP] got tired of locking his door with a key, so he decided to upgrade to a keypad system which he’s designed himself.

It uses an Arduino Mega with the standard 44780 display, a standard keypad, and the “key override” (shown above) for fun. The locking mechanism is a standard 12V actuator based lock which was modified to run off of only 7.5V, by softening up the spring inside and running it upside down (as to let gravity help do the work). The whole system draws less than half a watt on standby, and engaging the lock peaks at only 4-7W.

What’s really clever about this design is how he locks it from inside the room. He’s programmed the Arduino to write 1 to address 128 of the EEPROM — at power on it will increment this by 1, and after 5 seconds, it will reset to 1. This means it can detect a quick power cycle, so you can lock the door by turning it off, turning it on for a few seconds, and turning it off and on again — he did this so he didn’t have to make a button or console, or any kind of wireless control on the inside.

Now we know that kind of adds a huge flaw to the overall security of the system… but [HSP] learned his lesson last time he built something “too” secure.

The relay board is inside the box on the wall on the outside, and the lock is only locked with power. This is insecurity by design. This is to keep the casual people out. The door itself is thin wood with cardboard in between. I previously had a lock which was locked on power failure, and the machine (Windows) running it, crashed. I got to climb through the roof window, 7 meters up to get inside without trashing the door, so now I have a little respect for the possibility of failure, and design my systems for the expected threat-level.


Filed under: Arduino Hacks


  • Newsletter

    Sign up for the PlanetArduino Newsletter, which delivers the most popular articles via e-mail to your inbox every week. Just fill in the information below and submit.

  • Like Us on Facebook