Door security systems in government institutions generally still rely on conventional locks, which have several limitations, including the risk of being lost, easily duplicated, and the inability to automatically verify user identities. These limitations allow unauthorized visitors or individuals to enter restricted rooms without an authentication process, potentially disrupting office activities. This study aims to design and develop an automatic door locking system based on facial recognition using a Raspberry Pi as an alternative security solution. An experimental research method was employed by integrating a Raspberry Pi 3 Model B+, a USB camera, a 5V relay module, and a solenoid door lock as the hardware components, while the software was developed using the Python programming language, the OpenCV library, and the Local Binary Pattern Histogram (LBPH) algorithm for facial recognition. The proposed system detects a user's face and compares it with the registered facial database before automatically unlocking the door for authorized users. Experimental results indicate that the system achieved a facial recognition accuracy ranging from 40% to 90%, with performance influenced by lighting conditions, facial orientation, and the use of accessories such as eyeglasses. In addition, the system successfully controlled the automatic door locking mechanism according to the authentication results. Therefore, the developed system can serve as a practical and effective alternative to conventional door locking systems for improving access control in office environments
Copyrights © 2026