Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Maemo: Developers

dsme, Re: Would like to know the status of (was RE: Corporate ownership of open source projects [LWN])

 

 

Maemo developers RSS feed   Index | Next | Previous | View Threaded


dufkaf at seznam

May 7, 2008, 5:43 AM

Post #1 of 5 (1055 views)
Permalink
dsme, Re: Would like to know the status of (was RE: Corporate ownership of open source projects [LWN])

nick loeve wrote:
> 2. Is it possible to at least get some basic documentation of what bme
> and dsme are doing (beyond obvious basics)?

There is a lot of info. Search list archives for dsme (or bme)
http://www.gossamer-threads.com/lists/maemo/
If you still have some specific question not answered, ask again, maybe
someone knows, maybe not. I'm not sure what 'obvious basics' means to you.
_______________________________________________
maemo-developers mailing list
maemo-developers [at] maemo
https://lists.maemo.org/mailman/listinfo/maemo-developers


trickie at gmail

May 7, 2008, 6:03 AM

Post #2 of 5 (1007 views)
Permalink
Re: dsme, Re: Would like to know the status of (was RE: Corporate ownership of open source projects [LWN]) [In reply to]

Hi!

On Wed, May 7, 2008 at 2:43 PM, Frantisek Dufka <dufkaf [at] seznam> wrote:
> nick loeve wrote:
>>
>> 2. Is it possible to at least get some basic documentation of what bme
>> and dsme are doing (beyond obvious basics)?
>
> There is a lot of info. Search list archives for dsme (or bme)
> http://www.gossamer-threads.com/lists/maemo/
> If you still have some specific question not answered, ask again, maybe
> someone knows, maybe not. I'm not sure what 'obvious basics' means to you.
>

Yep, I have been reading the archives and have compiled a shortlist of
info based on past discussions (mainly that you have started! ). I
guess I might start documenting what is known already and try and get
it all in one place.

Thats a great site for searching the archives BTW, thanks!

--
Nick Loeve
_______________________________________________
maemo-developers mailing list
maemo-developers [at] maemo
https://lists.maemo.org/mailman/listinfo/maemo-developers


dufkaf at seznam

May 7, 2008, 6:45 AM

Post #3 of 5 (1017 views)
Permalink
Re: dsme, Re: Would like to know the status of (was RE: Corporate ownership of open source projects [LWN]) [In reply to]

nick loeve wrote:
> Yep, I have been reading the archives and have compiled a shortlist of
> info based on past discussions (mainly that you have started! ). I
> guess I might start documenting what is known already and try and get
> it all in one place.

Yes, please do if you can. I am guilty of not doing it myself over
years. I'm sure people on this list can fill some gaps. Apart from
examining dsme, its modules and dsmetest in initfs (and its runtime
behaviour using strace), check also powerlaunch
http://powerlaunch.garage.maemo.org/ It is replacement of mce (also
closed). mce talks to dsme too and is done in similar modular way so it
can help with some understanding. Powerlaunch imitates some mce<->dsme
communication, see dsme.c,h at
https://garage.maemo.org/plugins/scmsvn/viewcvs.php/trunk/powered/?root=powerlaunch

As for bme and figuring out how battery charging works, one could strace
it and see what tahvo/retu register it uses, some bits are mentioned in
kernel headers (not sure about name now, something like
tahvo_retu_user.h) and there is also this info
http://marc.info/?l=linux-omap&m=120752529631862&w=2

Frantisek

_______________________________________________
maemo-developers mailing list
maemo-developers [at] maemo
https://lists.maemo.org/mailman/listinfo/maemo-developers


dj at delorie

May 7, 2008, 7:33 AM

Post #4 of 5 (997 views)
Permalink
Re: dsme, Re: Would like to know the status of (was RE: Corporate ownership of open source projects [LWN]) [In reply to]

Frantisek Dufka <dufkaf [at] seznam> writes:
> As for bme and figuring out how battery charging works, one could strace
> it and see what tahvo/retu register it uses,

I did this once for the 770 (by modding the kernel, same basic
results). There are some undocumented RETU and TAHVO ports that
control the charge circuit. They're undocumented because setting them
wrong causes the battery to overheat and possibly explode. Read at
your own risk!

retu interrupt mask 0x0100 is a 5 second timer used for charge timing.
the ADCs are documented in that link you mentioned.
retu register 9 has bits that control the charge process but I never decoded
them fully.
reg 15 and 16 are also involved in controlling the regulator.
reg 20 mask 0x1000 is set when the charger is plugged in

tahvo register 4 is the charge control frob. Values from 0 (disable
charging) to 255 (maximum charge rate) can be written. Must
coordinate with ADC values or the battery goes boom!

tahvo reg 8 controls charging but I don't know exactly what the bits
do (except that mask 0x0001 global-enables the charger). Same for reg
12.

tahvo reg 13 is a signed 16 bit ADC that tells you the current flowing
into the battery (positive when charging, negative when running). I
don't know the scale.

The overall charge process is one of setting the charge current to try
to get a specific voltage (i.e. constant current (max) at first,
followed by variable current (mostly reducing) to get constant
voltage) and periodically shutting down the charger to read the "idle"
voltage/current. When you need to set the charge to zero current to
get the right voltage, you're done. This is a standard lithium charge
cycle.

I'm guessing the periodic shutdown helps it deduce charge time ETA.
_______________________________________________
maemo-developers mailing list
maemo-developers [at] maemo
https://lists.maemo.org/mailman/listinfo/maemo-developers


trickie at gmail

May 10, 2008, 7:47 AM

Post #5 of 5 (952 views)
Permalink
Re: dsme, Re: Would like to know the status of (was RE: Corporate ownership of open source projects [LWN]) [In reply to]

Hello!

On Wed, May 7, 2008 at 3:45 PM, Frantisek Dufka <dufkaf [at] seznam> wrote:
> nick loeve wrote:
>>
>> Yep, I have been reading the archives and have compiled a shortlist of
>> info based on past discussions (mainly that you have started! ). I
>> guess I might start documenting what is known already and try and get
>> it all in one place.
>
> Yes, please do if you can.

https://maemo.org/community/wiki/poweranddevicemanagement/

At the moment it is just a link dump and i intend to summarize some of
the info in that page.

If you anyone has more useful links/info just dump them on the page or
send them in this thread.

Cheers

>I am guilty of not doing it myself over years.
> I'm sure people on this list can fill some gaps. Apart from examining dsme,
> its modules and dsmetest in initfs (and its runtime behaviour using strace),
> check also powerlaunch http://powerlaunch.garage.maemo.org/ It is
> replacement of mce (also closed). mce talks to dsme too and is done in
> similar modular way so it can help with some understanding. Powerlaunch
> imitates some mce<->dsme communication, see dsme.c,h at
> https://garage.maemo.org/plugins/scmsvn/viewcvs.php/trunk/powered/?root=powerlaunch
>
> As for bme and figuring out how battery charging works, one could strace it
> and see what tahvo/retu register it uses, some bits are mentioned in kernel
> headers (not sure about name now, something like tahvo_retu_user.h) and
> there is also this info
> http://marc.info/?l=linux-omap&m=120752529631862&w=2
>
> Frantisek
>
>



--
Nick Loeve
_______________________________________________
maemo-developers mailing list
maemo-developers [at] maemo
https://lists.maemo.org/mailman/listinfo/maemo-developers

Maemo developers RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.