From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Karl Fogel Newsgroups: gmane.emacs.devel Subject: Re: [PATCH] battery.el Retrieve more information from sysfs Date: Wed, 21 Dec 2011 14:30:18 -0500 Message-ID: <87liq5rad1.fsf@kwarm.red-bean.com> References: <87r50190eb.fsf@Apollo.jerryland.fr> Reply-To: Karl Fogel NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1324495838 7991 80.91.229.12 (21 Dec 2011 19:30:38 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 21 Dec 2011 19:30:38 +0000 (UTC) Cc: emacs-devel@gnu.org To: =?utf-8?B?SsOpcsOpbXk=?= Compostella Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Dec 21 20:30:32 2011 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RdRrv-0005ub-0t for ged-emacs-devel@m.gmane.org; Wed, 21 Dec 2011 20:30:27 +0100 Original-Received: from localhost ([::1]:40002 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RdRru-0007dV-Dr for ged-emacs-devel@m.gmane.org; Wed, 21 Dec 2011 14:30:26 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:54517) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RdRrr-0007dP-PH for emacs-devel@gnu.org; Wed, 21 Dec 2011 14:30:24 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RdRrq-0004Tz-JI for emacs-devel@gnu.org; Wed, 21 Dec 2011 14:30:23 -0500 Original-Received: from mail-vw0-f41.google.com ([209.85.212.41]:41389) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RdRrq-0004Tt-Gx for emacs-devel@gnu.org; Wed, 21 Dec 2011 14:30:22 -0500 Original-Received: by vbbfn1 with SMTP id fn1so7224077vbb.0 for ; Wed, 21 Dec 2011 11:30:21 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=sender:from:to:cc:subject:references:reply-to:date:in-reply-to :message-id:user-agent:mime-version:content-type :content-transfer-encoding; bh=Qj+sMGVHDStYVAsTjnENaSRpjSR7pRUvrBKgdt4fNMM=; b=n7Mf/fPqJkuthBO6UZe8MMqdKZIpMeYokbaIPVCqmxdt8tNPCYdm0R4R+/SvUWlO/u 6Sv5gz41hkcGBl77JlzvAbvP7Owpd5jNVtGH+64NZlvLZV03wWE2m1S46IUnRkk2Re3u 6VHaHpFIYwJCfw27ltkKZmCZ9XAfaKIU17yyE= Original-Received: by 10.52.24.35 with SMTP id r3mr3619373vdf.81.1324495821570; Wed, 21 Dec 2011 11:30:21 -0800 (PST) Original-Received: from kwarm.red-bean.com (topp148-office-nyc.openplans.org. [67.221.177.15]) by mx.google.com with ESMTPS id hj10sm5135954vdb.0.2011.12.21.11.30.19 (version=TLSv1/SSLv3 cipher=OTHER); Wed, 21 Dec 2011 11:30:20 -0800 (PST) In-Reply-To: (=?utf-8?B?IkrDqXLDqW15?= Compostella"'s message of "Wed, 21 Dec 2011 11:03:47 +0100") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.92 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.212.41 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:146909 Archived-At: J=C3=A9r=C3=A9my Compostella writes: >I did not received any answers so I'm answering myself about : >- Do I miss something in the "submit" process, >- Is this patch is a mess ? >- Or maybe everybody is busy ... J=C3=A9r=C3=A9my, thanks for the patch. I think it's just #3: everyone is = busy. Sometimes it can take a while. In some cases, if the feature is not compelling enough to others, there may be no useful response at all. This doesn't mean it's a bad idea, it just means no one's convinced it's needed. Most people see battery status in an icon on their GUI toolbar, I think. Can you describe the use case(s) for battery.el? Is it easier for the visually impaired, for example? Maybe for people who are running their machine in text-console mode? When do you use it? Best, -Karl >So let me know, > >Thanks, > >Jeremy > >2011/12/18 J=C3=A9r=C3=A9my Compostella > > All, >=20=20=20=20 > I just bought a new laptop and installed a fresh Debian on it. I > used to > look at my current battery status using Emacs. I like to look at > the > current rate too since this laptop will be used during a long trip > and I > want to take care of the consumption in real time. >=20=20=20=20 > The issue is that with the 2.6.32 kernel from Debian for this > laptop I > do not have the /proc/acpi/battery part. However, the sysfs is > able to > report all the data I need. The current Emacs battery module is > not able > to retrieve the information I need from sysfs but it does from > /proc/acpi/battery. So I made a small evolution to enable the > following: >=20=20=20=20 > - Get the current rate > - Get the current temperature (does not work on my laptop but the > =C2=A0power_supply interface is able to provide it, so I added it too. > - Do the time remaining estimation using the current voltage, the > =C2=A0remaining capacity and the current rate. It works on both > charging and > =C2=A0discharging state. >=20=20=20=20 > I attached the patch but I warn you that it has been generated > using git > since I was unable to retrieve the bazar repository for the last > two > days (it hangs during the download process). By the way, do you > have any > advice which could help me ? >=20=20=20=20 > Please merge it or review it. >=20=20=20=20 > Best regards, >=20=20=20=20 >=20=20=20=20 > Jeremy >=20=20=20=20 > PS: I signed my Emacs assignment and post it by mail 10 days ago. > -- > Sent from my Emacs