[maemo-developers] Charger connected State

From: Deepak Kr. Sharma, Noida deepak.s at hcl.in
Date: Wed Sep 17 13:40:43 EEST 2008
I used the callback function for device insertion inside which I check
for ac_adapter namespace (libhal) and check for its presence.

This gives charger inserted or not.

But now I want to detect the changes in battery level. Any idea how to
do that?

-----Original Message-----
From: maemo-developers-bounces at maemo.org
[mailto:maemo-developers-bounces at maemo.org] On Behalf Of Simon Budig
Sent: Wednesday, September 17, 2008 2:29 AM
To: maemo-developers at maemo.org
Subject: Re: Charger connected State

unknown (matan at svgalib.org) wrote:
> If you want to read it directly from the hardware, ADC #3 of retu chip
> gives this information.

Depending on your application it might be easier to monitor the dbus
signals that happen when the charger gets inserted or removed.

I don't have sample code available right now, but the signals are
clearly visible when looking at the output of "dbus-monitor --system".

Hope this helps,
        Simon

-- 
              simon at budig.de              http://simon.budig.de/
       simon.budig at kernelconcepts.de      http://www.kernelconcepts.de/
_______________________________________________
maemo-developers mailing list
maemo-developers at maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers

DISCLAIMER:
-----------------------------------------------------------------------------------------------------------------------

The contents of this e-mail and any attachment(s) are confidential and intended for the named recipient(s) only. 
It shall not attach any liability on the originator or HCL or its affiliates. Any views or opinions presented in 
this email are solely those of the author and may not necessarily reflect the opinions of HCL or its affiliates. 
Any form of reproduction, dissemination, copying, disclosure, modification, distribution and / or publication of 
this message without the prior written consent of the author of this e-mail is strictly prohibited. If you have 
received this email in error please delete it and notify the sender immediately. Before opening any mail and 
attachments please check them for viruses and defect.

-----------------------------------------------------------------------------------------------------------------------

More information about the maemo-developers mailing list