Exposing the mouse battery status through HAL

Behdad Esfahbod behdad at cs.toronto.edu
Tue Nov 30 12:44:41 PST 2004


On Tue, 30 Nov 2004, David Zeuthen wrote:

> Ideally mousebatd should only be running when there is an appropriate
> device (e.g. Logitech wireless mouse) connected to the system we should
> monitor; for the moment it would make sense to use hal callouts (device
> add/device remove) to activate/deactivate the daemon. I'm hoping D-BUS
> activation on the system bus level with some clever rules will make this
> automatic at some point, e.g. we could say 'mousebatd should run if and
> only if a) org.fd.Hal is up; b) there is a Logitech wireless mouse.

So, is it going into the .fdi file for the mouse?  What I've been
looking for to show up on the list was that the fdi file merge
info saying that "run com.logitech.mouse..." daemon, and hald
finds the callout and run it, or otherwise asks somebody to tell
the user that she needs to install this and that package (or
automatically dl/install?) when she plugs in stuff.


About the battery stuff, perhaps Hal spec can recommend what keys
should/may daemons set under *.battery.  For example, milliWatt
remaining, time remaining, time to charge, charge percent, ...
This way for example the battstat applet can simply query Hal
tree for *.battery and show a list to the user...

> I think this approach is nice because if other vendors than Logitech
> want to ship such a daemon they now what properties to export.
>
> FWIW, I'd be happy to remove such code in the hal CVS and hal tarball -
> it looks like a cool and useful idea.
>
> Thanks,
> David

--behdad
  behdad.org
_______________________________________________
hal mailing list
hal at freedesktop.org
http://freedesktop.org/mailman/listinfo/hal



More information about the Hal mailing list