Introduction: Automated Door System (A Demonstration)

I'm sure everyone has seen those automatic doors at many places which shows that automation is limitless. Even though it seems like a complex thing, it's pretty easy to build. If you ever wanted to recreate something like that in a smaller scale, then you're viewing the right Instructable.

In this Instructable I'll show you the circuit I made to demonstrate the principle behind Automatic Doors. You can implement it in any automation project you're working on. So let's get started.

Step 1: Components Required

For this project you will need:

  • Arduino Uno
  • Micro Servo
  • IR Sensor
  • LED
  • Jumper Wires
  • Bread Board

With these few components we're ready to roll.

Step 2: The Principle

The theory behind the doors are pretty simple. The IR sensor senses the presence of a person . This data is used to operate the servo or the motors which control the doors. I am also using an LED to indicate the opening of the door. You can also use a buzzer as an indicator.

The IR sensor which I'm using has a built in Analog to Digital converter. This allows me to take the values in either analog or digital form as per the requirements. For this I'm taking the values in digital form. If you want to build your own IR sensor, I have another Instructable for that. Click here to check it out.

Step 3: The Circuit

Follow the schematics and build the circuit. The pin configuration is as follows:

  • +5V of Arduino to Vcc of the Servo.
  • +3.3V of the Arduino to Vcc of the IR Sensor.
  • Digital Pin 7 to The Output of the IR sensor.
  • Digital Pin 9 to the Signal Pin of the Servo.
  • Connect the Ground terminals of both Servo and IR Sensor to the Arduino Ground Pins.
  • Connect the Indicator LED across Pin 13 and Ground of the Arduino.

Step 4: The Code

#include

int irSensor = 7; // declaring the pin where IR sensor is attached Servo door; //naming the servo int pos = 0; // initial position of the servo

void setup() { door.attach(9); // pin to which servo is attached pinMode(13,OUTPUT); Serial.begin(9600); pinMode(irSensor, INPUT); // setting the pin to take input from the IR sensor }

void loop() { int buttonState = digitalRead(irSensor); //reading the input Serial.println(buttonState); if(buttonState == 0){ //if an object is detected the value turns 0 pos = 180; //open the door door.write(pos); digitalWrite(13,HIGH);//turn on indicator } else{ pos = 0; // closing the door when no object door.write(pos); digitalWrite(13,LOW);//turn off indicator } delay(1000); }

This code can be modified as per your personal specifications. If you have any doubts regarding the code please feel free to ask them in the comments below.

Step 5: Uploading and Testing

Once you've verified the code, it's now time to upload it on to the Arduino Uno.

Now a model of the automated door system is ready. You can probably implement it with bigger Servo Motors and use it to open doors or gates at your house .

"Take Any Challenge as a Creative Opportunity".

That's All Folks !! Follow and Stay tuned for More !!

Keep DIY-ing !!

Comments

About This Instructable

1,025views

31favorites

License:

Bio: My team has developed a new product. PLEASE CHECK IT OUT ON INDIEGOGO AND SHOW YOUR SUPPORT. CAMPAIGN LINK: https://igg.me/p/2165733/x ... More »
More by goks_lf:How to Use the L293D Motor Driver (With Arduino).Laser Tripwire Home Alarm SystemAutomatic Lights Using LDR (Brightness Control)
Add instructable to: