Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 162672 - gnome-base/gnome-applets - Battery monitor misrepresents fill status when on AC
Summary: gnome-base/gnome-applets - Battery monitor misrepresents fill status when on AC
Status: RESOLVED WORKSFORME
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] GNOME (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo Linux Gnome Desktop Team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-01-18 16:02 UTC by Peter Weilbacher
Modified: 2009-01-23 10:10 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Peter Weilbacher 2007-01-18 16:02:10 UTC
Since a while ago, the GNOME panel applet "Battery Charge Monitor"
displays the graphical representation strangely. Everything is OK when
the laptop is on battery. But when plugged in, the bar gets shorter and
redder (signifying a less and less charged battery) the fuller the
battery really gets. It shows e.g. a red, very small fill status when
the battery is fully charged. When unplugging in that state it takes
about a minute before it realizes that it is almost fully charged shows
a long green bar.

As far as I can tell, the information in
   /proc/acpi/battery/BAT0/state
   /proc/acpi/battery/BAT0/info
is correctly showing what is really going on. When fully charged, it says:
   $ cat /proc/acpi/battery/BAT0/state
   present:                 yes
   capacity state:          ok
   charging state:          charged
   present rate:            0 mW
   remaining capacity:      63180 mWh
   present voltage:         16711 mV

It was like this with gnome-applets 2.14.2 and now I updated to
gnome-applets 2.16.2 and it is still like this. I think when using
2.12.x it was still working correctly.

In alt.os.linux.gentoo I only got one person to comment and for him it works correctly. If there are guidelines anywhere that explain how to rebuild only that one applet with debug info in, I believe I would be capable of debugging what is going on in the applet.

Reproducible: Always

Steps to Reproduce:
1. Have a laptop on battery power, observe how the bar in the battery applet gets shorter and turn from green to yellow and red.
2. Plug in the laptop cable. Watch as the bar gets shorter and shorter the longer the laptop is on AC power.




emerge --info:

Portage 2.1.1-r2 (default-linux/x86/2006.1, gcc-4.1.1, glibc-2.4-r3, 2.6.18-gentoo i686)
=================================================================
System uname: 2.6.18-gentoo i686 Intel(R) Pentium(R) M processor 1.86GHz
Gentoo Base System version 1.12.5
Last Sync: Thu, 11 Jan 2007 14:00:02 +0000
app-admin/eselect-compiler: [Not Present]
dev-java/java-config: 1.2.11-r1
dev-lang/python:     2.4.3-r4
dev-python/pycrypto: 2.0.1-r5
dev-util/ccache:     [Not Present]
dev-util/confcache:  [Not Present]
sys-apps/sandbox:    1.2.17
sys-devel/autoconf:  2.13, 2.59-r7
sys-devel/automake:  1.4_p6, 1.5, 1.6.3, 1.7.9-r1, 1.8.5-r3, 1.9.6-r2
sys-devel/binutils:  2.16.1-r3
sys-devel/gcc-config: 1.3.13-r4
sys-devel/libtool:   1.5.22
virtual/os-headers:  2.6.17-r1
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-O2 -march=i686 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /usr/share/X11/xkb /usr/share/config"
CONFIG_PROTECT_MASK="/etc/env.d /etc/gconf /etc/terminfo /etc/texmf/web2c"
CXXFLAGS="-O2 -march=i686 -pipe"
DISTDIR="/media/extra/tmp/distfiles"
FEATURES="autoconfig distlocks metadata-transfer sandbox sfperms strict"
GENTOO_MIRRORS="ftp://ftp.wh2.tu-dresden.de/pub/mirrors/gentoo ftp://ftp.tu-clausthal.de/pub/linux/gentoo ftp://ftp.rz.tu-bs.de/pub/mirror/ftp.gentoo.org/gentoo-distfiles http://distfiles.gentoo.org http://www.ibiblio.org/pub/Linux/distributions/gentoo"
LANG="en_US"
LINGUAS="en de pl es"
PKGDIR="/usr/portage/packages"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --delete-after --stats --timeout=180 --exclude='/distfiles' --exclude='/local' --exclude='/packages'"
PORTAGE_TMPDIR="/media/ubuntu/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="x86 3dfx X a52 aac acpi alsa alsa_cards_ali5451 alsa_cards_als4000 alsa_cards_atiixp alsa_cards_atiixp-modem alsa_cards_bt87x alsa_cards_ca0106 alsa_cards_cmipci alsa_cards_emu10k1x alsa_cards_ens1370 alsa_cards_ens1371 alsa_cards_es1938 alsa_cards_es1968 alsa_cards_fm801 alsa_cards_hda-intel alsa_cards_intel8x0 alsa_cards_intel8x0m alsa_cards_maestro3 alsa_cards_trident alsa_cards_usb-audio alsa_cards_via82xx alsa_cards_via82xx-modem alsa_cards_ymfpci alsa_pcm_plugins_adpcm alsa_pcm_plugins_alaw alsa_pcm_plugins_asym alsa_pcm_plugins_copy alsa_pcm_plugins_dmix alsa_pcm_plugins_dshare alsa_pcm_plugins_dsnoop alsa_pcm_plugins_empty alsa_pcm_plugins_extplug alsa_pcm_plugins_file alsa_pcm_plugins_hooks alsa_pcm_plugins_iec958 alsa_pcm_plugins_ioplug alsa_pcm_plugins_ladspa alsa_pcm_plugins_lfloat alsa_pcm_plugins_linear alsa_pcm_plugins_meter alsa_pcm_plugins_mulaw alsa_pcm_plugins_multi alsa_pcm_plugins_null alsa_pcm_plugins_plug alsa_pcm_plugins_rate alsa_pcm_plugins_route alsa_pcm_plugins_share alsa_pcm_plugins_shm alsa_pcm_plugins_softvol bash-completion berkdb bitmap-fonts cddb cdr cli cracklib crypt cups dlloader dri dvd dvdread elibc_glibc esd exif ffmpeg firefox fortran gd gdbm gimpprint glitz gnome gnuplot gpm gstreamer gtk iconv input_devices_keyboard input_devices_mouse input_devices_synaptics ipv6 isdnlog jpeg kernel_linux libg++ linguas_de linguas_en linguas_es linguas_pl lm_sensors mmx mozbranding mp3 mpeg ncurses nls nptl nptlonly nsplugin ogg opengl pam pcre pdf perl png ppds pppd python readline real reflection sdl session spl sse sse2 ssl svg tcpd tiff tk truetype-fonts type1-fonts udev unicode userland_GNU video_cards_fglrx video_cards_radeon video_cards_vesa vim-with-x vorbis win32codecs xorg xprint zlib"
Unset:  CTARGET, EMERGE_DEFAULT_OPTS, INSTALL_MASK, LC_ALL, LDFLAGS, MAKEOPTS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
Comment 1 Benjamin 2007-09-06 00:09:26 UTC
According do your USE flags you don't have 'hal' set. The about screen for my version of the applet says that the HAL backend is enabled, and I don't have the problem. Could you try rebuilding gnome-applets with the 'hal' flag set and see if that fixes the issue?
Comment 2 Peter Weilbacher 2007-09-06 15:39:09 UTC
Rebuilding with hal (which seems to be off by default?!) didn't change anything apart from the message in the about box. In the meantime I also updated to gnome 2.18 (gnome-applets-2.18.0-r2, hal-0.5.9) and use 2.6.22-suspend2-r1 as kernel.

When fully charged and plugged in, the battery charge monitor still shows a short green bar instead of a full green one.
Comment 3 Gilles Dartiguelongue (RETIRED) gentoo-dev 2007-09-06 16:01:13 UTC
I guess this has something to do with your battery reporting mWh and not mAh.
If you can provide informations about your model, I'm sure hal upstream will be glad to include the necessary changes into hal-info updates.

For example, my battery reads:
remaining capacity:      3551 mAh
present voltage:         12340 mV
Comment 4 Peter Weilbacher 2007-09-07 10:27:21 UTC
This is what hal-device tells me.

3: udi = '/org/freedesktop/Hal/devices/acpi_BAT0'
  info.capabilities = { 'battery' } (string list)
  battery.charge_level.warning = 6900  (0x1af4)  (int)
  info.category = 'battery'  (string)
  info.product = 'Battery Bay'  (string)
  battery.technology = 'lithium-ion'  (string)
  battery.reporting.warning = 6900  (0x1af4)  (int)
  battery.rechargeable.is_discharging = false  (bool)
  battery.model = 'M6V'  (string)
  battery.charge_level.granularity_1 = 690  (0x2b2)  (int)
  battery.charge_level.granularity_2 = 690  (0x2b2)  (int)
  linux.acpi_path = '/proc/acpi/battery/BAT0'  (string)
  battery.charge_level.design = 69000  (0x10d88)  (int)
  battery.charge_level.low = 3450  (0xd7a)  (int)
  battery.reporting.last_full = 57810  (0xe1d2)  (int)
  battery.reporting.technology = 'LIon'  (string)
  battery.charge_level.current = 10770  (0x2a12)  (int)
  battery.reporting.granularity_1 = 690  (0x2b2)  (int)
  battery.is_rechargeable = true  (bool)
  battery.reporting.current = 10770  (0x2a12)  (int)
  battery.reporting.granularity_2 = 690  (0x2b2)  (int)
  battery.voltage.unit = 'mV'  (string)
  battery.charge_level.capacity_state = 'ok'  (string)
  info.parent = '/org/freedesktop/Hal/devices/computer'  (string)
  battery.remaining_time = 4795  (0x12bb)  (int)
  battery.rechargeable.is_charging = true  (bool)
  battery.reporting.rate = 35310  (0x89ee)  (int)
  battery.charge_level.rate = 35310  (0x89ee)  (int)
  battery.reporting.design = 69000  (0x10d88)  (int)
  battery.present = true  (bool)
  info.udi = '/org/freedesktop/Hal/devices/acpi_BAT0'  (string)
  linux.acpi_type = 0  (0x0)  (int)
  battery.voltage.design = 14800  (0x39d0)  (int)
  battery.reporting.low = 3450  (0xd7a)  (int)
  battery.type = 'primary'  (string)
  battery.reporting.unit = 'mWh'  (string)
  battery.voltage.current = 15642  (0x3d1a)  (int)
  battery.charge_level.last_full = 57810  (0xe1d2)  (int)
  battery.charge_level.percentage = 18  (0x12)  (int)
  battery.vendor = 'ASUSTEK'  (string)
  linux.hotplug_type = 4  (0x4)  (int)
  battery.charge_level.unit = 'mWh'  (string)

Let me know if I should provide anything else.
Comment 5 Gilles Dartiguelongue (RETIRED) gentoo-dev 2008-06-02 18:26:07 UTC
is this still an issue with gnome 2.20 or 2.22 and latest hal/hal-info ?
I've a new laptop which has a somewhat similar output and it works well with the battapplet in gnome 2.22 with hal-0.5.11.
Comment 6 Peter Weilbacher 2008-06-25 14:12:48 UTC
(In reply to comment #5)
> is this still an issue with gnome 2.20 or 2.22 and latest hal/hal-info ?
> I've a new laptop which has a somewhat similar output and it works well with
> the battapplet in gnome 2.22 with hal-0.5.11.

Gilles, the newest packages are apparently not yet marked stable (at least I don't get them using normal emerge) so for the moment I can't test with those. I have
   hal-0.5.9.1-r3
   gnome-applets-2.20.1
   gnome-light-2.20.3
and I see the same problem as 1.5 years ago.
Comment 7 Peter Weilbacher 2009-01-23 10:10:08 UTC
I have installed Gentoo on a new system where I don't use this applet any more. So I cannot reproduce any more and cannot help with any more debugging and I'm closing this bug.