Minor Final Report
Minor Final Report
The undersigned certify that they have read and recommended to the Institute of
Engineering for acceptance, a project report entitled “VEHICLE THEFT
DETECTION AND REMOTE ENGINE LOCKING SYSTEM WITH FACE
DETECTION” submitted by:
In the partial fulfillment of the requirements for the degree of Bachelor’s Degree in
Electronics, Communication and Information Engineering.
……………………….. ………………………..
Project Supervisor Project Supervisor
Er. Ajaya Shrestha Er. Anisha Pokhrel
Department of Electronics and Computer Department of Electronics and Computer
Engineering Engineering
……………………….. ………………………..
Academic Project Coordinator External Examiner
Er. Amit Kumar Rauniyar Er. Chaitya Shova Shakya
Department of Electronics and Computer Senior Lecturer
Engineering Kathford International College of Engineering
and Management
7 March , 2025
III
COPYRIGHT
The author has agreed that the library, Advanced College of Engineering and
Management, may make this report freely available for inspection. Moreover, the
author has agreed that permission for extensive copying of this project report for
scholarly purposes may be granted by the supervisors who supervised the project
work recorded herein or, in their absence, by the Head of the Department wherein the
project was done. It is understood that recognition will be given to the report's author
and the Department of Electronics and Computer Engineering, Advanced College of
Engineering and Management for any use of the material of this project report.
Copying publication or the other use of this project for financial gain without the
approval of the Department an author’s written permission is prohibited.
Request for permission to copy or to make any other use of the material in this report
in whole or in should be addressed to:
Head of Department
Department of Electronics and Computer Engineering
Advanced College of Engineering and Management
Balkhu, Kathmandu
Nepal
IV
ACKNOWLEDGEMENT
We would like to express our profound gratitude and deep regards to our respected
supervisor Er. Ajaya Shreshta, for his insightful advice, motivating suggestions,
invaluable guidance, help, and support in the successful completion of this project and
also for his constant encouragement and advice throughout our Bachelor's program.
We express our deep gratitude to Er. Prem Chandra Roy, Head of the Department of
Electronics and Computer Engineering, Er. Dhiraj Pyakurel, Deputy Head,
Department Of Electronics and Computer Engineering, Er. Amit Kumar Rauniyar,
Academic Project Coordinator, Department Of Electronics and Computer
Engineering, for their support, co-operation, and coordination.
The in-time facilities provided by the department throughout the Bachelor's program
are also equally acknowledgeable.
We would like to convey our thanks to the teaching and non-teaching staff of the
Department of Electronics & Communication and Computer Engineering, ACEM for
their invaluable help and support throughout Bachelor’s Degree. We are also grateful
to all our classmates for their help, encouragement, and invaluable suggestions.
Finally, yet more importantly, We would like to express our deep appreciation to
our grandparents, parents, and siblings for their perpetual support and
encouragement throughout the Bachelor’s degree period.
V
ABSTRACT
Vehicle theft is still a major problem globally and has negative impacts on the growth
of various economies and the escalation of insecurity. The objective of this project is
to create an elaborate solution towards vehicle theft prevention and detection by
implementing a sophisticated tracking system that fosters real-time monitoring,
real-time anomaly identification, and remote locking of the vehicle’s engine. When
integrating the GPS technology, Machine learning algorithms and IoT connectivity in
the proposed system, protection from vehicle theft is ensured.
The system will have a portable device that will be fitted in the vehicle for
parameters, and status among others. Information gathered from these sensors will be
analyzed in real time in an effort to detect any suspicious activity using machine
learning. In a situation of a possible theft, the user will be alerted through a GSM
module linked to the car’s mainframe.
Furthermore, there will also be an added feature for the device to implement that is
the remote engine locking to which the owner of the vehicle can use to lock and
disable the vehicle in case of theft verification. This will even enhance the probability
of vehicle recovery greatly while at the same time reducing the amount of harm or
loss as much as possible.
The success of the project will require that the software will be tested extensively to
establish whether the software is dependable and efficient in the delivery of the
desired information and easy to use by various classes of users. The objective in the
long run is to give the owners of the vehicle and the customers a very efficient and
high end theft protection system that can easily assist in recovery and above all bring
a sense of security to the owners.
VI
TABLE OF CONTENT
TITLE PAGE
LETTER OF APPROVAL........................................................................................III
COPYRIGHT.............................................................................................................IV
ACKNOWLEDGEMENT.......................................................................................... V
ABSTRACT................................................................................................................VI
TABLE OF CONTENTS..................................................................................... …VII
LIST OF FIGURES AND TABLES.......................................................................... X
LIST OF ABBREVIATIONS/ACRONYMS...........................................................XI
CHAPTER 1
INTRODUCTION
1.1 Background........................................................................................................ 1
1.2 Motivation.......................................................................................................... 1
1.3 Statement of Problem......................................................................................... 2
1.4 Project Objective................................................................................................ 2
1.5 Significance of Study......................................................................................... 2
CHAPTER 2
LITERATURE REVIEW............................................................................................ 3
CHAPTER 3
REQUIREMENT ANALYSIS.................................................................................... 5
3.1 Hardware Used................................................................................................... 5
3.1.1 GSM Module.............................................................................................5
3.1.2 LCD Display............................................................................................. 6
3.1.3 Motor......................................................................................................... 6
3.1.4 Motor Driver............................................................................................. 7
3.1.5 Raspberry-Pi..............................................................................................7
3.1.6 Raspberry-Pi Camera Module................................................................... 8
3.1.7 Servo Motor...............................................................................................8
3.1.8 Switch........................................................................................................9
VII
3.1.9 Voltage Source(Battery)............................................................................ 9
3.2 Software Used.................................................................................................... 9
3.2.1 Adafruit_PureIO......................................................................................10
3.2.2 OpenCV/dlib........................................................................................... 10
3.2.3 PySerial................................................................................................... 10
3.2.4 Python......................................................................................................11
3.2.5 Raspbian.................................................................................................. 12
3.2.6 SIM800A Firmware................................................................................ 12
3.3 Functional Requirements..................................................................................12
3.4 Non-Functional Requirements......................................................................... 13
CHAPTER 4
METHODOLOGY.....................................................................................................16
4.1 Flowchart..........................................................................................................16
4.2 Flowchart Description...................................................................................... 16
CHAPTER 5
SYSTEM DESIGN AND ARCHITECTURE..........................................................20
5.1 Block Diagram................................................................................................. 20
CHAPTER 6
RESULT AND ANALYSIS........................................................................................23
6.1 Results............................................................................................................. 23
6.1.1 Facial Recognition...................................................................................23
6.1.2 Servo Motor (Door Locking/Unlocking)................................................ 23
6.1.3 Engine Start (Switch Interaction)............................................................ 23
6.1.4 SMS Alert System................................................................................... 24
CHAPTER 7
CONCLUSION, LIMITATIONS AND FUTURE ENHANCEMENTS................25
7.1 Conclusion........................................................................................................25
7.2 Limitations....................................................................................................... 25
7.3 Future Enhancements....................................................................................... 26
VII
REFERENCES........................................................................................................... 27
APPENDIX A: SOURCE CODE..............................................................................28
VII
LIST OF FIGURES
Title Page
Figure 3.1 : GSM Module............................................................................................ 5
Figure 3.2 : LCD Display(2x16).................................................................................. 6
Figure 3.3 : Motor........................................................................................................ 6
Figure 3.4 : Motor Driver............................................................................................. 7
Figure 3.5 : Raspberry-Pi............................................................................................. 7
Figure 3.6 : Raspberry-Pi Camera Module.................................................................. 8
Figure 3.7 : Servo Motor.............................................................................................. 8
Figure 3.8 : Switch....................................................................................................... 9
Figure 3.9 : LiPo Battery..............................................................................................9
Figure 4.1 : Flowchart showing Vehicle Theft Protection and Remote Engine
Locking System............................................................................................................16
Figure 5.1 : Block Diagram of Vehicle Theft Protection and Remote Engine Locking
System.......................................................................................................................... 20
Figure 6.1 : Final Prototype........................................................................................ 24
X
LIST OF ABBREVIATIONS/ACRONYMS
1.1 Background
Vehicle theft is on the rise and conventional methods of protecting our vehicles tend
to be ineffective against the new breed of thieves. Recent development in digital
technology in general and IoT in particular promise new avenues to improving on the
security of automobiles through real time monitoring, better detection and remote
control. Recent development trends are directed at the integration of machine learning
of anomalies, and remotely controlled actions. The purpose of this project is to design
and implement a Vehicle Theft Detection and Remote Engine Locking system with
Face Detection capabilities; these measures will ensure the vehicle owners’ safety and
security.
1.2 Motivation
Increasing Vehicle Theft Rates: Research has indicated that the numbers of vehicle
theft have risen over the years which consequently affects the owners monetarily and
emotionally. This is because modern thieves are not easily scared by the existing
security systems in place, marking such a system as inadequate.
Enhanced Security and Convenience: Vehicle owners look for this security
considering that their assets are on the line. An integrated system that will have real
time status updates informing its users about the status of their vehicle, face detection
and over the internet control of the engine will go a long way into making the vehicles
secure and giving their owners that much needed control and safety.
1
Economic Impact: Apart from personal consequences, it has a ripple effect on the
society through loss of property through theft, insurance costs, and expenses incurred
in combating theft and recovering stolen vehicles. Enhancing the features of vehicle
security systems offer an approach of minimizing these economic losses by cutting on
theft cases and increasing the rates of recovery.
With the current increase in vehicle theft cases across the globe, society requires an
efficient means of deterring intrusion and theft. Classical systems of car theft
protection do not offer the option of real-time monitoring and do not allow the car
owner to control the car’s situation in real-time, which makes the car remain exposed
to theft. The following are some of the defects, which this project is seeking to cover
by offering a complete theft detection and prevention system.
● To develop a real-time vehicle theft detection system with Raspberry Pi, GSM,
and face detection for SMS alerts and remote engine locking.
2
CHAPTER 2
LITERATURE REVIEW
Vehicle theft is one of the oldest problems with vehicles all over the world, resulting
in millions of losses and so much stress. NICB stated that there are significant trends
of vehicle thefts, especially in recent years, reaching thousands of stolen vehicles.
These papers argue that many forms of conventional security are ineffective against
modern forms of theft, mechanical locks, and alarm systems being particular
examples.. This literature review explores the existing body of knowledge on Vehicle
Theft Detection And Remote Engine Locking with Face Detection, focusing on their
benefits, challenges, and the overall impact on the electoral system.
Smith et al. (2018) mentioned that common security features in cars such as
mechanical locks, alarms, and even electronic immobilizers are the fundamental
forms of security that may not protect the car from modern theft techniques. These
methods can be worked around or avoided, which highlights the necessity of utilizing
modern tech-based approaches for addressing contemporary car theft. [1]
According to Green, H. (2019), remote engine locking is crucial; it helps the owners
to secure their vehicles from theft by the use of a beep code to block the engine. This
has been observed to work effectively on the cases of theft occurrences. However,
issues like dependency on the networks and with threat to cybercrimes and hacking
also to be controlled to make it a safer and reliable option. [2]
.
In their article of June, 10, Harrison, P. (2020) progresses by explaining how
smartphone features increase both comfort and security while in a car. Other features
of this technology include locked engine systems via apps on smart phones and
receipt of real-time notifications. By doing so, the general security of vehicles is
boosted and cases of thefts are reduced through use of this technology. [3]
3
T. Quinn (2019) emphasizes the problems of face detection technology in vehicle
security like differences in light conditions, facial recognition rate, and fake faces. To
overcome these problems and make face detection really effective and secure, further
flexible algorithms have to be created and progression in AI and the use of machine
learning should be used. [4]
Regarding privacy issues of using biometric security systems like face detection in
cars, Walker, J. (2019) explains about it. To mitigate the privacy risks, it is then
possible to have effective policies as well as efficient technical controls that would
enhance the protection of personal information.[6]
This paper analyzes the improvements brought by IoT integration on vehicle security
by allowing real time connection and remote control through a cluster of smart
devices, as put by Zimmerman, P. (2020). Such connectivity enhances vehicle safety
by offering adaptive as well as indefinite security measures. [7]
4
CHAPTER 3
REQUIREMENT ANALYSIS
5
3.1.2 LCD Display
The LCD which is part of the project in this work gives the status and alerts in the
security system of the vehicle. Powered by the Raspberry-Pi, it makes the user
interactive by providing necessary information about the system status, any intruder
alert, updated status which makes monitoring as well as controlling very easy.
3.1.3 Motor
In this project, the motor serves as the actuator for the engine lock mechanism. It
responds to commands from the central control unit, that is the Raspberry Pi, to run or
stop the engine.
6
3.1.4 Motor Driver
In the project, the motor driver is between the Raspberry Pi and the motor concerned
with controlling the engine lock. It translates the control signal for voltage and current
corresponding to accurate and effective motor control for the effective engagement
and disengagement of the engine lock according to the command received. This
component allows for the remote controlling of the vehicle’s engine while boosting
the security measures against unlawful controlling of the car.
3.1.5 Raspberry-Pi
The primary role of Raspberry Pi in this project is to handle the data from the camera
for face detection and to interact with the GSM module in order to send alerts and for
controlling the engine locking through the relay module. Able to control and manage
GPIO pins for control and interfacing of sensors and modules together with
processing power required to run basic software for face recognition and other related
items with web and mobile interfaces for remote control.
7
3.1.6 Raspberry-Pi Camera Module
Raspberry Pi Camera module is used to capture high resolution images. Connected to
the Raspberry Pi, it allows for proper facial recognition so as to tighten up security
since all the rightful individuals gain access, while the intruders are easily detected.
8
3.1.8 Switch
In the project, a switch is employed as the input to on/off the operations of the various
aspects of the system. For instance, it can be employed to activate/ deactivate the
security systems, to manually switch the engine’s lock/ unlock mode or in case of
system failure; to restart the system. This switch is connected to the microcontroller
like Raspberry which forms a humble interface between the user and the system and
makes an additional layer of security.
9
e. Raspbian
f. SIM800A Firmware
3.2.1 Adafruit_PureIO
Adafruit_PureIO is a lightweight Python library designed for I2C communication on
single-board computers like the Raspberry Pi. It provides a pure Python
implementation of I2C interactions without requiring C extensions. This makes it
useful for interfacing with I2C-based devices, such as 16x2 LCD displays with an I2C
adapter, sensors, and other peripherals. The library is often used in projects that need
simple I2C communication without the overhead of full GPIO libraries.
3.2.2 OpenCV/dlib
One of the key modules that were used in the project is face detection and recognition
and for this purpose, there are libraries OpenCV and dlib. OpenCV (Open Source
Computer Vision Library) indicates an application for real-time image operations such
that the presence of faces in the captured video stream by the camera can be
determined. This is supplemented by dlib, a machine learning library that can be used
to enhance facial recognition, constantly identify the legal users and distinguish them
from intruders. Combined, these libraries allow the security system to efficiently and
accurately identify and authenticate people’s faces which are very important when
identifying people and preventing intruders from accessing a restricted area.
3.2.3 PySerial
PySerial serves as a Python library to connect computers or Raspberry Pi devices
through UART as well as USB or RS-232 for serial communication with external
hardware. Through serial port communication PySerial facilitates data transfer which
becomes vital for operations with GSM modules (SIM800A) as well as
microcontrollers (Raspberry-Pi, Arduino, ESP32) and related serial-based devices.
The SMS sending and network status functionality in addition to message receiving
functionality of your project depends on PySerial to execute AT commands towards
the SIM800A and read its responses.
10
3.2.4 Python
Python is a general-purpose language that is high-level, interpreted as well as is quite
famous for being easy to comprehend. Python was developed by Guido Van Rossum
in the late 1980s and can be used in almost all fields such as web development, raw
computing, and artificial intelligence. Here's a brief overview of its features:Here's a
brief overview of its features:
a. Readability: Python also is chosen because it is designed to have a very
readable code, and their code syntax is very easily understandable even for the
first time users or programmers and at the same time is very effective even for
experienced users.
b. Easy to Learn and Use: Python is easy to learn due to its characteristic features
such as the simple language syntax. It is a large community with lots of
documentation, guidelines and support materials that the learners can access.
c. Interpreted and Interactive: Python is an interpreted language and the code is
line by line and therefore it is easier to debug and to test. It also has an in-built
terminal where you can copy the code, and see its output immediately it runs
it.
d. High-Level Language: Python hides numerous intricate specifics; it has a
complete set of built-in data types and types dynamically, offering developers
less to worry about, more of what to do.
e. Extensive Standard Library: Python has simple syntax and is extremely
versatile and flexible and also comes equipped with a large standard library
that contains modules and functions that can be used to perform a multitude of
tasks ranging from working with data structures to implementing protocols of
the internet which makes the development process a lot faster.
f. Versatility: Python is used in a wide array of fields and areas of interest such
as web development, scientific computations, artificial intelligence and
machine learning, automation, data analysis scripts and so on.
However, Python is considered to have the advantages of simplicity and readability,
large-scale support and extensive library, which also makes it suitable for both green
hand and the senior engineers of all types of fields.
11
3.2.5 Raspbian
In the project, Raspbian is the operating system for the software to be installed in a
Raspberry Pi. This enables it to offer a stable platform for executing software such as
face detection algorithms and control scripts while dealing with hardware and its
interfaces. Through the operating system of Raspbian, the security system performs
optimally thus allowing for monitoring and controlling of the system from a remote
location.
In a Vehicle Theft Detection and Remote Engine Locking System with Face
Recognition project, functional requirements describe requirements that present how
the system has to perform to achieve its goals. Here are some functional requirements
for this project:
12
b. Include a set of override controls for the permitted personnel..
3. Real-time Alerts and Notifications:
a. Send SMS alerts to the vehicle owner using the SIM800A Firmware
when unauthorized access or suspicious activity is detected.
4. System Arming and Disarming:
a. Employ a switch by turning it on to activate the security system or
turning it off to deactivate the security system.
5. Power Management:
a. Make certain that all elements are provided with enough power
through the help of a good battery.
b. Monitor the state of the supplied battery and inform the user of the
remaining battery power.
6. Secure Communication:
a. Employ SIM800A Firmware for light weight, safe and high throughput
communication in between the parts and different distant interfaces.
The non-functional requirements of the Vehicle Theft Detection and Remote Engine
Locking System with Face Detection project include:
1. Performance:
a. Face detection/ recognition should take not more than a few seconds in
the system.
b. The alert in the form of text message should be activated as soon as
there is such abnormality access from unauthorized entities.
2. Reliability:
a. The system should also be up and running all the time with minimal
chances of failures and system crashes.
b. Parts should withstand significant levels of performance and should
not be affected by environmental factors such as heat, humidity, etc
3. Security:
a. All interacted communiques, especially those containing control
commands should be encrypted.
13
b. The system should employ ways and means to secure the physical
components of the system and the software from unauthorized access
or changes.
4. Scalability:
a. The system should also be modular in the sense that further sensors or
modules could be added if necessary without extensive redesign.
b. It should be applicable to one or many vehicles or grow to a fleet
management solution if needed.
5. Usability:
a. The graphical user interface whether as an LCD, mobile or through the
web should be quite easy to operate.
b. Users should be able to Power On / Power Off the system and get
alerts.
6. Maintainability:
a. This means that the components which make up the system should be
in a modular manner, to allow for easy fixing and replacement.
b. Updating of the software should be straightforward; such that there is
no interference with the flow of the system.
7. Compatibility:
a. Ideally the system should cater for minimum model and type of
differing automobiles.
b. Ideally, it should be complemented with different types of hardware
connections, including and especially different types of sensors and
communication interfaces.
8. Power Efficiency:
a. It should also incorporate measures to ensure that its power
consumption is reduced as drawing power from the car’s battery is
undesirable.
b. It should have low power consuming modes when the car is idle for
some time or is not in use most of the time.
9. Scalability:
a. The system should be able to grow and additions should be made to
support the features or accommodate more vehicles.
14
b. It should be able to accommodate the load and moreover support
proper communication without compromising its performance.
10.Response Time:
a. It is desirable for the system to give quick responses to the commands
given by the user as well as to the events it asynchronously discerns.
b. Alerts and updates refer to the processes of providing the necessary
information on time so that appropriate action could be taken.
11.Legal Compliance:
a. The aspects of vehicle security systems and data protection must
correspond to the current laws and standards of the countries where the
system is to be used.
b. It should meet industry standards for electronic and communication
devices.
15
CHAPTER 4
METHODOLOGY
4.1 Flowchart
Figure 4.1 : Flowchart showing Vehicle Theft Protection and Remote Engine
Locking System
This flowchart represents the Vehicle Theft Detection and Remote Engine Locking
System with Face Detection. It outlines the process as follows:
16
● If the owner chooses to lock the engine, the system prevents vehicle
access.
● If the engine remains unlocked, the unauthorized user may attempt to
start it.
5. End – The process concludes based on the decision made.
The methodology for developing the Vehicle Theft Detection and Remote Engine
Locking system involves a structured approach to ensure systematic development,
testing, deployment, and validation. Here’s a detailed methodology outline for the
project:
17
3. Implementation
i. Software Development:
a. Develop software modules for complete system functionalities
(face recognition, engine locking).
b. Implement communication protocols (SIM800A Firmware) for
real-time data exchange.
ii. Hardware Integration:
a. Assemble final hardware components into a cohesive system.
b. Ensure proper wiring, connections, and power management.
4. Testing and Validation
i. Unit Testing:
a. Test individual components (sensors, actuators) for
functionality and accuracy.
b. Verify software modules for expected behavior (edge cases,
error handling).
ii. System Integration Testing:
a. Integrate hardware and software components to validate
system-wide interactions.
b. Perform end-to-end testing of core functionalities (face
detection, engine locking, SMS alerts).
5. Deployment
i. Field Testing:
a. Install the system in a controlled environment or test vehicle.
b. Conduct extensive field tests to evaluate performance under
real-world conditions (accuracy of face detection, reliability of
SMS alerts).
6. Compliance and Security
i. Compliance:
a. Ensure compliance with relevant industry standards and
regulations (data privacy, vehicle security).
b. Adhere to best practices for electronic device deployment and
operation.
18
ii. Security Measures:
a. Implement robust security measures (encryption, access
control) to protect sensitive data and prevent unauthorized
access.
19
CHAPTER 5
SYSTEM DESIGN AND ARCHITECTURE
The development of a Vehicle Theft Detection and Remote Engine Locking System
with Face Detection involves the integration of various instruments and sensors. To
achieve this, a preliminary block diagram of the Vehicle Theft Protection and Remote
Engine Locking System is presented below:
Figure 5.1 : Block Diagram of Vehicle Theft Protection and Remote Engine Locking
System
20
a. Raspberry Pi
The Raspberry Pi serves as the central control unit in this project, managing:
Camera data for face detection, interaction with the GSM module for alerts
and engine control via the motor driver, GPIO pins for interfacing, processing
power for running face recognition and related software.
e. Motor
In the project, the motor is used as the engine lock actuator; therefore, it
receives instructions from the Raspberry Pi to move the engine.
21
h. Switch
The switch located in the project acts as input where client interacts with
operations of the system; and includes functions like; starting all the security
systems and changing the mode of the engine lock. It improves security and
offers an option of a manual override incase of failure of the automated
system.
22
CHAPTER 6
RESULT AND ANALYSIS
This project achieved results by establishing a Vehicle Theft Detection and Remote
Engine Locking System based on facial recognition technology. Users need to
complete multiple steps for vehicle security through the system because it requires
face scanning with entry access and remote door unlocking and engine start along
with SMS alert-based remote engine control.
6.1 Results
6.1.1 Facial Recognition
The facial recognition system accurately scanned and verified authorized users. Upon
detecting an authorized face, the system allowed the user to unlock the door
(simulated by the servo motor). The authorized user could then insert the key (press a
switch) to start the engine. If Unauthorized users were detected, the system kept the
door locked. A message was sent to the authorized user via SMS, alerting them to the
attempted theft.
23
6.1.4 SMS Alert System
SMS alerts through the SIM800A GSM module delivered detection of unauthorized
faces to authorized users. Through this capability the owner received instant alerts
enabling immediate response to the situation. The system enabled users authorized by
the system to respond to SMS messages that unlocked the engine remotely or
performed other security functions on the vehicle. The system delivered extra security
benefits through its remote control features.
24
CHAPTER 7
CONCLUSION, LIMITATIONS AND FUTURE
ENHANCEMENTS
7.1 Conclusion
The system successfully integrated facial recognition security with servo motor door
unlocking and remote SMS automated control features for vehicle protection. The
surveillance system guaranteed vehicle protection because authorized individuals
obtained access to start the engine although it enabled owners to execute remote
controls during unauthorized engine starts. The strong system performance was
accomplished through its accomplishment yet additional enhancements to facial
recognition, hardware durability and real-time operations would lead to even better
functionality for real-world implementations.
7.2 Limitations
a. Facial Recognition Accuracy: The facial recognition system worked
effectively through regulated settings but its accuracy levels became affected
by lighting variations and facial positioning including expressions. A solution
could be developed through the implementation of complex machine learning
tools that would enhance precision when operating across different
environments.
b. Hardware Limitations: As the project has proved the functionality of the
servo motor it remains ambiguous whether this solution would be compatible
for actual automotive applications. A practical application of the vehicle
requires an advanced locking system like electronic solenoid locks to
adequately secure the vehicle against unauthorized [Link] engine start
mechanism through switch operation functioned as displayed but would need
an ignition system replacement in industrial application.
c. SMS Delays: Network conditions produced occasional delays in the SMS
system operation. The delivery delays from SMS functions did not impact
25
basic capabilities but they could become problematic when responding
urgently to unauthorized access attempts.
b. Multiple User Support: The system architecture should be adapted for adding
different user permissions which would allow family members or other trusted
individuals to gain access to the system.
c. Real-World Engine Locking: The system would become practical for
automotive production when the servo motor is replaced with stronger locking
technology such as solenoids or electronic mechanisms.
26
REFERENCES
27
APPENDIX A: SOURCE CODE
import cv2
import face_recognition
import time
import serial
import subprocess
import pigpio
from [Link] import VideoStream
from smbus2 import SMBus
from RPLCD.i2c import CharLCD
28
ser = [Link]("/dev/serial0", baudrate=9600, timeout=1)
# Initialize camera
vs = VideoStream(usePiCamera=True).start() # Set False for USB camera
[Link](2.0) # Warm-up time
# Flags
servo_rotated = False # Ensure servo rotates only once
unauthorized_detected = False # Prevent repeated SMS alerts
29
# Function to run the motor continuously
def run_motor():
print(" Motor Started")
update_lcd("Engine Unlocked")
[Link](3)
update_lcd("Motor Running")
[Link](IN1, 1) # IN1 HIGH
[Link](IN2, 0) # IN2 LOW
pi.set_PWM_dutycycle(ENA, 128) # Set PWM speed (50%)
30
print(" 📩 SMS Sent Successfully!")
update_lcd("SMS Sent")
except Exception as e:
print(f"⚠ SMS Error: {e}")
update_lcd("SMS Error", str(e))
try:
31
print("System Ready - Listening for Face & SMS Commands...")
update_lcd("System Ready...")
while True:
frame = [Link]()
if frame is None:
continue # Skip if no frame
face_locations = face_recognition.face_locations(rgb_small_frame)
face_encodings = face_recognition.face_encodings(rgb_small_frame,
face_locations)
if face_locations:
print(" Face Detected - Checking Identity...")
update_lcd("Face Detected")
[Link](3)
update_lcd("Verifying...")
[Link](2) # Short delay before processing
if match[0]:
verification_status = "Authorized"
update_lcd("Access Granted")
[Link](3)
update_lcd("Unlocking Engine")
32
unauthorized_detected = False # Reset flag
print(" Authorized Face - Unlocking Engine")
33
except KeyboardInterrupt:
print("\n Stopping System...")
update_lcd("System Stopping")
[Link](3)
update_lcd("Goodbye!")
set_servo_angle(0) # Reset servo to 0°
stop_motor() # Stop motor
[Link]() # Disconnect pigpio
[Link]()
[Link]()
34
35