A battery charger circuit is arranged to charge batteries in a constant current
mode. A charging current flows from a power device through a sense resistor to
a battery. The voltage across the sense resistor is used to measure the charging
current. The temperature of the sense resistor changes either because of a change
in ambient temperatures or as the result of the charging current creating thermal
energy in the sense resistor. The measured charging current from the sense resistor
changes because of the temperature coefficient of the sense resistor, creating
inaccuracies. A temperature compensation block uses a set of controllable current
mirror banks to adjust reference signals such that the effects of the temperature
coefficient in the sense resistor are minimized and an accurate charging current
measurement is achieved.