
Enhanced Battery Monitor
Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net
tnaker
6 years ago
it cause the system to shutdow after showing a message that my battery is broken (%9)
it only occur on kde
Report
bigblondewolf
7 years ago
The applet shows a blank battery with a red cross on the bottom right on my laptop.
Everything else works fine: ac/batt status, percentage and time remaining, I just have a red cross on the battery. My battery is fine, holds for 5hrs.
OS is Arch Linux, KDE should be 4.10 something, computer is Dell Latitude with a samsung extended battery. Btw the applet doesn't show battery model, the original one does.
Report
bigblondewolf
7 years ago
Report
nekoxmachina
6 years ago
https://bugs.freedesktop.org/show_bug.cgi?id=60214
Report
Winnerer
7 years ago
Report
Myrmidon83
7 years ago
Is it something I have missed? Distro? KDE version?
Report
Myrmidon83
7 years ago
Report
arekm
7 years ago
Unfortunatelly battery applet seems unable to deal with this type of batteries even with "show the state for each battery present" set.
Could support for this be added?
I guess "show the state for each battery present" should become "show the state for each battery type present" with such support.
[arekm@t400 ~]$ solid-hardware details '/org/freedesktop/UPower/devices/mouse_0003o046DoC52Bx00BC'
udi = '/org/freedesktop/UPower/devices/mouse_0003o046DoC52Bx00BC'
parent = '/org/freedesktop/UPower' (string)
vendor = 'Logitech, Inc.' (string)
product = 'M570' (string)
description = 'Unknown Battery' (string)
Battery.plugged = true (bool)
Battery.type = 'MouseBattery' (0x4) (enum)
Battery.chargePercent = 50 (0x32) (int)
Battery.rechargeable = true (bool)
Battery.chargeState = 'Discharging' (0x2) (enum)
Report
viranch
7 years ago
Report
arekm
7 years ago
Report
EazyVG
8 years ago
Report
EazyVG
8 years ago
Report
EazyVG
7 years ago
Anyways, showing total time for both is not of critical essence for me, and as I undesratnd it might be related with tp_smapi as the same is yet not fully supported (kernel 3.4.x openSUSE 12.2) on newer ThinkPad notebooks.
Thanks again for the applet.
Report
EazyVG
7 years ago
Report
cyberbeat
8 years ago
diff -r enbattery/contents/ui/batterymonitor.qml ../../../../../Downloads/153981-enhanced-battery/contents/ui/batterymonitor.qml
52,53d51
< property int remainingMsec: Number(pmSource.data["Battery"]["Remaining msec"])
<
90d87
< property int remainingMsec: Number(pmSource.data["Battery"]["Remaining msec"])
124c121
< text: show_remaining_time?formatDuration2(remainingMsec):i18nc("overlay on the battery, needs to be really tiny", "%1%", percent);
---
> text: i18nc("overlay on the battery, needs to be really tiny", "%1%", percent);
241,254d237
< }
<
< function formatDuration2(msec) {
< if (msec==0)
< return "";
<
< var time = new Date(msec);
< var hours = time.getUTCHours();
< var minutes = time.getUTCMinutes();
< if (minutes<10)
< minutes = "0"+minutes;
< var str = hours+":"+minutes;
<
< return str;
Report
tomchiverton
7 years ago
Report
tomchiverton
6 years ago
$ diff -u batterymonitor.qml.orig batterymonitor.qml
--- batterymonitor.qml.orig 2014-04-13 13:43:57.976169606 +0100
+++ batterymonitor.qml 2014-04-13 13:48:38.216181061 +0100
@@ -85,6 +85,7 @@
property bool hasBattery: view.singleBattery ? batteries.cumulativePluggedin : model["Plugged in"]
property int percent: view.singleBattery ? batteries.cumulativePercent : model["Percent"]
property bool pluggedIn: pmSource.data["AC Adapter"]["Plugged in"]
+ property int remainingMsec: Number(pmSource.data["Battery"]["Remaining msec"])
width: view.width/view.count
height: view.height
@@ -118,7 +119,7 @@
Text {
id: overlayText
- text: i18nc("overlay on the battery, needs to be really tiny", "%1%", percent);
+ text: show_remaining_time?formatDuration2(remainingMsec):i18nc("overlay on the battery, needs to be really tiny", "%1%", percent);
color: theme.textColor
font.pixelSize: Math.max(parent.size/8, 11)
anchors.centerIn: labelRect
@@ -236,4 +237,18 @@
}
}
}
+ function formatDuration2(msec) {
+ if (msec==0)
+ return "";
+
+ var time = new Date(msec);
+ var hours = time.getUTCHours();
+ var minutes = time.getUTCMinutes();
+ if (minutes<10)
+ minutes = "0"+minutes;
+ var str = hours+":"+minutes;
+
+ return str;
+}
+
}
Report
viranch
8 years ago
Report
claude0001
8 years ago
I have a system (Lenovo T400) with two batteries. The Enhanced Battery Monitor correctly displays the total remaining time.
However, it displays only the charge state of one battery, although two ("Battery0" and "Battery1") show up correctly as sources in Plasma Engine Explorer.
The tooltip states e.g. "Battery: 93% (discharging)". Comparison with the information form Plasma Engine Explorer suggests that this corresponds to "Battery0". The information for "Battery1" is omitted.
I'm running Ubuntu 12.04.1 with Kernel 3.2.0 (amd64) and KDE 4.9.2.
Report
viranch
8 years ago
Report
claude0001
8 years ago
After some trying around I now believe that the problem is related to hibernation (aka. suspend-to-disk): Upon resume from hibernation, the plasmoid reproducibly "forgets" about one of the two batteries, although the information displayed by Plasma Engine Explorer is always correct.
After a clean reboot both batteries show up again in the plasmoid. Sending the system to sleep (suspend-to-ram) does not seem to result in "loss" of one battery.
All in all, the problem is less important than I first thought. Still, maybe things can be improved by somehow re-initialising the battery count upon resume ... ?
Report
claude0001
8 years ago
After some trying around I now believe that the problem is related to hibernation (aka. suspend-to-disk): Upon resume from hibernation, the plasmoid reproducibly "forgets" about one of the two batteries, although the information displayed by Plasma Engine Explorer is always correct.
After a clean reboot both batteries show up again in the plasmoid. Sending the system to sleep (suspend-to-ram) does not seem to result in "loss" of one battery.
All in all, the problem is less important than I first thought. Still, maybe things can be improved by somehow re-initialising the battery count upon resume ... ?
Report
viranch
8 years ago
Report
claude0001
8 years ago
I was using the official plasmoid on KDE 4.8.5 til yesterday, where it always worked as it should. I do not know if it ever worked properly on KDE 4.9.2 as I immediately switched to the unofficial plasmoid to get the remaining-time-feature back.
Sorry for double posting btw. it seems to happen when Firefox refreshes the page after submission ...
Report
viranch
8 years ago
Report