Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Changed this code if-statement back to stock because this
- * parameter is now user settable by changing the actual
- * register value inside the battery chip EEPROM.
- * --RP
- */
- if ((di->status.status_reg & 0x80) &&
- (di->status.percentage == 100)) {
- di->status.battery_full = 1;
- charge_mode = CHARGE_BATT_DISABLE;
- }
- /* We don't move from full to not-full until
- * we drop below 95%, to avoid confusing the
- * user while we're maintaining a full charge
- * (slowly draining to 95 and charging back
- * to 100)
- * Oddly, only Passion is for 99% cycles, HTC
- * set the Bravo to 95%.
- * -od of xbravoteam
- *
- * Set 99 for Passion - pershoot
- */
- if (di->status.percentage < 99) {
- di->status.battery_full = 0;
- }
- if (temp >= TEMP_HOT) {
- if (temp >= TEMP_CRITICAL)
- charge_mode = CHARGE_BATT_DISABLE;
- /* once we charge to max voltage when hot, disable
- * charging until the temp drops or the voltage drops
- */
- if (volt >= TEMP_HOT_MAX_MV)
- di->status.cooldown = 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement