Cat Door with Pet Recognition


This project employs computer vision to ensure that your cat will have exclusive entry access to your home. The door is motion-activated, and will unlock only when it detects a cat door with pet recognition

As an exercise, you can extend this project by implementing any of the following features:

  • A user interface to view photos of animals that tried to re-enter the house.
  • A dashboard that displays information on the frequency of your cat’s comings and goings.
  • An option to re-train the classifier using images of your cat.
  • A text-messaging system that sends images of animals blocked from entering the house, with the option for a reply to manually override the classifier’s decision.

Initial Setup

1. Set up your PC and Raspberry Pi or MinnowBoard according to these instructions.

2. Plug in your USB webcam, keyboard, and mouse into your device.

3. Next, wire up the PIR motion sensors, servos and LEDs as shown below. The servos will be used to lock and unlock the door.

4. Turn on your device, and follow these instructions to enable Lightning on your device.

Hardware Setup

Cut one end of each servo plate with a saw so that it’s flush with the edge of the servo, as shown in the image below. This will enable the pet door to open completely without hitting the servo plates.

Next, drill holes at the top of the pet door to house the LEDs and motion sensors. The holes should be slightly larger than each sensor.

Finally, use a 3D printer to print off two servo connectors and, if you want, a half case. We’ve provided a MinnowBoard half case in our attachments.

Attach the servo connectors to your servos on the side of the door opposite the existing stoppers. This allows your servos to control the opening and closing of the pet door.schematic cat door with pet recognition

Software Setup

1. Use Command Prompt to navigate to the folder where you want the project:

cd <your folder path>

2. Run the git clone command to download the project:

git clone

3. Open the PetDoor.sln solution file, in the PetDoor folder you just downloaded, using Visual Studio 2017.

4. Download OpenCV, build it, and add the built binaries to your project by following these instructions.

For more detail: Cat Door with Pet Recognition

About The Author

Ibrar Ayyub

I am an experienced technical writer holding a Master's degree in computer science from BZU Multan, Pakistan University. With a background spanning various industries, particularly in home automation and engineering, I have honed my skills in crafting clear and concise content. Proficient in leveraging infographics and diagrams, I strive to simplify complex concepts for readers. My strength lies in thorough research and presenting information in a structured and logical format.

Follow Us:

Leave a Comment

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

Scroll to Top