View Single Post
  #2  
Old March 4th 19, 06:46 PM posted to alt.comp.hardware
Paul[_28_]
external usenet poster
 
Posts: 1,467
Default Battery not recognised

Sécherre wrote:
Hello !

I've installed Debian Stretch on my HP x2 Detachable with the kernel 4.19.

My battery isn't recognised, so I don't have a battery level in the
systray. Only the command `lshw` is able to identify the battery :

-battery
--- produit: SW02032XL
--- fabriquant: 333-42-1E-A
--- identifiant matériel: 1
--- emplacement: Primary
--- capacité: 32570mWh
--- configuration: voltage=7,7V

I've tried a lot of things without succes. It's seems like the kernel
isn't able to recognise the battery.

Do you have any tips about this problem?


Sylvain


I like the Arch Linux articles, for background info.

https://wiki.archlinux.org/index.php...#Battery_state

"ACPI

Battery state can be read using ACPI utilities from the terminal.

ACPI command line utilities are provided via the acpi package.

See ACPI modules for more information.

cbatticon is a battery icon that sits in the system tray.

batterymon-cloneAUR is a battery monitor that sits in the
system tray, similar to batti.

batifyAUR is an udevrule file triggering plug and battery level
notifications (multi-x sessions support).
"

It says there, that the ACPI subsystem provided by the BIOS
(ACPI tables), has an ACPI object representing the battery.
So the software in Linux to read it, will be dealing with
the ACPI object, rather than running a "serial interface" on
the battery directly.

*******

And this article

https://superuser.com/questions/8083...ly-bat0-uevent

suggests:

cat /sys/class/power_supply/BAT0/uevent

POWER_SUPPLY_NAME=BAT0
POWER_SUPPLY_STATUS=Discharging
POWER_SUPPLY_PRESENT=1
POWER_SUPPLY_TECHNOLOGY=Li-ion
POWER_SUPPLY_CYCLE_COUNT=481
POWER_SUPPLY_VOLTAGE_MIN_DESIGN=7400000
POWER_SUPPLY_VOLTAGE_NOW=7400000
POWER_SUPPLY_POWER_NOW=9361000
POWER_SUPPLY_ENERGY_FULL_DESIGN=48248000
POWER_SUPPLY_ENERGY_FULL=40877000
POWER_SUPPLY_ENERGY_NOW=20712000
POWER_SUPPLY_CAPACITY=50
POWER_SUPPLY_MODEL_NAME=UX32-65
POWER_SUPPLY_MANUFACTURER=ASUSTeK
POWER_SUPPLY_SERIAL_NUMBER=

Maybe that will tell you if it is detected.

*******

If you have purchased a third-party battery, it's
possible the capacity monitoring chip is not set up
properly. And that's why it isn't registering properly.

This document seems to suggest it's on SMBUS (the same bus
that the SPD chip on the DIMMs use). While the word I2C
appears in the document in the definition section, the word
doesn't appear in the body text.

http://smartbattery.org/specs/sbdat110.pdf

And this is the smart battery charger, the "power management
block" on the motherboard. It charges the battery up, when
the battery is discharged slightly, and AC power is available.
This isn't likely to answer any of your questions, but is a
companion to the other spec.

http://sbs-forum.org/specs/sbc110.pdf

Pointer from here.

https://electronics.stackexchange.co...-battery-packs

*******

https://www.kernel.org/doc/html/v4.1...r-api/i2c.html

There is this. (With the usual "caution" language)

https://linux.die.net/man/8/i2cdetect

There is lm-sensors, but I can't see any evidence it sees
laptop battery chips as part of its feature set.

*******

It's possible some subsystem is missing between ACPI
and user-land. But what, I don't know... Is it udev?
I don't know the role of those softwares and what they do.

Paul