Home CAM Face Recognition Door Lock

Home CAM Face Recognition Door Lock


Home CAM Face Recognition Door Lock

Hello friends, welcome to distribution. In this video we’ll make a smart door lock system with face recognition, using ESP 32 cam. Let me show you how the circuit works fast to enroll my face. As you can see, it will take some sample picture to enroll the face, you can enroll multiple phase. After that, whenever it will detect any enroll phase, it will unlock the door and interface doesn’t match with the enroll phase, it will not unlock the door. As you can see whenever it detects my face, it is unlocking the door. So does this arcade walks, and during the video I will share the circuit diagram, the code for this project, and I’ll explain how the circuit works in details. So after watching this video you can easily design this project for your home.


Now these are the components required to make this ESP 32 cam project, but before making the circuit first we have to program this ESP 32 gram board. For that, I will use this, ftdi, 232, USB to serial interface board, and we’ll connect these two board as per the circuit diagram. Now I will connect this ESP 32 cam with my laptop to upload code. Now before uploading the code, you have to copy this URL, and then go to File, reference. And here you have to paste it. I also shared the details in the description. No, you have to go to those then old manager, and from the code manager you have to install ESP 32.You can see I’ve already started. After that, you have to come down and you have to insert a Wi Fi credential to type my Wi Fi name and Wi-Fi password, then go to Tools and select ESP 32 role model board. And you have to select the settings here in the partition scheme we have to choose huge app, and select a port. And after that click on Upload button to upload the code. I’ll explain this code in details at the end of the video. Now after uploading the code first add to name a piece where which connect GPIO zero which ground.


Now, I have to go to serial monitor. And here I have to choose 115200 prod Great. Now if I press the reset button. You can see showing me the IP. I have to type this IP in the browser to see the stream, which we’ll see later, after uploading the code to disconnect the ESP 32 cam. And now we’ll make the circuit and the circuit diagram will will look like this. Now in this circuit will supply 12 volt DC at the input, and I abused seven eight to five voltage regulator to supply five volts to ESP 10 to cam. And with this tip one to two transistor will control this 12 volt electronic clock. As you can see the base of the transistor is connected into GPIO 12. And these two led are connected with EPA 14, and GPIO 13, and these diode is important to protect the transistor from the negative pulse, as we have used a solenoid electronic lock here. You can also download the circuit from our website and unmade a circuit underpaid board. Now our lg 12 volt supply to the circuit. And you can see the radial returns on number and go to browser and type the IP address.


Now here, if I click on the Start stream. You can see the stream started. Now to enroll face. First I have to turn on this face detection and face recognition, and then click on the indoor face button. Now we will click some sample picture to encode a face, as you can see. Now, here you can see, after detecting my face, it will unlock the door, and there is six second delay. After that, it will lock the door again. And let me show you again, again, detect my face and brain energy, turn on and accordingly. Normally, unlock. Those, you can enroll multiple face. But if the face doesn’t match with the enrolled face, it will not unlock the door. As you can see, now we’ll discuss the code which I have used for this ESP 32 project. Now let me explain this code. In this port fast with lifting the camera model Chaya views in this project. In, we are defining the GPIO pin. Here you can see for the lock. I’m using a tool is connected with the GPIO 13, and green reduce GPIO 14.And after that, we are entering the Wi Fi credential. And then we are defining this match phase Boolean variable. And initially it is false.


Now, if I go to these. APP underscore HTTP dot app file. And if I search for that variable. Here you can see they’re also defined in here. And if I go down. And then, if the detected phase match with the enroll phase, then match it will be returned zero, and it will come to this IP block. Now, in this IP block you can see, first we have been talking. Hello subject, which the match ID. And then, we are making this match face variable to prove. Now if I go to this main code again. And here you can see the default setup. if I go to directly for loop. In the void loop First, we are checking if the match phase is true and open lock is false, then we’ll go to this IP block. And in this IP block First, we’ll unlock the door. Then we’ll turn on the green Lt. And Dr Aden. Then, put a predefined delay, the door will be unlocked.
Then, after the delay time over, it will go to this IP block. As you can see, and it will lock the door. Turn off the visibility and turn on the radio at. So like that this program works. Whenever any detected phase match with enrolled phase, the match phase variable will become true, and then it will go to this IP block, and unlock the door for six seconds. So I hope you have understood how this pays repopulation smart locks it works. And if you face any problem during this project, please let me know in the comment section.



Leave a Comment

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