RE: [PATCH] smb347_charger: cleaned battery power supply attributes

From: Pallala, Ramakrishna
Date: Sun May 06 2012 - 01:54:42 EST


Hi Anton,

> On Sat, May 05, 2012 at 09:33:54PM +0530, Ramakrishna Pallala wrote:
> > CURRENT_NOW and VOLTAGE_NOW should be instantaneous readings from
> > power supply(ex: battery).
> >
> > smb347 charger driver reports charge voltage for VOLTAGE_NOW and
> > charge current for CURRENT_NOW attributes which are not instantaneous
> > readings.
>
> Em. While charging, I guess charge current == instantaneous battery current? Should we
> then report it in such cases? And while discharging and not charging, assuming that HW
> can't report the real battery current flow, we can return some fancy errno code, like
> ENODATA?

Battery current depends on the following things during charging:
1. is the battery in constant current(CC) charge mode or in constant voltage(CV) charge mode?
during CC mode battery current will be close to charge current(with no load) but it will get
reduced gradually as the battery charging approaches CV mode. same for battery voltage.
in CC mode battery voltage will be less than charge voltage and as we approach CV mode
battery voltage be close to charge voltage setting.

2. instantaneous battery current & voltage also depends on the load current.

we should read battery current & voltage from either PMIC/ADC channels or from fuel gauge chip.

Thanks,
Ram
èº{.nÇ+‰·Ÿ®‰­†+%ŠËlzwm…ébëæìr¸›zX§»®w¥Š{ayºÊÚë,j­¢f£¢·hš‹àz¹®w¥¢¸ ¢·¦j:+v‰¨ŠwèjØm¶Ÿÿ¾«‘êçzZ+ƒùšŽŠÝj"ú!¶iO•æ¬z·švØ^¶m§ÿðà nÆàþY&—