Introduction: Automatic Chicken Coop Door - No Programming Needed!
I started the process of automating my chicken coop door many years ago. After many failed attempts, I found the following video that didn't require any computer controls and seemed within my reach.
However, there was no wiring diagram and I found out that the daylight sensor would activate the door too early in the evening, so I had to modify the photo resistor so it would close slightly after dark. The last reason for this build is that there was an antenna motor used in the original build and after 4-5 months, the gears stripped out and the door quit working. This build is based on a vertical sliding door. You will need approximately 12-16” clearance past the actual coop door for the mechanism. It can be adapted for a horizontal sliding door. This build will focus on the door controller, but will briefly address other items necessary for a completed project. You will need 120v AC power at your chicken coop to complete this build.
Step 1: Tools and Parts Lists
Soldering iron and solder
Wire cutters/strippers
Voltmeter
Electrical test leads (helpful, not absolutely necessary)
Hot glue gun
Drill, drill bits
Tap and die set
woodworking tools if you’re building the actual coop door
Materials needed (with links when possible):
12v power supply (I’m using an old Wii power supply that’s rated for 3.7 amps)
12vdc motor https://www.sciplus.com/car-seat-12vdc-gear-motor...
12v relay https://www.amazon.com/gp/product/B01DBU2VD4/ref=...
12V Car LED Light Control Photo resistor Plus Relay Module –
https://www.amazon.com/gp/product/B00VFBUFUS/ref=p...
3 micro switches - https://www.sciplus.com/defond-momentary-3a6a-mic...
Extra photo resistors https://www.amazon.com/HOODDEAL-Sensitive-Resistor...
These items can be purchase at your local big box store:
20 ga. door bell wire
Wire connectors [pictures E, F] (make sure you get the 1/4" male and female quick connect - I had to go back to the store to get the correct female connectors...)
Electrical tape
1/2” Threaded rod
pipe nipple 1/2x3” galvanized [picture G]
set screws
Plastic case to house the controller
Brad nails
misc. screws
Step 2: Preliminary Stuff for This Build
I’m using an existing sliding coop door, and will be retrofitting this to work. I won’t spend a lot of time on this since this Instructable is really about the electronic controls to make an automatic door. Here’s a synopsis of the door modifications:
A. I used some aluminum angle that I had in my garage to make 2 brackets and used a 1/4” bolt to attach the motor to the brackets. This was screwed to the top of the door frame.
B. I needed to extend the shaft on the motor, so I took a 3/8x3 galvanized nipple and drilled and tapped holes in it so I could use machine screws as set screws to lock it onto the shaft. I used 1/2” all thread rod as the extension shaft. I also had to drill out the inside of the rod to get it to fit well onto both shafts.
C. Finally, I made a mounting block to hold a 1/2” nut for the shaft to run through to raise and lower the door. You can temporarily attach this to the door using a hot glue gun. The block should be set halfway up the threaded rod and in the center of the door. That way, when testing the movement of the door and limit switches, you’ll have time to unplug the controls if needed. It can be removed with a putty knife later if needed to adjust the range of motion.
Step 3: Now, Onto the Electronics!
Step 1. Look at the back of whatever power supply you are using to determine which part of the plug is positive and which is negative. Since this is low voltage, I just crimped a wire a little bit so that I would get good contact with the output and pushed it into the hole in the plug. Then I bent the wire over and taped it well with electrical tape so that the wires wouldn’t come out. Use red wire for the positive and white wire for the negative.
Step 2. On the end of the red wire, use a wire nut to add on 3 more red wire leads. On the end of the white wire, add on 2 white leads [not shown].
Step 4: Wiring the Daylight Sensor
Step 3. Connect one of the red wires and one of the white wires to the power terminals on the daylight sensor. Red will connect to the lug labeled DC+, white will connect to the lug labeled DC-. If you plug in the power supply, a red LED will light up. This is the power indicator. Covering the photo resistor on the daylight sensor should cause a blue LED to light up. There is a sensitivity control near the plug for the photo resistor. Use this to control the light level that triggers the sensor to switch between light and dark.
Step 4. Take another of the red wire leads from Step 2 and connect it to the COM terminal on the other end of the light sensor. Add another red lead wire to the NO (normally open) terminal. This will connect to the relay to control the opening or closing of the door. The daylight sensor is completely wired.
Step 5: Wiring the Relay - This Is the Part That Controls the Direction of the Motor
Note – All connections to the relay and the motor will be made using the female quick disconnect connectors. Strip off about 1/2” of the insulation. I usually fold the wire over to give a little more to crimp onto, and then crimp the connector onto the wire with a pair of pliers. For the remaining red wire from Step 2, put on 2 connectors as in the 2nd picture above.
Step 5. Now to wire the relay. The relay is labeled on the end opposite the pins with pin numbers. Also, pins 7 & 8 are oriented differently than pins 1 – 6. Per the wiring diagram,
A. connect the remaining red wire from Step 2 (now with 2 connectors on it) to pins 1 & 4.
B. The red wire from the NO lug on the daylight sensor will connect to pin 8.
C. One of the white wires from Step 2 will connect to pin 7.
D. Finally, run a red and a white wire from pins 5 & 6 to the motor. (Use enough wire to reach from the motor to where you want to mount the controls.) At this point, don’t worry about which wire connects to which motor terminal.
This turns into a rat's nest pretty quickly so follow the wiring diagram closely and add labels as needed to help you keep track of your wires.
Step 6: Limit Switches - Control the Distance Your Door Moves
Step 6. Limit switches – Using the multimeter set to ohms (resistance), check the microswitches to determine the normally closed (NC) terminals. In this case, when I connect my meter to the outside terminals, it reads 0 ohms when the switch is not pushed and 1 when it is pressed. I want to connect to these 2 terminals.
A. Using a similar amount of wire that was used to run from the relay to the motor, solder a wire to these 2 terminals on one switch. This will be the “open” limit switch.
B. Also using a similar amount of wire, we’ll wire in 2 limit switches for the “closed” limit switches. Solder one wire to each switch. Then solder a jumper approximately the width of the door. In my case, the jumper was about 8” long. (Note – I added the 2nd switch as a revision to my initial build, so I have an extra wire nut you shouldn’t need)
Step 7. Take one of the “open” limit switch wires and attach it to pin 2 on the relay and one of the wires from the “closed” limit switches and attach it to pin 3. Both of the other wires from the limit switches will be connected to the last white wire from step 2 by another wire nut
Note- I cut into the motor wires and limit switch wires and added quick connectors so I can disconnect these easily at installation for routing wires as needed. Make sure to clearly mark which wires pair up so that there's no confusion later.
Step 7: Testing Operation of the Door
Warning!!
When testing the operation of the door, be prepared to kill power quickly if something doesn’t work as you would like! This motor has a lot of torque and something will break if it doesn’t shut off when it’s supposed to, and can trap and/or damage hands or fingers that get in the way.
Step 8. Plug in the power supply and the motor should start to rotate. Without the photo resistor on the daylight sensor covered, the motor should open the door. By covering the photo resistor, the motor should reverse and close the door.
**Troubleshooting** If the motor is closing the door when the photo resistor is not covered (only the red LED is lit) reverse the wires on the motor leads.
Step 9. Confirm operation of the limit switches.
A. Turn on power and with the door opening, press the “open” limit switch. This should shut off the motor. If it doesn’t, press one of the “closed” switches which should shut off the motor.
B. Now, if you cover the photo resistor, the motor should close the door and either of the “closed” limit switches should shut off the motor. Again, if they don’t, press the “open” limit switch and it should shut off the motor.
C. If the switches operated correctly, you’re done with this step. If they were opposite of what they should have been, remove the wires from pins 2&3 on the relay and reverse them. This should fix the problem. Go back to Step 9A and check that they work correctly.
Step 8: Placing the "open" Limit Switch
Step 10. I made a small wood block that would hang over onto the frame of the door and attached it with hot glue. Now let the door open to the maximum opening for your space and kill the power. Set the switch into place on the door frame so it is pressed closed against the block of wood and glue in place with hot glue. If you cover the photo resistor to make the door close and then uncover it, the door should stop when the block of wood contacts the switch. If not, kill power immediately and check placement of the switch. Once you are happy with the operation of the switch to shut off the motor when the door is fully open, use some brad nails to secure the switch through small holes in the switch body and add screws to the block of wood to secure it to the door.
Step 9: Installing a "pressure Bar" and the "closed" Limit Switches
Step 11. You could use a single switch when closing the door similarly to the “open” switch, but if anything interferes with the door so it doesn’t hit the closed switch, something will break. To try to prevent this, I used two pieces of wood approximately 3/4” wide that were about 1/4” shorter than the width of my door. I drilled two 1/4” holes in one [A] and smaller holes into the other piece [B] so that the holes lined up. I had some 2” bolts and threaded the bolts into the small holes in [B] through [A]. This allows [A] to slide on the bolts. Use a little hot glue to keep the bolts secured in [B]. Using hot glue, I attached [A] to the bottom of the door so that [B] hangs slightly below the door. I glued on a spacer by each bolt and glued a limit switch to the spacer so when either end of [B] is raised, one of the switches will shut off the motor. Once you are happy with the operation of the bottom rail to shut off the motor if anything interferes with the closing of the door, secure the switches with brad nails and rail [A] to the door with screws. I used some hot glue to secure the wires to the door so they wouldn’t tangle with the motor shaft.
Step 10:
Step 12. Adding extra photo resistors – carefully unplug the photo resistor from the daylight sensor. Using a small jeweler’s screwdriver or other pointy object, press out the tabs that hold the wires in the plastic plug and gently pry open the crimped ends of the connector. Solder a 6” piece of door bell wire to the connector. Be careful to not use too much solder since that will prevent the connector from going back into the plug. Do this for both wires. On the other end of the 6” leads, attach 2 extra photo resistors using wire nuts. Add more photo resistors as needed.
There will be a little trial and error to get the correct number of resistors for your location and to adjust the sensitivity control on the daylight sensor.
Final steps – You should be ready to install the coop door. I will be installing the controls in a plastic box on the outside of my coop so I can see the LEDs at night to know if the door is open or closed and for easy adjustment of sensitivity if needed. Route the wires as needed to get from the door assembly to the location where you want to mount the controls. At the very least, the photo resistors need to be installed outside or at a window facing out. Even if you don't put the controls outside your coop, I recommend putting them inside a box of some sort to keep them clean and free of moisture from the chickens.

Participated in the
Remix Contest
13 Comments
Question 2 years ago on Step 5
I followed the instructions and built it. I'm having problems with the power supply. I used the WII power supply and the door worked for 2 days, after that the supply was dead. I replaced another one with the same fate. I'm puzzle. Any suggestions?
Answer 3 months ago
I know you probably already got this fixed butt...
Most likely your power supply does not have enough amps to do this.Many manufactures will label their motors as "whatever" amps.
Let's say 2 amps. Same for the power supply. They label it 2 amps.
Here is the thing. While Motor manufacture will label the motor 2 amps, they fudge the truth, it is really a 3 or 4 amp motor. Why? Well it's all about profit. Why does this matter? While the motor WILL run, at most, 2 amps the startup is really around 3 to 4 amps.
While the power supply manufactures will also fudge the truth. That 2 amps they label it is MAX amps. If you try and run 2 amps all day it will kill that power supply.
Now let's put them together. That motor shoots up to 3 amps and settles, that 2 amp MAX PS might actually work a few times but it will die before too long.
Advice to you or anyone having this problem is either Buy a cheap wireless DC amps monitor or watch some youtube videos on how to read amps draw with a multimeter. Find out what the actual amps draw on that motor is. Get a power supply that puts out at least 1 amp higher than the MAX draw you find for your motor.
Last make sure you are not using too small of a wire. or too big. Too small or too big will also cause problems. Too small will make the the entire system work harder, and make the amps jump higher then they need to be. Too big, you get power loss.
Answer 2 years ago
Sorry, I don't know. The door I built has used the same power supply since I made it. Something that happened when I was testing it and running the door up and down a lot, the power supply shut itself off (I think it has temperature overload of some sort). After it cooled off, it was fine. I've since gotten rid of our chickens and sold the door to a friend, and he's still using it.
Reply 2 years ago
Thanks so much for responding to my question. I will recheck my wiring
Question 2 years ago
I'm just completing this build. Nice job. What is the effect of adding multiple photo resistors? Would it work to cut the wire to the existing photo resistor and splice in additional photo resistors instead of replacing the wire into the plug?
Reply 2 years ago
Hi. When I first was working on this, the door would go down a little before dark instead of a little after dark. I think that's due to using a car's auto headlight sensor and you want your headlights to come on earlier. Adding the extra photo resistors seemed to work to give the chickens a little more time to get inside before the door closed. I tried cutting the wire adding in more sensor that way, but the wire was so thin i couldn't strip it or tie it together, thus the more involved process. If you have a more elegant solution, I'd love to hear what you come up with.
Reply 2 years ago
I was talking with my wife about this discussion and realized that the wording of my response could be read as a sarcastic response. I really don't know much about electronics and if you come up with a simpler solution, I really would like to hear what you did. Hope your build is going/went well!
4 years ago
another way to do it is to use a solar activated water timer to drop water from a source into a bucket to hoist a door up. if short on water, change buckets.
connect to a solar powered water pump to keep a counterweight down, then when the sun goes down, the door closes again. you could use the same idea instead of the timer.
4 years ago
Nice. My chickens would get so mad when I wouldn't be there at the crack of dawn to let them out. This would solve that problem.
Tip 4 years ago
how about leds while its power is on so lights warn this while its moving aswell as the pressure bar
Reply 4 years ago
I never really considered that as part of this build since there's only the daylight sensor and the relay that control the action of the door. I may look into that if I ever need to rework mine in the future.
Question 4 years ago
is there a link to building the door frame
Answer 4 years ago
I don't have any build info for the actual door. It would be pretty easy to do if you have access to a table saw. I used a 2x4 and some 1/4" plywood when I first built the door. You'll need to base the height on what space you have available in your coop and cut one piece of 2x4 a couple of inches shorter than the available height. Rip the 2x4 into 2 equal pieces (about 1-3/4x1-1/2"). Then set the blade to make a 1/2" deep cut and starting in the center of the 2x4, cut a groove in both pieces and gradually adjust the fence to get a groove that the 1/4" plywood will slide in freely, but without too much extra space. You'll need to figure out how wide the door will be and cut another piece of 2x4 for that. Rip 2 - 1" pieces of of this chunk of 2x4 and screw them into top and bottom of each of the side pieces (be sure to slide in the plywood). The rest should be covered in this Instructable