Content uploaded by Arun Prasad
Author content
All content in this area was uploaded by Arun Prasad on Mar 11, 2019
Content may be subject to copyright.
2014 International Conference on Recent Trends in Information Technology
978-1-4799-4989-2/14/$31.00 © 2014 IEEE
Adaptive Headlight System for Accident Prevention
Shreyas S1, Kirthanaa Raghuraman1, Padmavathy AP1, S Arun Prasad2, G.Devaradjane3
Madras Institute of Technology, Anna University
Chennai, India
11992shreyas@gmail.com,1kirthan18@gmail.com,1anupaddu1993@gmail.com, 2 arunprasadmit@gmail.com,
3deva@mitindia.edu
Abstract—This paper focuses on the design and working of a
microcontroller based Adaptive Headlight System (AHS) for
automobiles. The main purpose of this system is to present a cost
effective technique to illuminate blind spots while driving in the
night and during the times when the visibility is reduced
significantly so as to make the objects visible in those darkened
locations and thereby prevent accidents. The system functions in
accordance to the controlled input from Atmel AT89S52
microcontroller unit which drives the stepper motors connected
to the headlights. The system is also designed to receive input
from the indicator switch wherein a full turn is achieved by the
headlight mirror when the indicator input is given. Also, the
adaptive headlights are automatically switched on when the
amount of light measured by a photo diode falls below a
threshold, thereby eliminating the need for the driver to switch
on the headlights.
Keywords— Headlight system; Accident mitigation in vehicles;
Embedded systems; Microcontroller; Blind spot elimination;
Stepper motor;
I. INTRODUCTION
Accidents during night have become very common in the
current scenario. Automobiles have headlights that lights up
the road in front of the vehicle and fails to provide
illumination at bends. Reasons like lack of visibility, inability
to view objects at the corner of a turn have plagued
automobile drivers during late night travel. To overcome these
situations, several mechanisms have been sought after to
mitigate once an accident occurs but there were not much
solutions proposed to prevent an accident even before it
occurs.
The main reason for accidents in roads having steep turns
and curved roads in hilly areas is due to the presence of blind
spots. Blind spots are the areas around the vehicle that cannot
be directly observed by the driver. These areas cannot be seen
directly by looking forward or by looking through either of the
side mirrors. Blind spots may occur due to inappropriate
positioning of the vehicles’ side mirrors, thickness of the A-
pillar, height and width of the vehicle, etc. Other causes of
blind spots are steep curves in roads, lack of visibility due to
weather conditions etc. Blind spots can occur due to the
condition of the driver as well. Poor infrastructure, like
improper street lights create problems for the driver, especially
in the highways. These blind spots must be eliminated for safe
driving.
Temporary blindness of the driver can occur due to
dazzling of headlamps. Dazzling occurs when the headlights
of the vehicle coming in the opposite direction falls directly
into the eyes of the driver. This result in the driver being
blinded for some time and in turn increase the probability of
accidents. This problem is more prevalent when the road is
curved. A vehicle with normal headlights sends the light rays
tangential to the curve. Thus, the probability of dazzling of
lights in the eyes of the driver of the vehicle coming in the
opposite direction is very high. This driver, with his eyes
momentarily blinded, can go off the curve and off the road and
create a major accident, hence, killing him and others on the
road.
There are also instances where the driver fails to switch on
the head lamp during night or when the visibility is not
sufficient to guarantee safe driving, accidents occur especially
in highways. Hence a mechanism to ensure that the head
lamps are turned on automatically is required. This mechanism
again is incorporated only in high end cars like BMW, Audi,
Volvo etc. In order to incorporate this mechanism in low end
cars, a cost effective and efficient method is the need of the
hour. This can be incorporated by mounting a photo diode on
the windshield behind the internal rear view mirror.
Thus, theremust be a cost effective mechanism to address
the problems of blind spots, dazzling of head lights and low
visibility. In this paper, the proposed system is one such
solution that helps in preventing an accident by providing
proper visibility to drivers by illuminating curves and bent
paths such that the driver can be cautioned before he hits any
object or life.
II. RELATED STUDY
The concept of adaptive headlamps is not new in high end
cars like Volvo, BMW, Audi etc. where in these mechanisms
are already employed but a rather different approach have
been taken in doing so. These vehicles used
expensive sensorsto measure speed, steering angle and
yaw, which is the degree of rotation around the vertical axis
and small electric motors to turn the cars’ headlights and to
guide the driver along the bends of the roads [1]. Due to such
2014 International Conference on Recent Trends in Information Technology
sophisticated devices being used in these cars the cost is as
high as $1000 [11].
The second approach is the use of Hardware in the loop
simulations, a mathematical approach, where the headlamp
orientation control system rotates the right and left low beam
headlights independently and keeps the beam as parallel to the
curved road as possible to provide better night time visibility.
Here two hardware platforms are employed where the first
platform simulates the vehicle and road models and the other
platform simulates the Adaptive Headlamp System controller
which obtains the necessary vehicle states from the first
platform and carries out the necessary AHS computations.
This second platform then sends the calculated commands to
the headlight positioning electric motors [2].
Furthermore actuator based mechanisms have also been tested
and developed for adaptive headlight systems where in a PIC
microcontroller PIC16F877A is used. A potentiometer based
sensor is attached to the steering shaft which provides the
sensing input to the microcontroller unit in the form of
voltage. Servomotors with built in feedback mechanisms were
used as actuating blocks that receives the microcontroller
output to turn the headlamps [3].
A table below has been provided which compares the cost of
the adaptive headlight system which is currently used in
various high end cars.
Table 1 Cost of AHS in various cars
Serial No. Car Model Cost estimate
1. Mercedes Benz
S550
$700 (For stand-
alone option)
2. Mercedes Benz
Premium 3 Engine
$6550
3. Volvo V60 $850
4. Lexus RX350 $515
From the above table it is clear that the cost of the adaptive
headlamp system is quite high for these sophisticated
automobiles. Whereas the system proposed in this paper
provides a cost efficient method to ensure safety while driving
in night. The approximate cost of the proposed system comes
to $250 which is marginally lower than the above mentioned
vehicles. Moreover the system described below is designed
specially for lower end vehicles like Tata Indica V2 which are
commonly found in Indian roads.
III. PROPOSED SYSTEM
The components that are used to implement the adaptive
headlight system are described below.
A. Microcontroller unit
The AT89S52 is a low-power, high-performance CMOS 8-bit
microcontroller with 8K bytes of in-system programmable
Flash memory. This chip is compatible with the industry-
standard 80C51 instruction set.The standard features of
AT89S52 includes- 8K bytes of Flash, 256 bytes of RAM, 32
I/O lines, Watchdog timer, two data pointers, three 16-bit
timer/counters, a six-vector two-level interrupt architecture, a
full duplex serial port, on-chip oscillator, and clock circuitry
[8]. In addition, this microcontroller unit is designed with
static logic for operation down to zero frequency and supports
two software selectable power saving modes.The
microcontroller is interfaced with a DC generator to measure
the current, a photo diode to measure the light intensity of
sunlight and two stepper motors to rotate the headlamp
accordingly. The microcontroller chip is shown in Figure 1.
Figure 1ATMEL 89S52 microcontroller IC in Dual-in line
(DIP) package.
B. DC Generator
The DC generator is a device that converts the mechanical
energy of a rotating conductor into electrical energy as shown
in Figure 2. It works on the principle of Faraday’s law of
electromagnetic induction which states that a change in the
flux linkage in a closed loop conductor causes an
Electromotive Force (EMF) to be induced. The direction of
current in the generator’s coil is given by Fleming’s right hand
rule. As the steering wheel is rotated, the steering column
rotates in the magnetic field and thus generates an EMF.
Figure 2 DC Generator
C. Photo diode
A photo diode is a device that is capable of converting light
into current or voltage [4]. Current flows from cathode to
anode when they are connected in the presence of light. For
the purpose of measuring the light intensity of sunlight in the
visible spectrum, a BPW21 silicon photodiode (shown in
2014 International Conference on Recent Trends in Information Technology
Figure 3) is used. Its spectral range is 350 nm to 820 nm. The
wavelength of maximum sensitivity is 550nm. The maximum
current generated is 2nA during extreme sunlight in noon. The
photo diode as mentioned earlier is mounted in the windshield
behind the internal rear view mirror such that the light rays of
the sun alone are incident on it and not that of the headlamps
of other vehicles plying on the roads.
Figure 3 BPW21 Silicon photodiode
D. Stepper Motor
A stepper motor is an electromechanical device that
converts electrical pulses into discrete mechanical movements.
The shaft of a stepper motor rotates in discrete step increments
when electrical command pulses are applied to it in proper
sequence. The stepper motor is interfaced with the ATMEL
89S52 microcontroller and the angle of rotation is determined
and fed to the stepper motor. The headlamp is fixed on the
stepper motor and rotates according to the stepper motor
rotation. Figure 4 shows a stepper motor.
Figure 4 Stepper Motor
IV. SYSTEM ARCHITECTURE AND OPERATION
The overall system architecture is as shownin Figure 5. The
Adaptive headlight system consists of a photo diode, two
stepper motors and a DC generator interfaced to the ATMEL
89S52 microcontroller unit. The mirror shaft is mounted on
the stepper motor and it rotates along with the turns of the
stepper motor. The working of the system is as follows: The
adaptive headlight system works when either of the following
condition is true- a) The headlight switch is on b) The current
generated by the photo diode falls below a particular threshold
value (i.e. the light intensity becomes less than the minimum
amount required for visibility). In the case b), the headlight is
automatically turned on and the adaptive headlight system
starts functioning. When the steering wheel is turned, the
steering column moves along with the DC generator fixed to
it. When the DC generator rotates in the magnetic field, the
flux linkage in the closed loop conductor varies and thereby
generating an EMF according to Faraday’s law of
electromagnetic induction. This EMF is measured by the
microcontroller unit which performs a conversion to get the
degree by which the head lamp has to rotate;this is described
by the algorithm given below. Once the degree of rotation is
determined, discrete signals are sent to the stepper motors and
it rotates. Hence, the head lamp mounted on it correspondingly
rotates. Figure 6 shows the block diagram of the proposed
adaptive headlight system.
Figure 5 System architecture of Adaptive Headlight
System
Figure 6 Block diagram of the proposed Adaptive
Headlight System method
2014 International Conference on Recent Trends in Information Technology
V. ALGORITHM
Table 1 presents the algorithm for adaptive headlight
system method. The algorithm works as follows. The
headlight and the indicator switch are continuously monitored.
The photodiode also measures the light intensity. If the light
intensity falls below a certain threshold value, the headlamps
are automatically turned on. If the indicator switch is on and
the steering wheel is rotated, the EMF generated is measured
by the microcontroller unit and the stepper motor is rotated
accordingly. The head lamps also rotate along with the stepper
motor. Once the steering wheel and/or indicator switch is
released, both the left and right stepper motors rotates in the
opposite direction to bring back the headlamps to the original
position.
Table 2 Algorithm of Adaptive Headlight System
VI. EXPERIMENTAL SETUP
Figure 7 shows the experimental setup of the adaptive
headlight system.
Figure 7 Experimental Setup
The specifications of the various components used in the
experiments are as follows. The threshold current for the
photo diode was set as 0.8 nA.The system is activated if the
current falls below this threshold. A stepper motor of torque
3kg cm is used. The maximum voltage generated by the DC
generator is 5V during full rotation of the steering wheel and
0V when there is to rotation. The experimental setup was
designed for Tata IndicaV2 car. The maximum rotation of the
headlight is 37 degrees on the left and 43 degrees on the right.
Hence we derive the mathematical relation for angle of
rotation from the voltage as follows. The constants τL and τR
can be calculated as follows. Since 37 degrees and 43 degrees
correspond to the maximum voltage of 5V,
For left headlight, we get
τL = 37/5 = 7.4
Similarly, for right headlight,
τR = 43/5 = 8.6
The initial programming was done in Assembly Language
using KeilμVision simulator and then burnt on to the chip. The
maximum limit of the turning of the headlamps was limited to
43 degrees on the right hand side turn and 37 degrees on the
left hand side turn, as the maximum turning of the vehicle is 43
degrees and 37 degrees on the right hand side and left hand
side, respectively. This is done by incorporating the same in
Assembly Language.
VII. RESULTS
Upon testing the system the following results were obtained
whose graphical representations are as illustrated below.
Figure 8 shows the relation between the number of steering
wheel rotations in rpm (N) and the corresponding voltage (V)
generated.
Figure 8 Relation between no of steering wheel rotations
(N) and the voltage generated (V)
From Figure 8, we infer that the voltage generated increases
linearly with respect to the number of steering wheel rotations
made. Figure 9 shows the relation between the voltage (V)
0
0.5
1
1.5
2
2.5
3
3.5
4
012345
V
o
l
t
a
g
e
Steering wheel rotation in rpm (N)
1. Monitor headlight switch status (HSstatus) and
indicator switch status (ISstatus).
2. Monitor current generated by photo diode(Ipd).
3. while (Ipd<Threshold current value)
4. HSstatus = ON
5. while( ISstatus = ON || HSstatus = ON)
6. Measure Voltage (Vdc) from DC Generator
7. Angle ωL = Vdc*τL
8. Angle ωR = Vdc *τR
9. Rotate left stepper motor through ωL in
direction of rotation of steering wheel
10. Rotate right stepper motor through ωRin
direction of rotation of steering wheel
11. If (ISstatus = released)
12. Rotate left stepper motor through ωL in the
opposite direction of rotation of steering wheel
13. Rotate right stepper motor through ωRin the
opposite direction of rotation of steering wheel
2014 International Conference on Recent Trends in Information Technology
given as input to the microcontroller and the degree of rotation
of the left stepper motor ωL as per the following relation.
ωL = Vdc*τL
whereτL = 7.4. We can infer from the given relation that the
angle of rotation of the left stepper motor varies linearly with
the voltage V from the DC generator.
Figure 9 Relation between Voltage V and the angle of
rotation of left stepper motor ωL
Figure 10 shows the relation between the voltage (V) given as
input to the microcontroller and the degree of rotation of the
right stepper motor ωR as per the following relation.
ωR = Vdc*τR
where τR = 8.6. We can infer from the given relation that the
angle of rotation of the right stepper motor varies linearly with
the voltage V from the DC generator.
Figure 10 Relation between Voltage V and the angle of
rotation of right stepper motor ωR.
From the above graphical representations we can conclude
that both the DC generator voltage and the voltage input to the
microcontroller unit has a linear dependence on the rotations
of the steering wheel and the stepper motor connected to the
headlamps.
VII. CONCLUSION AND FUTURE SCOPE
Thus the adaptive headlight system is an optimal and cost
effective solution to prevent frequent accidents in the nights.
The designed system provides step wise turns of the
headlamps on either side based on the controlled input given
to the stepper motor attached to the lamps on either side. The
maximum degree of turn achieved on the left headlamp is 37
degrees and on the right hand side is 43 degrees. The DC
generator voltage input ranging from 0-5V triggers the
microcontroller unit thereby it generates equivalent output
voltage to the stepper motor. The stepper motor transduces
this voltage value into corresponding turning angles and
provides adequate turn at the bends. Hence this system is
reliable and ensures efficient and safe driving. It also costs less
and can be included in low end cars also.
In future, the adaptive headlight system can be made more
efficient by controlling the spread of the light beam from the
head lamps using an ‘automatic range extender’ depending on
the vehicle speed. The beam can be made to diverge when the
vehicle is travelling at high speeds and can be made to
converge when the speed is low. Also automatic low beam-
high beam adjuster can be incorporated to reduce accidents
due to dazzling of lights.
ACKNOWLEDGMENT
We are overwhelmed in all humbleness and gratefulness to
acknowledge our debt to those who have helped and supported
us to move this paper well above the level of simplicity and
into something concrete.
We would like to express our heartfelt gratitude to the Centre
for Technology Development and Transfer (CTDT), Anna
University, Chennai, Tamil Nadu, India, for enthusiastic
encouragement and support for this paper.
We would also like to express our sincere gratitude to our
review panellists for their valuable suggestions which helped
us to make this project a success.
Finally we thank our friends, parents and relatives for giving
support to do this work.
REFERENCES
[1] www.bmw-motorrad.com/Adaptive Headlight System-lighting the
way.pdf
[2] T. Hacıbekir, S. Karaman, E. Kural, E.S. Öztürk, M. Demirci and B.
AksunGüvenç, ]“Adaptive Headlight System Design Using Hardware-In-
The-Loop Simulation.” Automotive Control and Mechatronics Research
Center, ,Proceedings of the 2006 IEEE International Conference on
Control Applications. Munich, Germany, October 4-6, 2006.
[3] MeftahHrairi and Anwar B. Abu Bakar, “Development of an Adaptive
Headlamp Systems.” International Conference on Computer and
Communication Engineering (ICCCE 2010), Kuala Lumpur, Malaysia,
11-13 May 2010.
[4] http://www.osioptoelectronics.com/application-notes/AN-Photodiode-
Parameters-Characteristics.pdf
0
5
10
15
20
25
30
35
40
0246
R
o
t
a
t
i
o
n
A
n
g
l
e
Voltage V
0
10
20
30
40
50
012345
R
o
t
a
t
i
o
n
A
n
g
l
e
Voltage V
2014 International Conference on Recent Trends in Information Technology
[5] Hacibekir, T.; Karaman, S.; Kural, E.; Ozturk, E.S.; Demirci, M.;
AksunGuvene, B., "Adaptive headlight system design using hardware-in-
the-loop simulation," Computer Aided Control System Design, 2006
IEEEInternational conference on Control Applications, 2006
IEEEInternational Symposium on Intelligent Control, 2006 IEEE , vol.,
no., pp.915,920, 4-6 Oct. 2006.
[6] YaliGuo; Qinmu Wu; Honglei Wang, "Design and implementation of
intelligent headlamps control system based on CAN bus," Systems and
Informatics (ICSAI), 2012 International Conference on , vol., no.,
pp.385,389, 19-20 May 2012.
[7] XuPingping; Song jianguo; ShenGuangDi, "The design on Adaptive Front
Lighting System (AFS) based on brushless DC motor," Electrical
Machines and Systems, 2008. ICEMS 2008. International Conference on ,
vol., no., pp.1442,1444, 17-20 Oct. 2008.
[8] Atmel 8bit microcontroller with 8K bytes in-system programmable flash
AT89S52, http://www.atmel.in/Images/doc1919.pdf
[9] Guo Dong; Wang Hongpei; Gao Song; Wang Jing, "Study on adaptive
front-lighting system of automobile based on
microcontroller," Transportation, Mechanical, and Electrical Engineering
(TMEE), 2011 International Conference on , vol., no., pp.1281,1284, 16-
18 Dec. 2011.
[10] Pena-Garcia, A.; Pena, P.; Espin, A.; Aznar, F., “Impact of Adaptive
Front-lighting Systems (AFS) on road safety: Evidences and open points,”
First International Symposium on Mine Safety Science and Engineering,
2011. Safety Science vol. 50, no.4., pp.945,949, April 2012.
[11] Brain on board program resources/Vehicle Safety Features Fact Sheet
Eng_ Adaptive Headlights.
[12] www.carmax.com/enus/top-10-lists/top-10-high-tech-car-safety-
technologies
[13] vehicles.automobilemag.com/am/99/2014/lexus/rx350/base_sport_utility/
349/prices.html