Skip to main content

Real-Time Driver Drowsiness and Health Monitoring using Edge AI and Embedded Systems

Page 1


International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

Real-Time Driver Drowsiness and Health Monitoring using Edge AI and Embedded Systems

Dubey1 ,

2 ,

3 ,

4

1Department of Computer Engineering, Thakur Shyamnarayan Engineering College, Mumbai, Maharashtra

2Department of Computer Engineering, Thakur Shyamnarayan Engineering College, Mumbai, Maharashtra

3Department of Computer Engineering, Thakur Shyamnarayan Engineering College, Mumbai, Maharashtra

4Professor, Department of Computer Engineering, Thakur Shyamnarayan Engineering College, Mumbai, Maharashtra ***

Abstract - Fatigue-inducedmicrosleep remains oneofthe most critical catalysts for fatal highway collisions, particularly within the commercial transportation sector. Conventional Advanced Driver-Assistance Systems (ADAS) often depend exclusively on single-modality visual cues, which are highly vulnerable to environmental degradation such as low ambient cabin lighting or facial occlusions. To mitigate these vulnerabilities, this paper presents "SafeDrive," a localized, multimodal driver monitoring architecture that synergizes Computer Vision with Embedded physiological diagnostics. Operating strictly on an Edge AI framework to eliminate cloud-induced latency, the vision module utilizes the MediaPipe pipeline and OpenCV to extract 468 high-fidelity spatial landmarks at 30 frames per second. These coordinates dynamically compute the Eye Aspect Ratio (EAR) and Mouth Aspect Ratio (MAR) to quantify ocular closure and yawning behaviors. Concurrently, an Arduino Uno interfaces with a MAX30102 photoplethysmography (PPG) sensor to capture localized cardiovascular rhythms, applying a C++ based moving average filter to stabilize Beats Per Minute (BPM) against vehicular vibration. System integration is achieved through a dedicated serial handshake protocol; upon registering a continuous EAR depreciation below 0.18 for a 3-second temporal threshold, the Python master node transmits a high-priority byte signal to the microcontroller, instantly triggering a 5V acoustic alert. This dual-modality paradigm provides a zero-latency, fail-safe monitoring environment, offeringahighlyeconomicalADASretrofittingsolution.

Key Words: Edge AI, Driver Drowsiness, MAX30102, Eye Aspect Ratio, Photoplethysmography, Embedded Systems, Real-Time Monitoring.

1.INTRODUCTION

The continuous expansion of global supply chains has placed unprecedented physiological demands on commercial transit operators. Prolonged periods of monotonic highway navigation inevitably degrade cognitive alertness, frequently culminating in localized sleepepisodesknownas"microsleep."Amicrosleepevent, typically lasting between two to four seconds, completely severs a driver’s responsive capabilities. At standard

cruising velocities, this brief lapse results in the vehicle traversing substantial distances unguided, drastically amplifyingtheprobabilityofhigh-impactcollisions.

While the automotive industry has made significant strides in reactive safety protocols such as advanced airbag deployment and crumple zones proactive accident prevention remains a complex challenge. Contemporary driver monitoring systems are heavily skewed toward vision-based analysis, tracking eyelid proximity and head posture. However, these optical systems exhibit critical failure points. Visual processing algorithmsdegraderapidlyinsuboptimalilluminationand are frequently neutralized by physical barriers like polarized sunglasses or heavy facial hair. Conversely, physiological fatigue is not entirely dependent on visual manifestation; autonomic nervous system shifts, reflected in fluctuating heart rates, serve as highly reliable preindicatorsofsleeponset.

Addressing the inherent flaws of single-modality reliance, thisresearchproposesahybridsafetymatrix.Bycoupling real-timefacialtopographyanalysiswithcontinuous,nonintrusive cardiovascular tracking, the proposed architecture guarantees operational redundancy. A core objective of this project is to maintain absolute data sovereignty and execution speed by decentralizing the computational load. By processing all visual and physiological streams locally via Edge AI and embedded microcontrollers, the system fundamentally bypasses the transmission latency and bandwidth dependencies associated with cloud-based IoT solutions, ensuring instantaneousphysicalalertdeployment.

2. LITERATURE REVIEW

The trajectory of vehicular safety systems demonstrates a clear shift toward multi-sensor environments. Dewi et al. [1] provided the foundational geometric logic for ocular monitoring by standardizing the Eye Aspect Ratio (EAR). Their empirical analysis concluded that a static EAR threshold of 0.18 effectively flags true eye closure across varyingfocaldistances,establishingtheprimarytriggering mechanism forvision-basedprototypes. Shrestha etal. [2] expanded on this by validating the robustness of the Dlib

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

and MediaPipe libraries in handling diverse facial geometries, proving that high-density landmark mapping cansustainaccuracyevenamidstminorfacialocclusions.

To augment the predictive window of fatigue detection, Florez et al. [3] successfully integrated the Mouth Aspect Ratio(MAR)intoreal-timetrackingloops,determiningthat the onset of frequent yawning precedes microsleep by a marginof1.5to2.5seconds,effectivelyactingasanearlywarning buffer. However, the environmental fragility of opticalsystemswashighlightedbyDasetal.[4],whonoted that heavy shadowing necessitates alternative tracking methodologies.

This optical limitation has driven parallel research into unobtrusive biometrics. Wang et al. [5] systematically analyzedin-cabinsensorplacement,verifyingthatsteering wheelsandseatingfabricsareoptimalzonesforcapturing vital signs without disrupting driver ergonomics. Mattioli et al. [6] reinforced this by mapping the direct correlation between Heart Rate Variability (HRV) and cognitive exhaustion during extended driving simulations. Furthermore, Lin et al. [7] demonstrated that neural networks analyzing cardiovascular rhythms can predict sleepiness with a 94.35% accuracy rate before any visual droopingoccurs.

The architectural execution of these systems is equally critical. Essel et al. [8] emphasized the need for dynamic filtering to distinguish between actual fatigue and mere dashboard-glancing, necessitating temporal counter logic. Finally, Almodhwahi et al. [9] and Babusiak et al. [10] validated the necessity of Edge computing and localized hardware. Their respective studies proved that localized data parsing not only protects user privacy but strictly enforces the zero-latency response times required to preventhigh-speedtransitfatalities.

3. PROPOSED METHODOLOGY

The structural design of the system operates on a dualmodality framework, simultaneously processing spatial optical data and localized hardware signals before unifying them through a master-slave communication protocol.

3.1EdgeAIVisionDiagnostics

The primary tracking module relies on an uncompressed 720p visual feed processed natively within a Python 3.10 environment. Bypassing computationally expensive deep learning models that require dedicated GPUs, the system utilizestheMediaPipeframeworktogeneratea 468-point 3D topographical mesh of the driver’s face at a stable 30 FramesPerSecond(FPS).

To quantify fatigue, the algorithm isolates the periocular coordinates. The Eye Aspect Ratio (EAR) is computed dynamicallyusingtheEuclideandistanceformula:

Where the numerator represents the vertical distance between the upper and lower eyelids, and the denominatorrepresentsthehorizontalspanoftheeye.To prevent erratic false positives generated by natural physiological blinking (which occupies a fraction of a second), the architecture integrates a rigorous temporal gate. The system logic dictates that an actionable fatigue event is only validated if the EAR calculation remains submergedbelowthe0.18thresholdforapproximately48 consecutive frames, equating to a 3-second microsleep window.

3.2EmbeddedPhysiologicalFiltering

Functioning as the secondary fail-safe, the hardware subsystem is managed by an Arduino Uno. The microcontroller communicates via the I2C bus with a MAX30102 pulse oximetry module, utilizing integrated red and infrared photodetectors to capture Photoplethysmography (PPG) waveforms. Because the operational environment is a moving vehicle, raw PPG telemetry is highly susceptible to mechanical vibration and ambient noise. To extract actionable data, a continuous Moving Average Filter is executed within the embedded C++ codebase, stabilizing the signal arrays to outputaconsistentBeatsPerMinute(BPM)read.

3.3Master-SlaveIntegrationandAlertProtocol

The convergence of the AI and hardware streams is facilitated by an optimized serial handshake using the pyserial library. The Python environment acts as the master processing node, evaluating the EAR/MAR matrices. The Arduino functions as an asynchronous listenerpollingthelocalCOMport.UpontheAIconfirming a 3-second EAR breach, Python dispatches an encrypted single-byte trigger (e.g., '1') to the serial buffer. The microcontroller intercepts this payload and immediately interrupts its physiological monitoring loop to actuate a localized5Vactiveacousticbuzzer,shatteringthedriver's sleepstate.

4. SYSTEM REQUIREMENTS

To ensure scalability and ease of retrofitting, the component architecture utilizes highly accessible hardwareandopen-sourcesoftwarelibraries.

 Hardware Stack: Arduino Uno R3 Microcontroller, USB 720p Imaging Sensor, MAX30102 Pulse Sensor, 5V Active Piezo Buzzer, standardbreadboard,andjumpertelemetrylines.

 Software Stack: Python3.10,OpenCV,MediaPipe Framework, PySerial, and the Arduino Integrated DevelopmentEnvironment(IDE).

International Research Journal of Engineering and Technology (IRJET) e-ISSN: 2395-0056

Volume: 13 Issue: 04 | Apr 2026 www.irjet.net p-ISSN: 2395-0072

Fig-1:EmbeddedhardwaresetupfeaturingArduinoUno andactivebuzzer.

5. RESULTS AND DISCUSSION

Rigorous simulated testing of the integrated Edge AI and embeddedarchitectureyieldedhighlyfavorableoutcomes.

The MediaPipe optical tracking maintained a resilient 30 FPS inference speed without triggering thermal throttling on standard local hardware. The 3-second temporal counter logic successfully eliminated false alarms associated with rapid blinking or temporary head rotations.

Crucially, the decision to pivot away from clouddependent IoT logging resulted in profound latency improvements. The transmission gap between the algorithmic detection of the EAR breach and the physical actuation of the 5V hardware buzzer was reduced to a near-instantaneous millisecond margin. Furthermore, the physiological tracking proved durable; the MAX30102 successfully bridged the monitoring gap during simulated opticalocclusiontests(e.g.,coveringthecameralens).The entire hardware footprint was kept economically viable, with a total material cost falling well below ₹3000, confirmingitsstatusasahighlypracticalADASretrofitting kit.

6. CONCLUSION AND FUTURE SCOPE

The "Safe-Drive" methodology successfully substantiates the hypothesis that merging localized Computer Vision

with embedded physiological tracking yields a highly resilient, fail-safe monitoring paradigm. By aggressively localizing the computational workload to the Edge and utilizing a direct serial communication bridge, the architecture fundamentally resolves the latency constraints of remote cloud processing, guaranteeing the immediate intervention required in vehicular emergencies.

Looking forward, the evolution of this research will focus on advancing the physical ergonomics of the hardware. Future iterations aim to abandon external breadboard configurations by embedding dry-contact ECG and PPG arrays directly into a 3D-printed steering wheel chassis, facilitating completely invisible and continuous physiologicalprofilingforcommercialtransitoperators.

REFERENCES

[1] C. Dewi et al., "Eye Aspect Ratio for Real-Time DrowsinessDetectiontoImproveDriverSafety,"2022.

[2] S. Shrestha et al., "Real Time Drowsiness Detection SystemUsingFacialLandmarks,"2023.

[3] R. Florez et al., "A Real-Time Embedded System for DrowsinessDetection(EyesandMouth),"2024.

[4]S.Dasetal.,"IoT-AssistedDriverDrowsinessDetection throughFacialMovementAnalysis,"2024.

[5] J. Wang et al., "Unobtrusive Health Monitoring in PrivateSpaces:TheSmartVehicle,"2020.

[6] V. Mattioli et al., "IoT-Based Assessment of a Driver's StressLevel,"2024.

[7] C. Lin et al., "Early Driver Fatigue Detection System: WearableApproach,"2025.

[8] E. Essel et al., "Drowsiness Detection in Drivers Using FacialFeatureAnalysis,"2025.

[9] M. A. Almodhwahi et al., "A Facial-Expression-Aware EdgeAISystem,"2025.

[10] B. Babusiak et al., "Smart Steering Wheel Prototype forIn-VehicleVitalSignMonitoring,"2026.

Turn static files into dynamic content formats.

Create a flipbook