summaryrefslogtreecommitdiff
path: root/firmware/target/arm/imx31/gigabeat-s
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/arm/imx31/gigabeat-s')
-rw-r--r--firmware/target/arm/imx31/gigabeat-s/powermgmt-gigabeat-s.c2
-rw-r--r--firmware/target/arm/imx31/gigabeat-s/powermgmt-target.h2
2 files changed, 3 insertions, 1 deletions
diff --git a/firmware/target/arm/imx31/gigabeat-s/powermgmt-gigabeat-s.c b/firmware/target/arm/imx31/gigabeat-s/powermgmt-gigabeat-s.c
index 39f6d88976..dc00b1ede6 100644
--- a/firmware/target/arm/imx31/gigabeat-s/powermgmt-gigabeat-s.c
+++ b/firmware/target/arm/imx31/gigabeat-s/powermgmt-gigabeat-s.c
@@ -608,6 +608,8 @@ static bool charging_ok(void)
void powermgmt_init_target(void)
{
+ last_inputs = power_thread_inputs;
+
#ifdef IMX31_ALLOW_CHARGING
const uint32_t regval_w =
MC13783_VCHRG_4_050V | MC13783_ICHRG_0MA |
diff --git a/firmware/target/arm/imx31/gigabeat-s/powermgmt-target.h b/firmware/target/arm/imx31/gigabeat-s/powermgmt-target.h
index 02d94015a1..c881bed68c 100644
--- a/firmware/target/arm/imx31/gigabeat-s/powermgmt-target.h
+++ b/firmware/target/arm/imx31/gigabeat-s/powermgmt-target.h
@@ -104,7 +104,7 @@
#define BATTERY_VMAINTAIN_USB MC13783_VCHRG_4_150V
/* Battery filter lengths in samples */
-#define BATT_AVE_SAMPLES 32
+#define BATT_AVE_SAMPLES 128
#define ICHARGER_AVE_SAMPLES 32
void powermgmt_init_target(void);