6 ms·
I've had my own design of one of these up and running for about 5 years now. I should probably write it up. I used a normal (non-stepper) motor with some gearb
by 3chelon 8y ago
I've had my own design of one of these up and running for about 5 years now. I should probably write it up.
I used a normal (non-stepper) motor with some gearbox I found in an old cassette player. The door limits are detected using reed switches.
It is solar powered, with a 12V lead-acid battery. I've had to replace that twice over the 5 years because winter tends to kill it. Since then I've added a winter trickle charge wire from the nearest outbuilding.
The solar panel voltage into an ADC provides the daylight reading. An Arduino Nano provides the main control functions. It spends a lot of time in sleep mode, waking every 5 minutes to check light levels, and at night sleeps until a preset time when it makes sense to start checking for daylight again.
It also has an XBee radio link to a Raspberry Pi which sends me email updates, keeps the Arduino's clock accurate (obviating the need for an RTC), and alerts me of any mechanical problems with the door mechanism. A common one is straw and other mess getting jammed in the door runners, and once a broken door mechanism.
Over the years I've tweaked the opening/closing times to account for the hens' habits, and for predators. I've learned that the dawn/dusk opening technique is not enough on its own, it needs to know the time of day also.
It opens at 6:30am or first light, whichever is latest. Too early in the summer and you're asking for fox trouble, and also the neighbours used to complain the cockerel would crow when it opened too early (sunrise can be before 4am in midsummer).
My hens go to bed very early, so it closes before dark, and again at least by 7:30pm in the summer because foxes can be active by then.
We live in the country and almost everyone near me has hens, but they rely on manual opening. They have all lost their entire flocks to foxes at least once in the time my automated door has been operational, but thankfully we have not. I have seen scratch marks on the sliding door indicating interested predators, but I think my timing is right to keep the coop closed when foxes are about.
- 3chelon 8y agoIf I was building it now I'd use an ESP8266 to replace the Arduino, XBee and RPi for a faction of the cost.
- bcheung 8y agoI'm wanting to use the ESP8266 more but most things I want to interface with are 5V so it is a little annoying have to incorporate logic level shifters. How you found an easier way to deal with it?
- 3chelon 8y agoThat's the same problem as Raspberry Pi. For output-only digital signals there are some 5V peripherals that will accept 3V3 input levels. And for input-only, you can use a potential divider. It's bidirectional where you need a proper level shifter. But you can get really small cheap ones. I've used them a lot on I2C interfaces. If you're careful you can design the entire system around I2C and then you only need a single level shifter. But I've not built many things around ESP8266 just yet. Still learning about it. It's an incredibly cheap and powerful platform though.
- brokenmachine 8y agoI believe lots of people have found it will cope with 5V but of course that's out of spec. They're only a couple of dollars if you burn one out though. I guess it comes down to how much hassle it will be for you if you need to replace the ESP8266.
- lostlogin 8y ago>It also has an XBee radio link to a Raspberry Pi which sends me email Nice. Slack is great for this sort of things and adds additional mute channel functionality for normal events. There is the odd service (eg Freshping) that will check it can ping your Pi, even when on your on a dynamic IP, and alert you to outages. Results also sent to Slack but not muted. I hope you have all the bad puns configured for your notification. “Chick in”, “chicken out”.
- rsync 8y ago"We live in the country and almost everyone near me has hens, but they rely on manual opening. They have all lost their entire flocks to foxes at least once in the time my automated door has been operational, but thankfully we have not. I have seen scratch marks on the sliding door indicating interested predators ..." We live on a very small island of private property inside a huge expanse of open space / wilderness and thus have very heavy predation on any animals we raise. In the case of our chickens, I just kept adding hot wires to the fence until nothing could get into the run. There are four hot wires now, two of which form a negative (back bending) slope. It is impossible for a thing to climb the fence now without touching (and holding) at least two hot wires. We've had our current flock for over a year with no losses, vs. losing every previous flock to raccoons and weasels every 2-3 months. I wonder if you would comment on this (seemingly successful) strategy - you seem to know what you're doing...
- 3chelon 8y agoThe problem with fences is the underground part. I have relatives in France whose chickens were all killed by a fox digging under the fence. They say you need as much fence under the ground as you have above it. Your problem with being really isolated is that the predators will not be afraid to come out in daylight. If I were going for a tech solution I might start thinking about detection systems... Or maybe just dogs?
- anon_cow1111 8y agoIf you're still having problems with the lead-acid battery, you might want to try swapping it out for NiCads at some point. The battery packs from cordless drills often contain these; they're just a bunch of 1.2v cells in series so you can always adjust the voltage manually.
- driverdan 8y agoDo you mean NiMH? NiCads are pretty outdated at this point. The cost of 18650s is so low now that I'd skip NiMH too. You can get free 18650 cells by going to your local landfill / dump and grabbing discarded laptop battery packs. They typically have a few bad cells with the rest reusable.
- leggomylibro 8y agoNiMH is a fantastic technology, but there are still advantages to using NiCad. NiMH batteries are notoriously fickle because it is very difficult to detect their charge state based on their voltage. Many chargers will just charge at something like 1.5V / 1A for an hour or two and expect you to drain the batteries between charges. NiCad batteries handle 'trickle charging' much better than NiMH ones, which usually degrade significantly with overcharging. So NiCads are still used in places like alarm backups, power tools, or off-grid applications where they might be connected to a charging circuit for long periods of time between discharges. And 18650 cells are great, but I would think carefully about using li-ion or li-po chemistries in areas where they will be exposed to the elements and unsupervised.
- AngryData 8y agoIm glad that works. By me a fox will show up at like 2 PM and dart out across the lawn to try and grab something. Thankfully it doesn't come by very often, but at the same time it means catching that mofo is near impossible.
- 3chelon 8y agoWow, that's bad news. Whereabouts in the world are you?
- CobrastanJorji 8y agoI wonder how much extra battery/computing power would be necessary to get a camera outside which could detect the immediate presence of a fox. Or maybe a simple motion sensor that would halt opening until there had been no motion on the outside for at least 15 minutes.
- 3chelon 8y agoYes I came pretty close to adding a PIR, but that was actually to catch rats that were coming in and stealing eggs. A camera with IR LEDs would work equally well, esp. if activated by a PIR.