2S LiPo Battery pack

IMGP3715.jpg2S Battery pack is very useful. It can be used to supply 5V electronic circuit without DC/DC. With help of a simple boost a 2S battery can drive 3 power LED lamp with reasonable currents. Etc…

Let’s see what is required for reliable, safe lithium polymer batter pack with two serially connected cells (2S LiPo battery pack).

Obviouslly, at least two cells are needed. Unfortunately, LiPo cells are very dangerous if used over specified limits. Most dificult is maximum cell voltage during charge. If cells are aexposed to voltages above 4,2V they can burn, but not at the charging, this could happen at any time after charging.  The absolute maximum charging voltage is 4.25V per cell. To avoid burning down the house and other troubles, a battery protection circuit board (PCB) is a must with LiPo cells.

All components should be nicely packaged inside rigid housing. LiPo cells have plastic body made from soft foil. It’s easy punctured. Hole in LiPo cell results in sudden death. Moisture from air penetrates inside nd reacts with battery inner layers. Battery expands, rapidly self-discharge and die in short period from few hours to couple of days, depending on puncture size.

Battery cells

I found good source for industrial grade LiPo cells. Presented battery pack uses two cells LP7545135. There are many low cost sources, but not all are good quality. And good quality means cells will not explode, burn or leak. Good quality LiPo cell exhibits some properties superior to low-cost “chinese” cells:

  • at least 3.7V plateau voltage
  • at least 2C discharge rate without significant degradation due to discharge
  • stable discharge under wide oprating conditions
  • low self-discharge
  • at least 75% capacity after 500 cycles

Short circuit

LiPo cells must not be short circuited! A short circuit can result in over-heating of terminals and provide in ignition source. More than a momentary short circuit will generally reduce the cell or battery service life and can lead to ignition of surrounding materials within the cell or battery if the seal integrity is damaged. Extended short-circuiting creates high temperature in the cell and at the terminals. Physical contact to high temperatures can cause skin burns. In addition, extended short-circuit may cause the cell or battery to flame.

Cell edge

The cell edge of the heat seal zone is electronically conductive. Avoid the edge cross battery terminals, PCB, or conductive surfaces.

Bending

Do not bend or fold or fall the battery or part of the battery. It may cause the battery be damaged and result in the battery swelling, leaking, explosive or ignition.

Do not open or manipulate the folded cell edge.

Do not bend or fold the sealing edge. And do not tear off the sealing film.

 

Battery protection and fuel gauge

The cells must be equipped with a PCM that protects the cell/battery from overcharging, over-discharging and over-current. Maybe the best solutions for lithium cell protection is offered by Seiko Instruments Inc. (SII). Unfortunately for average hobbist, the SII is not optimal selection. Their chips are hard to obtain in small quantities. They have strict policy for samples: design must be approved by SII, minimum order quantity is one tray, etc… It is possible to find some part numbers from SII via octopart search, but not all.

Another option is Maxim/Dallas component with battery protection and fuel gauge in single chip: DS277x.

The DS2775–DS2778 report available capacity for rechargeable lithium-ion (Li+) and Li+ polymer (Li-Poly) batteries in mAh and as a percentage of full. Safe operation is ensured by the integrated Li+ protector. The DS2776/DS2778 support SHA-1-based challenge-response authentication in addition to all other DS2775/DS2777 features.

Precision measurements of voltage, temperature, and current, along with a cell characteristics table and application parameters, are used for capacity estimation calculations. The capacity registers report a conservative estimate of the amount of charge that can be removed given the current temperature, discharge rate, stored charge, and application parameters.

The DS2775–DS2778 operate from +4.0V to +9.2V for direct integration into battery packs with two Li+ or Li- Poly cells.

In addition to nonvolatile storage for cell compensation and application parameters, the DS2775–DS2778 offer 16 bytes of EEPROM for use by the host system and/or pack manufacturer to store battery lot and date tracking information. The EEPROM can also be used for nonvolatile storage of system and/or battery usage statistics. A Maxim 1-Wire® (DS2775/DS2776) or 2-wire (DS2777/DS2778) interface provides serial communication to access measurement and capacity data registers, control registers, and user memory. The DS2776/DS2778 use the SHA-1 hash algorithm in a challenge-response pack authentication protocol for battery-pack verification.

Schematic circuit is shown in diagram:

2S-lipo-bttery-pack-with-protection.jpg

Circuit is placed on double sided, 45mm wide PCB, same as battery cells.

slika4.jpg

Battery protection circuit operats with two N-type power MOSFETs, which operates as switches for charging and discharging. When any of protection limits are exceeded, one of the FETs are swithed off. The Li+ protection function ensures safe, high-performance operation. nFET protection switches are drivenwith a charge pump that maintains gate drive as the cell voltage decreases. The high-side topology preserves the ground path for serial communication while eliminating the parasitic charge path formed when the fuel-gauge IC is located inside the protection FETs in a low-side configuration. The thresholds for overvoltage,undervoltage, overcurrent, and short-circuit current are programmable. Detailed operation is described in datasheet: http://datasheets.maxim-ic.com/en/ds/DS2775-DS2778.pdf

Communication with DS277x

Two functions are required, Battery_Read() and Battery_Write().

/**
 * Battery_Read()
 *
 * Reads single byte from DS277x via I2C
 *
 * @param[in] 	adr – address
 * @return 	BYTE – read value
 */
BYTE Battery_Read(BYTE adr)
{
BYTE rv;

	I2Cm_fSendStart(0x59,I2Cm_WRITE);       // First write slave...
	I2Cm_fWrite(adr);                       //  ... address
	I2Cm_fSendRepeatStart(0x59,I2Cm_READ);  // Followed by reading
	rv = I2Cm_bRead(I2Cm_NAKslave);    	   // Single byte
						   // ... and NACK, to report end
    I2Cm_SendStop();
    return rv;
}

/**
 * Battery_Write()
 *
 * ZWrite single byte to DS277x via I2C
 *
 * @param[in] 	adr – address
 * @param[in] 	val - value
 */
void Battery_Write(BYTE adr, BYTE val)
{

	I2Cm_fSendStart(0x59,I2Cm_WRITE);       // Send adress
	I2Cm_fWrite(adr);                       // first,
	I2Cm_fWrite(val);                       // followed by data
    I2Cm_SendStop();
}

Complete source code is in this archive file: zip.png (16×16) DS277x.

Datasheet has error in slave addressing. Communication with slave address 0110100b is not successfull. Correct slave address is 1011001b:

slika9.jpg

Fuel gauge parameters

Fuel gauge is universal device. It calculates charge state with battery cell model parameters given at the design time. To achieve reasonable accuracy in estimating remain-ing capacity, the cell performance characteristics overtemperature, load current, and charge-termination pointmust be considered. Since the behavior of Li+ cells isnonlinear, these characteristics must be included in thecapacity estimation to achieve an acceptable level ofaccuracy in the capacity estimation. Source for deining cell model parameters is battery datasheet:

slika2.jpg

Calculating parameters, which are finally stored in EEPROM is complicated. I prepared excel file with calculation. It’s commented with register names and battery cell paramters. In addition to cell model characteristics, several appl-cation parameters are needed. All are listed in file: excel_icon.gif (16×16) ds277xregisters

Complete list of parameters for LP7545135 are shown in following tables:

Battery cell Active Empty state

Parameter Value Unit Register
Active Empty point value for +40°C 30 mAh 68h
Full 40 4700 mAh 6Ah:6Bh
Full point 30-40 4653 mAh 6c
Full point 20-30 4582.5 mAh 6d
Full point 10-20 4418 mAh 6e
Full point 0-10 4230 mAh 6f
Active empty 30-40 47 mAh 6c
Active empty 20-30 70.5 mAh 6d
Active empty 10-20 103.4 mAh 6e
Active empty 0-10 211.5 mAh 6f
Active empty 30-40 9.261084 mAh 70h
Active empty 20-30 23.15271 mAh 71h
Active empty 10-20 46.30542 mAh 72h
Active empty 0-10 125.0246 mAh 73h
74h

 

Application parameters:

Parameter Value Units Register
Rsense 10 mOhm /
Nominal capacity 4700 mAh /
Ageing capacity 4500 mAh 63h:62h
Charge voltage 4.2 V 64h
Minimum Charge Current 80 mA 65h
Active Empty Voltage 2.75 V 66h
Active Empty Current 800 mA 67h

Final EEPROM content

Address Register description Value (hex)
61h Accumulation Bias Register (AB) 00
62h Aging Capacity Register MSB (AC) 1C
63h Aging Capacity Register LSB (AC) 20
64h Charge Voltage Register (VCHG) D7
65h Minimum Charge Current Register (IMIN) 10
66h Active-Empty Voltage Register (VAE) 8C
67h Active-Empty Current Register (IAE) 28
68h Active-Empty 40 Register 06
69h Sense Resistor Prime Register (RSNSP) 64
6Ah Ful l 40 MSB Register 1D
6Bh Ful l 40 LSB Register 60
6Ch Ful l Segment 4 Slope Register 10
6Dh Ful l Segment 3 Slope Register 18
6Eh Ful l Segment 2 Slope Register 39
6Fh Ful l Segment 1 Slope Register 41
70h AE Segment 4 Slope Register 05
71h AE Segment 3 Slope Register 08
72h AE Segment 2 Slope Register 0B
73h AE Segment 1 Slope Register 25
74h SE Segment 4 Slope Register 03
75h SE Segment 3 Slope Register 04
76h SE Segment 2 Slope Register 08
77h SE Segment 1 Slope Register 1B
78h Sense-Resistor Gain Register MSB (RSGAIN) 04
79h Sense-Resistor Gain Register LSB (RSGAIN) 00
7Ah Sense-Resistor Temperature Coeff icient Register (RSTC) 00
7Bh Current Offset Bias Register (COB) 00
7Ch TBP34 Register 28
7Dh TBP23 Register 14
7Eh TBP12 Register 05
7Fh Protector Threshold Register 0

 

Battery pack design and manual soldering

The battery housing should have sufficient mechanical strength. No sharp edge components shall be inside the battery housing. The sharp edge may destroy the cell packaging. No cell movement is allowed in the battery housing. Avoid designing airtight battery housing.

Battery cell manual soldering guidelines:

  • Use a solder with temperature controlled and ESD
  • Soldering temperature should not exceed 350°C
  • Soldering times should not be longer than 3s
  • Soldering times should not exceed 5 times
  • Keep battery tab cold down before next time soldering.
  • Do not directly heat cell body. It may cause the battery be damaged by heat above 90°C.

Battery pack housing is alluminium profile. Both ends are closed with plastic caps, which can be simply machined with home made CNC milling machine. One plastic cover has opening for DB9 connector. Two pins are used for I2C, remaining pins are divided in two groups of three pins for power connection.

 

IMGP3707.jpg IMGP3709.jpg IMGP3713.jpg IMGP3717.jpg

 

Battery pack weights 337g, which is not so bad for fully protected (electronically and mechanically) 35Wh of instant energy.

Battery pack testing

Finally, complete battery pack was tested. After full charge, battery was discharged with constant current load. Discharge current was 3,3A. Result is shown in diagram:

discharge.jpg

Resources:

cells LP7545135

battery driver source code: zip.png (16×16) DS277x

Fuel gauge register calculator: excel_icon.gif (16×16) ds277xregisters

Altium designer project for PCB: DS277x altium designer project

 

 

Leave a Reply