Friday, May 18, 2012

USB Charging

USB 1.x/2.0 standard pinout
Pin 1 : VBUS (red) : +5V
Pin 2 : D- (white) : data -
Pin 3 : D+ (green) : data +
Pin 4: GND (black) : ground


The USB Battery Charging Specification of 2007 defines new types of USB ports, e.g., charging ports. As compared to standard downstream ports, where a portable device can only draw more than 100mA current after digital negotiation with the host or hub, charging ports can supply currents above 0.5A without digital negotiation. A charging port supplies up to 500 mA at 5 V, up to the rated current at 3.6 V or more, and drop its output voltage if the portable device attempts to draw more than the rated current. There is no upper limit for the rated current of a charging downstream port, as long as the connector can handle the current (standard USB 2.0 A-connectors are rated at 1.5 A). The charger port may shut down if the load is too high. The Battery Charging Specification 1.2 of 2010 makes clear, that there are safety limits to the rated current at 5 A coming from USB 2.0.


Charging ports exist in two flavors: charging downstream ports (CDP), supporting data transfers as well, and dedicated charging ports (DCP), without data support. With charging downstream ports, current passing through the thin ground wire may interfere with high-speed data signals. Therefore, current draw may not exceed 900 mA during high-speed data transfer. On a dedicated charging port, the D+ and D- pins are shorted. Before the battery charging specification was defined, there was no standardized way for the portable device to inquire how much current was available. For example, Apple's iPod and iPhone chargers indicate the available current by voltages on the D- and D+ lines. When D+ = D- = 2V, the device may pull up to 500 mA. When D+ = 2.0 V and D- = 2.8 V, the device may pull up to 1000 mA of current.


USB 2.0
One unit load is 100 mA.
A device may draw a maximum of 5 unit loads (500 mA) from a port.
A low-power device draws at most 1 unit load, with minimum operating voltage of 4.4 V.
USB 3.0
One unit load is 150 mA.
A device may draw a maximum of 5 unit loads (900 mA) from a port.
A low-power device draws at most 1 unit load, with minimum operating voltage of 4 V.

Lithium-ion Polymer Battery
LiPo batteries are usually composed of several identical secondary cells in parallel to increase the discharge current capability. The voltage (nominal cell voltage is 3.7V) of a Li-poly cell varies from about 2.7 V (discharged) to about 4.23 V (fully charged), and Li-poly cells have to be protected from overcharge by limiting the applied voltage to no more than 4.235 V per cell used in a series combination.

Example, a circuit produces +5V and +3.3V to power portable devices It allows the port to maintain communications while supplying power, e.g., to charge a Li+ battery.

IC1 - MAX1811 (Li+ battery charger)
  • Pulling SELI terminal low sets the charging current to 100mA for low-power USB ports, and pulling high sets 500mA for high-power ports. 
  • Pulling SELV high or low configures the chip for charging a 4.2V or 4.1V Li+ battery. To protect the battery, IC1's final charging voltage exhibits 0.5% accuracy. 
  • /CHG light up an LED during charging.
  • MAX1811 has preconditioning that soft-starts a near-dead battery cell before charging. It is available in 1.4W thermally enhanced 8-pin SO package.
  • Battery voltages less than 2.5V activate a 43mA preconditioning mode (/CHG = high impedance). Normal charging resumes when the battery voltage exceeds 2.5V.
  • At high input voltages (5.5V) and low cell voltages (2.7V), the MAX1811’s thermal loop may limit the charge current until the cell voltage rises. 
IC2 - step-up DC-DC converter, boosts VBATT to 5V and delivers up to 450mA. The low-battery detection circuitry and true shutdown (limits battery current to less than 2μA) capability protects the Li+ battery.
  • The low-battery trip point is set by an external resistive divider between VBATT and GND, connected to LBI. Connecting the low-battery output (LBO) to shutdown (SHDN) causes IC2 to disconnect its load in response to a low battery voltage.
  • The n-channel FET at LBO eliminates on/off oscillation (caused by internal source impedance of a Li+ battery) by adding hysteresis to the low-battery detection circuitry. When VBATT goes below 2.9V, LBO opens and allows SHDN to be pulled high, turning on the FET. With the FET turned on, the parallel combination of 1.3MΩ and 249kΩ eliminates oscillation by setting the battery turn-on voltage to 3.3V.
IC3 - step-down converter, bucks 5V to 3.3V, and delivers up to 250mA.

MAX1811 Functional Diagram

Wednesday, May 16, 2012

About Charge and Discharge

The available capacity of a battery depends upon the rate at which it is discharged.  The capacity printed on a battery is usually the product of 20 hours multiplied by the constant current that a new battery can supply for 20 hours at 68 F° (20 C°), down to a specified terminal voltage per cell. For example, 2000mAh = 100mA x 20h.

Discharge
Peukert's law describes the (approximated) relationship between current, discharge time, and capacity for a lead acid battery: t = Q1 / I^k, where
t = amount of time (in hours) that a battery can sustain
Q1 = capacity at a one-ampere discharge rate, which must be expressed in A·h
I =  current drawn from battery (A)
k = 1.2-1.6 for flooded batteries, 1.1-1.3 for  lead–acid battery
(For low values of I internal self-discharge must be included.)

High-drain loads such as digital cameras can result in delivery of less total energy, as happens with alkaline batteries. For example, a 2000 mA·h battery would not sustain a current of 1 A for a full two hours as its stated capacity implies.

Example, SANYO Eneloop rechargeable battery
Batteries
Degradation usually occurs because electrolyte migrates away from the electrodes or because active material falls off the electrodes.

NiCd batteries suffer the drawback that they should be fully discharged before recharge. Without full discharge, crystals may build up on the electrodes, thus decreasing the active surface area and increasing internal resistance. This decreases battery capacity and causes the "memory effect". These electrode crystals can also penetrate the electrolyte separator, thereby causing shorts. NiMH, although similar in chemistry, does not suffer from memory effect to quite this extent.

The chemistry that eneloop batteries use is Nickel Metal Hydride (NiMH). A NiMH battery can have two to three times the capacity of an equivalent size NiCd, and their energy density approaches that of a lithium-ion cell.

NiMH use positive electrodes of nickel oxyhydroxide (NiOOH), like the NiCd, but the negative electrodes use a hydrogen-absorbing alloy instead of cadmium. The "metal" M is actually an intermetallic compound. Many different compounds have been developed for this application, but those in current use fall into two classes. The most common is AB5, where A is a rare earth mixture of lanthanum, cerium, neodymium, praseodymium and B is nickel, cobalt, manganese, and/or aluminium. Any of these compounds serve the same role, reversibly forming a mixture of metal hydride compounds.

Lithium polymer batteries (abbreviate LiPo) devolved from lithium-ion batteries. The primary difference is that the lithium-salt electrolyte is not held in an organic solvent but in a solid polymer composite such as polyethyleneoxide or polyacrylonitrile. The battery is constructed as:

  • Positive electrode: LiCoO2 or LiMn2O4
  • Separator: Conducting polymer electrolyte (e.g., polyethyleneoxide, PEO)
  • Negative electrode: Li or carbon-Li intercalation compound

Charge
NiMH Trickle Charge
A NiCd charger should not be used as an automatic substitute for a NiMH charger. The simplest way to safely charge a NiMH cell is with a fixed low current, with or without a timer. Most manufacturers claim that overcharging is safe at very low currents, below 0.1 C (where C is the current equivalent to the capacity of the battery divided by one hour). The Panasonic (SANYO) NiMH charging manual warns that overcharging for long enough can damage a battery and suggests limiting the total charging time to 10 to 20 hours. Panasonic's handbook also recommends that NiMH batteries on standby are kept charged by a lower duty cycle approach, where a pulse of a higher current is used whenever the battery's voltage drops below 1.3 V. This can extend battery life and use less energy.

ΔV charging method
When the battery is fully charged the voltage across its terminals drops slightly. The charger can detect this and stop charging. This method is often used with NiCd cells which have a large drop in voltage at full charge but the voltage drop is much less pronounced for NiMH and can be non-existent at low charge rates, which can make the approach unreliable. Therefore, with this method, a much higher charging rate can be used than with a trickle charge, up to 1 C. At this charge rate, ΔV is approximately 5–10mV per cell.

Lithium Ion Charging
The chemistry is basically the same for the two types of batteries, so charging methods for lithium polymer batteries can be used for lithium-ion batteries.

Trickle charging is not acceptable for lithium batteries. The Li-ion chemistry cannot accept an overcharge without causing damage to the cell, possibly plating out lithium metal and becoming hazardous.

In order to charge the Li ion battery safely, the basic algorithm is:

  • charge at constant current (0.2 C to 0.7 C depending on manufacturer) until the battery reaches 4.2 Vpc (volts per cell), 
  • hold the voltage at 4.2 volts until the charge current has dropped to 10% of the initial charge rate. The termination condition is the drop in charge current to 10% (the top charging voltage and the termination current varies slightly with the manufacturer).
Notes:
  • The charge cannot be terminated on a voltage. The capacity reached at 4.2 Volts per cell is only 40 to 70% of full capacity unless charged very slowly. For this reason you need to continue to charge until the current drops, and to terminate on the low current.
  • Most dedicated lithium polymer chargers use a charge timer for safety; this cuts the charge after a predefined time (typically 90 minutes).

Example, Apple's lithium-ion polymer batteries page
"Most lithium-ion polymer batteries use a fast charge to charge your device to 80% battery capacity, then switch to trickle charging. That’s about two hours of charge time to power an iPod to 80% capacity, then another two hours to fully charge it, if you are not using the iPod while charging. "