all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: "T.V Raman" <raman@google.com>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: "Basil L. Contovounesios" <contovob@tcd.ie>,  emacs-devel@gnu.org
Subject: Re: battery.el broken?
Date: Sat, 05 Jun 2021 18:58:00 -0700	[thread overview]
Message-ID: <p914kebbvpz.fsf@google.com> (raw)
In-Reply-To: <jwvczt0uf27.fsf-monnier+emacs@gnu.org> (Stefan Monnier's message of "Sat, 05 Jun 2021 18:23:45 -0400")

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain; charset=gb18030, Size: 2330 bytes --]

And on the same machine a few mins later:

(setq battery-status-function #'battery-linux-sysfs)
M-x battery displays the time left:
Power BAT, battery Discharging (98.7% load, remaining time 10:48)
(battery-linux-sysfs)
((99 . "4110066.461338953") (114 . "4.9") (109 . "624") (104 . "10") (116 . "10:24") (100 . "N/A") (66 . "Discharging") (98 . "") (112 . "98.7") (76 . "BAT"))

Stefan Monnier <monnier@iro.umontreal.ca> writes:

I am mostly convinced this is a dbus/upower bug since I too checked and
nothing has changed on the Emacs side  on the machine, still running
Emacs from Github@HEAD.

Will now try some of the other status functions, I think the output
stopped telling me time left likely a couple of days ago.

Typing this with the machine fully charged and not plugged into the AC
jack, but the upower output shown below appears to think it's on AC
Power.

battery-status-function == battery-upower

(mapcar #'battery--upower-device-properties
(battery--upower-devices)
)

((("NativePath" . "AC") ("Vendor" . "") ("Model" . "") ("Serial" . "") ("UpdateTime" . 1622943939) ("Type" . 1) ("PowerSupply" . t) ("HasHistory") ("HasStatistics") ("Online") ("Energy" . 0.0) ("EnergyEmpty" . 0.0) ...) (("NativePath" . "BAT0") ("Vendor" . "SMP") ("Model" . "01AV431") ("Serial" . "5195") ("UpdateTime" . 1622944181) ("Type" . 2) ("PowerSupply" . t) ("HasHistory" . t) ("HasStatistics" . t) ("Online") ("Energy" . 51.36) ("EnergyEmpty" . 0.0) ...) (("NativePath" . "ucsi-source-psy-USBC000:001") ("Vendor" . "") ("Model" . "") ("Serial" . "") ("UpdateTime" . 1622943939) ("Type" . 1) ("PowerSupply" . t) ("HasHistory") ("HasStatistics") ("Online" . t) ("Energy" . 0.0) ("EnergyEmpty" . 0.0) ...) (("NativePath" . "ucsi-source-psy-USBC000:002") ("Vendor" . "") ("Model" . "") ("Serial" . "") ("UpdateTime" . 1622943940) ("Type" . 1) ("PowerSupply" . t) ("HasHistory") ("HasStatistics") ("Online") ("Energy" . 0.0) ("EnergyEmpty" . 0.0) ...))


>> If so, please say which Emacs version you're running and what your value
>> of battery-status-function is.
>
> You might also want to try using another of those
> battery-status-functions to see if that helps.
>
>
>         Stefan
>
>

-- 

Thanks,

--Raman(I Search, I Find, I Misplace, I Research)
7©4 Id: kg:/m/0285kf1  •0Ü8



  parent reply	other threads:[~2021-06-06  1:58 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-05 13:55 battery.el broken? T.V Raman
2021-06-05 22:21 ` Basil L. Contovounesios
2021-06-05 22:23   ` Stefan Monnier
2021-06-06  1:52     ` T.V Raman
2021-06-11 10:51       ` Basil L. Contovounesios
2021-06-11 14:30         ` T.V Raman
2021-06-06  1:58     ` T.V Raman [this message]
2021-06-26  2:01 ` T.V Raman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=p914kebbvpz.fsf@google.com \
    --to=raman@google.com \
    --cc=contovob@tcd.ie \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.