Battery charging/discharging state change delayed by cinnamon?

Questions about hardware,drivers and peripherals
Forum rules
Before you post please read how to get help
Post Reply
m.ardito
Level 1
Level 1
Posts: 15
Joined: Mon May 19, 2014 6:47 am
Location: Torino, Italy

Battery charging/discharging state change delayed by cinnamon?

Post by m.ardito » Wed May 02, 2018 2:55 am

Hi,
Mint 18.3 on ASUS n580vs-fi038t - cinnamon

I have recently installed mint on my notebook (previously had 18.1 on an old lenovo thinkpad)

I have this issue: if the battery is low, and I plug the AC charger, cinnamon icon is not detecting the plugged AC charger, even if it IS charging the battery.
The icon stays in battery mode, but its status will slowly show the increasing battery charge. And the same happens for the opposite.

Update: I later found that, after a reboot, the real battery charging state is shown after a quite long delay (see below)...

here is what acpi -i says while it is in this state:

$ acpi -i
Battery 0: Discharging, 60%, 01:12:23 remaining
Battery 0: design capacity 4164 mAh, last full capacity 3989 mAh = 95%

note: I plugged the AC when battery was at 11%...

But, if I even just "suspend" mint, and then resume it, the icon now shows the charging state.

and this is the new acpi -i output:

$ acpi -i
Battery 0: Charging, 64%, 00:42:59 until charged
Battery 0: design capacity 4164 mAh, last full capacity 3989 mAh = 95%

This laptop came with Windows 10, and it is set as a dual boot option: booting from W10, the charger state is immediately noticed, so I don't think is charger or battery issue, but a linux software issue, probably...

[edit]
I did some more testing, as I recalled to have tested this behaviour with the live .iso before installing, and in my memory it worked well...
Now I tried again booting from the USB drive, and indeed it worked, but the cinnamon battery state was updated with a delay between 60 and 120 seconds... nearly 2 minutes!

So I booted back to the installed mint, and tried to wait, after plugging/unplugging the AC cable, while monitoring acpi state with

watch acpi -i

well, it seems that acpi -i can detect instantly when the plug is in or out, showing charging/discharging state in near real time.

but cinnamon (both the taskbar icon and the preferences battery status panel) seems to wait a bit too much to display the new state...!

Usually I try to suspend/resume well before 90 seconds, to prevent hybernating...maybe I never noticed?
But I could swear that sometimes it's not updating at all... as I said above, when I plugged the AC cable it went from 11% to 60% always showing the discharging state...

[/edit]

What can be causing this?
How can I fix this weird behaviour? Is there even a workaround?

Thanks,
Marco
Last edited by m.ardito on Wed May 02, 2018 4:17 am, edited 1 time in total.

User avatar
AZgl1500
Level 10
Level 10
Posts: 3478
Joined: Thu Dec 31, 2015 3:20 am
Location: Oklahoma where the wind comes sweeping down the plains
Contact:

Re: Battery charging, charger not detected

Post by AZgl1500 » Wed May 02, 2018 2:57 am

typical for ASUS I do believe,

I have an ASUS laptop phablet and the icon shows this.
been doing so for 2 years, and the battery is always at 98%


Image

m.ardito
Level 1
Level 1
Posts: 15
Joined: Mon May 19, 2014 6:47 am
Location: Torino, Italy

Re: Battery charging/discharging state change delayed by cinnamon?

Post by m.ardito » Wed May 02, 2018 4:22 am

Hi, thanks for replying.
I did some more testing, and update my post above (even changed the title), as it seems (at least just after a reboot) that it is an apparently very long delay by cinnamon...

But I fear that this is not always the case, as said above. I'll keep monitoring this, but is there a way to make the overall system more reactive to the battery charging state? Maybe a polling frequency?

Moreover, I usually just suspend my mint laptop, as it comes back in a few seconds, could this be causing troubles to the power management detection?

any tip is welcome...

User avatar
AZgl1500
Level 10
Level 10
Posts: 3478
Joined: Thu Dec 31, 2015 3:20 am
Location: Oklahoma where the wind comes sweeping down the plains
Contact:

Re: Battery charging/discharging state change delayed by cinnamon?

Post by AZgl1500 » Wed May 02, 2018 11:42 am

m.ardito wrote:
Wed May 02, 2018 4:22 am

But I fear that this is not always the case, as said above. I'll keep monitoring this, but is there a way to make the overall system more reactive to the battery charging state? Maybe a polling frequency?

any tip is welcome...
I have never investigated this area, would be nice to learn what is going on though.

Post Reply

Return to “Hardware Support”