Department of Science and Technology
Institutionen för teknik och naturvetenskap
Linköping University Linköpings Universitet
SE-601 74 Norrköping, Sweden
601 74 Norrköping
LiU-ITN-TEK-A--08/061--SE
Intelligent charging and
control of portable battery
packs
Olof Kjellberg
Intelligent charging and
control of portable battery
packs
Examensarbete utfört i Elektronikdesign
vid Tekniska Högskolan vid
Linköpings universitet
Olof Kjellberg
Handledare Runo Tirholm
Examinator Amir Baranzahi
Detta dokument hålls tillgängligt på Internet – eller dess framtida ersättare –
under en längre tid från publiceringsdatum under förutsättning att inga
extra-ordinära omständigheter uppstår.
Tillgång till dokumentet innebär tillstånd för var och en att läsa, ladda ner,
skriva ut enstaka kopior för enskilt bruk och att använda det oförändrat för
ickekommersiell forskning och för undervisning. Överföring av upphovsrätten
vid en senare tidpunkt kan inte upphäva detta tillstånd. All annan användning av
dokumentet kräver upphovsmannens medgivande. För att garantera äktheten,
säkerheten och tillgängligheten finns det lösningar av teknisk och administrativ
art.
Upphovsmannens ideella rätt innefattar rätt att bli nämnd som upphovsman i
den omfattning som god sed kräver vid användning av dokumentet på ovan
beskrivna sätt samt skydd mot att dokumentet ändras eller presenteras i sådan
form eller i sådant sammanhang som är kränkande för upphovsmannens litterära
eller konstnärliga anseende eller egenart.
För ytterligare information om Linköping University Electronic Press se
förlagets hemsida
http://www.ep.liu.se/
Copyright
The publishers will keep this document online on the Internet - or its possible
replacement - for a considerable time from the date of publication barring
exceptional circumstances.
The online availability of the document implies a permanent permission for
anyone to read, to download, to print out single copies for your own use and to
use it unchanged for any non-commercial research and educational purpose.
Subsequent transfers of copyright cannot revoke this permission. All other uses
of the document are conditional on the consent of the copyright owner. The
publisher has taken technical and administrative measures to assure authenticity,
security and accessibility.
According to intellectual property law the author has the right to be
mentioned when his/her work is accessed as described above and to be protected
against infringement.
For additional information about the Linköping University Electronic Press
and its procedures for publication and for assurance of document integrity,
please refer to its WWW home page:
http://www.ep.liu.se/
of portable battery packs
This report describes thesis work performed at SAAB Aerotech
in Link
o¨ping, Sweden.
The task was to find a way to have
portable electronics’ battery packs supervise their own
charg-ing i.e. designcharg-ing a charger that would fit inside the battery
pack itself. The work was started by identifying the demands
that SAAB Aerotech and their customer have on portable
bat-tery packs. A survey was done, forming the basis of a design
specification that specifies what an implementation should aim
at fulfilling. The resulting design specification closely matches
what is known as a smart battery, but with different
character-istics especially when it comes to driving high power loads and
coping with rough conditions. Therefore, this report describes
one possible way to implement “Smart Battery” functionality in
a battery pack while at the same time adressing the special
de-mands of the company. A Smart Battery is capable of measuring
and logging data, and uses this data to predict performance. A
communication inteface can then convey this information to host
equipment and chargers.
A background to what smart batteries do differently than
dumb batteries is given in the beginning of the report. Following
chapters discuss battery technology and smart batteries in more
detail. The main portion of the report is the description of the
design and implementation of a prototype smart battery pack.
This section describes choice of hardware, circuit board design
and coding in C. The report is concluded with results from the
design and implementation. Recommendations on further work
are also presented.
Acknowledgement
The author would like to thank the project supervisor at SAAB
Aerotech, Runo Tirholm, for his support. The author is also
thankful to Per Nordgren, SAAB Aerotech, for sharing his
knowl-edge in the field of battery technology and to SAAB Aerotech for
providing the subject for the thesis. Thanks finally to ITN, and
to the examiner Amir Baranzahi who provided helpful comments
and input to the report.
Abbreviations
SBS The Smart Battery System SMBus The System Management Bus NACK Not Acknowledge
ACK Acknowledge R/W Read/Write
Cell The smallest unit of a battery Battery Array of interconnected cells SoC State Of Charge
BOM Bill Of Material
COTS Commersial O The Shelf
API Application Programming Interface RISC Reduced Instruction Set Computer FET Field Eect Transistor
TWI Two Wire Interface
LQFP Low prole Quad Flat Pack SLA Sealed Lead Acid
NiCd Nickel Cadmium NiMH Nickel Metal Hydride LiIon Lithium Ion
Contents
1 Introduction 6 1.1 Background . . . 6 1.2 Goal . . . 6 1.3 Delimitation . . . 7 1.4 Method . . . 7 2 Theory 8 2.1 Batteries . . . 82.1.1 Primary and secondary cells . . . 8
2.1.2 Coulombic eciency . . . 9
2.1.3 Peukerts equation . . . 10
2.1.4 Chemistries' pros and cons . . . 11
2.1.5 Cell Balancing . . . 12
2.1.6 Environmental aspects and economy . . . 13
2.2 Smart Battery System . . . 14
2.2.1 Rationale . . . 14
2.2.2 System overview . . . 14
2.2.3 The System Management Bus . . . 14
2.2.4 Compatibility between SMBus and I2C . . . 16
2.2.5 The Smart Battery Data specication . . . 17
2.2.6 The Smart Battery Charger specication . . . 17
2.2.7 Downsides to the SBS . . . 18
2.2.8 Digital memory eect . . . 18
3 Design process 18 3.1 Assessment of requirements . . . 18
3.2 Reference battery pack . . . 20
3.3 Special functionality . . . 21
3.3.1 Charger independent charging . . . 21
3.3.2 Emergency fast charging . . . 21
3.3.3 Design for higher power battery packs . . . 21
3.3.4 Cell condition warning . . . 22
3.3.5 Prediction of number of batteries needed for a given temperature and load . . . 22
3.3.6 Battery warming . . . 22
3.3.7 Battery user interface . . . 22
3.4 What is on the market? . . . 22
3.4.1 Smart Battery ASIC . . . 22
3.4.2 LTC1759 . . . 23
3.4.3 DS2438 . . . 23
3.4.4 The ATMEL ATmega406 microcontroller . . . 23
3.5 What has been done within the company . . . 24
3.6 Specication of design . . . 25
3.6.1 Battery block diagram . . . 25
3.6.2 Functionality of battery . . . 25
3.6.3 Supported Smart Battery commands . . . 26
4 Implementation 26 4.1 Hardware . . . 26
4.1.1 CAD tools . . . 27
4.1.2 Schematic design . . . 27
4.1.3 Circuit board design . . . 28
4.1.5 IPort/ AI rs232 to I2C adapter . . . 30
4.1.6 Experiment board . . . 30
4.1.7 Functional mockup . . . 31
4.2 Battery code . . . 31
4.2.1 Development tools . . . 32
4.2.2 ATAVRSB100 development board . . . 32
4.2.3 Description of code ow . . . 33
4.2.4 Variables . . . 35
4.2.5 Files . . . 35
4.2.6 Problems encountered during programming . . . 37
4.3 Software for hosting equipment . . . 38
4.4 PC test software . . . 38
5 Verication of functionality 39 5.1 Verication of communication functionality . . . 39
5.2 Testing hardware functionality . . . 39
5.2.1 Functionality of extra connector set . . . 40
5.2.2 Balancing . . . 40
5.2.3 A/D conversion of current measurements . . . 41
5.2.4 Softfuse . . . 41
5.2.5 Temperature elevation . . . 41
5.2.6 Current consumption . . . 41
6 Possible implementation of special functionality 41 6.1 Questions and experimental method . . . 41
6.1.1 Charger independent charging . . . 41
6.1.2 Emergency fast charging . . . 42
6.1.3 Higher power handling capability . . . 42
6.1.4 Cell condition warning . . . 42
6.1.5 Prediction of number of batteries needed . . . 42
6.1.6 Battery warming . . . 43
7 Experimentation with the A123 Li-Ion cell 43 7.1 Cell performance testing . . . 43
8 Results 46
9 Discussion & further work 47
10 References 47
11 Appendix 49
A PCB drawings 49
B Schematic drawings 51
C Battery controller code 56
D PC test software code 69
List of Figures
1 Battery impedance . . . 9
2 Typical discharge curves . . . 10
3 Capacity vs. load current . . . 11
4 Typical high power LiIon discharge curves . . . 11
5 Typical energy density of dierent chemistries . . . 12
6 Loss of usable capacity due to cell imbalance . . . 13
7 The Smart Battery System . . . 15
8 SMBus transmission format . . . 15
9 Typical SMBus package . . . 16
10 Delimitation of implementation . . . 26
11 Printed circuit board . . . 29
12 Battery pack information panel . . . 30
13 Second set of cell connectors . . . 31
14 Experiment board connected to PC . . . 32
15 The reference battery and smart battery mockup . . . 33
16 Battery pack application ow . . . 34
17 Division of code into les . . . 37
18 Modication of circuit . . . 38
19 Modication of circuit board . . . 39
List of Tables
1 SBS documentation . . . 15
2 SMBus and I2C frequency range . . . 16
3 SMBus and I2C logic levels (V) . . . 17
4 Sink current and pull up resistors . . . 17
5 A/D converter step size vs. shunt resistor value for the 18 bit output . . . 24
6 A/D converter step size vs. shunt resistor value for the 13 bit output . . . 24
7 The chosen subset of commands . . . 27
8 Minimum dimensions of PCB process . . . 28
9 Estimated junction temperature . . . 30
10 Structs . . . 35
11 Conversion constant for three dierent shunt values . . . 36
12 Theoretical warm up of cell vs energy input . . . 43
13 Capacity vs. temperature . . . 45
14 Cell instantaneous power experiment . . . 45
15 Cell abuse experiment . . . 46
1 Introduction
1.1 Background
With an ever growing need for more electrical energy in portable electron-ics, there is always a need for better batteries. New battery technologies with improved chemistries have catered for at least some of this growing need and manufacturers keep improving them. Among the more recently developed are Lithium Ion cell capable of handling remarkable charge and discharge currents. The cells also show an excellent cycle life performance and are tolerant to abuse. To top this o, the lithium Ion cells are also environmentally sound, and do not require costly handling once worn out.
As a way of storing power, batteries have many weaknesses. The biggest problem is knowing when they will run out. The amount of remaining energy, and the ability of the battery to deliver it, is at any given time dictated by numerous factors. Temperature and age are two of the most important along with how the battery has been used. All of this means that it is not possible to reliably estimate charge status from a single reading of e.g. voltage. We can think of this as gaugeing fuel in a fueltank. To know how much energy is left in a battery , one has to have information not only about the present, but also about the past.
One fairly recent development, mostly driven by the portable computer market, is the incorporation of electronics into batteries. By putting a microprocessor in the battery that keeps track of currents and voltages as well as temperature and age of the battery, it is possible to accurately predict the state of charge.
The electronics industry calls this approach the Smart Battery System or just SBS. There is a SBS standard stating what functionality should be present in a Smart Battery and most importantly, it denes a communi-cation protocol and a set of commands.
SAAB Aerotech are interested in replacing an older type of standard battery with one built on more modern Li-Ion cells. They are also interested in making the battery smarter, for example by letting it control it's own charging. The company has performed testing of Li-Ion batteries and are interested in learning more about what the alternatives are when looking for new batteries.
1.2 Goal
The overall goal of this thesis work is to present to SAAB Aerotech a good starting point for further work with batteries for portable electronics. The initial description of the thesis task was nding a way to provide battery packs with a way of controlling their own charging. This report is focused on nding out what the specic needs of SAAB Aerotech are concerning batteries, and present possible ways to address these needs in a physical implementation. During the start up of the thesis work, it became clear that batteries with built in chargers alone, would soon become obsolete. The development is moving towards batteries with a higher degree of func-tionality built in. Therefore, the initial aim of presenting a suggestion to how built in charging capability could be realized was abandoned. Instead, the work was set out with the intention of decribing how battery systems can be improved, from a larger perspective. This was broken down into the following points.
Finding the requirements that SAAB Aerotech has on battery systems Looking at what solutions are available on the market, to adress these
requirements
Design a physical Smart Battery system that will allow experimenta-tion
Discuss solutions to requirements not fully adressed by commercial alternatives
Perform experiments to nd out if proposed solutions are feasible Discuss how SAAB Aerotech could proceed, based on the results of
this work
1.3 Delimitation
This report aims at nding the specic needs Saab Aerotech has on battery systems, and demonstrating a way to implement a Smart Battery that will full those needs.
A Smart Battery prototype is designed. The capacity and voltage of the prototype matches those of a reference battery pack used by Saab Aerotech, and is realized using battery cells that the company has already been looking at.
The report describes the work done to identify requirements, and design a battery back that fulls specic needs. It describes testing that has been done to test the feasibility of some special functionality that Saab Aerotech are interested in. It also describes testing of the chosen battery cell.
The report does not aim at presenting a nalized product, but is intended to be read before starting looking at designing smart battery systems.
1.4 Method
The rst step in the planning of this work is dening what should be done. Discussions with the supervisor at Aerotech will form the basis of the project outline. Other parties that may be interested in the results of the work are contacted to narrow the denition down even more. An existing battery pack is proposed by SAAB Aerotech as a reference for the study. Finding out the power supply specications of the equipment using this battery is necessary while planning. In short, the rst part of the project is spent nding out the answers to the following questions:
What are the expectations and ideas of SAAB Aerotech on this work? What functionality do SAAB Aerotech want in battery packs? What are the specications in terms of voltages, current handling,
size, robustness et.c. of the reference design?
Knowing the answers, a literature study is commenced to gain more understading of the problem. More in depth analysis of the expectations shall be done and used to form requirements, subsequently used to design a prototype battery pack. This prototype will be used for experiments designed to answer specic questions resulting from those requirements. Use of a microcontroller is likely to be hard to avoid as hinted in section 1.2. Programming, especially in high level programming languages, is a relatively
new area for the author. Therefore, a study of the C programming language is an integral part of the planning phase.
When the initial phase of planning and studying is completed the work is basically continued as described below. The aim of these steps is to produce the prototype battery pack described above and to make sure it works.
Conceptual design of the system, and more detailed design of the hardware
Choice and ordering of hardware
Implementation on strip board and verication of functionality Design and build up of a prototype circuit board
Verication of functionality
When a working prototype board is available, a set of experiments are designed and conducted in order to answer specic questions that have arisen during the initial phase of the project. In short, these activities include the following.
Draw up of a plan for the experiments Experimental methods and setup Experimental results
Finally, once experimentation is concluded, the results of the conducted work will be discussed, and hopefully some conclusions are possible.
2 Theory
2.1 Batteries
A battery is a device that converts chemical energy to electrical energy. Throughout this report, a battery is known as an array of similar battery cells connected in either serial or parallel or both. There are many dierent types of cells, all of which have dierent properties. Battery cells may be optimized for dierent applications e.g. have a high energy density or a high count cycle life (ability to withstand many charge - recharge cycles without excess deterioration in performance) Dierent compositions of materials, dierent chemistries, give the cells their characteristics and there is not one single chemistry that is the most suitable for every conceivable application. Successful use of batteries as a means of storing energy starts with choosing the right chemistry for the application.[1]
2.1.1 Primary and secondary cells
A primary battery transforms chemical energy in a non reversible reaction into electrical energy while being discharged. Once depleted, the only way to recharge such a battery is to physically replace some of it's components. Secondary batteries on the other hand can be recharged, since the chemical reactions they are based on can be reversed by supplying electrical energy. Their cycle life performance is the very important measure of their capa-bility of being recharged.
electronic equipment, the electrical properties are what is of interest. A problem with batteries is that their performance is largely dependent on many factors, some of which may be unknown. As an example, the available energy in a battery is to a very large degree dependent on both temperature and discharge rate. Equation 1 shows the relationship between open circuit terminal voltage and actual terminal voltage under load.
Vt= Voc− I ∗ Zinternal (1)
Figure 1: Battery impedance
From this expression it is immediately clear that the available terminal voltage of the battery is proportional to the load current. The internal impedance Zinternal of a cell is described by gure 1. Rm is the resistance
of the metal connections inside the cell. Ra is the resistance of the
elec-trochemical path (electrolyte) while Ri is the contact resistance between
the electrolyte and the plates. Cb is the capacitance formed by the parallel
plates. While discharging, the internal impedance of a cell increases. As a cell ages its internal impedance increases due to unavoidable and unwanted chemical reactions. The internal impedance is also inversely proportional to the temperature of the cell. At low temperatures, therefore, the terminal voltage of a cell is lower than at higher temperatures.
Load current for batteries is often specied in terms of C, where C equals the current that would drain the battery in one hour. Figure 2 shows typical discharge curves for a Li-Ion polymer battery. The three curves are measurements of the same battery at dierent load currents.
Discharged energy = I ∗ Z T
0
Vt(t) dt (2)
2.1.2 Coulombic eciency
Equation 2 shows the energy released by a cell during discharging. The internal impedance of the cell produces a voltage drop and energy is dis-sipated as heat. The magnitude of this loss is proportional to the load current. Thus, for larger currents the eciency of the cell decreases. The term Coulombic eciency, or charge acceptance, is referring to the ratio of discharged energy to charged energy for one complete charge / discharge cycle of a cell. While charging the cell, the internal impedance of the cell will produce a voltage drop, increasing the terminal voltage. Just like in the case of discharging, the power dissipated over this voltage drop is lost as heat. Apart from the fact that the amount of energy that can be released
Figure 2: Typical discharge curves
by a battery is dependent on load current, there is another phenomenon aecting usable cell capacity.
2.1.3 Peukerts equation
Peukerts law [1, 2], which is an empirically determined formula, describes the dependence of load magnitude on battery capacity. Every battery has an ampere hour rating. For an ideal cell, the relationship between capacity, load current and the time it would take to empty the cell at that current is given by equation 3. C is the capacity in (Ah), I is the load current (A)
t = C
I (3)
The problem is that the capacity is not constant, but depends on the load current. A typical example of this is shown in gure 3. Because it is not constant, a capacity rating is rather useless without knowing how the manufacturer has measured it. To get a true idea of the capacity of a cell, one must also know the C - rate at which it was measured. Common rates are C = 1, and C = 20. The impact of load current on capacity is quantied by the dimensionless Peukert constant k. The value of this constant has to be determined experimentally for every type of cell. By knowing the Peukert constant, and the C - rate at which the measure of capacity is valid, one can estimate the time it would take to deplete a cell by using equation 4. This eect is also called capacity oset.
t = H
(I∗HC )k (4)
The typical peukert number ranges from 1.3 - 1.4 for SLA cells down to just over 1 for some LiIon cells.[1] Figure 4 shows discharge curves gathered from a high power LiIon cell datasheet [3]. In this gure, the eect of increasing the discharge current is much smaller. In eect, this cell acts more like an ideal cell.
Figure 3: Capacity vs. load current
Figure 4: Typical high power LiIon discharge curves 2.1.4 Chemistries' pros and cons
Nickel Cadmium (NiCd) is a fully developed chemistry. It has a good cycle life and is economical. They can deliver high currents during dis-charge. They have a good shelf life which means they are not quickly damaged by prolonged storage. NiCd batteries are tolerant to abuse, both electrical and mechanical. NiCd batteries contain toxic metals and are not environmentally friendly. Their toxicity have lead to their being subject to handling fees within some countries. More about this in the following section. They also have a low energy density compared to some other chemistries and a high self discharge rate. They are also subject to a memory eect the importance of which is something that is being debated. [1]
Nickel Metal Hydride (NiMH) batteries have a higher energy density than NiCd (Around 30-40% higher). The price for this is a limited cycle life (around 200 - 300 cycles). In other aspects, they are
compa-rable to the latter. NiMH batteries do not contain the toxic metals of the NiCd chemistry.[1]
Lead Acid (LA) come in many variations. Some need regular main-tenance and some are mainmain-tenance free. This chemistry is suitable for high power applications where weight is of no concern. Lead Acid batteries like being fully charged and have a long service life in this condition. They do not, however, like being cycled. Therefore, they are often used in electrical back up systems and hospital equipment. One of it's most widespread use is of course in vehicles. Lead acid batteries are toxic to the environment, but they are recycled to a high extent. [1]
Lithium Ion (Li-Ion) is the chemistry most often employed in portable electronics. It has a high energy density and is light weight. Li-Ion batteries are more expensive than e.g. NiMH and may be unsafe if handled incorrectly. To the end of ensuring their safety, strict guide-lines must be followed and more or less complicated electronical so-lutions for their protection have been devised. Including protection circuits eectively limits the current output and voltage of a battery pack. Li-Ion batteries are also more expensive to produce than for example NiCd.[1]
Lithium Ion Polymer (Ion polymer) batteries are a variation of Li-Ion. They allow thin form factors and are used in portable electronics.[1] Figure 5 shows typical gravimetric and volumetric energy density for dier-ent types of cell. The position of the a123 cell described within this report is calculated using the measurements done within the thesis work and the rest of the gure is from here [4].
Figure 5: Typical energy density of dierent chemistries
2.1.5 Cell Balancing
When constructing a battery pack out of individual cells, manufacturers usually try to nd cells that are very close to each other in terms of capacity.
If one cell in a series connected pack should be of a slightly smaller capacity, this will have an impact on the capacity of the pack as a whole since that cell will determine when charge and discharge will have to be terminated. When discharging, the weaker cell will be depleted before the other cells. When this happens, the load may either sense this and shut o, or keep discharging until some predetermined condition signalling that the pack is empty has been met. Failing to shut o the load once one cell is empty may damage that cell. There are several techniques to manage individual cell condition and minimize the impact of dierences between cells. Cell equalization is the technique of charging each cell individually to the same charge level. Active balancing removes energy from the cell with the highest charge level and delivers it to the weaker cells. Passive balancing simply removes energy from the strongest cell until it's charge level is equal to the weaker cells. Charge limiting techniques monitor the individual cell voltages of a pack, terminating charging when the rst cell reaches the cuto voltage level for charging. Similarly it shuts o discharging when the rst cell reaches the discharge shut o level.[4] This technique obviously has some implications to the capacity of a battery pack. Figure 6 describes this situation. To the left is a two cell battery where only one cell is fully charged. To the right is the same battery, and the cell that wasn't fully charged will be depleted rst. Small dierences in battery capacity may add up to large dierences in charge state over time, and may eventually render a battery pack unusable even if it's individual cells are ne. The main objective of the dierent battery balancing techniques is to avoid this.
Figure 6: Loss of usable capacity due to cell imbalance
2.1.6 Environmental aspects and economy
Trading with batteries is regulated within sweden by the swedish battery ordinance [5]. Importing of batteries that are hazardous to the environment is subject to a fee of up to 500 SEK/kg. Li-Ion batteries are not included in this group of battery technologies, hence they have an economical advantage over many other technologies.
2.2 Smart Battery System
2.2.1 Rationale
Traditionally, as a source of power for electronics, batteries have suered from two important drawbacks.
They are unpredictable. It is dicult for electronic equipment to know when their battery will run out. Factors such as temperature, age and state of charge all inuence the behaviour of battery cells. There is also no way of accurately predicting, from a single one-factor measurement, how the battery will cope with additional load, for example while spinning up a laptop hard drive.
Chargers have had to be individually designed for the specic charging characteristics of individual batteries. Chargers capable of being set up for dierent sizes and chemistries of batteries are in common use, but there has been no standardized way of designing an automatic charger to handle all available battery types without being actively set by the user.
More or less advanced methods have been used to try to predict battery performance. One method is using cell voltage and current to calculate state of charge. This method is described in a paper written by Johan Håkansson and Said Paknejad at the university of Örebro[6]. Some variation of this method is also likely what is used in many portable electronic devices. Depending on the circumstances, this method may or may not be very accurate. A guess is that for large variations in for example surrounding temperature, though, this method may lead to very inaccurate predictions. The SBS is a recent development in the industry, which makes it possible to address these drawbacks. The standard has its most widespread use in portable computers where the cost of the additional electronics is of little concern.
2.2.2 System overview
The Smart Battery concept comprises three main physical entities. They share a common data bus (the SMBus) and a power bus. The SMBus stan-dard denes the electrical interface as well as a protocol and a stanstan-dardized dataset.
The Smart Battery The Smart Charger The System Host
Three main documents decribe the interaction between these entities. Table 1 summarizes what information can be found in each one of them.
2.2.3 The System Management Bus
The SMBus [7] is the physical bus used in the SBS. It is a two wire interface based on the I2C communications interface. Basically, this means that
the two wires are pulled to the bus voltage by pull up resistors, and that the output stages of the communicating IC's are open collector or open drain, pulling the lines low to produce the clock and data signals. All IC's
Figure 7: The Smart Battery System Smart Battery System documentation
Document name Contents
System Management Bus (SMBus) Specication[7] Electrical and protocol related Smart Battery Data Specication[8] SBS Data set
Smart Battery Charger Specication[9] Smart Charger requirements Table 1: SBS documentation
connected to the bus must release the bus lines for the bus to be available for use. As soon as one of the IC's pulls the lines low, the bus is considered busy. Data is sent in packages according to the format seen in gure 8. The gure is borrowed from Maxim. [10]
Figure 8: SMBus transmission format
All transfers are initiated by a start condition. The start condition is the transition from high to low of the data line while the clock line is stable at logical one. Similarly, all transfers are ended by a stop condition where the clock line goes from low to high when the data line is at it's high level. Between the start and stop condition, the data is considered valid and can be read at all times when the clock line is high. After an initial start condition, a slave address is sent. The address consists of eight bits where the least signicant bit represents what direction consequent data is to be sent. A one tells the addressed slave that the master wishes to read data. The ninth bit is an acknowledge bit. When a slave recognizes it's address on the bus, it responds by pulling the data line low during this clock cycle. The next byte contains the data sent in the direction specied by the least signicant
bit of the slave address, the R/W (read write) bit.
Additional bytes of data can be sent after the rst byte, and the transfer is terminated with a stop condition after the transmission of the last byte. By sending a new start condition before a stop condition has been sent, a repeated start is issued. This is of use when a master wishes to initiate a new transmission without releasing the control of the bus. One example is shown below. Here, the master rst addresses a slave with the write bit set, and then sends data. After a repeated start the master then reads data from the same slave. In a smart battery, this could be used to read out some specic data specied by the byte sent. Figure 9 below shows a typical transaction. The master rst adresses the slave with the write bit cleared indicating a write is to be done. It then writes a byte of data. After issueing a repeated start and addressing the slave with the write bit set, indicating a read transaction, it then reads out data from the slave. A NACK and a stop condition concludes the transmission.
Figure 9: Typical SMBus package
2.2.4 Compatibility between SMBus and I2C
The SMBus is based on the I2C bus. By adressing the dierences between
the two, devices designed for the I2C bus will be compatible with SMBus devices, and vice versa [10]. The main dierences fall into the following categories.
Clock speed and bus time out. Logic levels.
Current levels and choice of pullup resistors.
The I2C bus is specied to operate from DC up to 3.4 MHz. An I2C slave
can extend the clock indenately while preparing a response. In the SMBus however, extension of clock is a way of signalling that an error occured. In the SMBus, a slave should reset it's interface whenever it detects that the clock or data line has been low for a period longer than the specied time out period. The highest frequency of operation is 100 KHz for the SMBus, and the time out requirement puts a lower limitation of 10 KHz on the frequency range. Table 2 summarizes the respective frequency ranges.
SMBus and I2C frequency range
Lower limit Upper limit SMBus 10KHz 100KHz
I2C DC 3.4MHz
Table 2: SMBus and I2C frequency range
Because of the time out requirement of the slaves, SMBus masters don't need any error recovery mechanisms. In I2C, there is the potential for a
slave to hang while holdning the data line low. The I2C master has to have
the data line is released. These dierences mean that there is a potential problem when mixing SMBus masters and I2C slaves.
The logic levels dier between the two buses[7][11]. The levels are shown in table 3. For I2C, the levels are specied both in terms of V
dd and as xed
levels where the latter are kept in the specicatin for backwards compati-bility.
SMBus and I2C logic levels (V)
Logic 0 Logic 1
SMBus < 0.8 2.1 − 5.5
I2C V
dd related (−)0.5 − 0.3 ∗ Vdd 0.7 ∗ Vdd - Vddmax + 0.5
I2C xed levels (−)0.5 − 1.5 3 − 5.5
Table 3: SMBus and I2C logic levels (V)
The allowed level of the current that needs to be sunk in order to con-trol the bus varies between I2C and SMBus. The maximum sink currents
of the two buses are shown in table 4, together with the corresponding minimum values of pull up resistors for two dierent bus voltages. The minimum values of the pull up resistors, in order to avoid overloading the bus sink transistor stages of the devices, can be calculated by equation 5. The Vdriverlow is the output low level of the bus devices' sink transistors.
Rpmin =
Vbus− Vdriverlow
Isinkmax
(5)
Max. sink current/Min. resistor value for Vdriverlow = 0.4V
Vbus= 3V Vbus= 5V
SMBus 350µA/7.4KΩ 350µA/13.1KΩ I2C 3mA/0.9KΩ 3mA/1.5KΩ
Table 4: Sink current and pull up resistors
2.2.5 The Smart Battery Data specication
This is the document describing the data set that is used in the communi-cation within the Smart Battery System.[8] It describes the protocols used e.g. read word and write word. It describes the commands sent to and from a smart battery, and the format of the corresponding data. It also describes a secondary communications mechanism, used as a safety measure should the SMBus communication fail.
2.2.6 The Smart Battery Charger specication
This document[9] describes the requirements of a smart charger i.e. one that has it's charging prole dictated by a smart battery. Two types of smart chargers are dened and referred to as level 2 and level 3 chargers respectively. In short, a level 2 charger is a slave device controlled by the smart battery acting as a master. The level 3 charger on the other hand may also act as a master, and take advantage of all the functions speed in the Smart Battery Data Specication.[8]
2.2.7 Downsides to the SBS
There are obviously drawbacks with incorporating additional electronics into battery pack. First and foremost it means additional manufacturing steps are needed and the cost of the additional parts may not be negligi-ble. A smart battery is around 25% more expensive [1] than it's dumb counterpart. The charger also becomes more expensive because of the com-munication requirement and because it needs to be able to set its output to dierent voltages. Smart batteries measure current owing from and into the battery to estimate state of charge. Using even the most accurate A/D converters, the estimate of charge level will become more and more inaccu-rate. This phenomenon is known as digital memory eect. To counteract this, the charge level needs to be calibrated at a regular interval by fully charging or discharging the battery pack.
2.2.8 Digital memory eect
NiCd batteries may show a memory eect[1] after extended use where the battery is not allowed to fully discharge, or is left connected to a charger after full charge has been reached. In a smart battery, the state of charge is estimated by incrementing or decrementing a fuel gauge. An A/D con-verter is used to do this, and depending on the implementation and applica-tion, it will after some time loose precision. This is a result of A/D converter inaccuracy. In for example a battery pack powering a computer, the rate of discharge is never constant but varies constantly. A/D conversion is the process of taking discrete-time samples of analog values. Anything hap-pening in between two samples will remain unknown to the A/D converter. Once the precision of the fuel gauge has been lost, the only way to restore it is to perform a calibration. This is done by performing a full charge and discharge. The SBS data specication includes provision for signaling it's need of calibration. See the BatteryMode CONDITION_FLAG of the Smart Battery Data Specication. [8]
3 Design process
3.1 Assessment of requirements
This thesis work was initiated with the intention of studying ways of mak-ing battery packs smarter the meanmak-ing of which was quite unclear. SAAB Aerotech had a list of properties they want in a battery, but the way of implementing them was not given. To make it possible to go forward a clearication was therefore needed. A standard product, a NiCd battery pack already in use, was choosen as a reference point in the studies de-scribed in this report. The work was continued with the intent of nding the requirements on a smarter replacement of the reference battery pack, and implement solutions to these requirements in in a prototype Smart Bat-tery pack. The questions needing answers before any further work could be commenced were the following.
What is the application of the reference battery?
What functionality do SAAB Aerotech, and customers need in a bat-tery system replacing the current one?
What functionality is not essential, but wanted could it be easily im-plemented?
To answer the questions above, discussions were held with the project supervisor at Saab Aerotech. Through these discussions a number of key questions and one initial requirement were identied. The properties de-scribed by the questions are considered wanted properties in any new bat-tery pack and are described below.
Can a battery pack be made smarter, i.e. can built in charging capa-bility be realized?
Can battery cell supervision be built in, so that prevention of damage to the battery cells is possible?
What are the benets of using Li-Ion cells instead of Nickel chemistry cells in battery packs, and what are the drawbacks?
How can battery packs be made to withstand the abuse of military use, such as an extreme temperature range and rough handling? Battery cells from the manufacturer A123 systems shall be used for
the study.
To detail these questions and to be able to formulate more requirements a call to FMV, the Swedish defence materiel adminstration, was placed. FMV are using the reference battery pack mentioned above. This was done to verify and possibly extend the list of wanted properties. The data that was collected through FMV and contacts within SAAB Aerotech is presented in section 3.2.
From the contact with FMV it also became clear that any new system including batteries would have to be compliant to the Smart Battery Sys-tem, SBS. This standard actually includes the properties listed by SAAB Aerotech in the rst place, and puts a name on them. In summary, the requirements put forth by SAAB Aerotech and their customer are the fol-lowing.
Compliance to the SBS standard is a must. This demand stems from a need for adaptation to international standards when designing new equipment.
A charger must be able of having its charging prole dictated by a connected battery, and may be either built into the battery pack itself or external. It needs to be able to supply enough current to allow fast charging. Support for these mechanisms is included in the SBS, although fast may mean dierent things.
A new battery pack has to be electrically and mechanically compatible with the present equipment. The SBS is chemistry independent, which means any type of battery cells can be used. The SBS species that a Smart Battery may enter a sleep mode when not connected to a smart charger or host, therefore in order to be backwards compatible, the battery pack must be instructed to function also without this connection.
Finally, the possibility of implementing the functionality shown below should be studied as part of the thesis work.
Ability to recharge directly from dierent power sources without an external charger. This ability is not described in the SBS, but could be inplemented by means of microcontroller software.
Ability to perform an emergency fast charge in situations where a minimal charging time is preferred over battery supervision and battery life.
Ability of delivering higher power than the typical commercial smart battery of comparable size.
Cell condition warning, some way of signalling that an individual bat-tery cell is likely to fail.
Some way of predicting how many batteries will be needed for a certain task and for dierent temperatures. The SBS leaves room for some custom functionality, this could be one of the extra functions. Battery warming, the ability of the battery to use some of it's energy
in order to warm itself in cold conditions. This may be of use when heavy loads are intermittently placed on a battery in cold weather. A simple user interface on the pack itself to allow the user to gain
access to the Smart Battery Functionality in old equipment not sup-porting the Smart Battery System. This is not described by the SBS, but a way to provide backwards compatibility
More energy per weight.
3.2 Reference battery pack
The following was learned regarding the reference battery pack and it's use. Data for the battery packs and equipment regarding its electrical char-acteristics is scarce. There is no real data of the failure rate or actual, in eld performance of the batteries.
There are two versions of the current battery pack, one rated 2.8Ah and one rated at 5Ah. The packs' chemistry is Ni-cd and they have a rated voltage of 12V, implying they are in 10-cell congurations. The specied temperature range of operability is -40 through +60
degrees C but users often have to warm the batteries inside their clothes before use.
Maximum discharge current from the pack ranges from 2A to 10A. The pack voltage may vary from approximately 16V for a fully charged
battery while still connected to a charger down to around 9.5V while connected to a load. Exact gures for the limits of operation of the equipment using the batteries seem to be unavailable.
The packs have to withstand substantially rough handling.
There is no regular cycling of battery packs, but rather just topping o
The charger is a universal model with quite a bulk, that charges both battery models.
Apart from the cost of the current battery system itself, it is also charged with a fee to pay for its safe recycling.
3.3 Special functionality
This section describes functionality that lies outside of the scope of the Smart Battery System. The items described are the results of the assessment of requirements described earlier in this report. The purpose of this section is to describe in higher detail the special functionality that SAAB Aerotech feel are interesting to look at when designing battery systems. The items below are looked into further in section 6.
3.3.1 Charger independent charging
Smart Batteries need Smart Chargers to recharge. The battery pack in-forms the charger of it's specic charging parameters. This is done by sending data over the SMBus or more specically by sending the function calls ChargingVoltage() and ChargingCurrent() specied in the Smart Bat-tery Data Specication [8]. This is initiated either from the charger side, by polling of the Smart Battery using the SBS commands, or from the battery side by sending the same commands. By updating this information during the charging process, any charging prole is possible. The battery may, for example, start it's charging at a low current and then request a higher ChargingCurrent() after warming up e.g. when charging at very low tem-peratures. In some applications, it may be benecial to be able to charge a battery pack without using a dedicated Smart Charger. In cases when the ability to charge a Smart Battery directly from an external power source is important, some means of controlling the ChargingCurrent() and Charging-Voltage() in the battery pack itself is needed, as opposed to just requesting charging by these parameters from a charger.
3.3.2 Emergency fast charging
In some scenarios, one may want to fast charge a battery pack at the fastest rate possible. Li-Ion batteries, and specically the A123 cells, like fast charging. Thus, the ability to connect directly to the battery pack's cell stack without including the charge control circuitry may be interesting. By surpassing the active circuits in this way, it would be possible to charge at a rate much higher than the maximum current allowed by the charge control circuit. Charging times down to a few minutes is possible with the A123 cells, at the possible expense of reducing their lifespan. Also, by disconnecting the charge control circuit, all battery safety functionality is made inoperable. Emergency fast charging is possible, but would have to be used sensibly. The ability of the battery pack to track it's state of charge would also be compromised.
3.3.3 Design for higher power battery packs
The reference of this thesis work, a small NiCd battery pack, is used to power relatively small loads. In some applications, batteries are used to drive heavy loads for short amounts of time. For this kind of task, the inclusion of active electronics as charge control is problematic. Even the most advanced transistors introduce losses into the circuit, losses show in the form of heat which has to be dissipated. At the end of this report, this subject is discussed in more detail.
3.3.4 Cell condition warning
Since the SBS reports voltage on a battery pack level rather than on a in-dividual cell level, it is possible for one cell in a battery pack to weaken without it showing to the connected host. If the electronics inside the bat-tery pack monitor the individual cell voltages e.g. to perform cell balancing, the electronics will know if one cell is about to give up. The SBS does not have any mechanism for reporting this.
3.3.5 Prediction of number of batteries needed for a given tem-perature and load
FMV wants some way of predicting how many battery packs would be needed for a certain task at a certain temperature. This would be something like the AtRate() functions described in the SBS data specication[8] and could use one of the ve available command codes reserved for proprietary functionality. These are referred to as OptionalMfgFunction commands in the documentation.
3.3.6 Battery warming
A cold battery performs poorly. By warming the battery before use its ability to release energy improves. This warming could be done within the battery cell, either by using power from the charger, or when a charger is not present by using some of the energy from the battery. Using some of the stored energy for warming, the amount of available energy may increase. 3.3.7 Battery user interface
When using the equipment designed for the reference battery together with a smart battery, the smart battery functionality will be unavailable, since there is no way of reading out data. To make use of the smart battery functionality in this situation, a simple user interface could be used. The interface would be an integral part of the battery pack, and make it possi-ble to view battery data in a simplied format. A way to implement this functionality is proposed at a later stage in this report.
3.4 What is on the market?
3.4.1 Smart Battery ASIC
There are numerous electronic ciruits available intended for use in smart battery packs or smart chargers. These circuits are designed to be used in conjunction with external transistor switches, current sensing shunt re-sistors et.c. Based on a study of available solutions to implementing the SBS, one was picked out as the most interesting. ATMEL has released a microcontroller with built in functionality catering for most of the needs one might have while designing a smart battery. The attractive part about this solution is that all functionality needed to implement a SBS compli-ant battery, apart from switch transistors and shunt resistor, is put on a single chip. Below, a smart charger IC is presented as well as a simpler type of battery monitor chip. The monitor chip would have to be interfaced through a microcontroller to be able to be used in a smart battery since it's communication is done via a one wire protocol.
3.4.2 LTC1759
The LTC1759 is designed to implement a level 2, slave, Smart Charger. It has an SMBus interface for programming of charging current and charging voltage. It's outputs drive a switch mode DC-DC converter, the operation of which is monitored by integrated A/D converters.
3.4.3 DS2438
The DS2438 is a Smart Battery Monitor intended to be placed inside a battery pack. It communicates though a proprietary one wire interface. It has an integrated current accumulator and measures current by voltage drop over an external sense resistor. It has an A/D converter for measurement of battery voltage and temperature. It has an integrated clock to keep track of real time. It's operation is controlled by sending commands that initiate some action within the chip, the result of which is then read out by issuing another command. The chip is intended for smaller battery packs and would need to be used in conjunction with a microcontroller to act as a smart battery for two reasons. Firstly, it doesn't support the SMBus and Smart Battery Data protocol either on a hardware or on a software level and secondly, it doesn't have any battery protection functionality built in. This kind of chip could still be used to gain real time data from a battery pack, but the pack would not be a smart battery without additional support from a microcontroller.
3.4.4 The ATMEL ATmega406 microcontroller
The ATmega406[12] is an 8 bit RISC microcontroller. It is designed to meet the specic demands of Smart Battery implementations. As such, it has some special battery related features built in. It is powered by a built in voltage regulator, and it's input may vary between 4V and 25V. The lower limit of input voltage of 4V means that t will not be possible to use the controller for a battery pack with only one cell (in the case of Li-Ion). In reality however, it is more likely that the controller is chosen for applications where three or four cells are used. It has individual 12 bit A/D converter inputs for four cells, and has calibration values for the converters stored in memory from the factory. Using these calibration values, the cell voltages are calculated as described in equation 6
Vcell[mV ] =
A/D output ∗ gain calibration word
T BD (6)
The TBD is interesting, but this really is the information provided by the data sheet [12]. Atmel apparently made up their mind on this value, since they state it is 214 in their Atmega 406 reference design description
[13].
The controller has individual resistor / Field Eect Transistor, FET, nets for the four cell inputs making it possible to discharge unbalanced cells into the other cells of a battery pack. The typical magnitude of the balancing current is 2 mA.
The controller has an A/D converter for the measurement of current (voltage drop over a shunt resistor). This converter outputs an 18 bit value which can be used to keep track of the charge level of the battery, and a faster conversion time 13 bit value that can be used for battery protection and measurement of instantaneous current.
The input range of the converter is limited to ± 220 mV according to the data sheet. The step size for measured current for dierent shunt resistances are shown in table 5 for the 18 bit output and in table 6 for the 13 bit output.
Resolution of current measuring A/D converter 5 mΩ 10 mΩ 15 mΩ
0.335 µA 0.168 µA 0.112 µA
Table 5: A/D converter step size vs. shunt resistor value for the 18 bit output
Resolution of current measuring A/D converter 5 mΩ 10 mΩ 15 mΩ
10.7 mA 5.37 mA 3.58 mA
Table 6: A/D converter step size vs. shunt resistor value for the 13 bit output
The latter is used by an integrated battery protection module, which can be set to turn o the current to the load should the supplied current surpass a programmed value i.e. a short circuit protection. This switching of the outputs is done by means of two external FET transistors. The transistors are driven by special high voltage output pins of the controller. The controller has a TWI interface that can be used to implement the SMBus communications functionality. It's physical package is a 48 pin Low prole Quad Flat Pack, LQFP.
3.5 What has been done within the company
Smart batteries in dierent shapes and with dierent electrical data are available on the market. Also, chargers for these batteries can easily be found.[14] The motivation for the development of new designs must stem from somewhere else. Obviously, it is when some special functionality or performance is needed that one could want to develop new designs. Exam-ples of such special functionality could be the ability to charge at a higher than normal rate, the ability to handle special interface requirements or the possibility to use some special kind of cells. Within SAAB Aerotech, eorts involving smart batteries have already been made. Göran Ottosson and Per Finander at SAAB Aerotech, Växjö have been working on smart battery technology for a couple of years. A visit was made at their facility to study what they had done. Starting out in 2005, they designed a smart battery unit intended for the supply of regulated power to portable elec-tronics. The unit is a hotswap, two battery unit that will power the load from one or two connected batteries or an external DC supply connected to the unit. If there is more power available from the external supply than what is used by the load, the unit will charge the connected batteries. The unit communicates with a terminal program in a PC through RS232 and can communicate through the SMbus.
One year later, in 2006, the team built on the experience gained from the smart battery unit and in a short amount of time developed a six channel smart battery charger.
Both products use commercially available smart batteries, and use charge controller ASIC's and microcontrollers.
From searching the web for smart battery products, it seems the area not really covered by COTS products are smart batteries specialized for high rates of charge and discharge. Most smart batteries are naturally intended for portable computers with moderate power demands. For example, this manufacturer[14] states the highest continuous discharge current for any of their batteries to be 8A. This rate of discharge is far from what is possible with the chosen cells, the A123 m1. Later sections of this report discuss how to design a smart battery that takes advantage of the properties of the cell.
3.6 Specication of design
The specication of the design desribed in this report is based on the assess-ment of requireassess-ments described earlier. SBS compliance means the use of microcontrollers is inevitable. Environmental concerns teamed with capac-ity and performace demands is the basis of the decision to use Li-Ion battery cells in this study. More precisely, Li-Ion cells from A123-systems will be used, based on a decision by SAAB Aerotech. The electrical specications of the equipment using the studied reference battery, and the compatibility with such equipment dictate what congurations of cells are possible. They also dictate what components can be used for switching.
3.6.1 Battery block diagram
Figure 10 indicates what part of the SBS concept will be implemented within this project. In order to be able to use the battery implementation as a platform for experimentation with Smart Battery functionality, a system host is needed. The host will be implemented as a PC program performing the communication tasks of a level 3 charger as described in section 2.2.6, i.e. the host acts as a bus master. The resulting communication pattern is as described by gure 9 of section 2.2.3. In order to be able to communicate with the battery, a computer serial port to I2C adapter will be purchased
and modied to allow SMBus communication. Figure 10 also shows the adapter and the user interface.
3.6.2 Functionality of battery
The battery pack is designed for a subset (see table 7 of section 3.6.3) of the functionality specied by the SBS standard. Only enough functionality is included to allow the experiment board to act as a platform to try ideas on and perform experimentation with.
The battery is designed to act as a bus slave, replying to calls from the bus master by returning requested data.
The required voltage range means that 4 A123 Li-Ion cells in series provide compatible pack voltage. The required lowest voltage of 9.5V means that the cells will not be discharged to their recommended cuto voltage (2V/cell at room temperature)[3] and thus will not be optimally used. This mismatch will be larger as the temperature de-creases as described in section 2.1.1
Its microcontroller measures instantaneous current in and out of the battery, it measures individual cell voltages and total stack voltage. It has a user interface (display) capable of showing the operating point
Figure 10: Delimitation of implementation
It has a IEEE 1149.1[15] compliant JTAG interface for programming Its microcontroller implements a software fuse able of disconnecting
the pack if certain criteria are met.
Additional connectors are included to allow exclusion of active com-ponents in the path of current to and from the cell stack. This feature is included for experimentation purposes on the experiment board desribed further on in this report.
3.6.3 Supported Smart Battery commands
A subset of the commands specied in the Smart Battery Data Specication [8] shall be implemented in the code written for this project. The command subset is chosen so as to give a reasonable idea of what functionality is possible using a design similar to the one described within this report. More information on the commands, their intended responses and their specied accuracy can be found in the referred document. The chosen subset is shown in table 7
4 Implementation
4.1 Hardware
This section describes the implementation of an experimental setup that allows experimenting with smart battery functionality. It was decided that the implementation should support most of the functionality of the chosen microcontroller. The implementation consists of a main circuit board, a detachable user interface board and a modied RS232 to I2C adapter. The
Commands and expected replies BatteryMode() 0x03 Sets mode and contains ags AtRate() 0x04 Sets value for predictions
AtRateTimeToEmpty() 0x06 Predicts time to empty for load as set by AtRate() AtRateOk() 0x07 Predicts ability to supply AtRate() for 10 seconds Voltage() 0x09 Pack voltage in mV
Current() 0x0A Instantateous current in mA with sign Absolute SoC() 0x0E Remaining capacity in % of designed capacity RemainingCapacity() 0x0F Remaining capacity in mAh
FullChargeCapacity() 0x10 Returns predicted full charge capacity
RunTimeToEmpty() 0x11 Predicts remaining life at present rate in minutes ChargingCurrent() 0x14 Returns desired charging rate
ChargingVoltage() 0x15 Returns desired charging end voltage BatteryStatus() 0x16 Returns the battery's status word
DesignCapacity() 0x18 Returns the theoretical capacity of a new pack DesignVoltage() 0x19 Returns the theoretical voltage of a new pack
Table 7: The chosen subset of commands
outer dimensions of the circuit board are chosen in such a way that it ts inside a box of the same size as the reference NiCd battery pack, together with four of the chosen Li-Ion battery cells. The SBS implicitly species what connectors the board should have. The ve pins are: battery positive and negative connection, SMBus data and clock and the back up variable resistance safety signal. Four A123 m1 cells need to be connected, and to be able to monitor the state of these on a cell level, another ve pins are needed. The pins carrying current need to be able to handle the current owing to and from the cells during charging and discharging. The ATMEL controller has transistor driver outputs for switching of the output of the battery. The transistors used for the switching need to be chosen such that they are able to handle the currents owing through them. They also need to be compatible with the driver voltage levels presented by the controller. The board needs a shunt resistor for the measurement of current and a connector for the JTAG debugger. Lastly, a 32,768kHz clock crystal is included to make it possible to maintain track of the real time within the controller. This section describes how the above has been met within this work.
4.1.1 CAD tools
The P-Cad 2004 toolchain was used to design the circuit board. Some of the components used in the design were not present in the default libraries, and had to be modeled. This was done with the Library Excecutive, Pattern Editor and Symbol Editor that come with the installation.
4.1.2 Schematic design
The schematic design is based on the datasheet reference design and the implementation found on the development board. The design takes into ac-count the easy availability of components. Apart from the microcontroller, all components are bought from ELFA. It is implemented in such a way that it is easy to test the functionality of the available microcontroller functions. The transistors used as a switch between the battery pack output and the battery cell stack are of the TO-252 type. The chosen transistor has the
lowest RDSon available from ELFA with a suitable price and VGSon and
VGSof f matching the driver outputs of the Atmega 406. To measure current
owing in and out of the battery, a 5mΩ sense resistor was chosen. The input range of the microcontroller A/D converter will translate to a |30A| range for the current measured. The schematics and the bill of material (BOM) are shown in appendix B.
4.1.3 Circuit board design
The circuit board is designed to handle both large currents and weak analog and digital signals. The layout of the components is done accordingly. The high power components are put together on one side of the board. JTAG port, microcontroller and I/O ports are put along the other side. All com-ponents except the connectors are surface mounted and are spaced out so as to make it possible to solder them by hand. The board is produced by a manufacturer of development PCB's and it's construction is very basic being only two layer FR-4 with 35µm copper. It is tin-plated and lacks a solder mask. The minimum dimensions for the process used by the manu-facturer is summarized in table 8. The nished circuit board is shown in gure 11
Process minimum dimensions Denition Dimension µm
Via size 300 Line width 150 Line separation 150
Table 8: Minimum dimensions of PCB process
Apart from where large currents will be owing, the circuit board is de-signed using close to the minimum dimensions in most places. The absolute minimum dimensions have been avoided to make it less likely that boards will be faulty. The microcontroller is in a 7*7mm LQFP48AA package, with a 0.5mm pitch. The passive components are of the 0805 and sot23 types. The standard linewidth of the circuit board is 0.2mm, via hole diameter is 0.3mm and the annual ring is 0.15mm making the via diameter 0.6mm.
For the power transistors and the shunt, the dissipation of power has to be taken into account. Relevant gures for thermal resistance of the transistors are found in their datasheet[16]. For the power transistors, there is an estimate of the junction to ambient resistance Rθja. The estimate
is valid when the transistor is mounted to a one square inch FR-4 board using a standard footprint. The secondary side of the board is assumed to be metallized.[16, 17] This situation is similar to the board designed within this thesis work. Using the estimated Rθja , and letting Q denote
dissipated power, the temperature of the semiconductor junction, Tj, can
be expressed with equation 7. The equation is the thermal management equivalent to ohms law, and is described in books about electronics, for example this one [18].
Tj= Tamb+ Q ∗ Rθja (7)
The transistor datasheet species the resistance RDS(on)to 65mΩ. The
Figure 11: Printed circuit board
current can then be expressed with equation 8. The Rθjais specied to be
50K/W
Tj= Tamb+ (UDS(transistor)∗ I) ∗ Rθja= Tamb+ (65mΩ ∗ I2) ∗ 50K/W (8)
Table 9 shows the estimated junction temperature for dierent loads at ambient temperatures ranging from -20to 60. The thermal resistance of a circuit board is dicult to estimate. In the design described in this text, two power transistors and a shunt resistor share roughly two square inches of board space. The tranistors' footprints are from the standard footprint library of the CAD program used. This means that the actual value for thermal resistance Rθja should be in the same region as the value given in
the transistor datasheet. This table is meant to indicate a problem that shows up when moving to higher power outputs. The 5mΩ shunt resistor obviously doesn't have a junction that can break, and since it dissipates less than one tenth of the power dissipated in each transistor, it's contribution to the warming of the board is negligible.
The table shows that for the chosen transistors, and without using any extra heat sink, the limitation arising from the maximum allowable junc-tion temperature Tj limits the maximum current the board can handle to
around 6A. There are many ways to overcome this problem for applications needing higher power output. The best way, obviously, would be to use transistors with a lower internal resistance RDS(on) or to use more
tran-sistors in parallel. Both sides of the circuit board are shown in appendix A.
Estimated junction temperature No load 1A 2A 3A 4A 5A -20 -16,7 -7 9,3 32 61,3 0 3,3 13 29,3 52 81,3 20 23,3 33 49,3 72 101,3 40 43,3 53 69,3 92 121,3 60 36,3 73 89,3 112 141,3
Table 9: Estimated junction temperature 4.1.4 User interface design
The SBS makes it possible for battery powered equipment to gather battery data from it's battery and display it on it's display. One aim with this report is to show how a smart battery system could be designed, that takes advantage of the functionality of a smart battery when used with equipment that doesn't support the SBS. This has been done by including a small user interface in the battery pack design. The interface is controlled by a pushbutton and is described by gure 12.
Figure 12: Battery pack information panel
The user interface is constructed on a stripboard using all hole mounted components. It connects to the battery controller board using a 20 pin header and a cable. The physical dimensions are kept small to make it possible to mount the board together with the battery controller board and cells inside a box the same size as the reference battery pack.
4.1.5 IPort/ AI rs232 to I2C adapter
The IPort/AI is the name of an RS-232 format to I2C format adapter. It
is designed for use together with a terminal emulator. It's operation is controlled by sendning it text commands. The list of available commands can be seen in the manufacturer's documentation [19]. The adapter has internal pull up resistors that were disconnected and replaced by external resistors with a higher resistance as described in section 2.2.4. This way, the adapter was made compatible with SMBus devices.
4.1.6 Experiment board
An experiment board to allow experimentation with the circuit board was put together and is shown in gure 14. The board includes apart from the circuit board itself the four battery cells, an SMBus connector and two