release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide

# Rockbox mail archive

Subject: YACQ (Yet Another Charging Question)
From: Johan Vromans (jvromans_at_squirrel.nl)
Date: 2003-09-17

Two observations (for AJBR20):

While the recorder is connected to the charger and the battery voltage
steadily increases, the charge percentage first takes a dive before
it also starts increasing.

Also, when I remove the charger when it's at, say, 60% and re-insert
it, the charging screen suddenly shows it's fully charged.

An attempt to explain this:

Internally, rockbox makes use of two tables to map battery voltages to
percentages[1]. One for normal operation, and one while charging. The
difference is that while charging, the voltage is much higher than its
real (not-charging) value. For example, a voltage of 5.2V indicates
about 80% charge, but while charging it corresponds to only 10%
charge. Likewise, 80% during charge requires 5.8V.

So, when the batteries are filled to 80% (5.2V), putting in the
charger will cause the battery voltage to increase slowly and
steadily. Meanwhile, Rockbox has switched its voltage_to_percent table
to the charging variant, and the charge status would suddenly drop to
10% -- but there's a (Rockbox imposed) limit on the amount that the
charge status can change (not more than 1% per minute). So what you
see when looking closely to the charging screen is that the voltage is
rising while the percentage slowly drops. I've seen it dropping as low
as 9% before the rising voltage could catch up and it started
increasing. Slowly, since there's still the 1% per minute maximum
allowed change.

This explains that, while the recorder is connected to the charger and
the battery voltage steadily increases, the charge percentage first
takes a dive before increasing.

When I remove the charger when the voltage is, say, 5.7V (60% while
charging), and re-insert it, the charging screen suddenly shows it's
fully charged because Rockbox first looks at the voltage using the
normal mapping table, that says that 5.7V is well exceeding 100%
charge)

Are these observations and explanations correct?

-- Johan

[1] see firmware/powermgt.c, table percent_to_volt_decharge (line 79 in
my version), and table percent_to_volt_charge (line 121).