diff options
Diffstat (limited to 'firmware/target/sh/archos/recorder/powermgmt-target.h')
-rw-r--r-- | firmware/target/sh/archos/recorder/powermgmt-target.h | 89 |
1 files changed, 0 insertions, 89 deletions
diff --git a/firmware/target/sh/archos/recorder/powermgmt-target.h b/firmware/target/sh/archos/recorder/powermgmt-target.h deleted file mode 100644 index 6b68d05bd4..0000000000 --- a/firmware/target/sh/archos/recorder/powermgmt-target.h +++ /dev/null | |||
@@ -1,89 +0,0 @@ | |||
1 | /*************************************************************************** | ||
2 | * __________ __ ___. | ||
3 | * Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
4 | * Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
5 | * Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
6 | * Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
7 | * \/ \/ \/ \/ \/ | ||
8 | * $Id$ | ||
9 | * | ||
10 | * Copyright (C) 2002 by Heikki Hannikainen, Uwe Freese | ||
11 | * Revisions copyright (C) 2005 by Gerald Van Baren | ||
12 | * | ||
13 | * This program is free software; you can redistribute it and/or | ||
14 | * modify it under the terms of the GNU General Public License | ||
15 | * as published by the Free Software Foundation; either version 2 | ||
16 | * of the License, or (at your option) any later version. | ||
17 | * | ||
18 | * This software is distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY | ||
19 | * KIND, either express or implied. | ||
20 | * | ||
21 | ****************************************************************************/ | ||
22 | #ifndef POWERMGMT_TARGET_H | ||
23 | #define POWERMGMT_TARGET_H | ||
24 | |||
25 | /* | ||
26 | * Define CHARGING_DEBUG_FILE to create a csv (spreadsheet) with battery | ||
27 | * information in it (one sample per minute/connect/disconnect). | ||
28 | * | ||
29 | * This is only for very low level debug. | ||
30 | */ | ||
31 | #undef CHARGING_DEBUG_FILE | ||
32 | |||
33 | |||
34 | /* stop when N minutes have passed with avg delta being < -0.05 V */ | ||
35 | #define CHARGE_END_SHORTD 6 | ||
36 | /* stop when N minutes have passed with avg delta being < -0.02 V */ | ||
37 | #define CHARGE_END_LONGD 50 | ||
38 | |||
39 | /* Battery % to start at top-off */ | ||
40 | #define START_TOPOFF_CHG 85 | ||
41 | /* Battery % to start at trickle */ | ||
42 | #define START_TRICKLE_CHG 95 | ||
43 | /* power thread status message */ | ||
44 | #define POWER_MESSAGE_LEN 32 | ||
45 | /* minutes: maximum charging time for 1500 mAh batteries | ||
46 | * actual max time depends also on BATTERY_CAPACITY! */ | ||
47 | #define CHARGE_MAX_MIN_1500 450 | ||
48 | /* minutes: minimum charging time */ | ||
49 | #define CHARGE_MIN_MIN 10 | ||
50 | /* After charging, go to top off charge. How long should top off charge be? */ | ||
51 | #define TOPOFF_MAX_MIN 90 | ||
52 | /* which voltage is best? (millivolts) */ | ||
53 | #define TOPOFF_VOLTAGE 5650 | ||
54 | /* After top off charge, go to trickle harge. How long should trickle | ||
55 | * charge be? */ | ||
56 | #define TRICKLE_MAX_MIN 720 /* 12 hrs */ | ||
57 | /* which voltage is best? (millivolts) */ | ||
58 | #define TRICKLE_VOLTAGE 5450 | ||
59 | /* initial trickle_sec for topoff */ | ||
60 | #define START_TOPOFF_SEC 25 | ||
61 | /* initial trickle_sec for trickle */ | ||
62 | #define START_TRICKLE_SEC 15 | ||
63 | |||
64 | #define PID_DEADZONE 4 /* PID proportional deadzone */ | ||
65 | |||
66 | extern char power_message[POWER_MESSAGE_LEN]; | ||
67 | |||
68 | extern int long_delta; /* long term delta battery voltage */ | ||
69 | extern int short_delta; /* short term delta battery voltage */ | ||
70 | |||
71 | extern int powermgmt_last_cycle_startstop_min; /* how many minutes ago was | ||
72 | the charging started or | ||
73 | stopped? */ | ||
74 | extern int powermgmt_last_cycle_level; /* which level had the batteries | ||
75 | at this time? */ | ||
76 | |||
77 | extern int pid_p; /* PID proportional term */ | ||
78 | extern int pid_i; /* PID integral term */ | ||
79 | extern int trickle_sec; /* how many seconds should the | ||
80 | charger be enabled per | ||
81 | minute for trickle | ||
82 | charging? */ | ||
83 | void charger_enable(bool on); | ||
84 | bool charger_enabled(void); | ||
85 | |||
86 | /* Battery filter lengths in samples */ | ||
87 | #define BATT_AVE_SAMPLES 32 | ||
88 | |||
89 | #endif /* POWERMGMT_TARGET_H */ | ||