Mobile Chicken Coop With Some Automation

32K12614

Intro: Mobile Chicken Coop With Some Automation

My wife and I have wanted to raise chickens(for the eggs) and we finally decided to do it this spring.  I have read a lot about pastured chicken and wanted to create a mobile coop so that the chickens would not destroy the yard.  I have a fairly decent sized yard for the burbs so I hope to move the coop every day or every other day if possible.  Hopefully there will be enough space to rotate efficiently   I am planning on using mobile fencing to limit the chickens to an area around the coop. This would be moved with the coop everyday as well.  So coming up with a system to make this simple is an important goal.

Also I have messed around with the Arduino over the years and thought it would be a great tool for reporting the temperature, water use and closing the doors at night.  I hope to use Zigbee to transmit the data back to a pc in the house, then display the data on a web page for remote viewing.  The general dimensions are 4 feet by 3 feet with a height of 5 feet on the high side and 4 on the low.  It will be raised 2 feet off the ground to keep the critters away and have less impact on the grass.


Items left(items will be removed as they are add to the instructable):
Update:
Still searching for some cedar shingles for the siding.

Added Roof Step 5
Added Door and Ramp Step 6
Added Electronics Step 7
Added Software Step 8

Automation(motor problems)




STEP 1: Building the Frame(lessons Learned)

The basic design was to build a frame similar to the slanted roof  in the example picture.  I initially used a pocket screw jig but it caused some serious structural integrity issues so I used small steel brackets.  I talked to one of my coworkers and he said I just did not set up the jig correctly.  Maybe in the future I will see if it can be used in a better manner.

STEP 2: Adding the Sides

We plan on added cedar shingles to the sides for aesthetics   Cedar shingles would not provide enough support or protection themselves on their own. So I decided to put 5.0mm plywood(subflooring) on the sides because it would be a good balance of weight and strength .  I did not want the coop to be too heavy and hard to move around the yard.

STEP 3: Perches and Nest Boxes

There is a 1 foot gap in the floor that two perches are mounted above.  One perch is placed directly over the gap and the other one in right front of the nest boxes so that the chickens can hop right in.  The gap is covered with 1/2' mesh to allow the chicken droppings to fall onto the grass instead of building up in the coop.

STEP 4: Attaching the Tires

The original and future designs will entail 4 wheels but due to budgetary concerns I just mounted two wheels on one side.  The coop can still be moved very easily by lifting the non-wheel side. 

STEP 5: Roof (and Painting)

Originally, there was no plan to paint the chicken coop, but the plywood that I used can easily disintegrate if it gets wet. We had some leftover exterior primer + paint, and my wonderful wife painted as much of the coop as she could before the primer + paint ran out. 

The roof is 40" x 52", and I was able to acquire some metal roofing that was 8 feet by 25".  I forgot that the longer of the two lengths was horizontal, not vertical, down the roof.  Fortunately, I was able to use 3 pieces.  I screwed in the outer two then glued the middle piece over the top, covering the screws.  The final dimensions of the roof are 48" x 60" with 4" of overhang on all sides.

STEP 6: Ramp and Door

The ramp and door have been a quandary   I have been trying to figure out the best way to automate the opening of the door and dropping of the ramp.  I went with a simple hinge setup for both the door and the ramp.  I have done some testing with the door opening mechanism, but the motor is stripping the wood.  I have not been able to figure out a ramp lift mechanism yet.

STEP 7: Electronics and Sensors

There are three sensors in the system: thermistor for temperature, capacitive sensor for  water level and contact sensor for door status.  All the sensors are connected to an Arduino Uno via a custom board I built..  Xbee communication is handled with an xbee shield from Sparkfun and an xbee adapter/FDTI cable from Adafruit.  Here is a great basic tutorial for Xbee.

Thermistor is just a standard NTC with a 10k pullup.  The water sensor is two pieces of aluminum on both sides of the water bottle.  One side is grounded, the other side is tied to the sense pin.  A 1 Mohm resistor is jumpered between the receive pin and sent pin.  The capsense library for Arduino makes this fairly straight forward.  The door sensor is just two piece of aluminum that connects the pin to ground when the door is closed.

STEP 8: Software

All of the code has been committed to github and can be found here.  The code is broken down into three parts: Arduino, Web and pc side.  Arduino reads the sensors then formats the data into a json message.  This is sent over Xbee to the laptop.  The python code reads the data saves it to a text file then uploads the file to the web server via ftp.  In the future I would like to have a way to push commands to the controller from the website.

I have been messing around with Dart, Google's attempt to replace Javascript and I like the syntax it is closer to C so I am more comfortable with it.  There seems to be a bug with the dart to javascript conversion so the website is not optimal in browsers that don't have the DartVM.  The webpage should auto-refresh every 10-30 seconds.

14 Comments

I am having trouble finding the shopping list.

You will not need a ramp for the chickens - once they understand this is home then they will return prior to dark - they are good jumpers and will launch themselves as long as the hole is not too small.

In relation to the door closing - you can use a 12v stepper motor - have a look at Sparkfun - nice and cheap and they have an easy driver module for it. Run them and the arduino off a 12v battery that you change out for charging once a week or with a solar panel.

I just have limit switches top and bottom for mine.

Currently my stepper motor uses wire to raise and lower the door - i am thinking of changing this to use a threaded bar as i have had the stainless wire fray where it runs through the limit switches.

Craig
How well is your water sensor working after its use so far? Also, this just sees if they have water or not, correct?
Have you a plan for making sure all chickens have returned before the drawbridge rises and the portcullis comes down? I've wanted to do this for years (as I want to keep chickens but still go to work without worrying about them).
Thanks, Duncan
You may want to correct your github link to:
https://github.com/Neuromancer2701/ChickenCoop

There are very cheap switches that are made to be operated by a closing door. They are made to switch a light in a closet on and off and such switches may be more reliable than 2 pieces of alufoil or a reed switch and magnet (reedswitches tend to magnetize after a while)
Those switches are a break contact on closing the door and a close on opening the door, but that is easily addressable in code
been working on this myself converting a 6x4 shed into a semi automated coop
Your pocket screws ripped out because your pockets were drilled to close to the end of the board. The pocket screws should alway come out in middle of the thickness of the board.  You have to move the jig towards/away from the end of the board to adjust for the thickness of the board and change the length of the screws you use.

The jig shown in the photo is clearly set up for 3/4" thick boards and you are using 1-1/2". The former is the standard thickness for cabinet case frames where most pocket screws are used.
Cool, just make sure the chickens don't know how to drive.
Very Cool, love the water sensor, I'll have to try that! I've got some Harbor Freight Solar panels on my coop for lights. I thought a maybe a lightweight pressure sensor for the food bowl could be good! I'm inspired, Thanks!! Nice work!
Yeah, I would love to do both of those ideas as well. Maybe even a heat lamp to control the temperature if it gets too cold. Ultimately I would love to be able to have electric fencing that could be folded into the side and then set out after the coop was moved.
Also for the door sensor a reed switch and magnet might work for you
just a thought, you could use a magnet on the door and a non latching hall effect sensor, such as diodes inc. ah180-pl-a, inside the coop. a neodymium magnet should reach through the plywood, keeping electronics out of the weather, whereas the foil will be exposed to water that drips down the side of the coop.
Yeah, that sensor was a bit of a hack. I really wanted to open and close the door on a timer but since I was unable to get the door mechanism working I just came up with an impromptu sensor.

Thanks for the feedback,
I've always wondered about doing this sort of thing, will watch with interest - thanks ;)