diff options
Diffstat (limited to 'firmware/export/powermgmt.h')
-rw-r--r-- | firmware/export/powermgmt.h | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/firmware/export/powermgmt.h b/firmware/export/powermgmt.h index 5be3a39c1d..39e2e6eab9 100644 --- a/firmware/export/powermgmt.h +++ b/firmware/export/powermgmt.h | |||
@@ -27,7 +27,7 @@ | |||
27 | 27 | ||
28 | enum charge_state_type | 28 | enum charge_state_type |
29 | { | 29 | { |
30 | /* sorted by increasing charging current */ | 30 | /* sorted by increasing charging current (do not change!) */ |
31 | #if CONFIG_CHARGING >= CHARGING_MONITOR | 31 | #if CONFIG_CHARGING >= CHARGING_MONITOR |
32 | CHARGE_STATE_DISABLED = -2, /* Disable charger use (safety measure) */ | 32 | CHARGE_STATE_DISABLED = -2, /* Disable charger use (safety measure) */ |
33 | CHARGE_STATE_ERROR = -1, /* Some error occurred that should not allow | 33 | CHARGE_STATE_ERROR = -1, /* Some error occurred that should not allow |
@@ -143,13 +143,16 @@ unsigned int battery_voltage(void); /* filtered batt. voltage in millivolts */ | |||
143 | 143 | ||
144 | #ifdef HAVE_BATTERY_SWITCH | 144 | #ifdef HAVE_BATTERY_SWITCH |
145 | unsigned int input_millivolts(void); /* voltage that device is running from */ | 145 | unsigned int input_millivolts(void); /* voltage that device is running from */ |
146 | #endif /* HAVE_BATTERY_SWITCH */ | ||
146 | 147 | ||
148 | #if defined(HAVE_BATTERY_SWITCH) || defined(HAVE_RESET_BATTERY_FILTER) | ||
147 | /* Set the filtered battery voltage (to adjust it before beginning a charge | 149 | /* Set the filtered battery voltage (to adjust it before beginning a charge |
148 | * cycle for instance where old, loaded readings will likely be invalid). | 150 | * cycle for instance where old, loaded readings will likely be invalid). |
149 | * Also readjust when battery switch is opened or closed. | 151 | * Also readjust when battery switch is opened or closed. |
150 | */ | 152 | */ |
151 | void reset_battery_filter(int millivolts); | 153 | void reset_battery_filter(int millivolts); |
152 | #endif /* HAVE_BATTERY_SWITCH */ | 154 | #endif /* HAVE_BATTERY_SWITCH || HAVE_RESET_BATTERY_FILTER */ |
155 | |||
153 | 156 | ||
154 | /* read unfiltered battery info */ | 157 | /* read unfiltered battery info */ |
155 | void battery_read_info(int *voltage, int *level); | 158 | void battery_read_info(int *voltage, int *level); |