Go Down

Topic: RFID door lock (Read 2764 times) previous topic - next topic

Hey,

I have known about arduinos existence for quite a while but I never got into it because I'd have no idea of what to make. But recently I got an idea. In our building we got RFID tags to open the entrance ports, to book time in the sauna and laundry, but not for our apartments. I thought it would be cool to create something that would read my existing RFID tag (or a new one if the one I got now isn't readable) and unlock the door for me.

I'm renting the apartment, so I'm probably not allowed to drill in the door or outside wall. Also, I don't have these doorknob locks I've seen in other RFID lock instructables, but a doorhandle with a lock over it which you rotate to lock/unlock, much like this but without the upper keyhole.

I've tested a bit if I can put wires out the door and still being able to close it, and it seems like it's working alright.

I've checked this guide about connecting Arduino and RFID and this guide

seems to have a mechanism of turning the lockknob which maybe I can use? I don't know how I should create the parts though becuase I have no knowledge and no place to create them (I'm a web developer), but I guess I can check around town and with friends if they know a place that can create them for me.

So I have a couple of questions:


  • Do you think an RFID lock mechanism would be safe? Could it be hacked with other RFID tags?

  • What part do you reckon I need? Obviously an Arduino, an RFID reader, and some sort of motor to turn the lock, but I'm not really sure which.

  • I should still be able to open/lock the door with a key if the system would fail. I don't want to damage the system in that case.

  • How much do you think a project like this can cost?




johnwasser

A low-melting-point plastic called Shapelock should allow you to form an adapter between a motor and your lock knob.

A ratchet mechanism that allows the motor to turn the knob only in the UNLOCK direction would allow you to unlock from the outside with a key if the RFID fails.

You may be able to read the RFID token THROUGH the door.  No holes needed.

Someone would, in theory, need access to your RFID token if they wanted to duplicate it.  If you keep it in a shielded wrapper when in your pocket it should be safe from duplication.

A metal strap hung from the top of the door would support the Arduino, RFID reader, and lock motor without requiring holes in the door surface.
Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

PaulS

Quote
Do you think an RFID lock mechanism would be safe?

Depends on the programming, and the ability to exit in case of emergency, but, in general, yes.

Quote
Could it be hacked with other RFID tags?

If you don't let your tag be cloned, no.

Quote
How much do you think a project like this can cost?

How much do you have?



A ratchet mechanism that allows the motor to turn the knob only in the UNLOCK direction would allow you to unlock from the outside with a key if the RFID fails.

You may be able to read the RFID token THROUGH the door.  No holes needed.



Ah, though I want to be able to lock the door with RFID too though. I was thinking of locking the door the same way, by reading the RFID tag and turning the knob in the other direction. I'm not experienced in electronics, but I experimented with stuff, taking them apart when I was a kid so I know a bit about motors and such. If the motor would be "turned off" (like, no power fed to it? I saw some video discussing that idea but I can't recall which one) while no card is being read, would that allow the motor to freely rotate without damaging it?

Also, does RFID really have that range to read through the door? The door is about 6.5cm (2.5in) and made of wood (I don't know if there is metal inside of the door), wouldn't that require quite a large reader, which might need more power and be more expensive? Otherwise, I was thinking of just having an antenna taped to the outside of the door (having the wires go trough the springs of the door), and having a nameplate sticker over it to hide it some (my nameplate was stolen anyway).

How much power do you think the project would take (in standby)?



Quote
Do you think an RFID lock mechanism would be safe?

Depends on the programming, and the ability to exit in case of emergency, but, in general, yes.


I'll figure something out about the programming when I got everything I need. I've programmed in a few languages before (java, c++, php, python) but I learn new languages pretty fast :P. On the inside I would have two buttons, one for lock and one for unlock. In the case of power outtake I guess I could remove the thing from the door and open it normally.


Quote
How much do you think a project like this can cost?

How much do you have?


Well, I could think of spending about $100 - $200 on it, but the cheaper the better, I'm a student afterall :>

Grumpy_Mike

Quote
Also, does RFID really have that range to read through the door? The door is about 6.5cm (2.5in) and made of wood (I don't know if there is metal inside of the door), wouldn

Yes an RFID reader will easily read through a wooden door. However, if for some reason it had a metal sheet inside it then no.



A ratchet mechanism that allows the motor to turn the knob only in the UNLOCK direction would allow you to unlock from the outside with a key if the RFID fails.



Actually, I just tested, the lockknob doesn't rotate when you unlock/lock the door with a key, though it would rotate a little bit if it would be turned exactly to the angle where it would start to unlock/lock the door. So if I just rotate the motor a bit more than needed it should work.

johnwasser




A ratchet mechanism that allows the motor to turn the knob only in the UNLOCK direction would allow you to unlock from the outside with a key if the RFID fails.



Actually, I just tested, the lockknob doesn't rotate when you unlock/lock the door with a key, though it would rotate a little bit if it would be turned exactly to the angle where it would start to unlock/lock the door. So if I just rotate the motor a bit more than needed it should work.


Excellent!  No ratchet needed and you can use the RFID to lock the door as well as unlock.  I was worried that to get sufficient torque to lock you would need a gearmotor (probably still do) and because a gearmotor is geared way down it is hard to turn the shaft even with the motor off.
Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

#7
Feb 09, 2012, 08:46 pm Last Edit: Feb 11, 2012, 06:09 pm by galaxyAbstractor Reason: 1




A ratchet mechanism that allows the motor to turn the knob only in the UNLOCK direction would allow you to unlock from the outside with a key if the RFID fails.



Actually, I just tested, the lockknob doesn't rotate when you unlock/lock the door with a key, though it would rotate a little bit if it would be turned exactly to the angle where it would start to unlock/lock the door. So if I just rotate the motor a bit more than needed it should work.


Excellent!  No ratchet needed and you can use the RFID to lock the door as well as unlock.  I was worried that to get sufficient torque to lock you would need a gearmotor (probably still do) and because a gearmotor is geared way down it is hard to turn the shaft even with the motor off.


Ah. So looking at parts and stuff, what would be needed? What I gather:

Arduino uno: http://store.arduino.cc/eu/index.php?main_page=product_info&cPath=11_12&products_id=195
The RFID reader: http://www.seeedstudio.com/depot/1356mhz-rfid-module-iosiec-14443-type-a-p-196.html?cPath=144_153
RFID tag to be placed inside the battery case of my phone: http://www.seeedstudio.com/depot/1356mhz-rfid-book-tag-p-1067.html?cPath=144_153
In the RFID guide, they use a breadboard. Is it neccesary? http://store.arduino.cc/eu/index.php?main_page=product_info&cPath=11_15&products_id=190 (Alternatively http://www.makershed.com/Mini_Breadboards_p/mkkn1.htm ?)
I guess wires are needed? http://www.makershed.com/product_p/mkseeed3.htm
A LED indicating the status (on the inside, if the door is locked or not (different colors): http://store.arduino.cc/eu/index.php?main_page=product_info&cPath=6&products_id=150 http://store.arduino.cc/eu/index.php?main_page=product_info&cPath=6&products_id=151
Button for locking/unlocking from the inside: http://www.adafruit.com/products/367
A gearmotor: http://www.seeedstudio.com/depot/gear-motor-6v-60rpm-dustproof-p-714.html?cPath=170_171
Motor driver: http://store.arduino.cc/eu/index.php?main_page=product_info&cPath=11_5&products_id=204
Shapelock: http://www.makershed.com/product_p/mkshl1.htm
PVC Pipes and suction cups

Did I get everything right? What about resistors? Also, how would I get a power supply? Worth noting is that I live in Sweden, so we got 230V schuko/europlug. It's about 2 - 3m from the door to nearest outlet.

johnwasser

You don't need the breadboard but it may be handy for testing the circuits before soldering anything.

Add some resistors for the LEDs.  Add an H-bridge to drive the gearmotor.  Maybe some mounting hardware.

Get some male terminal strip.  Solder wires to the strips and plug the strips into the Arduino sockets.  That way you can take the Arduino out easily. for replacement or upgrade.
Send Bitcoin tips to: 1L3CTDoTgrXNA5WyF77uWqt4gUdye9mezN
Send Litecoin tips to : LVtpaq6JgJAZwvnVq3ftVeHafWkcpmuR1e

#9
Feb 09, 2012, 11:22 pm Last Edit: Feb 10, 2012, 01:23 pm by galaxyAbstractor Reason: 1

You don't need the breadboard but it may be handy for testing the circuits before soldering anything.

Add some resistors for the LEDs.  Add an H-bridge to drive the gearmotor.  Maybe some mounting hardware.

Get some male terminal strip.  Solder wires to the strips and plug the strips into the Arduino sockets.  That way you can take the Arduino out easily. for replacement or upgrade.


Like a http://store.arduino.cc/eu/index.php?main_page=product_info&cPath=11_5&products_id=204 ? Also, what sort of resistors? I don't have an electrical background but I recall it needs to have the right Ohm resistance but I never been sure how to get the right ones.

I can go with the breadboard if I don't want to solder anything, right? I've tried soldering before, but I totally suck at it (my hands usually shake a bit too much when I try to focus and my precision isn't very good, the times I did I always messed up).

I found an power supply that outputs 12VDC 1500mA current, and has a 2.1mm plug. The description says "Polarity could be changed by twisting the plug" too. Would that be good enough for an arduino? I don't feel safe enough creating the power supply myself.

Go Up