Automatic Pet Door - Shcematic Validation

Hi, Request to pleae help if the attached schematic I have made will work correctly for the following purpose. Any improvement to minimize parts are most welcome. Also need help in simulating the project

If BLE Tag on pet collar is read by ESP 32 and if door is closed, the door will open. If door is open, it will close. If door is closing and beam is broken, door will open.

Download Project Automatic Pet Door

Hello and welcome to the forum!

First off, let me help you to get help. I have downloaded your file and looked at it, and to be honest, I’m not really sure what I am looking at. In breadboard view, see a bunch of parts connected together, but I’m not sure why they are connected together. So I went into the schematic view and I found nothing useful in there, you haven’t done any work on that part yet. Schematics are basically the language of electronics, without one, you are basically speaking a foreign language that I don’t understand. You need to work in this area, and it’s basically like working in the breadboard view. Arrange components in some logical order, and connect the wiring.

By this, I mean group together parts that are related to each other. You have a barrel jack connector, 2 capacitors and a voltage regulator. That’s a power supply, so group them together and route the ratsnest wiring for those parts. Then maybe group the sensors together and route their wiring…

Second, I’m not sure of the operation, you might want to describe this in more detail:

I understand if the pet’s BLE is read by the ESP32 and door is closed it will open. What I don’t understand is the ’ If door is open, it will close. If door is closing and beam is broken, door will open.’. I understand that if the door is closing, and the beam is broken, open the door. The beam is broken by the pet walking in I assume?

Why not try - if the pet’s BLE is read by the ESP32 and door is closed, it will open. Once the ESP32 looses it’s connection to the pet’s BLE, it closes the door?

What are the magnetic sensors for? To detect the state of the door? Open door or Closed door sensors? You might be able to do away with them since you are using a stepper motor.

It’s an interesting project and I wish you luck with it!


I see an issue in this statement. If something other than your pet (i.e. no BLE Tag is present) breaks the beam the door will open. That appears to defeat the purpose of the BLE tag which appears to be to only allow your pet to enter via the door. After that the main problem I see is safety. Depending on how strong the stepper motor is (and probably even if the stepper isn’t strong enough to cause injury) you need to make sure that the beam sensor will catch a smaller object in the door (such as your pet’s tail flat on the floor or a paw which will likely be smaller than the pet) or alternately have a pressure sensor on the bottom of the door that will stop the door (and probably open it a bit to provide clearance to remove the blockage) when it encounters something such as you pet’s tail or a paw, when the door is closing. A sufficiently strong stepper motor may injure your pet if it manages to get a limb or tail under the door when the door is trying to close without a limit switch of some kind. So you need to check how much force the door can exert when closing and decide if it is enough to produce a danger, even not being able to get a tail or limb out from under the door may cause your pet to injure itself trying to do so.