diff options
Diffstat (limited to 'firmware/target/arm/tcc780x/cowond2/powermgmt-cowond2.c')
-rw-r--r-- | firmware/target/arm/tcc780x/cowond2/powermgmt-cowond2.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/firmware/target/arm/tcc780x/cowond2/powermgmt-cowond2.c b/firmware/target/arm/tcc780x/cowond2/powermgmt-cowond2.c index 751e45eb6a..683c1c3be7 100644 --- a/firmware/target/arm/tcc780x/cowond2/powermgmt-cowond2.c +++ b/firmware/target/arm/tcc780x/cowond2/powermgmt-cowond2.c | |||
@@ -26,32 +26,32 @@ | |||
26 | #include "pcf50606.h" | 26 | #include "pcf50606.h" |
27 | 27 | ||
28 | unsigned short current_voltage = 3910; | 28 | unsigned short current_voltage = 3910; |
29 | 29 | ||
30 | const unsigned short battery_level_dangerous[BATTERY_TYPES_COUNT] = | 30 | const unsigned short battery_level_dangerous[BATTERY_TYPES_COUNT] = |
31 | { | 31 | { |
32 | /* FIXME: calibrate value */ | ||
33 | 3380 | 32 | 3380 |
34 | }; | 33 | }; |
35 | 34 | ||
36 | const unsigned short battery_level_shutoff[BATTERY_TYPES_COUNT] = | 35 | const unsigned short battery_level_shutoff[BATTERY_TYPES_COUNT] = |
37 | { | 36 | { |
38 | /* FIXME: calibrate value */ | ||
39 | 3300 | 37 | 3300 |
40 | }; | 38 | }; |
41 | 39 | ||
42 | /* voltages (millivolt) of 0%, 10%, ... 100% when charging disabled */ | 40 | /* voltages (millivolt) of 0%, 10%, ... 100% when charging disabled */ |
43 | const unsigned short percent_to_volt_discharge[BATTERY_TYPES_COUNT][11] = | 41 | const unsigned short percent_to_volt_discharge[BATTERY_TYPES_COUNT][11] = |
44 | { | 42 | { |
45 | /* FIXME: calibrate values. Table is "inherited" from iPod-PCF / H100 */ | 43 | /* Standard D2 internal battery */ |
46 | { 3370, 3650, 3700, 3740, 3780, 3820, 3870, 3930, 4000, 4080, 4160 } | 44 | { 3370, 3690, 3750, 3775, 3790, 3820, 3880, 3940, 3980, 4090, 4170 } |
45 | |||
46 | /* TODO: DIY replacements eg. Nokia BP-4L ? */ | ||
47 | }; | 47 | }; |
48 | 48 | ||
49 | #if CONFIG_CHARGING | 49 | #if CONFIG_CHARGING |
50 | /* voltages (millivolt) of 0%, 10%, ... 100% when charging enabled */ | 50 | /* voltages (millivolt) of 0%, 10%, ... 100% when charging enabled */ |
51 | const unsigned short percent_to_volt_charge[11] = | 51 | const unsigned short percent_to_volt_charge[11] = |
52 | { | 52 | { |
53 | /* FIXME: calibrate values. Table is "inherited" from iPod-PCF / H100 */ | 53 | /* FIXME: voltages seem to be offset during charging (eg. 4500+) */ |
54 | 3370, 3650, 3700, 3740, 3780, 3820, 3870, 3930, 4000, 4080, 4160 | 54 | 3370, 3690, 3750, 3775, 3790, 3820, 3880, 3940, 3980, 4090, 4170 |
55 | }; | 55 | }; |
56 | #endif /* CONFIG_CHARGING */ | 56 | #endif /* CONFIG_CHARGING */ |
57 | 57 | ||