forked from len0rd/rockbox
stupid bug, trickle setting in menu didn't work
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@3007 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
6ebf5e432a
commit
ae1ba1d5de
2 changed files with 5 additions and 1 deletions
|
|
@ -463,7 +463,7 @@ static bool trickle_charge(void)
|
|||
{
|
||||
bool result;
|
||||
result = set_bool( str(LANG_TRICKLE_CHARGE), &global_settings.trickle_charge );
|
||||
enable_trickle_charge(result);
|
||||
enable_trickle_charge(global_settings.trickle_charge);
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -422,6 +422,8 @@ static void power_thread(void)
|
|||
trickle_sec = CURRENT_NORMAL * 60 / CURRENT_CHARGING; /* first guess, maybe consider if LED backlight is on, disk is active,... */
|
||||
trickle_time = 0;
|
||||
charge_state = 2; /* 0: decharging/charger off, 1: charge, 2: top-off, 3: trickle */
|
||||
} else {
|
||||
charge_state = 0; /* 0: decharging/charger off, 1: charge, 2: top-off, 3: trickle */
|
||||
}
|
||||
} else {
|
||||
/* if we didn't disable the charger in the previous test, check for low positive delta */
|
||||
|
|
@ -444,6 +446,8 @@ static void power_thread(void)
|
|||
trickle_sec = CURRENT_NORMAL * 60 / CURRENT_CHARGING; /* first guess, maybe consider if LED backlight is on, disk is active,... */
|
||||
trickle_time = 0;
|
||||
charge_state = 2; /* 0: decharging/charger off, 1: charge, 2: top-off, 3: trickle */
|
||||
} else {
|
||||
charge_state = 0; /* 0: decharging/charger off, 1: charge, 2: top-off, 3: trickle */
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue