• Skip to main content
  • Skip to primary sidebar

Homemade Circuit Projects

Need circuit help? Post them in the comments! I've answered over 50,000!

Blog | Categories | About | Contact | Calculators-online
You are here: Home / Automation Projects / Hen House Automatic Door Controller Circuit

Hen House Automatic Door Controller Circuit

Last Updated on January 3, 2024 by Swagatam 36 Comments

In this article I have explained an automatic door mechanism circuit that responds to the ambient light conditions by keeping the door open during day time and closed during night. Here the application is used for operating a hen house door. The idea was requested by Mr. Gavin Sweet

Table of Contents
  • Technical Specifications
  • The Design

Technical Specifications

I have a project that I am starting to investigate and was wondering if you had any ideas

The project is to make an automatic door for a hen house, I would like it to be controlled by dawn/dusk to run a 12v motor to open the door then reaching a limit switch to then reverse motor direction when it is dark returning the door down to a second limit switch placed at the bottom of the door (I was also Hoping to put a delay on the door closure of Upto 30 mins)

There are many designs for a timer version of this circuit but this would mean periodic adjustments to the programmable timer.

I hope you can point me in the right direction

Thanks
Gavin Sweet

warning message: electricity is dangerous, proceed with caution
lightdependantdoorlock 1024x484 1

The Design

The requested dawn dusk hen house door operator circuit may be witnessed in the above diagram and understood with the help of the following points.

Two 555 IC stages can be seen the proposed design.

The IC1 stage is wired as light activated switch using an LDR as the sensor.

The relay associated with IC1 is held deactivated during day time and vice versa.

IC2 is configured as a set/reset latch flip flop or bistable stage wherein the relay associated with this IC stays activated when SW1 is in the depressed position and deactivated when SW2 is in a pushed ON state.

Let's assume it's day time and the door being fully open, and the door mechanism keeping the SW1 switch pushed ON.

In the above scenario,  the IC1 DPDT relay can be assumed to be in the N/C positions, while the IC2 relay in N/O position.

IC2 relay being in the N/O position cuts off the negative supply to the DPDT relay making sure that the motor in this state stays shut off and tightly locked keeping SW1 pressed and ON.

Now, as day light begins to fade and dusk arrives, the LDR senses this and toggles IC1 pin3 low, actuating the DPDT relay whose contacts now change positions towards their respective N/O points.

The above changeover immediately switches ON the motor which starts moving the door mechanism until its fully closed. In the course it releases SW1 rendering IC2 in a standby position.

When the closing procedure ends, SW2 which is positioned at the the other end of the door mechanism responds to the closing of the door pressure resets the IC2 such that its relay now chnages from N/O to N/C. This action instantly cuts off the other negative line to the N/O contacts of the DPDT.aking sure that the motor shuts off again and stays in that position until dawn sets in.

The 2200u capacitor and R3 may be appropriately tweaked for getting a delayed response from IC1 after dawn or dusk transitions are sensed by the LDR

You'll also like:

  • 1.  Day/Night Triggered Automatic Door Lock Circuit
  • 2.  SMS Based Pump Controller with Automatic Dry Run Shut Off
  • 3.  Automatic Street Light Dimmer Circuit
  • 4.  Simple Tea Coffee Vending Machine Circuit
  • 5.  Line Follower Robot Circuit without Microcontroller or Arduino
  • 6.  Arduino Automatic School/College Bell System

About Swagatam

I am an electronics engineer with over 15 years of hands-on experience. I am passionate about inventing, designing electronic circuits and PCBs, and helping hobbyists bring their projects to life. That is why I founded homemade-circuits.com, a website where I share innovative circuit ideas and tutorials. Have a circuit related question? Leave a comment.... I guarantee a reply!

Previous Post: « Christmas LED Candle Light Timer Circuit
Next Post: LPG Gas Leakage Detector Alarm Circuit »

Reader Interactions

Comments

  1. chris says

    January 20, 2025 at 4:51 pm

    is it possible for you to make an example of a circuit schematic of an micro control sensors automatic doors lock system with an led when occupied

    Reply
    • Swagatam says

      January 20, 2025 at 6:12 pm

      Please provide the full working details of your design, it will help me to understand the concept better and to design it…

      Reply
  2. project says

    April 15, 2023 at 4:54 pm

    can i change LDR sensor with IR sensor?

    Reply
    • Swagatam says

      April 15, 2023 at 5:55 pm

      Sorry, no, that may not be possible.

      Reply
      • Project says

        April 18, 2023 at 12:41 pm

        I Change LDR with IR and the circuit work but i have Problem the motor only work in one direction, How can fix that?

        Reply
        • Swagatam says

          April 18, 2023 at 12:49 pm

          Did you wire the DPDT relay correctly with the motor as shown. The given DPDT connections ensure that the motor rotates both ways.

          Reply
          • Project says

            April 18, 2023 at 1:47 pm

            Yes, the common with motor and NC, NO with Vcc. Also( NC with NC and NO with NO to other relay)

            Reply
            • Swagatam says

              April 18, 2023 at 5:09 pm

              When the relay contacts change their positions the polarity of the motor wires become opposite so the motor should also change its rotation direction. You can track the wires of the motor connections with the relay contacts, you can easily see that the polarity of the motor changes when the relay operates.

              Reply
  3. fahad says

    March 11, 2023 at 4:24 pm

    Can you tell me the function of the resistors and diodes in this electrical circuit

    Reply
    • Swagatam says

      March 11, 2023 at 5:19 pm

      Which resistor and diode?

      Reply
  4. Kman says

    June 10, 2022 at 7:45 pm

    Hi,
    I’ve built this circuit on a breadboard and I’m having a few problems. I’m hoping you can help me find out where I’ve gone wrong.
    The main problem is the motor only turns on when SW1 is pressed, and it runs for a varying period before turning off by itself (without me doing anything). If I press SW2 while the motor is running it will stop.
    I think one problem is the DPDT is active as soon as I power on the circuit – which I think means the IC1 Pin3 is Low.
    Covering the LDR or running the circuit in darkness doesn’t have any effect. The motor still only runs if SW1 is pressed.
    The other problem is the motor turns itself off, even if the SW2 hasn’t been pressed.
    I hope I’ve explained the problem clearly.
    Thanks for your help.

    Reply
    • Swagatam says

      June 10, 2022 at 8:18 pm

      Hi, IC1 DPDT relay should switch OFF (move to N/C contacts) when the LDR is exposed to light, and switch ON (move to N/O contacts) when the light is removed from the LDR.
      For the IC2 pressing SW1 momentarily should switch ON the SPDT relay (move to N/O contacts) when SW1 is released and SW2 is pressed then the SPDT relay should switch OFF (move to N/C contacts). Please confirm the above. If these are not happening then something is not correct with your circuit.
      By the way breadboard assembly will not work for this circuit, you will have to join the parts by soldering.

      I can provide the same circuit using transistors which can be much easier.

      Reply
      • kman says

        June 11, 2022 at 3:53 am

        Hi,
        Thanks for your quick reply.
        I changed IC1 to a new 555. IC1 DPDT is now switched off (N/C) when the circuit powers on, but the LDR still doesn’t have any effect. Should the change be instant or is there a delay? I’ll recheck all my connections to make sure they’re correct. Is there anything else you can suggest?
        For IC2 the SPDT is now working properly. When I press SW1 the SPDT moves to N/O, and when SW1 is released and SW2 is pressed it moves to N/C.
        Once I have the circuit working I’ll build it properly on a PCB.

        Reply
        • Swagatam says

          June 11, 2022 at 9:38 am

          Hi, the LDR ON/OFF will not be instant because of the internal hysteresis of the IC and because of C1. Please remove C1 completely for the removing the slow response.
          Since your IC2 is now working, that’s great, now you only have to fix the IC1 working. Remove C1 and I think the slow response will be solved.

          Reply
      • kman says

        June 11, 2022 at 9:36 am

        I think the reply function might not be working? my reply keeps disappearing.
        Thanks for your quick reply.
        I changed IC1 to a new 555. IC1 DPDT is now switched off (N/C) when the circuit powers on, but the LDR still doesn’t have any effect. Should the change be instant or is there a delay? I’ll recheck all my connections to make sure they’re correct. Is there anything else you can suggest?
        For IC2 the SPDT is now working properly. When I press SW1 the SPDT moves to N/O, and when SW1 is released and SW2 is pressed it moves to N/C.
        Can I use the breadboard to test the circuit before I solder it?

        Reply
        • Swagatam says

          June 11, 2022 at 9:56 am

          All your replies are all intact, none of them have disappeared… you can check them under the article….I have replied to your previous comment, please check it.

          Reply
  5. JP says

    April 4, 2021 at 2:27 am

    I wanted to make this but am having a bit of trouble matching parts. Do you have a parts list for this circuit? For that matter do you have parts lists for other circuits?

    Reply
    • Swagatam says

      April 5, 2021 at 12:15 pm

      All the parts exactly as given in the diagram…..the resistors are all 1/4 watt….the part dealer will be able to guide you through…

      Reply
      • JP says

        April 6, 2021 at 11:30 am

        The only problem is that Digikey.com has variants of the same part. For example NE555 isn’t just NE555 there are a few different types of NE555. I can take a logical guess, but since this is for someones pet I don’t want to guess.

        Reply
        • Swagatam says

          April 6, 2021 at 3:59 pm

          All 555 IC has the same function and same pinout specs, so you can use any of those IC 555

          Reply
  6. niconoe says

    June 22, 2017 at 7:33 am

    Thanks a lot, I'll try the suggested solutions. I indeed already included C1. I also played with the value of R3 (10k for example), and as expected I can decrease the delay after the threshold is reached. It's at the time the DPDT finally switch to "day mode" that I observed this oscillation.

    I'll keep you informed, thanks for the good work and cheers from (exceptionally sunny) Belgium!

    Reply
    • Swagatam says

      June 22, 2017 at 11:55 am

      You are most welcome!! I wish you all the best!!

      Reply
  7. niconoe says

    June 21, 2017 at 6:33 pm

    Hi Swagatam,

    Great circuit, thanks a lot! I just build it, works fine except a small quirk: when the DPDT relay switch to "day mode", it oscillates (ON/OFF) like crazy for a few seconds, then stabilize. The motor runs fine, I'm just a bit worried about the relay longevity.

    Any idea of what the cause could be? I was thinking some back EMF from the motor, but obviously since it runs in both directions I can't avoid this phenomenon by using a diode (like you did on the relay's coils).

    Thanks a lot!

    Reply
    • Swagatam says

      June 22, 2017 at 4:22 am

      Thanks Niceone, I am glad you could build it successfully.

      To rectify the issue, just try connecting a 100uF/25V capacitor in parallel with the relay coil or D1, positive of the cap will go to the positive side of the coil, and the negative to the pin#3 side of the IC…I am sure this will solve the problem….

      Reply
    • Swagatam says

      June 22, 2017 at 4:25 am

      if the above doesn't help, you can use a BC547 transistor driver for the DPDT relay exactly as done for the other relay…and connect a 10uF/25V with base/emitter of this trasistor

      Reply
    • Swagatam says

      June 22, 2017 at 5:00 am

      ….by the way did you include C1 in the design?…the delay caused by C1 itself should be enough to stop any kind of stuttering on the relay.

      Reply
  8. Yohana Tijala says

    July 31, 2016 at 1:04 pm

    hello sir i hope you doing fine,is it possible to use that circuit above instead of closing the door during evening and then opening while someone block the LDR and then it open and vice versa

    Reply
    • Swagatam says

      August 1, 2016 at 5:50 am

      hello yohana, the operation can be reversed by simply interchanging the LDR and R1 positions

      Reply
  9. Unknown says

    November 1, 2015 at 4:02 pm

    hi swagatam sir if possible can u provide me ckt dia for digital ic tester using raspberry pi……….
    and happy diwali in advance

    Reply
    • Swagatam says

      November 2, 2015 at 8:53 am

      I am sorry, at the moment I do not have this circuit, if I happen to find it will surely let you know…

      Reply
  10. Gavin says

    March 29, 2015 at 3:23 pm

    Hi thanks for posting this design, I have a couple of questions whilst I source components/make a parts list. Firstly what is the value of the C1 on the IC2 part of the circuit? How will I tweek R3 to delay dusk activation? Finally there is a DPDT switch at the top of the diagram next to the motor, what is its function, is it to provide override facility to operate the circuit/motor on demand if needed?
    Thanks again Gavin

    Reply
    • Swagatam says

      March 30, 2015 at 3:37 am

      Please read the previous comment for the answers…..I have mistakenly written R1 instead of R3, please note this correction….

      R1 is for setting the dawn/dusk threshold, whereas R3 is for producing a delay after these thresholds are reached.

      Reply
  11. Gavin says

    March 29, 2015 at 3:18 pm

    Hi, thanks for posting this design, I have a few questions whilst I source components/make a parts list. What is the value of C1 on the IC2 part of the circuit? How will I tweek the dusk part of the operation? There is a DPDT switch at the top of the diagram next to the motor, what is its function, is it a toggle type override switch to test functionality and be able to operate the system on demand if necessary?
    Thanks again Gavin

    Reply
    • Swagatam says

      March 29, 2015 at 5:10 pm

      Thanks it's my pleasure!!

      The value C1 of IC2 should be 0.01uF.

      Increasing the values of R1/C1 in the IC1 stage will proportionately increase the delay period after the dusk threshold is reached, but I am not sure what value would provide 30 minutes delay, it will need to be experimented by trial and error.

      The DPDT indication is for the relay, it's not a switch. The relay associated with IC1 is a DPDT type involving a pair of changeover contacts as shown in the figure.

      in order to get an override feature, you can add a SPDT switch parallel with the relay contacts of IC2.

      Reply
  12. Humphrey Mndaka says

    March 28, 2015 at 6:22 am

    Smart idea..keep it up Swagatam.
    regards Humphrey

    Reply
    • Swagatam says

      March 28, 2015 at 9:45 am

      thank you Humphrey.

      Reply

Need Help? Please Leave a Comment! We value your input—Kindly keep it relevant to the above topic! Cancel reply

Your email address will not be published. Required fields are marked *

Primary Sidebar

Subscribe to New Circuit Ideas

Categories

  • Arduino Projects (87)
  • Audio and Amplifier Projects (132)
  • Automation Projects (17)
  • Automobile Electronics (101)
  • Battery Charger Circuits (83)
  • Datasheets and Components (104)
  • Electronics Theory (143)
  • Free Energy (37)
  • Games and Sports Projects (11)
  • Grid and 3-Phase (19)
  • Health related Projects (25)
  • Home Electrical Circuits (12)
  • Indicator Circuits (14)
  • Inverter Circuits (87)
  • Lamps and Lights (142)
  • Meters and Testers (69)
  • Mini Projects (46)
  • Motor Controller (64)
  • Oscillator Circuits (27)
  • Pets and Pests (15)
  • Power Supply Circuits (108)
  • Remote Control Circuits (50)
  • Security and Alarm (64)
  • Sensors and Detectors (101)
  • Solar Controller Circuits (59)
  • Temperature Controllers (42)
  • Timer and Delay Relay (49)
  • Transmitter Circuits (29)
  • Voltage Control and Protection (37)
  • Water Controller (36)

Calculators

  • Battery Back up Time Calculator
  • Capacitance Reactance Calculator
  • IC 555 Astable Calculator
  • IC 555 Monostable Calculator
  • Inductance Calculator
  • LC Resonance Calculator
  • LM317, LM338, LM396 Calculator
  • Ohm’s Law Calculator
  • Phase Angle Phase Shift Calculator
  • Power Factor (PF) Calculator
  • Reactance Calculator
  • Transistor Astable Calculator
  • Transistor base Resistor Calculator
  • Voltage Divider Calculator
  • Wire Current Calculator
  • Zener Diode Calculator
  • Filter Capacitor Calculator
  • Buck Converter Calculator
  • Boost Converter Calculator
  • Solar Panel, Inverter, Battery Calculator
  • Wire Current Calculator
  • SMPS Transformer Calculator
  • IC SG3525, SG3524 Calculator
  • Inverter LC Filter Calculator

People Also Search

555 Circuits | 741 Circuits | LM324 Circuits | LM338 Circuits | 4017 Circuits | Ultrasonic Projects | SMPS Projects | Christmas Projects | MOSFETs | Radio Circuits | Laser Circuits | PIR Projects |

Recent Comments

  • Swagatam on 10 LED Tachometer Circuit Diagram
  • Swagatam on How Shunt Regulator TL431 Works, Datasheet, Application
  • Göran on 10 LED Tachometer Circuit Diagram
  • SA on How Shunt Regulator TL431 Works, Datasheet, Application
  • Swagatam on Adjustable 0-100V 50 Amp SMPS Circuit

Company

  • Privacy Policy
  • Cookie Policy
  • About Me
  • Contact
  • Disclaimer
  • Copyright
  • Videos
  • Sitemap

Social Profiles

  • Twitter
  • YouTube
  • Instagram
  • Pinterest
  • My Facebook-Page
  • Quora
  • Stack Exchange
  • Linkedin
  • © 2025 · Swagatam Innovations