Our fuel gauge code is based on blaze board TI 2.5 release kernel (commit id e9515a74fe28cf097adf37875acc03476cb4770a) in Omapedia website.
In the capacity_changed function in kernel/android-3.4/driver/power/twl6030_bci_battery.c file, one comment said
/* Compensate based on the sense resistor value */
acc_q = acc_q * 10 / (int)di->cell.config->r_sense;
1. Also in blaze board, di->cell.config->r_sense=10, does this mean the 10mohm in the system?
2. Is there any PMIC document mention about such fuel gauge conversion? We are using 20mohm sense resistor here but our capacity percentage calculation always have around 25 more percent errors and then corrected by EDV 10% voltage point. Note: we adjust the EDV voltage points based on real battery discharge curve.