Rockbox

  • Status Closed
  • Percent Complete
    100%
  • Task Type Bugs
  • Category Battery/Charging
  • Assigned To No-one
  • Operating System iPod 4G Color
  • Severity Low
  • Priority Very Low
  • Reported Version Daily build (which?)
  • Due in Version Undecided
  • Due Date Undecided
  • Votes
  • Private
Attached to Project: Rockbox
Opened by kubiix - 2009-02-18
Last edited by dreamlayers - 2009-04-19

FS#9926 - System -> rockboxinfo shows Battery: Charging even if I run on battery

In daily build r20040 the System → rockboxinfo shows Battery: Charging even if I run on battery

Indicators in statusbar and wps display correct non-charging icon

Closed by  dreamlayers
2009-04-19 22:22
Reason for closing:  Fixed
Additional comments about closing:   Warning: Undefined array key "typography" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 371 Warning: Undefined array key "camelcase" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 407

Fixed in r20752

With Release 3.1 it displays correctly battery level and estimated time left

This happens since r19872: “Make sure ‘Battery: Charging’ is displayed in the info screen when charging no matter the algorithm (Archos Recorder still specially handled). Have screen refresh itself at 1HZ if CONFIG_CHARGING”

It works on my 5G 30GB. I guess the bit being tested in charging_state() in firmware/target/arm/ipod/power-ipod.c is incorrect on 4G iPods. Note how other bits are at different locations on different iPods. Someone needs to find how to detect if a 4G iPod is charging. “View I/O ports” in the debug menu may help. Note that other bits report presence of FireWire and USB power.

On iPod Color the GPIO D changes from F0 to F8 when charger is connected

GPIOD_INPUT_VAL & 8 just detects voltage at the USB +5V input. This does not mean that the battery is charging. It might be full or hardware might not be configured properly (see  FS#8802 ). To properly implement charging_state() you need some way to know that the battery is charging.

BTW I wonder why this bit isn’t being used. It was used at one point, eg.
http://svn.rockbox.org/viewvc.cgi/trunk/firmware/target/arm/usb-fw-pp502x.c?revision=16817&view=markup

I think I found the “charging” bit for Photo and Colour iPods: GPO32 & 1. It seems like the word at 0×70000088 may be a latching input for GPO32 bits; the OF writes a 0 and then reads to check if the bit is set.

For other iPods the code still checks GPIOB_INPUT_VAL & 0×01. That should at least be valid for 4G mono, 5/5.5G, 2G Mini and 1G Nano. It might still be wrong for some other iPods.

The patch seems to work.
Perhaps someone should add this bug to the 3.2 release notes.

Ali commented on 2009-03-26 00:59

I can verify the patch solves the problem, and I agree it should be listed as a known issue.

Thanks for testing. Just to confirm: With the patch, do you see “battery: charging” when the battery is actually charging? Does it go back to displaying remaining time when the battery is full or external power is removed?

I see that 1G and 2G iPods use GPIOB_OUTPUT_VAL & 0×01 to enable and disable the wheel. The same pin cannot be used as an input, so those iPods must also use a different pin.

I don’t have wiki access. I’ll see what I can do about getting it added to the release notes tomorrow.

Great work Boris

thanks

Loading...

Available keyboard shortcuts

Tasklist

Task Details

Task Editing