Security System with Servos

Thread Starter


Joined Sep 7, 2011
Hi all,

I've being designing this project myself for a week now for my final year project at college. The whole idea behind project is to control the movement of personnel into a designated area. The concept is to have a door locking canal as follows

doors at either side of a 'canal' that can only be opened one at a time by an operator. (ie one door must remain closed)

When a person enters, the door closes behind them and they must enter their identity code and pin code to gain access to the inner door.
(Vica versa - exiting the 'building', same procedure)

For identity code and pin code a keypad and LCD display used.

Operator has 3 buttons -
1. to reset system
2. to open inner door
3. to open outer door

I added a smoke alarm for inside the canal instead of motion laser sensors as I'm finding it difficult on how to interface them with 8051/52 etc - undecided on uC.

Currently having major major issues on how to interface 2 servo motors or 2 stepper motors for the doors into the design. Also on choosing which ones to go for. An operator pushes a button to open them and close them and I would like a sensor to detect the door is closed. I would want the door to open and then close via a motor.

I've uploaded my original project schematic submission and my current proteus designs,

any help on these issues greatly appreciated, block diagrams complete due Thursday!



View attachment Idea.pdf

View attachment Isis Word.pdf
Last edited:


Joined Nov 25, 2009
Is it really important to you that the doors will open and close automatically? If you go towards this direction you will need pretty hefty motors and you most probably face great construction problems.
I would suggest you only energize the door locks and let the user open and close them.

Other than that, how exactly do you plan to replace the lazer motion sensor with a smoke detector? I can't imagine how this will work.

Thread Starter


Joined Sep 7, 2011
Yeah good point on construction, may have problems. If I energize them - the doors could be manually pushed open and closed as you mention.
To energize the doors would it be a case of a relay and/or solenoid attached to door? Also I would like uC to be able to detect doors closed or opened?

I'm putting smoke alarm in because its practical and also looking at lasers I'm not sure I'll be skilled and be able to manage my time enough to insert these as they seem quite complicated!


Joined Aug 15, 2007
Your best bet is to first write out the steps for access via each door:

1) Door 1 opens
2) Door 2 locks
3) User enters the "canal."
4) Door 1 closes and locks
5) User enters codes.
6) Test the codes
7a) If the codes are valid, unlock and open Door 2
7b) If not valid, flood canal with cyanide gas. (I'm joking! -- but you WILL need to figure out what to do with incorrect entries.)
8) Door 2 closes; Door 1 unlocks.

I work at programming the micros for alarm systems. I would use magnetic reed switches to detect the door states -- cheap and readily available. Rather than a laser or smoke detector, I would use which door opens first to determine the direction of travel.

The method we use here at work is to have the employee enter their passcode (actually, we use RFID tags) before they enter the building. We also have an inner door that, when an employee is validated, automatically opens the door for them.

So, basically, it's
1) Wave tag at card reader.
2) Open door, go towards Engineering.
3) Wave tag at card reader.
4) Door to Engineering opens, and lets me in.


Thread Starter


Joined Sep 7, 2011
I'm looking for a small scale solenoid controlled door lock to use so I can build it when pcp board complete but having difficultly locating one, anyone able to help with suggestion please?

Ideally to my knowledge, have two relays, two solenoids that control the two door locks and a sensor on each door, maybe attached somehow solenoid - is that possible???

Thread Starter


Joined Sep 7, 2011
If perhaps I used these two circuits, the control signal comes form microcontroller pins and activates the base of transistors - switching on relay which activates solenoid. Using a 'motor' for demonstration purposes.

Thinking perhaps should be connected to emitter for good current to drive both solenoids..

Also I would physically 'insert' small size solenoids into make shift doors for miniature display model, could a sensor be attached?

Thanks for all the help, really appreciate it!

View attachment Solenoids.pdf