In the previous tutorial, the basics of Lithium-ion batteries were discussed. Also, it was discussed how it is important to handle these batteries with care. as mentioned in the previous tutorial, that Lithium-ion batteries need to be charged using CC-CV method, in this tutorial, a Li-ion battery charger for a single-cell Li-ion battery of nominal voltage 3.7 V will be designed.

*Battery linear charger real time circuit arrangement*

There are basically two topologies for designing the charger circuit -

1. Charger using Linear Regulator

2. Charger using Switching Regulator

There are charger modules available in the market which can be used to charge the Li-ion batteries. In this tutorial, a charger built using the basic electronic components including Linear Regulator will be designed from scratch. The charger circuit will be customized as per the battery specifications and the charging requirements.

Regular 3.7 V Li-ion batteries have a maximum rated voltage of 4.2 V per cell. That means, when the terminal voltage of the battery reaches 4.2 V, it is fully charged and cannot store charge beyond that. In Constant Voltage state, the same voltage is applied at a constant rate by the charger circuit at the terminals of the battery. Trying to charge the battery by applying a higher voltage than this may charge the battery fast but it reduces the battery life.

Apart from maximum rated voltage or peak terminal voltage, another important consideration to be kept in mind while designing the charger circuit is the C rate. If a Li-ion battery of 3000 mAh is charged with 1500 mA maximum current then, it will be called 0.5 C charge rate. For safety reasons, the Li-ion batteries must be charged with 0.5 C to 0.8 C charge rate.

The charging cycle of a Li-ion Battery have basically two stages -

1. Constant Current Charging (abbreviated as CC mode)

2. Constant Voltage Charging (abbreviated as CV mode)

But some chargers are designed to skip or add more stages in the charging process. In this tutorial, the charger designed will have both the basic stages that include Constant Current and Constant Voltage mode. Check out the previous tutorial - “Basics of Li-ion Battery Charging” to learn about the fundamentals of Li-ion batteries and their charging methods.

The charger circuit designed in this tutorial is divided into two parts -

a) Designing Constant Current and Constant Voltage Source

b) Designing switching mechanism

In this tutorial, designing of Constant Current and Constant Voltage Source will be discussed and design of switching mechanism will be discussed in the next tutorial. So, in this tutorial, first, a Constant Current Source having a charge rate of 0.5 C will be designed. This will be followed by designing a Constant Voltage Source of 4.2 V.

**Components Required - **

The components required designing Constant Current Source and Constant Voltage Source using linear regulators are listed in the table below -

**Block Diagram - **

*Linear Regulator based 3.7 V Lithium Ion Battery Charger Block Diagram *

**Circuit Connections - **

The charger circuit follows the following charge algorithm -

*Linear Regulator based 3.7 V **Lithium-Ion** Battery Charging Algorithm*

For designing the constant current source and constant voltage source for the charger circuit, following steps are followed -

1) Testing the battery specifications

2) Determining the design parameters of the charger circuit

3) Designing Constant Current Source using LM317 IC

4) Designing Constant Voltage Source using LM317 IC

**Testing the Battery Specifications - **

Before designing the charger, it is first important to verify the battery specifications. First of all, it is important to test the maximum charge rate for the battery. In this circuit, a 18650 Li-ion battery with a maximum rated voltage of 4.2 V / 1000 mAh has been taken for charging. If this battery is charged with 0.5 C charge rate, that means the maximum current supplied by the charger circuit to the battery must be 500 mA.

First, the battery will be tested in CC mode and will be charged with a maximum current of 500 mA. In this mode, the voltage of the battery should be in between 3 V and 4 V as per the maximum rated voltage of the battery. In CC mode the charging current must be 500 mA but the charging voltage has to be determined for this mode. This voltage can be determined by the charging curve of the battery shown below.

*Charging Curve of Li-ion Battery*

It can be observed that in CC mode the battery charging voltage is equivalent to the battery real voltage. Therefore, in this mode, the battery should take a voltage drop across it which must be equal to its real voltage. When the battery voltage reaches to 4.0 V then a Constant Voltage equal to the maximum rated voltage of the battery i.e. 4.2 V must be provided to it. The battery charging current then should start decreasing and when it reaches to 0.1 C i.e. 100 mA, then the battery must be considered fully charged.

**Determining design parameters for the charger circuit**

Practically, the on-paper battery specifications seem to be less useful. For a maximum current of 500 mA, a constant current source using a linear IC can be designed. By this constant current source, on trying to charge the Li-ion battery in CC mode, it was observed that during charging the actual voltage of the battery was 3.5 V which on charging by a maximum current of 500 mA, the battery voltage exceeded to 4 V. As per the standards, the battery can withstand without any deviation in its actual voltage up to 1C charge rate. But it was observed that the battery voltage has a deviation in its actual voltage in CC mode. Although the label at the battery reads 1000 mAh, it was not charging at 0.5 C. Therefore, after initial testing of the charger circuit, it was easy to conclude that the battery is not meant to charge at 500 mA.

So for charging this battery, the charging current should be decreased so that the desired voltage at the battery terminals could be achieved. So the battery is tested at different currents less than 500 mA. Going through several hit and trials, it was observed that the battery voltage approaches near its real voltage at a charging current of 60 mA. So the charger circuit must be designed for charging the battery at 60 mA in CC mode.

Finally, the design parameters of the charger circuit after initial testing of the battery with the charger circuit are as follow -

- Charging current in CC mode must be 60 mA

- Charging voltage in CV mode must be 4.2 V

For charging the battery in CC and CV mode separate constant current and constant voltage source need to be designed. Both constant current and constant voltage sources can be designed using LM317 voltage regulator IC. There needs to use two separate LM317 ICs, one to function as a Constant Voltage source and another to function as Constant Current Source.

The working of LM317 as Constant Current Source and Constant Voltage Source can be understood from the following tutorials -

- LM317 as Adjustable Constant Current Source

- LM317 Power Supply

**Designing Constant-Current Source**

The following circuit of LM317 works as a constant current source -

**LM317 Constant Voltage Source Circuit for Lithium Ion Battery Linear Charger**

For designing this circuit, the value of resistance Rs has to be determined. It value can be calculated using the direct equation for constant current source circuit. Here the resistance R_{s }decides the current at the output and its value can be calculated by the following equation -

I= 1.25/ R_{s }(Equation given in the datasheet of LM317)

Desired Current, I = 60mA

R_{s}= 1.25/0.06

R_{s} = 20 ohm (approx.)

The value of desired constant current can be changed by changing the value of R_{s.} As LM317 can provide a maximum current of 1.5 A, that is why the value of R_{s} cannot be less than 0.83E.

In the selection of any resistor, there are basically two parameters that have to be considered, one is its resistance and another is its power rating. The power rating expressed in watts depends upon the maximum current which can flow through the resistor without damaging it. So, if a low watt resistor is taken, then, the high current will heat up the resistor and damage it. So, it is equally important to determine the power rating of the resistor as well. It can be calculated as follow -

Maximum current which has to flow from the resistor R_{s }is 60mA.

So, Power = (voltage drop across R_{s})*(maximum current across R_{s})

Power = 1.25*0.06

Power = 75 mW (approx.)

Therefore, the maximum power which is dissipated by R_{s }is 75 mW.

As per the availability, a resistor of 0.25W or 250 mW can be used.

It must be noted that the charging circuit has been designed for a charging current of 60 mA in CC mode. But as per the charging current of a specific battery, it can be changed to a maximum value 1.25 A by changing the value of resistance R_{s} in the LM317 circuit.

**Designing Constant Voltage Source -**

The following circuit of LM317 works as a constant voltage source.

*LM317 Constant Voltage Source Circuit for Lithium Ion Battery Linear Charger*

For using the LM317 as a constant voltage source, a resistive voltage divider circuit is used between the output pin and the ground. The voltage divider circuit has a programming resistor (Resistor R_{p}) and another is output set resistor (Resistor R_{s}). By taking a perfect ratio of programming resistor and the output resistor, the desired value of output voltage can be determined. The output voltage V_{out }can be calculated by the following equation -

V_{out }= 1.25*(1 + (R_{c}/ R_{p}) (Equation given in the datasheet of LM317)

The typical value of resistor R_{p} should be from 220E to 240E for the stability of the circuit. In this circuit, the value of programming resistor R_{p} is taken to be 220E. Now as per the requirement, the output voltage should be 4.2V, so the value of resistor R_{c} will be as follow -

Desired output voltage, V_{out}= 4.2V

Output set resistor, R_{p}= 220E

Putting values of V_{out} and R_{p} in the equation,

4.2 = 1.25*(1+ (R_{c} / 220)

After solving the equation, value of Rc is calculated as follow -

R_{c} = 520 ohm (approx.)For using the LM317 as a constant voltage source, a resistive voltage divider circuit is used between the output pin and the ground. The voltage divider circuit has a programming resistor (Resistor R_{p}) and another is output set resistor (Resistor R_{s}). By taking a perfect ratio of programming resistor and the output resistor, the desired value of output voltage can be determined. The output voltage V_{out }can be calculated by the following equation -

V_{out }= 1.25*(1 + (R_{c}/ R_{p}) (Equation given in the datasheet of LM317)

The typical value of resistor R_{p} should be from 220E to 240E for the stability of the circuit. In this circuit, the value of programming resistor R_{p} is taken to be 220E. Now as per the requirement, the output voltage should be 4.2V, so the value of resistor R_{c} will be as follow -

Desired output voltage, V_{out}= 4.2V

Output set resistor, R_{p}= 220E

Putting values of V_{out} and R_{p} in the equation,

4.2 = 1.25*(1+ (R_{c} / 220)

After solving the equation, value of Rc is calculated as follow -

R_{c} = 520 ohm (approx.)

Therefore by using two LM317 ICs, a Constant Current Source of 60 mA and Constant Voltage Source of 4.2 V are finally designed. Both of these smaller circuits will be part of the charger circuit for the Li-ion battery.

*Constant Voltage Source and Constant Current Source in Lithium Ion Battery Linear Charger Circuit*

It is important that the battery rated current and maximum rated voltage are must be checked before designing the charger and using the charger circuit with it. The charging voltage of the battery must be greater than its maximum rated voltage in CV mode. The battery must be charged with 0.5 C to 0.8 C charge rate. The resistor Rs must have an appropriate watt rating to prevent the resistor from any damage.

The input voltage and output current limit of the LM317 IC should not be exceeded as this can damage the regulator IC. These specifications must be checked from the datasheet of the IC. If high current (500 mA or more) is taken in CC mode from LM317 IC, a heat sink must be used with it to aid its cooling and to increase its lifespan. The heat sink is also a conductor so, it should be taken care that the pins of the IC not get shorted with the heat sink as that can lead to short circuiting and damage to the IC.

In the next tutorial, the switching mechanism for switching from constant current mode to constant voltage mode will be discussed and the complete charger circuit for 3.7 V Li-ion battery using the linear regulator will be designed.

.

## Comments

## HI, I have a 11.1v 4400mah

HI,

I have a 11.1v 4400mah battery in 3s2p configuration .I need to charge a battery with cc and cv mode using LM317 IC with automatically switching from cc to cv mode when it is needed.I have a smps of 12v ,2a. So how can I make circuit after smps?First I need to increase smps voltage from 12v to near around 13 because battery's peak voltage is 12.6 v when it is fully charged. So how can i make 12v to 13v?And secondly CC and CV circuit with LM317 and auto switching from cc to cv with indication?

Please help me on this...

Thanks.

## What is the chemistry of the

What is the chemistry of the battery ?

## Hello Sham,As you want to

Hello Sham,

As you want to charge a Li-ion battery pack whose excited voltage is 12.6V and nominal voltage is 11.1V. But you have only 12V DC supply. So here you have two queries first how to increase the DC voltage and second to use an automatic switching and battery indication. In the above experiment you can read about automatic switching with battery indication. So please read the above experiment carefully for your second query.

Now regarding your first query (step up the SMPS voltage) you can do two things

1. The excited voltage of the Li-ion battery is its maximum voltage, it is recommended to charge a Li-ion battery below its excited voltage. So it is fine if you charge the battery at 12V for better battery life. But if you want to charge the battery at its maximum excited voltage.Then you can read the second point

2. For stepping up the DC votage to higher voltage there are following methods

i. First way is to use a "Voltage Doubler Circuit"

ii. Second you can use a Boost converter IC like XL6009 or you can make a simple boost converter circuit using some inductors and capacitors. Boost converter is a DC to DC converter which step up your input DC voltage to a higher voltage.

You can find Voltage Doubler circuit, Simple Boost converter circuit and XL6009 IC circuit (Experiment named - Power bank) here at engineers garage website. So please refer them. Even though if you have any query then please feel free to ask. I hope this will help you in your design.

## Hii,i am Gayathri , i have a

Hii,

i am Gayathri ,

i have a Tech Fest in my college. so i need to implement ELECTRONIC'S AND COMMUNICATION based project.

i will be pleased if u suggest me easy project ....to implement .

## Add new comment