forked from len0rd/rockbox
battery capacity (1500-2400 in 50mAh steps) saved to disk
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@3008 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
ae1ba1d5de
commit
0bf70e65e8
5 changed files with 20 additions and 29 deletions
|
|
@ -73,9 +73,9 @@ int battery_capacity = 1500; /* only a default value */
|
|||
|
||||
void set_battery_capacity(int capacity)
|
||||
{
|
||||
int values[8] = {1500, 1600, 1700, 1800, 1900, 2000, 2100, 2200};
|
||||
|
||||
battery_capacity = values[capacity];
|
||||
battery_capacity = capacity;
|
||||
if ((battery_capacity > BATTERY_CAPACITY_MAX) || (battery_capacity < 1500))
|
||||
battery_capacity = 1500;
|
||||
}
|
||||
|
||||
#ifdef HAVE_CHARGE_CTRL
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue