Automobile Battery Monitoring System Using Arduino Uno R3 Microcontroller Board
Automobile Battery Monitoring System Using Arduino Uno R3 Microcontroller Board
discussions, stats, and author profiles for this publication at: https://www.researchgate.net/publication/318127866
CITATIONS READS
0 848
1 author:
Ignatius Barasa
University of Nairobi
1 PUBLICATION 0 CITATIONS
SEE PROFILE
Some of the authors of this publication are also working on these related projects:
All content following this page was uploaded by Ignatius Barasa on 04 July 2017.
Abstract:
The car starter battery normally provides electrical power for engine cranking, lighting of accessories and feeding the engine
ignition system. During any given car engine cranking event, a high current ranging from 100A to 1500A, depending on the
engine capacity and starter motor type is usually drawn from the starter battery. With each engine cranking event, there is an
associated voltage loss in the battery which consequently leads to battery degradation and ultimate failure. The failure may
occur abruptly thereby inconveniencing and at times endangering the life of the motorist. The battery monitoring system in this
research used the voltage loss associated with each engine cranking event to compute the state of health of the car starter
battery. It has a voltage divider, current and temperature modules designed for measuring the battery’s voltage, current and
temperature respectively using a microcontroller on an Arduino Uno R3 computing board. Just before the engine cranking
request is made, the battery temperature and open circuit voltage are recorded, followed by the set of current and voltage values
drawn during engine cranking. After a successful engine cranking event, the acquired temperature compensated voltage value is
subtracted from the open circuit voltage value to get the voltage loss for that particular cranking event. The voltage loss
together with a voltage loss threshold value were then used in computing the cranking health status of battery and the result
displayed in real time to the motorist over a screen on the car’s dashboard. Of the 2 batteries used in the laboratory and in a car
in this research, one of them needed to be replaced since its state of health fell below the state of health threshold while the other
battery was in good cranking condition since it was brand new. The motorist in whose car this battery monitoring system is
installed will be able to know beforehand about an impending battery failure and so take the necessary precaution in time.
Keywords: State of health, State of charge, Arduino microcontroller, engine cranking event, lead acid battery
1. Introduction
A battery is a device that converts the chemical energy stored in its active materials to electrical energy through an electrochemical
reaction (Jung et al., 2016).The active materials for the lead acid battery (LAB) are the lead oxide (PbO2) and lead (Pb) terminal plates
and a solution of sulfuric acid (H2SO4) (Rekioua and Matagne, 2012). The structure of a rechargeable lead acid is shown in Figure 1;
The most prevalent battery technology, due to low internal resistance and low price is the LAB which is commonly used in cars for
starting, lighting and ignition, functions that are otherwise known as (SLI). SLI batteries are designed with battery grids having
minimum electrical resistance, thin plates and higher concentrations of electrolyte to maximize the cranking ability. Heavy-duty SLI
batteries for trucks, buses and construction equipment use heavier and thicker plates which have high-density paste and premium
separators that often have glass mat in them in order to enhance longer life.
2. Battery Monitoring
The battery’s temperature, voltage, current and state of charge (SoC) are the most common parameters that are normally monitored.
Currently, the number of electrical appliances in the modern car keep increasing and consequently the need for more power from the
battery which can, if not monitored, easily and abruptly lead to battery failure thereby inconveniencing or endangering the motorist.
There is need therefore, of a car battery monitoring system (BMS) for monitoring and relaying to the motorist, the real-time health
status of the car’s battery by providing reliable information and notification of its working condition and the appropriate action to be
taken when need arises.
Figure 2: Sensors placed inside a rechargeable battery to monitor the individual cells (Matthias et al., 2015)
The SoC of a battery is the amount of charge available in a battery in percentage form at any given time in comparison to the same
battery’s charge when fully charged (Andrea, 2010). The SoH of a battery is a qualitative parameter that indicates the ability of the
battery to deliver the charge that is stored in it at any given time as compared to the same ability when the battery was new (Escobar et
al., 2015). The definition of SoH can either be based on the battery’s capacity or it’s internal resistance, depending on the specific
application to which the battery is put (Caihao et al., 2013). There is no fixed definition for SoH and so battery manufacturers
calibrate their own SoH thresholds and develop their own algorithms which then become part of their trade secrets (Rezvanizaniani et
al., 2014).
In Equation 1, SoC t is the estimated SoC at time t; SoC t o is the initial SoC; η is the efficiency of the current; I is the current which
is assumed to be positive during charging process and negative when discharging; and the nominal capacity of the battery is denoted
by Cn (Zou et al., 2014). In this method, the total capacity of the battery is assumed to be fixed and so it does not vary with the
temperature, age and discharge current of the battery (Vepa, 2013).
A second method of monitoring the SoC of a battery is by use of the open circuit voltage method in which the battery’s voltage is
measured using a meter connected across its terminals. A 30-minute rest period is required in case the battery had been freshly
charged to allow diffusion inside the battery to come to an end before the voltage readings are taken (Huggins et al., 2014). The value
of the voltage obtained is then compared to the corresponding SoC value in a standard chart that correlates the open circuit voltage of
the battery to the SoC.
Another method of determining SoC is by using a hydrometer to get the specific gravity of the electrolyte that is used in the battery.
The specific gravity shows the concentration of the acid in the electrolyte and it correlates directly to the battery's SoC (Garche et al.,
2009). Once the value of the specific gravity is acquired, it’s coresponding SoC is read of from a standard table that relates the SoC to
the specific gravity. For a fully charged battery, the specific gravity lies between 1.230 and 1.330 depending on the chemical
technology used (Garche et al., 2009).
A battery’s SoH can be computed using its temperature fluctuation while the battery is in use. The recommended temperature for
normal operation of a battery is 25oC and so a temperature rise far above this causes an increase in the rate of chemical reactions
inside the battery by a factor of 2 for every 5.5oC temperature rise (Garche et al., 2014). Consequently, the rate of self-discharge
reactions and chemical degradation processes double as well (Garche et al., 2009). ). Once the battery temperature is measured, an
algorithm is developed for computing the SoH of the battery.
Another method for finding the SoH of a battery is by using electrochemical impedance spectroscopy. In this method, an alternating
current is injected into the battery using a current injector such that an identifiable current of a specified frequency and magnitude
flows and causes a resultant voltage drop across the battery under test (Bergveld et al., 2013). From the voltage and current
measurements obtained, the impedance spectra are deduced and used to predict the SoH of the battery.
The coulomb counting method cannot account for the deteriorating SoC of the battery through ageing which will lead to inaccuracies
in the SoC and SoH values obtained. The 30-minute rest period needed for the open circuit voltage method compromises the
measurement accuracy because of voltage fluctuations and is unreliable for continuous battery monitoring. The specific gravity
method is intrusive and cannot be used on sealed, maintenance free batteries. The electrochemical impedance spectroscopy method is
expensive, time consuming and requires expertise in carrying it out and so, it is mostly reserved to research laboratories.
Generally, when the battery capacity drops to 80%, it is recommended that it be replaced (Xing et al., 2011). The failure modes of the
LAB are dependent upon the type of application and the specific battery design for that application. Some cells inside the battery may
deteriorate faster than others due to increase in resistance and accumulation of discharge products thereby reducing the voltage output
of the battery (Chen et al., 2012). The LAB has extremely low internal resistance of 0.022 Ohms per cell and so the voltage drop when
current is drawn from it is remarkably small (Gianfranco, 2008). Internal short circuits in the battery formed by dendrites growth
across the separators between the positive and the negative electrode during each battery cycle may lead to exothermic reactions and
decreased capacity (Wu et al., 2014).
The starter motor draws a large amount of current required to generate enough torque to turn the flywheel which in turn runs the
engine (Gilles, 2012). The ignition system transforms the norminal 12 V of the battery to about 8kV to 40 kV and deliver it to the
correct engine cylinder to ignite the compressed air and fuel vapor therein. When one winding of the ignition coil switches on and off
it, causes a high voltage to be induced in the secondary winding (Denton, 2006). The starter motor can draw as high as 1500A on light
duty vehicles and 2500A on commercial vehicles (Murugesan et al., 2012). Immediately after engine cranking, the voltage of the
battery does not normally go back to its original value implying that there is a voltage loss (Vloss) associated with engine cranking
events.
4.1. Introduction
The apparatus used in this research were a 500A battery load tester, a 1500cc Toyota Carina and the fabricated BMS. The block
diagram in Figure 4 shows the system components and the working relationship between them. The direction of signals flow in the
whole system is indicated by the arrows connecting those components. The specific function represented by each block is written
inside that particular block.
12V battery
Voltage sensing
15 minute Power supply unit module
wake up Micro-Power +3.3V, +5V Range: 0V to 14V
interrupt
MICROCONTROLLER
Temperature sensing Atmega 328
Current sensing
module
module
Range: -55oC to +150oC
Range: 0A to 400A
User interactive
interface
4.2.1. The voltage Sensing Module for Measuring the Battery Voltage
The voltage divider with two resistors, resistor 14 (R14) rated 100 kkΩ and resistor 15 (R15) rated 10 kΩ Ω connected in series as shown
in Figure 5 was designed for measuring the battery’s
tery’s voltage. The voltage input (Vin) from the battery is applied across
a the two series
resistors R14 and R15.
The output voltage (Vout) across R15 is given by Equation 2 below (Raymond et al., 2009):
Vin × R15
Vout = (2)
(R14 + R15 )
The analog voltage (Va), measured is obtained based on Equation 3 below (Bayle, 2013):
5 × analogRead ( ) value
Va = (3)
1023
4.2.2. The Current Sensing Module for Measuring the Battery Current
The 5 pin ACS755SCB-200U 200U current sensor from the Allegro family of current sensors was used for measuring the current drawn
during engine cranking. Since one of this type of current sensors measures a maximum of 200A, two of them were connected in
parallel so as to measure a current of up to 400A.
4.2.3. The Temperature Sensing Module for Measuring the Battery Temperature
The battery’s’s temperature measurements were done using a digital thermal probe, DS18B20, which was attached to the side of the
battery under test. The temperature sensor uses two voltage signals derived from bipolar transistors inside the digital temperature
tempe
probe to generate a proportionate temperature measurement based on its voltage output. The circuit connection of DS18B20 is shown
in Figure 7.
Figure 7: The digital temperature sensor, DS18B20 for measuring the battery temperature
4.2.4. Voltage Regulator Module for Stepping down Voltage from 12V to 5V
The LM 7805 IC was used as shown in Figure 8 to regulate the voltage supply from 12V to 5V to be used by the temperature and
current sensors and the Arduino Uno R3 microcontroller unit.
Figure 8: LM 7805 based voltage regulator for reducing the voltage from 12V to 5V
The computed output was displayed on a 160 x 128, 160 columns and 128 rows, arrays of the PG160128A thin film transistor screen.
4.2.6. The Data Logger for Storing the Measured and Computed Data
The secure data card for storing data was mounted on to the Arduino microcontroller compatible data-logger
logger shield shown in Figure
10.
Figure 10: A stackable data logger with a secure data card slot (Igoe, 2011)
5. Fabrication of the Battery Monitoring System and the Engine Cranking Process
When the car ignition key is turned to the ON position, the battery’s open circuit voltage and temperature are recorded. When the key
is moved to the START position, the voltage and current values during engine cranking are taken and used to compute the SoH of the
battery using Equations 4 to 12 that are embedded in the ATmega 328 microcontroller on the Arduino board. The computed data is
displayed on the screen and simultaneously stored into the secure data card on the data logger.
Start
No
Engine cranking
request made
Yes
Read voltage and current values during the engine cranking period
Plot a graph of voltage against current and get the y-intercept voltage value ( Eq 5 – Eq 9 )
Subtracting the y-intercept value from the open circuit voltage to get voltage loss (Eq 12)
No
Generate the real-time battery
state of health
Generate warning of a bad battery
5.2. The State of Health Indication Algorithm for the Battery Monitoring System
Since the battery temperature affects the open circuit voltage (OCV) and performance of the battery, a temperature compensation
algorithm was used to correct the OCV and other voltage values before using them to compute the state of heath of the battery. The V
and I value are designated as v for voltage and c for current respectively for use in the linear regression formulae listed below from
Equation 4 to Equation 12 (Ronald et al., 2004):
v = a + bc (4)
where a is the y-intercept and b is the regression coefficient of v on c;
(∑ c)2
S cc = ∑ c 2 −
n (5)
S vv = ∑ v 2
−
( ∑ v)2
n (6)
S cv = ∑ cv −
∑ ∑ c v
n
(7)
and S
b = cv
S cc
(8)
_ _
y intercept a = v− b c (9)
the regression coefficient;
Sc (10)
r =
S cc S vv
V = V o + IR batt
(11)
The voltage values obtained during engine cranking were plotted against the values of the corresponding current values and a line of
best fit, which is described by the Equation 11 was plotted. Equation 11 is a linear equation, similar to the regression Equation 4 where
Vo is the y-intercept value similar to a, and Rbatt the battery resistance similar to the regression coefficient b. Plotting the graph was one
way of getting the Vloss, and so in a second method of acquiring the same was applied by using the voltage and current values in
equations 5 to 11 to compute the Vloss. After applying Equations 5 to 11, the Vloss was arrived at by using Equation 12;
V loss = OCV − V o (12)
The values of SoC and Vloss acquired during the engine cranking event are then compared with the voltage loss threshold value, Vlossth,
and SoC threshold, SoCth, value. It is recommended that battery load testing be done when the battery’s SoC is 75% but Spectro™
CA-12 battery tester from Cadex Inc. uses a minimal SoC of 60% (Buchman, 2016). To get the SoCth, it was assumed that the battery
monitoring system had an error margin of 3% and another 1% due to parasitic losses and so the SoCthwastaken to be 71%. To get the
Vlossth and voltage loss of a new battery, Vlossnew, engine cranking was simulated in the laboratory using a 500A battery load tester on a
brand-new battery from which the average Vloss and Vlossnew were found. The tests on the LAB were therefore conducted with the
following measured parameters and assumed theoretical thresholds;
i. Vlossnew = 0.5V
ii. SoCth = 71%
iii. Vlossth = 1.5V
iv. SoHth = 80%
The Vloss, temperature and SoC signals are used to compute the battery’s SoH using Equation 13 below (Zhang, 2012);
V loss − V lossth
SoH = x 100
V fresh − V lossth
(13)
The SoH index values that are less than zero are set at 0% while those that are greater than 1 are set at 100% (Zhang, 2012). The
computed SoH is then displayed as a percentage in one of the 3 ways listed below with an indicative or instructive message to the
motorist as;
SoH: 90-100 %: Good and a green LED on the BMS turns on
SoH: 81- 89 %: Fair and a yellow LED on the BMS turns on
SoH: 80%: Replace battery and a red LED on the BMS turns on
OCV: 12.69V
Voltage loss: 0.11 Volts
SoC: 100.00 %
SoH: 100.00 % ---> Health: Good
Battery Temperature: 85.00 Degrees Celsius
Cranking Duration: 0.59 Seconds
Figure 13: A sample display of the cranking results from the battery monitoring system
While the display will be showing the results in the format shown in Figure 13, the same results were simultaneously saved for each
cranking event in an excel format in the data-logger of the BMS. The SoH and SoC for 78 engine cranking events using a brand new
75Ah Chloride Exide battery in the laboratory set-up using a 500A battery load tester is shown in Figure 14 below;
120 0.09
0.08
SoC (%) and SoH (%)
100
0.07
Resistance (Ω)
80 0.06
0.05
60
0.04
40 0.03
0.02
20
0.01
0 0
0 10 20 30 40 50 60 70 80 90
Crank number
At the crank number 68, the SoH fell below 100% and at crank number 73, it fell below the threshold value of 80%. The display for
the crank number 74 to 78 showed that the battery should be replaced because the SoH had fallen below the 80% threshold. The SoC
also kept on decreasing with every crank and gradually reduced to 57.42 %. The resistance of the battery kept increasing with each
cranking event. This cranking events were simulated in the laboratory using a 500A battery load tester which drew a current ranging
between 200A and 250A during every crank event. The battery was not charging during all these cranking events and that’s why the
SoC kept reducing.
The cranking data for the second battery, a 100Ah Unistar battery that had been used in a car for two years is shown in Figure 15.
120 0.2
SoC (%) and SoH (%)
100
0.15
Resistance (Ω)
80
60 0.1
40
0.05
20
0 0
0 5 10 15 20 25 30 35 40 45 50
Crank number
Figure 15: SoH and SoC against the number of cranks for a 2-year-old Unistar battery
The SoC and SoH for the Unistar battery were both 100% up until crank number 12 when the SoC started reducing. The SoH
remained at 100% until crank number 29 and on crank number 30, it fell to 80.33%. At the failure point, that is crank number 31, the
SoC was 34.02%, SoH 46.62 oC and the resistance 0.0358Ω. The range of resistance for the 47 cranking events was 0.0016Ω –
0.1735Ω. The SoCth ,71%, was reached at crank number 16 and so the battery should have been charged at this point before
proceeding with more cranking events but since the current being drawn from this battery was between 100A and 120A, the SoH was
above threshold. There were 15 more successful cranks after the SoCth value had been reached as can be seen from the corresponding
SoH values reading 100%. This battery’s health had deteriorated so much since it failed the crank test after 30 cranking events
otherwise the SoC should have been above threshold for more than the recorded 16 cranks before starting to decrease. Since the
battery cranked successfully below SoC threshold, it means that successful cranking depends on the magnitude of the load applied to
the battery.
The Unistar battery was charged to 12.65V and installed in a 1500cc Toyota Carina for a period of one week to collect the cranking
data. The acquired data is represented in the graph in Figure 16.
120 0.06
SoC (%) and SoH (%)
100 0.05
Resistance (Ω)
80 0.04
60 0.03
40 0.02
20 0.01
0 0
0 10 20 30 40 50 60
Crank number
Figure 16: SoH and SoC against the number of cranks the 100Ah Unistar battery in a 1500cc Toyota Carina
With the Unistar battery installed in the car, 50 cranks were recorded with the first 25 taken over a distance of 5km moved by the car.
The rest of the cranks were taken while the car was in a stationary condition. In the first 14 cranks, both the SoH and SoC was 100%
and the car cranked in 0.56 seconds. From crank number 15 to crank number 25, the cranking time increased to an average of 0.72
seconds due to reduction of the SoC and an increase in battery resistance. The engine cranked successfully up to the point where the
SoH was 75%, below which there was no successful cranking. The range of resistance for this battery when used in this car was
0.0014Ω – 0.0486Ω while the temperature was 33.31oC.
The brand-new Chloride Exide battery was charged to 12.65V and installed in the 1500cc Toyota Carina for five days and the
cranking data collected is shown in Figure 17.
120 0.025
SoC (%) and SoH (%)
100 0.02
Resistance (Ω)
80
0.015
60
0.01
40
20 0.005
0 0
0 50 100 150 200 250 300
Crank number
Figure 17: SoH and SoC for a brand-new 75Ah Chloride Exide battery in a 1500cc Toyota Corona
The SoC and SoH of the battery was 100% for the five days since the battery was brand new. The average cranking time was 0.49
seconds for each crank. The temperature of the battery was 23.7oC for the first crank in the morning just before the car took off. The
car covered an average of 102km on each day and the cranking data was taken when the temperature of the battery was 85oC. The
resistance of the battery was between 0.076Ω – 0.0783Ω.
7. Conclusions
The SoH of the SLI battery starts off at a high value and gradually decreases with battery usage. As the battery charging and
discharging cycles increase, the battery’s resistance increases and consequently lower the ability of the battery to crank the car. The
battery degradation process takes place in the background such that the person using the battery, may not notice it. With the BMS
installed in the car, the motorist will not need to wait for the battery to fail completely before replacing it. Most battery monitors
found in cars only show the SoC of the battery, a parameter that cannot tell how healthy a battery is. The SoC and SoH monitoring
using the developed BMS will monitor the electrical consumption of the loads in the car and help optimize the battery utilization and
eliminate failures from unintended discharge. The BMS will also keep track of the ability of the battery to store and supply charge
Motorists can use the new BMS in their cars to monitor their battery performance, conserve energy, save expensive battery repairs and
avoid being inconvenienced by breakdowns from battery failures.
8. Recommendations
There gap between the laboratory tests and the real time field applications need to be narrowed down so as to develop more accurate
monitoring devices. The voltage threshold value in this research was selected based on car engine cranking simulations in the
laboratory using a 500A fixed load battery tester that takes 10 seconds whereas the actual average car cranking time was 0.59 seconds.
The performance of the BMS under operating conditions, such as vibration from bumpy roads and temperature extremes from snow,
rain or summer heat need to be studied so that these external loads will be reflected in the battery’s available capacity. The BMS
should be installed in a car for at least one year to be able to get a better deterioration trend of the starter battery in order to improve
the accuracy of the SoH indication algorithm.
9. References
i. Bergveld, H. J. (2013). Battery Management System; Design and Modelling. Eindhoven,Nederlands: Royal Philips
Electronics.
ii. Banzi, M. (2011). Getting Started with Arduino 2nd Eddition. Sebastopol, CA: O'Reilly & Associates.
iii. Buchman, I. (2016, 8 3). http://www.cadex.com/en/products/. Retrieved from http://www.cadex.com/en/:
http://www.cadex.com/en/products/spectro-ca-12-ga
iv. Bosch, R. (2016, 12). http://www.boschdiagnostics.com. Retrieved from http://www.boschdiagnostics.com/pro/products/bat-
110-battery-tester.
v. Chris K. Dyer, Patrick T. Moseley,Zempachi Ogumi,David A. J. Rand,Bruno Scrosati,. (2014).
vi. David Linden and Thomas B. Reddy. (2002). Handbook of Batteries. New York USA: McGraw Hill Companies Inc, 104-
105.
vii. Delphi,Inc.(2016,August3).Retrieved September, 3,2016 from http://www.argusanalyzers/:
http://forex.hu/images/pdf/ARGUS500.pdf
viii. Denton, T. (2006). Advanced automotive fault diagnosis second edition. Burlington, MA: Elsevier BH, 108-113.
ix. Florez-Escobar W. F., C. A. Brebbia, F. Chejne,F. Mondragon. (2015). Energy and Sustainability VI. Southampton SO40
7AA UK: WIT Press, 243-247.
x. Gilles, T. (2012). Automotive Service: Inspection, Maintenance, Repair. MA 02451, USA: Cengage Learning, 367.
xi. Huggins, R. (September 11, 2014). Energy Storage 2010 edition. New York: Springer.
xii. Hui Wu, Denys Zhuo, Deshang Kong, Yi Cui. (2014, 10 13). Improving battery safety by early detection of internal shorting
with a bifunctional separator. Nature Communications, 5, 5193.
xiii. http://www.projecta.com.au/Products/BatteryMaintenance/BatteryTesters.aspx. (2016, 8 3). Retrieved from
http://www.projecta.com.au/site/DefaultSite/filesystem/documentshttp://www.projecta.com.au/site/DefaultSite/filesystem/do
cuments/BatteryMaintenance/BLT300_Instructions_Issue1.pdf
xiv. Hollembeak, B. (2011). Automotive Electricity and Electronics, 5th edition. USA: Delmar cengage learning, 471.
xv. Jack Erjavec, Rob Thompson. (2014). Automotive Technology: A Systems Approach. NY USA: Cengage Learning, 543.
xvi. Jurgen Garche, Chris K Dyer, Patrick T, Mosley, Zempani Ogumi, David A.J. Rand, Bruno Scrosati. (2009). Encyclpedia of
Electrochemical Power Sources. NX Amsterdam: Elsevier,556.
xvii. Jurgen Garche,Chris K. Dyer, Patrick T. Moseley,Zempachi Ogumi,David A. J. Rand,Bruno Scrosati. (2014).Encyclopedia
of Electrochemical Power Sources,Amsterdam Netherlands: Elsevier, 729-795.
xviii. Joey Jung, L. Z. (2016). Lead-Acid Battery Technologies: Fundamentals, Materials, and Applications. Boca Raton Florida:
CRC Press, 5-6.
xix. Matagne, D. R. (2012). Green Energy , Optimization of Photovoltaic Power Systems. London: Spinger.
xx. Matthias Schneider, S. I.-R. (2015). Vehicle Batteries with Wireless Cell Monitoring. IEEE, 3-4