All of lore.kernel.org
 help / color / mirror / Atom feed
From: Alexey Starikovskiy <aystarik@gmail.com>
To: Andika Triwidada <andika@gmail.com>
Cc: linux-acpi@vger.kernel.org
Subject: Re: Battery 'present rate' display weirdness
Date: Sat, 28 Jul 2007 12:50:03 +0400	[thread overview]
Message-ID: <46AB033B.80608@gmail.com> (raw)
In-Reply-To: <7e0bae390707270823v3e80b72cmc0f4c665c3ce907f@mail.gmail.com>

Hello Andika,

Acer was long user of smart battery system (SBS), which allows for 
negative values of the current (it is signed 16 bit value in SBS).
If your Acer exports battery directly with SBS, there is a bug in drivers/acpi/sbs.c
If it exports battery with ACPI control methods (CM), then there is a need of 
workaround in drivers/acpi/battery.c (CM uses 64 bit value to store current, 
so this is not a matter of getting absolute value of it).  

Could you please open bug against ACPI/Battery and attach acpidump output
to it?

Thanks,
Alex. 

Andika Triwidada wrote:
> My Acer Aspire 5580 shows normal info on discharging
> 
> andika@hokage:~$ cat /proc/acpi/battery/*/*
> alarm:                   unsupported
> present:                 yes
> design capacity:         4000 mAh
> last full capacity:      4131 mAh
> battery technology:      rechargeable
> design voltage:          11100 mV
> design capacity warning: 300 mAh
> design capacity low:     165 mAh
> capacity granularity 1:  32 mAh
> capacity granularity 2:  32 mAh
> model number:            PRESPAL
> serial number:           217
> battery type:            LION
> OEM info:                PANASONIC
> present:                 yes
> capacity state:          ok
> charging state:          discharging
> present rate:            2437 mA
> remaining capacity:      448 mAh
> present voltage:         10336 mV
> 
> But abnormal (?) one when charging:
> 
> andika@hokage:~$ cat /proc/acpi/battery/*/*
> alarm:                   unsupported
> present:                 yes
> design capacity:         4000 mAh
> last full capacity:      4131 mAh
> battery technology:      rechargeable
> design voltage:          11100 mV
> design capacity warning: 300 mAh
> design capacity low:     165 mAh
> capacity granularity 1:  32 mAh
> capacity granularity 2:  32 mAh
> model number:            PRESPAL
> serial number:           217
> battery type:            LION
> OEM info:                PANASONIC
> present:                 yes
> capacity state:          ok
> charging state:          charging
> present rate:            63418 mA
>                          ^^^^^^^^
> remaining capacity:      256 mAh
> present voltage:         10640 mV
> 
> Does it need to be handled differently in battery.c or up to any
> userspace tools to check 'charging state' and calculate proper (65535
> - x) 'present rate'?
> 
> This is on kernel 2.6.22
> 
> TIA.
> 
> --
> andika
> -
> To unsubscribe from this list: send the line "unsubscribe linux-acpi" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> 


  reply	other threads:[~2007-07-28  8:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-27 15:23 Battery 'present rate' display weirdness Andika Triwidada
2007-07-28  8:50 ` Alexey Starikovskiy [this message]
2007-07-28 10:32   ` Andika Triwidada

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=46AB033B.80608@gmail.com \
    --to=aystarik@gmail.com \
    --cc=andika@gmail.com \
    --cc=linux-acpi@vger.kernel.org \
    /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.
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.