Visvesvaraya Technological University, Belagavi: "Anti Sleep Alarm For Drivers and Engine Cutoff"
Visvesvaraya Technological University, Belagavi: "Anti Sleep Alarm For Drivers and Engine Cutoff"
Belagavi
Submitted By
Page | 1
Page | 2
ACKNOWLEDGEMENT
Firstly, we would like to express our sincere gratitude to the almighty for his solemn
presence throughout the project work.
We express our sincere gratitude to Dr. Thejaswi A. H., Professor, Head of the
Electrical and Electronics Engineering Department for providing us with adequate
facilities, ways and means by which we are able to complete this Mini project work.
We would like to express a deep sense of gratitude and thanks profusely to our
Mini-project guide Mr/Mrs. . Maheshwarappa H M, Assoc/Asst. prof. Department
of Electrical and Electronics engineering for her/his proper guidance and valuable
suggestions. Without her/his wise counsel and able guidance, it would have been
impossible to complete the project work in this manner.
Also, we would also like to express our sincere gratitude and special thanks to
the principal Dr. K Nagendra Prasad and Dean Academic Dr. P Manjunatha for
providing an opportunity to carry out this Mini-project work.
Finally, we would also like to express our gratitude to Jawaharlal Nehru New
College of Engineering for providing us with all the required facilities without which the
project work would not have been possible.
Project associates,
Name 1: Adarsha Nadiger 4JN20EE002
Name 2: Darshan K J 4JN20EE012
Name 3: Darshan K Y 4JN21EE013
Name 4: Kedareshwara Swami K C 4JN21EE021
Page | 3
Abstract :
As such, there is a high demand for cheap and efficient driver sleep
detection. Therefore, we came up with an idea and successfully
developed a sleepy detection and alarming system, which could
effectively meet this demand.
Page | 4
TABEL OF CONTENTS
ACKNOWLEDGEMENT
ABSTRACT
LIST OF FIGURE
LIST OF TABELS
Chapter 1: Introduction………………………………………………………………………………………............6
General introduction/theoretical background etc..
Chapter 2: Literature survey………………………………………………………………7
2.1 problem Statement…………………………………………………………….8
2.2 Objectives……………………………………………………………………………………………………9
Chapter 3: Methodology…………………………………………………………………10
3.1 circuit diagram /block diagram ………………………………………...11-16
3.2 Design and Implementation ……………………………………………..17-18
Includes all software details /flowchats
3.3 Code used for aruino………………………………………….…………19-22
3.4 Output of the project ………………………………………………………..23
Chapter 4: Results and Discussions……………………………………………………...24
All results are discussed
Chapter 5: Advantages and disadvantages……………………………………………25-27
Chapter 6: Conclusion and Future Scope
6.1 Application ……………………………………………………………………28
6.2 Conclusion …………………………………………………………………….29
6.3 Future scope…………………………………………………………………..30
6.4 Reference……………………………………………………………………...31
Page | 5
Chapter 1
INTRODUCTION
In this mini project we proposed a ………………………………...
❖ The goal of this project is to develop a system that can accurately
detect sleepy driving and make alarms accordingly, which aims to prevent
the drivers from drowsy driving and create a safer driving environment.
The car accident is the leading cause of death, killing around 1.3 million
people each year. Most of these accidents are caused by driver distraction
or drowsiness. Drowsiness decreases the driver's concentration, activity,
alertness, and alertness, and causes the driver to make slow decisions and
sometimes not make decisions. Drowsiness affects mental alertness and
reduces the driver's ability to drive a vehicle safely and increases the risk
of human error, which can lead to death and injury .
The error rate for the driver had decreased. Countless people drive long
distances on the road day and night. Lack of sleep or distractions such as
talking on the phone, talking to the passenger, etc. can cause an accident.
To avoid these accidents, we propose a system that will warn the driver if
they are distracted or drowsy. Accident due to driver drowsiness can be
prevented using eye blink sensor. There are two main components here in
this project. First is Arduino nano which is the heart of the project. And the
second one is eye blink sensor. The driver has to wear the eye blink sensor
frame throughout the course of driving and the eye blink has to be for some
particular amount of second to detect drowsiness or sleep. The outcome is
that the vibrator attached to the eye blink sensor’s frame vibrates if the
driver falls asleep and a buzzer will beep for sound indication. So there is
audio and vibration indication for the driver if he falls asleep.
Page | 6
Chapter 2
LITERATURE SURVEY
[1] paper 1:
• "Real-Time Eye Blink Detection System for Drivers using Arduino
Microcontroller" by S. S. Khatri, S. Singh, and A. Tiwari (2019): This
paper presents a real-time eye blink detection system for drivers using
Arduino microcontroller. The system uses infrared sensors to detect eye
blinks and can be used to prevent accidents caused by driver fatigue.
[2] paper 2:
• "Real-Time Eye Blink Detection and Tracking using Arduino and
OpenCV" by J. J. Lin, Y. J. Hsieh, and C. C. Wu (2017): This paper
presents an eye blink detection and tracking system using Arduino and
OpenCV. The system detects eye blinks in real-time and can be used in
various applications such as driver fatigue detection and medical
diagnosis.
[3]paper 3:
• Swapnil Titare, Shubham Chinchghare,K N Hande, “driver Drowsiness
Detection and alert system “. International Journel of Scientific Research
in Computer science, Engineering and Information Technology
(IJSRCSEIT),issn:2456-3307,Volume 7,Issue 3,pp.583-588,May-June-
2021
[4]paper 4:
• Arpit Agarwal, “Driver Drowsiness Detection System”, portfolio of
projects on human computer interaction, December,2010.[5] Paul
Stephen Rau, National Highway Traffic Safety Administration, United
States, Paper Number05-0192 Drowsy Driver Detection and Warning
System for Commercial Vehicle Drivers: Field Operational Warning
System for Commercial Vehicle Drivers: Field Operational Test Design,
Data Analyses and progress.
[5]paper 5:
• Weirwille, W.W. (1994). “Overview of Research on Driver Drowsiness
Definition and Driver Drowsiness Detection,” 14th International
Technical Conference on Enhanced Safety of Vehicles.
Page | 7
[2.1]Problem statement:
Develop an anti-sleep alarm system for drivers with an additional engine cutoff
feature to enhance road safety.
Driving while fatigued or drowsy poses a significant risk to road safety, as it
increases the likelihood of accidents due to delayed reactions and impaired
judgment. To address this issue, there is a need for an advanced anti-sleep alarm
system for drivers. The system should effectively detect signs of drowsiness or
fatigue in real-time and alert the driver, preventing potential accidents.
Page | 8
[2.2]Objectives:
1. Early Detection of Drowsiness: The system should effectively monitor driver
behavior and detect signs of drowsiness or fatigue in real-time, allowing for
timely intervention before the situation escalates into a potential accident.
4. Engine Cutoff Mechanism: In extreme cases where the driver fails to respond
to the alarm and continues to exhibit signs of extreme fatigue or sleepiness, the
system should automatically disable the engine, bringing the vehicle to a safe
stop to prevent accidents and ensure the driver's safety.
By achieving these objectives, the anti-sleep alarm system with an engine cutoff
feature aims to reduce accidents caused by driver fatigue, prioritize road safety,
and protect the well-being of both the driver and other road users
Page | 9
Chapter 3
Methodology:
1. Hardware Setup:
a. Gather the necessary components: Arduino Nano, sensors (e.g., eye
monitoring sensor, accelerometer), buzzer or speaker, LED indicators, and
necessary connecting wires.
b. Connect the eye monitoring sensor and accelerometer to the Arduino Nano
following the sensor's specifications and pin connections.
c. Connect the buzzer or speaker to the Arduino Nano for generating the alarm
sound.
d. Connect LED indicators for visual alerts (optional but recommended).
2. Software Development:
a. Install the Arduino IDE and ensure the Arduino Nano is properly
recognized by the computer.
b. Develop the software code for the anti-sleep alarm system using the
Arduino programming language (C/C++).
c. Use appropriate libraries to interface with the eye monitoring sensor and
accelerometer, reading their data and detecting signs of drowsiness or fatigue.
Page | 10
[3.1]Circuit diagram:
Page | 11
Components used:
1. Arduino nano:
Page | 12
2. Eye blink sensor:
An eye blink sensor, also known as an eye blink detector or eye blink
module, is a device used to detect and monitor the blinking of a person's
eyes. It is often used in applications such as eye interfaces, drowsiness
detection systems, and wearable devices. controlled There are different
types of eye blink sensors available, but one common approach is to utilize
electroocu lography (EOG) principles. EOG is a technique that measures
the electrical potential difference between different points around the eye,
which changes when the eye blinks. Here's a general overview of how an
eye blink sensor based on EOG works: Electr odes Placement The sensor
typically consists of one or more electrodes that are placed around the eye.
These electrodes pick up the electrical signals generated by eye movement
and blinking. Signal AmplificationThe weak electrical signals picked up
by the electrodes are usually amplified using a specialized amplifier circuit.
This amplification stage helps to make the signals more discernible and
easier to process.
Signal Processing: The amplified signals are then processed using signal
processing techniques to extract meaningful information related to eye
blinks. This processing can involve filtering out noise, detecting blink
patterns, and determining the timing and duration of blinks. Output
Generation: Based on the processed signa ls, the eye blink sensor generates
an output, which can be in the form of a digital signal, an analog voltage
level, or a triggering event. This output can be used to control other devices
or systems, depending on the specific application. Eye blink senso rs can be
interfaced with microcontrollers or other electronic devices to enable
integration into larger systems. For example, in an eye controlled interface,
the sensor's output can be used to navigate through menus or control the
Page | 13
movement of a cursor on a computer screen. It's worth noting that eye blink
sensors have different levels of complexity and sensitivity, and their
performance can vary based on the specific design and implementation.
Advanced eye often utilize more sophisticated tracking systems techniques,
such as infrared light and image processing, to achieve higher accuracy and
precision in detecting eye blinks
3. Relay model:
The relay model is commonly used and has a 5V DC coil voltage. It features a
throw (SPDT) configuration, allowing it to switch between one common
terminal, one normally open terminal, and one normally closed terminal. It can
handle a switching current of up to 10A. s important to consider factors such as
contact configuration, current and voltage ratings, and application requirements
when selecting a relay for your specific project. Refer to the datasheets and
technical specifications of the relay models you are considering for detailed
information on their capabilities and suitability for your application
Relays are designed to handle different voltage and current ratings based on
their specific application requirements. They can also have additional features
such as multiple sets of contacts, built-in diodes for suppressing voltage spikes,
and various mounting options.
The control signal for a relay can come from various sources, such as a switch,
a microcontroller, or other electronic devices. By using a relay, a low-power
control signal can safely control a high-power load, providing isolation between
Page | 14
the control circuit and the load. This isolation is particularly useful in
applications where the control circuit operates at a different voltage level or in
environments with high voltage or current levels
Overall, relays play a crucial role in electrical and electronic systems by
providing reliable and safe switching capabilities, allowing for the control of
larger loads using smaller control signals.
[4]Dc motor:
A mini DC motor, also known as a direct current motor, is an electric motor that
converts electrical energy into mechanical energy. It is widely used in various
applications, including robotics, toys, fans, and small appliances
The basic construction of a mini DC motor consists of several key components:
Armature: The armature is the rotating part of the motor. It typically consists of
a shaft, a commutator, and a set of windings. The windings are made of copper
wire and are wound around an iron core. Commutator: The commutator is a
cylindrical assembly of metal segments, usually made of copper. It is connected
to the armature shaft and acts as a mechanical switch to change the direction of
the current flowing through the armature windings.
Brushes: The brushes are conductive contacts that press against the commutator
segments. They supply electrical current to the armature windings as the
commutator rotates.
Permanent Magnets: Mini DC motors usually have permanent magnets that
provide a constant magnetic field. These magnets are stationary and surround
Page | 15
the armature, creating a magnetic field that interacts with the current flowing
through the armature windings.
When electric current is applied to the motor, it flows through the armature
windings, creating a magnetic field. This magnetic field interacts with the
permanent magnets, causing a rotational force (torque) on the armature.
[5]Piezo buzzer:
Page | 16
[3.2]Implementation:
To implement an anti-sleep alarm for drivers and an engine cutoff using an
Arduino Nano, you would need a few components and follow these general
steps.
components ratings
1.Relay 1
2.Piezo buzzer 1
3.Arduino nano 1
4.Eye blink sensor 1
5.Gear motor 1
6.Wheel 1
7.Spst switch 1
8. 9v battery 2
9.Wires required
Page | 17
Flowchart:
Page | 18
[3.3]Code used for Arduino:
define Relay 13
#define buzzer A0
static const int sensorPin = 10; // sensor input pin
int SensorStatePrevious = LOW; // previousstate of the sensor
void setup() {
Serial.begin(9600); // Initialise the serial monitor
Page | 19
pinMode(sensorPin, INPUT); // set sensorPin as input
Serial.println("Press button");
pinMode(Relay,OUTPUT);
pinMode(buzzer,OUTPUT);
}
Serial.println("Button pressed");
}
Page | 20
// Calculate how long the sensor has been activated
SensorOutDuration = currentMillis - SensorLongMillis;
void loop() {
Page | 22
[3.4]Output of the project:
Page | 23
Chapter 4
The results indicate that the fatigue detection module accurately identifies driver
drowsiness based on the collected sensor data. The alarm module effectively
alerts the driver using visual and auditory signals, ensuring prompt attention and
response. In cases where the driver did not respond to the alarm, the engine
cutoff module successfully deactivated the engine, preventing potential
accidents.
Discussion :
The developed system holds significant potential for integration into vehicles,
particularly long-haul trucks, commercial buses, and other transport vehicles
where driver fatigue is a common concern. It could also find applications in
personal vehicles, promoting safer driving practices and reducing the risk of
accidents caused by drowsiness.
Page | 24
Chapter 5:
Advantages :
An anti-sleep alarm for drivers and engine cutoff using an Arduino Nano can
offer several advantages in terms of driver safety and vehicle maintenance. Here
are some key benefits:
Page | 25
met, such as excessive speeding, sudden braking, or collision detection. Engine
cutoff adds an extra layer of safety by preventing further movement of the
vehicle in potentially dangerous situations.
It's important to note that while an anti-sleep alarm and engine cutoff system
can provide significant safety benefits, they should not replace responsible
driving practices and regular rest breaks. These systems are intended to
complement driver awareness and serve as preventive measures, but it's still
crucial for drivers to prioritize their well-being and adhere to proper sleep
schedules for safe driving.
Page | 26
Disadvantage :
While anti-sleep alarms for drivers and engine cutoff systems using Arduino
Nano have several advantages, there are also a few potential disadvantages to
consider:
[1]. False alarms: Anti-sleep alarms rely on various sensors to detect signs of
drowsiness or inattentiveness. However, these sensors may not always
accurately determine the driver's state. False alarms can occur due to sensor
malfunctions or misinterpretation of data, leading to unnecessary distractions
and potential annoyance for the driver.
2. Limited effectiveness: While anti-sleep alarms can help mitigate the risk of
accidents caused by fatigue, they are not foolproof. In some cases, drivers may
become habituated to the alarm or find ways to disable or ignore it, rendering
the system less effective over time. Additionally, the alarm may not be able to
detect microsleep episodes or situations where the driver remains technically
awake but still lacks focus.
[3]. Reliance on technology: The effectiveness of anti-sleep alarms and engine
cutoff systems is dependent on the proper functioning of the technology
involved, including the Arduino Nano and associated sensors. Technical
failures, such as software glitches, hardware malfunctions, or power supply
issues, can compromise the system's reliability and pose safety risks if the driver
relies solely on its functionality.
[4]. Lack of human judgment: While anti-sleep alarms and engine cutoff
systems can provide timely alerts and take preventive actions, they do not
possess human judgment or situational awareness. There may be instances
where the driver's judgment or decision-making ability is essential, such as in
emergency situations or unpredictable road conditions. Over-reliance on
automated systems may lead to complacency and a decrease in the driver's
ability to react appropriately in critical situations.
Page | 27
Chapter 6
1. Long-distance truck drivers: Truck drivers often cover long distances, leading
to extended periods of driving, which can increase the risk of driver fatigue. An
anti-sleep alarm can be particularly useful in this context to prevent accidents
caused by drowsiness. It can continuously monitor the driver's alertness and
provide timely alerts to keep them awake and focused on the road.
Page | 28
[6.2]Conclusions :
Page | 29
[6.3]Future scope:
The future scope of an anti-sleep alarm for drivers and engine cutoff using an
Arduino Nano or similar microcontroller is quite promising. As driver fatigue
and drowsiness are significant contributors to road accidents, the development
and implementation of such safety systems are crucial.
1. Enhanced Detection Algorithms: Future anti-sleep alarms can utilize
advanced detection algorithms, incorporating machine learning techniques to
analyze various driver-related parameters, such as eye movements, head
position, facial expressions, and even biometric data like heart rate variability.
This would allow for more accurate and reliable detection of drowsiness or
fatigue.
2. Integration with Vehicle Systems: Anti-sleep alarms can be integrated with
other vehicle systems, such as advanced driver-assistance systems (ADAS) or
telematics units. This integration would enable real-time monitoring of driver
behavior and provide a holistic approach to driver safety. For example, if
drowsiness is detected, the system could activate adaptive cruise control or
trigger an audiovisual warning for the driver.
3. Data Logging and Analysis: By incorporating data logging capabilities, future
anti-sleep alarm systems can collect and store driver behavior data for analysis.
This data can be used for identifying patterns of fatigue, analyzing driving
habits, and developing personalized safety recommendations. The analysis of
this data can help in understanding the causes of drowsiness, improving the
effectiveness of the alarm system, and promoting better driving practices.
4. Integration with Mobile Applications: With the increasing prevalence of
smartphones and wearable devices, anti-sleep alarm systems can integrate with
mobile applications to provide additional functionalities. For instance, the
system could send alerts or notifications to the driver's smartphone, initiate
emergency calls to predefined contacts, or even sync with fitness tracking apps
to provide health-related insights.
5. Customization and User Experience: Future systems can focus on providing a
personalized user experience, allowing drivers to customize alarm sensitivity,
alarm types (auditory, visual, haptic), and preferences for engine cutoff. Such
customization options would make the system more user-friendly and adaptable
to individual driver characteristics and preferences.
Page | 30
[6.4]Reference :
[1] paper 1:
• "Real-Time Eye Blink Detection System for Drivers using Arduino
Microcontroller" by S. S. Khatri, S. Singh, and A. Tiwari (2019): This
paper presents a real-time eye blink detection system for drivers using
Arduino microcontroller. The system uses infrared sensors to detect eye
blinks and can be used to prevent accidents caused by driver fatigue.
[2] paper 2:
• "Real-Time Eye Blink Detection and Tracking using Arduino and
OpenCV" by J. J. Lin, Y. J. Hsieh, and C. C. Wu (2017): This paper
presents an eye blink detection and tracking system using Arduino and
OpenCV. The system detects eye blinks in real-time and can be used in
various applications such as driver fatigue detection and medical
diagnosis.
[3]paper 3:
• Swapnil Titare, Shubham Chinchghare,K N Hande, “driver Drowsiness
Detection and alert system “. International Journel of Scientific Research
in Computer science, Engineering and Information Technology
(IJSRCSEIT),issn:2456-3307,Volume 7,Issue 3,pp.583-588,May-June-
2021
[4]paper 4:
• Arpit Agarwal, “Driver Drowsiness Detection System”, portfolio of
projects on human computer interaction, December,2010.[5] Paul
Stephen Rau, National Highway Traffic Safety Administration, United
States, Paper Number05-0192 Drowsy Driver Detection and Warning
System for Commercial Vehicle Drivers: Field Operational Warning
System for Commercial Vehicle Drivers: Field Operational Test Design,
Data Analyses and progress.
[5]paper 5:
• Weirwille, W.W. (1994). “Overview of Research on Driver Drowsiness
Definition and Driver Drowsiness Detection,” 14th International
Technical Conference on Enhanced Safety of Vehicles.
Page | 31
Page | 32
Page | 33