On 2007-09-14 02:09:14 +0200 Quentin Mathé <[EMAIL PROTECTED]> wrote:

> Le 14 sept. 07 à 00:42, David Chisnall a écrit :
> 
>> Hi Andreas,
>> 
>> I had a little look at the code and screenshot, and it looks
>> promising.  A few minor things:
> 
> There is an apm-based Power status menulet in Étoilé repository:  
> <http://svn.gna.org/viewcvs/etoile/trunk/Etoile/Bundles/PowerMenulet/>
> 
Looks like I should play on trunk instead of on 0.2....

>> - It seems to be Linux-only.  Étoilé is a cross-platform project, and
>> there is no abstraction layer between the Linux-specific code and the
>> rest, which will make this very difficult to port to other
>> platforms.  Take a look at Etoile/Services/Private/MenuServer/
>> Subprojects/AboutEtoileEntry/ETMachineInfo* for a clean way of doing
>> this.  This class provides info about the amount of real memory and
>> the CPU model / speed, and works on Linux, FreeBSD, OpenBSD, Darwin
>> and Solaris.
> 
> Well Étoilé has an abstraction layer for hardware-related and host  system 
> configuration (sound, monitor, mouse, network etc.). It is  called 
> SystemConfig and needs a lot of work :-) You can find it in  
> trunk/Etoile/Framework/SystemConfig
> See also my recent mail on etoile-dev.
> 
>> - It seems like the battery reading code seems incredibly
>> complicated.  On FreeBSD, reading the battery level just involves
>> reading the hw.acpi.battery.life sysctl, and reading the number of
>> minutes of life remaining just involves reading
>> hw.acpi.battery.time.  Between them, these are about six lines of
>> code.  Is Linux really so much more complicated?
> 
> I don't really know :-)…
> It may be interesting to leverage existing work done for Freedesktop  HAL, 
> specially for all suspend operations which are really hard to  get right and 
> vary a lot depending on the hardware and the host system.
> There is a DBus / HAL power management spec here: <http:// 
> www.freedesktop.org/wiki/Specifications/power-management-spec>
Well, it starts to get complicated, then. I have played around a little with 
HAL/DBus for an automounting system/volume management system and did only 
partly understand what was going on. However, Battery.menulet was not meant to 
be a power manager, but just a simple thing to display the power status. For 
that purpose, HAL/DBus might be too much overhead. OK, there would be no more 
need for polling, but the programming model will become more complicated, then.
BTW, has anyone ever tried to write a glue library to integrate DBus into 
GNUstep, maybe to even handle DBus as event source for the run loop?

Cheers,
Andreas

-- 
Mail: aheppel at web dot de
Home: http://www.andreasheppel.de
Burn.app: http://gsburn.sourceforge.net

PGP Key is available from the MIT key server (pgp.mit.edu).
RFC3156 defines security multipart formats for MIME with OpenPGP.

Attachment: pgpD9GdW1APTm.pgp
Description: PGP signature

_______________________________________________
Etoile-discuss mailing list
[email protected]
https://mail.gna.org/listinfo/etoile-discuss

Répondre à