Package: acpi Version: 1.1-1 Severity: normal
Hello, I noticed today that the command "acpi" reported strange charging and dicharging times for my thinkpad: [EMAIL PROTECTED]:~$ acpi Battery 0: Discharging, 83%, 00:02:07 remaining [EMAIL PROTECTED]:~$ acpi Battery 0: Charging, 83%, 00:00:14 until charged While investigating the issue further, I noticed that the correct values were shifted to the right, so instead of displaying a charging time of 14 minutes, acpi calculated a remaining time of 14 seconds. I traced the issue down to the lines 289 and 297 in the file acpi.c: seconds = 60 * (design_capacity - remaining_capacity) / present_rate; [...] seconds = 60 * remaining_capacity / present_rate; Instead of converting the expression to the unit of seconds, it returns the value in minutes (since design_capacity has the unit of Wh). Replacing the 60 with the correct value of 3600 should fix the problem. -- System Information: Debian Release: lenny/sid APT prefers testing APT policy: (990, 'testing'), (500, 'unstable'), (1, 'experimental') Architecture: i386 (i686) Kernel: Linux 2.6.26-1-686 (SMP w/2 CPU cores) Locale: [EMAIL PROTECTED], [EMAIL PROTECTED] (charmap=ISO-8859-15) Shell: /bin/sh linked to /bin/bash Versions of packages acpi depends on: ii libc6 2.7-10 GNU C Library: Shared libraries acpi recommends no packages. acpi suggests no packages. -- no debconf information -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]