summaryrefslogtreecommitdiff
path: root/firmware/export/powermgmt.h
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/export/powermgmt.h')
-rw-r--r--firmware/export/powermgmt.h8
1 files changed, 6 insertions, 2 deletions
diff --git a/firmware/export/powermgmt.h b/firmware/export/powermgmt.h
index 2847156f46..ce006e9145 100644
--- a/firmware/export/powermgmt.h
+++ b/firmware/export/powermgmt.h
@@ -26,13 +26,15 @@
26#define BATTERY_LEVEL_FULL 400 /* 4.00V */ 26#define BATTERY_LEVEL_FULL 400 /* 4.00V */
27#define BATTERY_CAPACITY_MIN 2200 27#define BATTERY_CAPACITY_MIN 2200
28#define BATTERY_CAPACITY_MAX 3200 /* max. capacity selectable in settings */ 28#define BATTERY_CAPACITY_MAX 3200 /* max. capacity selectable in settings */
29#elif CONFIG_BATTERY == BATT_3AAA_ALKALINE /* Ondio, Alkalines */ 29#define BATTERY_TYPES_COUNT 1
30#elif CONFIG_BATTERY == BATT_3AAA /* Ondio */
30#define BATTERY_LEVEL_SHUTDOWN 260 /* 2.60V */ 31#define BATTERY_LEVEL_SHUTDOWN 260 /* 2.60V */
31#define BATTERY_LEVEL_EMPTY 270 /* 2.70V */ 32#define BATTERY_LEVEL_EMPTY 270 /* 2.70V */
32#define BATTERY_LEVEL_DANGEROUS 280 /* 2.80V */ 33#define BATTERY_LEVEL_DANGEROUS 280 /* 2.80V */
33#define BATTERY_LEVEL_FULL 450 /* 4.50V */ 34#define BATTERY_LEVEL_FULL 475 /* 4.75V */
34#define BATTERY_CAPACITY_MIN 500 35#define BATTERY_CAPACITY_MIN 500
35#define BATTERY_CAPACITY_MAX 1500 /* max. capacity selectable in settings */ 36#define BATTERY_CAPACITY_MAX 1500 /* max. capacity selectable in settings */
37#define BATTERY_TYPES_COUNT 2 /* Alkalines or NiMH */
36#else /* Recorder, NiMH */ 38#else /* Recorder, NiMH */
37#define BATTERY_LEVEL_SHUTDOWN 450 /* 4.50V */ 39#define BATTERY_LEVEL_SHUTDOWN 450 /* 4.50V */
38#define BATTERY_LEVEL_EMPTY 465 /* 4.65V */ 40#define BATTERY_LEVEL_EMPTY 465 /* 4.65V */
@@ -40,6 +42,7 @@
40#define BATTERY_LEVEL_FULL 585 /* 5.85V */ 42#define BATTERY_LEVEL_FULL 585 /* 5.85V */
41#define BATTERY_CAPACITY_MIN 1500 43#define BATTERY_CAPACITY_MIN 1500
42#define BATTERY_CAPACITY_MAX 3200 /* max. capacity selectable in settings */ 44#define BATTERY_CAPACITY_MAX 3200 /* max. capacity selectable in settings */
45#define BATTERY_TYPES_COUNT 1
43#endif 46#endif
44 47
45#define BATTERY_RANGE (BATTERY_LEVEL_FULL - BATTERY_LEVEL_EMPTY) 48#define BATTERY_RANGE (BATTERY_LEVEL_FULL - BATTERY_LEVEL_EMPTY)
@@ -111,6 +114,7 @@ bool battery_level_safe(void);
111 114
112void set_poweroff_timeout(int timeout); 115void set_poweroff_timeout(int timeout);
113void set_battery_capacity(int capacity); /* set local battery capacity value */ 116void set_battery_capacity(int capacity); /* set local battery capacity value */
117void set_battery_type(int type); /* set local battery type */
114 118
115void set_sleep_timer(int seconds); 119void set_sleep_timer(int seconds);
116int get_sleep_timer(void); 120int get_sleep_timer(void);