The Petting Problem
We currently have three cats, one dog and one pet door. Note: Click on any picture to see a larger view.
The Mischievous Mutt
Toby, our two year old Labrador needs access to the backyard anytime, day or night for access to his food, water and other amenities.
The Clutter Kittens
Bazyl and Kismet, are free to go out during the day (sometimes even encouraged) however in an ideal world the pet door would only allow them to come in, but not out again after dark.
The Wanderer Murray, the venerable 17 year old veteran of the family who has a habit of going walkabout. At this stage in his life, it would be best if he stayed indoors.
Our pet door, that allows the rabble to go out on the deck and into the backyard. The door is fixed in a wooden panel in the frame of what was originally a window.
So basically we need something that is able to stop the door swinging outwards during the evening, except when Toby is in proximity,
and any time Murray is in proximity. We don’t need to worry about foreign cats coming into the house (you’ve met Toby, yes?) and if we really want to lock the dog out we put the barricade in place as shown below. (We soon learnt that the little plastic lock on the door is not gonna stop him if he really wants in!)
I’m planning on using an Arduino board as the control unit, and think I need
two RFID tag – one for Toby and one for Murray – at the minimum to handle the rules I’ve outlined above.
So the preliminary parts list is:
One Arduino controller board.
One light sensor for sensing daylight hours.
One RFID scanner.
Two RFID tags that can be attached to the animals’ collar.
One solenoid or something else that can be used to stop the flap opening to the outside.
A red/green LED to indicate if the door is currently locked or not.
A three state switch to enable us to set the door to always open, always locked, or on automatic as required, although we expect it to be on automatic most of the time.
The concerns I have are finding the right RFID scanner and tags that’ll work in this environment. I’ve no experience with RFID but hear a bit about range issues. One tag will be on the collar of a big Labrador, the other on a medium sized cat, so there is a reasonable height difference. The proximity sensing cannot be flaky for this to work, especially for Toby who will get confused if the door only works some of the time and just not bother.
I have been considering an ID-12 or ID-2 scanner with a custom antenna, but people I’ve talked to think the range will be too small. The size difference between a domestic cat and a Labrador is fairly significant in this case.
Another option might be bluetooth. This would also have the advantage that it could act as a true proximity sensor, detecting when the animal comes into range, remains in range, and goes out of range, whereas RFID is generally triggered once each time the tag comes into range after not being in range. The disadvantage is batteries.
Any other ideas for proximity sensors?
The other thing is the mechanism to block the door. Ideally something that can shoot out out a little bolt to block the path of the door, or retract it to leave the door clear to open. Preferably not something that is spring loaded that needs an active voltage on it to either hold it open or hold it closed. Should only need to apply voltage to change state, not maintain state.
If a bolt is not available, I’ve seen a stepper motor with a bit of metal on the spindle used to do the same thing. To lock it simply rotates the bit of metal into place, to unlock is rotates it out the way.
UPDATE 2009/11/02: Some smart people over at stackexchange also had some good suggestions on a locking mechanism. Adam suggested using a linear actuator, and Zklapow had the novel idea of taking apart an old CD drive and using the workings that slides the tray in and out. And his suggestion reminded me that this isn’t the first time a CD drive has been used as part of an access control system either!
So, any and all feedback on the above would be welcome. Once I’ve figured out all the bits I need, I’m planning on again visiting the friendly folk at Melbourne Hackerspaces to get help on sourcing the parts and get up to speed on the fun world of Arudino programming (this time I’ll remember to bring my laptop.)
UPDATE 2010/01/17: Have finally ordered most of the parts I need for this, as well as the hermit crab tank humidity control, which I’ll probably build first (‘cause it’s simpler). I went with an ID-20 RFID scanner to start with, so we’ll see how that goes. Unfortunately, my copy of Practical Arduino which I’ll be using as a reference apparently wont arrive until mid-Feb so progress will be slow before then.