HAL

power manger shows always the same capacity of logitech mouse

Bug #120549 reported by checkstein
18
Affects Status Importance Assigned to Milestone
HAL
Confirmed
Medium
linux (Ubuntu)
Won't Fix
Low
Unassigned

Bug Description

Hi ubuntu team,

the power-manager-panel reports always a 71% capacity of my logitech mouse (v100).
After upgrading to feisty (this was about 3 month ago) the 71% didn't change.

I've started to be amazed since I saw a screenshot in this blog:
http://ubuntu.blog.de/2007/02/23/feinheiten_im_powermanager~1791362

The picture showed the same entry for the mouse-battery.

The author of that blog acknowledged my notice.
(http://ubuntu.blog.de/2007/06/15/bug_im_powermanager~2455808)

If you need further details, pls let me know it.

(Phew this was my first bug-report.)

regards
Karsten

Revision history for this message
In , Anders Kaseorg (andersk) wrote :

I also filed a bug for g-p-m <http://bugzilla.gnome.org/show_bug.cgi?id=330822>,
but I don't see why HAL can't begin reporting the battery level immediately.

Revision history for this message
In , Richard Hughes (richard-hughes) wrote :

Can you attach the output of:

killall hald
/usr/sbin/hald --retain-privileges --verbose=yes --daemon=no

Many thanks, Richard.

Revision history for this message
In , Anders Kaseorg (andersk) wrote :
Download full text (13.4 KiB)

Created an attachment (id=4599)
/usr/sbin/hald --verbose=yes --daemon=no

I've attached the output of /usr/sbin/hald --verbose=yes --daemon=no. (It
doesn't recognize --retain-privileges or any similar option.) Here are the
parts that look relevant:

19:44:14.281 [I] physdev.c:1457: phys_add: subsys=pci
sysfs_path=/sys/devices/pci0000:00/0000:00:1d.1, parent=0x00000000
19:44:14.295 [I] physdev.c:1382: Add callouts completed
udi=/org/freedesktop/Hal/devices/pci_8086_24c4
19:44:14.295 [I] hald.c:82: Added device to GDL;
udi=/org/freedesktop/Hal/devices/pci_8086_24c4
19:44:14.295 [I] classdev.c:1373: class_add: subsys=usb_host
sysfs_path=/sys/class/usb_host/usb_host2 dev= physdev=0x080c0708
19:44:14.296 [I] physdev.c:1457: phys_add: subsys=usb
sysfs_path=/sys/devices/pci0000:00/0000:00:1d.1/usb2, parent=0x080c0708
19:44:14.307 [I] physdev.c:1382: Add callouts completed
udi=/org/freedesktop/Hal/devices/usb_device_0_0_0000_00_1d_1
19:44:14.307 [I] hald.c:82: Added device to GDL;
udi=/org/freedesktop/Hal/devices/usb_device_0_0_0000_00_1d_1
19:44:14.307 [I] classdev.c:1373: class_add: subsys=usb_device
sysfs_path=/sys/class/usb_device/usbdev2.1 dev=/dev/bus/usb/002/001
physdev=0x080c0720
19:44:14.316 [I] classdev.c:1236: Add callouts completed
udi=/org/freedesktop/Hal/devices/usb_device_0_0_0000_00_1d_1_usbraw
19:44:14.316 [I] hald.c:82: Added device to GDL;
udi=/org/freedesktop/Hal/devices/usb_device_0_0_0000_00_1d_1_usbraw
19:44:14.316 [I] physdev.c:1457: phys_add: subsys=usb
sysfs_path=/sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1, parent=0x080c0720
19:44:14.317 [E] util.c:463: Cannot open
'/sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/serial'
19:44:14.317 [E] util.c:463: Cannot open
'/sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/serial'
19:44:14.323 [I] device_info.c:1429: *** Matched file
/usr/share/hal/fdi/information/10freedesktop/10-wireless-mice.fdi
19:44:14.326 [I] physdev.c:1382: Add callouts completed
udi=/org/freedesktop/Hal/devices/usb_device_46d_c50e_noserial
19:44:14.326 [I] hald.c:82: Added device to GDL;
udi=/org/freedesktop/Hal/devices/usb_device_46d_c50e_noserial
28991: 19:44:14.331: addon-usb-csr.c:269:
device:[/org/freedesktop/Hal/devices/usb_device_46d_c50e_noserial]
19:44:14.332 [I] hald.c:95: Started addon hald-addon-usb-csr for udi
/org/freedesktop/Hal/devices/usb_device_46d_c50e_noserial
19:44:14.332 [I] classdev.c:1373: class_add: subsys=usb_device
sysfs_path=/sys/class/usb_device/usbdev2.22 dev=/dev/bus/usb/002/022
physdev=0x080c0750
19:44:14.342 [I] classdev.c:1236: Add callouts completed
udi=/org/freedesktop/Hal/devices/usb_device_46d_c50e_noserial_usbraw
19:44:14.342 [I] hald.c:82: Added device to GDL;
udi=/org/freedesktop/Hal/devices/usb_device_46d_c50e_noserial_usbraw
19:44:14.343 [I] physdev.c:1457: phys_add: subsys=usb
sysfs_path=/sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1:1.0,
parent=0x080c0750
19:44:14.352 [I] physdev.c:1382: Add callouts completed
udi=/org/freedesktop/Hal/devices/usb_device_46d_c50e_noserial_if0
19:44:14.352 [I] hald.c:82: Added device to GDL;
udi=/org/freedesktop/Hal/devices/usb_device_46d_c50e_noserial_if0
19:44:14.352 [I] classdev.c:1373: class_add: subsys=input
sysfs_path=/sys/class/in...

Revision history for this message
In , Bastien Nocera (hadess-deactivatedaccount) wrote :

I think that the battery level reporting is broken on the HAL side. In lmctl:
                printf ("\tBattery status: %d ", P5 & 0x07);
                switch (P5 & 0x07) {
                case 0: printf ("(unavailable)\n"); break;
                case 1:
                case 2: printf ("(critical)\n"); break;
                case 3:
                case 4: printf ("(low)\n"); break;
                case 5:
                case 6: printf ("(good)\n"); break;
                case 7: printf ("(full)\n"); break;
in the csr addon:
                                if (current_charge != 0)
                                        percentage = (100.0 / 7.0) * current_charge;

0 means unavailable, not empty (well, it might be unavailable because it's
empty, but that would only be useful if the previous level was non-zero). Makes
sense Richard?

Revision history for this message
checkstein (checkstein) wrote :

Hi ubuntu team,

the power-manager-panel reports always a 71% capacity of my logitech mouse (v100).
After upgrading to feisty (this was about 3 month ago) the 71% didn't change.

I've started to be amazed since I saw a screenshot in this blog:
http://ubuntu.blog.de/2007/02/23/feinheiten_im_powermanager~1791362

The picture showed the same entry for the mouse-battery.

The author of that blog acknowledged my notice.
(http://ubuntu.blog.de/2007/06/15/bug_im_powermanager~2455808)

If you need further details, pls let me know it.

(Phew this was my first bug-report.)

regards
Karsten

Revision history for this message
Jason Liquorish (jason-liquorish) wrote :

Thanks for taking the time to report this bug. Unfortunately we can't fix it, because your description didn't include enough information. You may find it helpful to read "How to report bugs effectively" <http://www.chiark.greenend.org.uk/~sgtatham/bugs.html>. We'd be grateful if you would then provide a more complete description of the problem.

We have instructions on debugging some types of problems. <http://wiki.ubuntu.com/DebuggingProcedures> Thanks!

Revision history for this message
checkstein (checkstein) wrote :

Hi Jason,
ok, so I try to make it better now:

I have ubuntu feisty (german localization, latest upgrades and patches) on a HP G5042EA notebook.
Additionally I use a cordless Logitech Mouse V100.

The strange thing is, that gnome-powermanager (2.18.2) shows the battery status of the mouse always with 71% capacity.
This happend since I use that mouse. And the 71% did not change for about 3 month.
But really weird is that another guy experienced the same problem (as you can see in the above metioned screenshot), whose configuration unfortunately I don't know.

Maybe following is helpful for you: also in the xfce4 applet the battery status of the mouse seems not to work. There is shown 0%.

Please let me know, which information you need.
Karsten

Revision history for this message
Stephan Frank (sfrank) wrote :

Hi,

I can confirm this phenomenon with my Logitech MX700 (battery driven laptop mouse). I'm running the latest gutsy on a Thinkpad R50. The estimated charge is for the mouse is at 71% constantly.

Best regards,
Stephan

Revision history for this message
checkstein (checkstein) wrote :

Ok, trying it once more:

I just tried out the Fedora 7 Live CD on above mentioned laptop and there is the bug also to be seen!

Regards,

Karsten

Revision history for this message
Basilio Kublik (sourcercito) wrote :

Hi There
Thank you for taking the time to report this bug and helping to make Ubuntu better. You reported this bug a while ago and there hasn't been any activity in it recently. We were wondering is this still an issue for you?, Can you please try with the live environment of the Desktop CD of the development release - Hardy Heron?

Thanks in advance.

Changed in gnome-power-manager:
assignee: nobody → sourcercito
importance: Undecided → Low
status: New → Incomplete
Revision history for this message
Sense Egbert Hofstede (sense) wrote :

My brother's laptop(Packer Bell, Logitec Mouse) also has the same issue, I can ask him if he can post some information, but if checkstein already posts enough information the confirmation is enough.

Chris Jones (cmsj)
Changed in gnome-power-manager:
status: Incomplete → Confirmed
Changed in gnome-power-manager:
assignee: sourcercito → nobody
Revision history for this message
Tomas 'tt' Krag (tt) wrote :

I can confirm this for a logitech codless optical trackman , except i only have 14% battery on mine.
This battery level has been the same for at least a few versions of ubuntu. I am currently running hardy heron, on a IBM thinkpad X31.

There is an unfortunate downside to this minor issue: Since 14% is considered critical battery level, i get an annoying pop-up warning every time i plug in the trackball, and the gnome power manager applet constantly shows the battery level of the mouse instead of the battery-level of the laptop, making it effectively useless as a power-manager applet.

 tkrag@tkragX31:~ $ lsusb -s 002:002
 Bus 002 Device 002: ID 046d:c508 Logitech, Inc.

and the relevant output from hwinfo eems to be the following:

48: USB 00.0: 0000 Unclassified device
  [Created at usb.122]
  UDI: /org/freedesktop/Hal/devices/usb_device_46d_c508_noserial_if0
  Unique ID: hSuP.uYIOgYiMV63
  Parent ID: pBe4.D92PQaaYz03
  SysFS ID: /devices/pci0000:00/0000:00:1d.1/usb2/2-2/2-2:1.0
  SysFS BusID: 2-2:1.0
  Hardware Class: unknown
  Model: "Logitech USB Receiver"
  Hotplug: USB
  Vendor: usb 0x046d "Logitech Inc."
  Device: usb 0xc508 "USB Receiver"
  Revision: "15.00"
  Driver: "usbhid"
  Driver Modules: "usbhid"
  Device File: /dev/input/input10
  Speed: 1.5 Mbps
  Module Alias: "usb:v046DpC508d1500dc00dsc00dp00ic03isc01ip02"
  Driver Info #0:
    Driver Status: usbmouse is not active
    Driver Activation Cmd: "modprobe usbmouse"
  Driver Info #1:
    Driver Status: usbhid is active
    Driver Activation Cmd: "modprobe usbhid"
  Config Status: cfg=new, avail=yes, need=no, active=unknown
  Attached to: #51 (Hub)

Revision history for this message
CharlesWGreenJr (charleswgreenjr) wrote :

I can also confirm this with my "Logitech Cordless Optical Mouse" showing as 14% continuously.

Xubuntu 8.04 with the latest stuff to come down the 'general public' distributions pipe

Power Manager 2.22.1

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

Thank you for taking the time to report this bug and help make Ubuntu better. For those of you experiencing this problem, could you please provide the following information:

1) Please attach the output of "gnome-power-bugreport.sh" as a text file.
2) Please attach the output of "hal-find-by-capability --capability "battery" | xargs -n 1 hal-device" as a text file.

This is less likely to be a gpm issue than it is to be a HAL or kernel problem.

Thanks in advance.

Changed in gnome-power-manager:
status: Confirmed → Incomplete
Revision history for this message
Tomas 'tt' Krag (tt) wrote :

Here is the output from the above commands on my thinkpad X40 running hardy. It's worth noting that unlike my x31 on this machine the mouse battery level is shown at a constant 100%. No more correct than the 14% shown on my other computer, but much less annoying, since it doesn't trigger critical battery warnings.

cheers tomas

Revision history for this message
Tomas 'tt' Krag (tt) wrote :
Revision history for this message
CharlesWGreenJr (charleswgreenjr) wrote :

And here is the output from 'hal-find-by-capability' for a Dell Dimension XPS T450 running Hardy, constantly reporting 14% battery on my Logitech Cordless Optical Mouse with USB receiver on a PCI USB 2.0 card. (It seems the interface only allows a single attachment per message)

Revision history for this message
CharlesWGreenJr (charleswgreenjr) wrote :

...and 'gnome-power-bugreport.sh' output.

Revision history for this message
Chris Coulson (chrisccoulson) wrote :

Thanks. This isn't a gnome-power-manager bug, as the numbers it is displaying are correct according to HAL. I'm re-assigning to the kernel for now (it's unlikely to be a HAL bug too).

Please include the following additional information, if you have not already done so (pay attention to lspci's additional options), as required by the Ubuntu Kernel Team:
1. Please include the output of the command "uname -a" in your next response. It should be one, long line of text which includes the exact kernel version you're running, as well as the CPU architecture.
2. Please run the command "dmesg > dmesg.log" after a fresh boot and attach the resulting file "dmesg.log" to this bug report.
3. Please run the command "sudo lspci -vvnn > lspci-vvnn.log" and attach the resulting file "lspci-vvnn.log" to this bug report.
4. Please run the command "sudo lsusb -v > lsusb.log" and attach the resulting file "lsusb.log" to this bug report.

Tomas - Please could you please post the output of:

"ls -l /sys/devices/pci0000:00/0000:00:1d.7/usb4/4-1/4-1.3/4-1.3.3"
"cat /sys/devices/pci0000:00/0000:00:1d.7/usb4/4-1/4-1.3/4-1.3.3/*"

Charles - Please post the output of:
"ls -l /sys/devices/pci0000:00/0000:00:0f.2/usb4/4-1/4-1.2"
" cat /sys/devices/pci0000:00/0000:00:0f.2/usb4/4-1/4-1.2/*"

For your reference, the full description of procedures for kernel-related bug reports is available at https://wiki.ubuntu.com/KernelTeamBugPolicies Thanks in advance!

Revision history for this message
Tomas 'tt' Krag (tt) wrote :

OK,
I'm at home now, rather than at the office, and while i have the same mouse hre, and the same issue, the usb idents are different. I've made a guess at what the above commands should be on this setup. if it's wrong, i'll redo it the next time i'm at the office.

I've attached a zip file with the hal-find-capability, gnome-power-bugreport, dmesg, lsusb and lspci output. And output from the ls, cat and uname commands is pasted below.

#uname -a
Linux tkragX40 2.6.24-21-generic #1 SMP Tue Oct 21 23:43:45 UTC 2008 i686 GNU/Linux

#ls -l /sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.3/2-1.3:1.0
total 0
-r--r--r-- 1 root root 4096 2008-10-28 08:59 bAlternateSetting
-r--r--r-- 1 root root 4096 2008-10-28 08:57 bInterfaceClass
-r--r--r-- 1 root root 4096 2008-10-28 08:57 bInterfaceNumber
-r--r--r-- 1 root root 4096 2008-10-28 08:57 bInterfaceProtocol
-r--r--r-- 1 root root 4096 2008-10-28 08:57 bInterfaceSubClass
-r--r--r-- 1 root root 4096 2008-10-28 08:59 bNumEndpoints
lrwxrwxrwx 1 root root 0 2008-10-28 08:57 driver -> ../../../../../../../bus/usb/drivers/usbhid
lrwxrwxrwx 1 root root 0 2008-10-28 08:59 ep_81 -> ../../../../../../../devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.3/2-1.3:1.0/usb_endpoint/usbdev2.4_ep81
drwxr-xr-x 3 root root 0 2008-10-28 08:57 input
-r--r--r-- 1 root root 4096 2008-10-28 08:57 modalias
drwxr-xr-x 2 root root 0 2008-10-28 08:59 power
lrwxrwxrwx 1 root root 0 2008-10-28 08:57 subsystem -> ../../../../../../../bus/usb
-rw-r--r-- 1 root root 4096 2008-10-28 08:57 uevent
drwxr-xr-x 3 root root 0 2008-10-28 08:57 usb_endpoint

#cat /sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.3/2-1.3:1.0/*
 0
03
00
02
01
01
cat: /sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.3/2-1.3:1.0/driver: Is a directory
cat: /sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.3/2-1.3:1.0/ep_81: Is a directory
cat: /sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.3/2-1.3:1.0/input: Is a directory
usb:v046DpC501d0910dc00dsc00dp00ic03isc01ip02
cat: /sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.3/2-1.3:1.0/power: Is a directory
cat: /sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.3/2-1.3:1.0/subsystem: Is a directory
DEVTYPE=usb_interface
DRIVER=usbhid
DEVICE=/proc/bus/usb/002/004
PRODUCT=46d/c501/910
TYPE=0/0/0
INTERFACE=3/1/2
MODALIAS=usb:v046DpC501d0910dc00dsc00dp00ic03isc01ip02
cat: /sys/devices/pci0000:00/0000:00:1d.1/usb2/2-1/2-1.3/2-1.3:1.0/usb_endpoint: Is a directory

Revision history for this message
CharlesWGreenJr (charleswgreenjr) wrote :

File containing the requested data is attached (hopefully this is better than several postings with individual files).

Thanks again!

-Charles

Changed in linux:
status: Incomplete → Confirmed
Revision history for this message
Chris Coulson (chrisccoulson) wrote :

Hi,

Would you mind testing this with the current Jaunty Alpha 2 live CD, available here: http://cdimage.ubuntu.com/releases/9.04/alpha-2/

This is something that you should be able to recreate from the live CD environment.

Changed in linux:
status: Confirmed → Incomplete
Revision history for this message
CharlesWGreenJr (charleswgreenjr) wrote :

I've never understood from any of the available numbers where my 14% came from, and I don't know that lack of the alert constitutes verification of a fix, but previously where gnome-power-bugreport.sh gave figures for battery.charge_level. {current, design, last_full, percentage} of {3, 7, 7, 42} the figures under the Jaunty (9.04) alpha workstation live CD boot are {7, 7, 7, 100}. Again, this is for a Dell Dimension XPS T450 on my Logitech Cordless Optical Mouse with USB receiver on a PCI USB 2.0 card. Let me know if any additional output is needed.

Come to think of it, I don't recall seeing this message for some time now, so perhaps one of the updates to Hardy (8.04) fixed it?

Thanks!

-Charles

Revision history for this message
checkstein (checkstein) wrote :

Hi all, Hi Chris,

I just tested the RC3 Live CD of Jaunty. I don't want to install it on my disk, so I don't know, wether there are some issues caused by the live system.
However: The system is *very* slow - like no other Live CD before.
The arrow of my cursor flickers and "jumps" over the desktop. After boot up there is no battery symbol in the tray. I tried to activate it in the "Energieverwaltung" and logged out. Before log out there came a message, that the gnome-power-manager hangs (about five or more processes of the manager where shown in the window) and after log in a message came up, that a crash report was detected (compiz related).
Hope this helps.
Do you need some more information?

Cheers
Karsten

Revision history for this message
Eric Miao (eric.y.miao) wrote :

The Wireless CSR mouse addon in HAL composes a USB control message directly to get the battery status, without going through any kernel specific driver. I'm adding HAL to the affected projects here.

And according to http://bugs.freedesktop.org/show_bug.cgi?id=5865, and git revision history of git://anongit.freedesktop.org/hal, commit 5c97b026 should have fixed this issue already. Could you please try again the stable jaunty 9.04 release and make sure this is still a problem?

Changed in linux (Ubuntu):
status: Incomplete → Won't Fix
Changed in hal:
status: Unknown → Confirmed
Changed in hal:
importance: Unknown → Medium
Changed in hal:
importance: Medium → Unknown
Changed in hal:
importance: Unknown → Medium
Revision history for this message
In , Anton Patsev (patsev-anton) wrote :

Anders Kaseorg
Do you still experience this issue with newer drivers ?
Please check the status of your issue.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.