Fix units of current consumption value. #5
Manually merged
SlavekB
merged 1 commits from fix/unify-units-of-current-consumption
into master
4 years ago
Loading…
Reference in new issue
There is no content yet.
Delete Branch 'fix/unify-units-of-current-consumption'
Deleting a branch is permanent. It CANNOT be undone. Continue?
Previously it was not clear whether the units in tdehwlib are in Wh and W or Ah and A. Now the units are always Ah and A.
Because power consumption is usually given in W, the value is converted from A to W. If it is less than 100 W, it is displayed as a decimal number.
This is related to issue TDE/tdelibs#68.
Well, after testing with the two other PR's it seems that the reporting is wrong for me.
While the output should be 65.0 W it is 650 W. 😅
Also, it seems while we found consens now that there is no need of translation of "W, Ah" and such, there is the problem that in German (and other languages), for example the . has to be , as the decimal separator.
So 65,0 W (right) - 65.0 W (wrong - used now).
That should be true for all other PR's too.
Looks good overall. Just something to discuss together before merging.
@Chris where do you see this numbers in tdepowersave? I have searched everywhere but I can't find something similar. What am I missing?
Yes, it's a bit hidden. 😸
You need to click with the left mouse button on the TDEPowersave systray icon and you get some overview, where you can see that.
EDIT: Also, you need to use a laptop or likely, with some battery and need to unplug the power cord, so the consume of power can be read out.
Yeah, I did that but I don't see any power number there.... Could you post a screenshot just for my own info?
My TDE runs in a VM, so perhaps that could be the reason of the difference, so I am just curious.
During a discussion with Chris, the problem with 640 W clarified – tdepowersave with a patch was started with tdelibs without a patch. There remains only a problem with listing numbers with respect to locales.
Because the problem of listing numbers with respect to locales is more widespread – this not only concerns battery information, but also many other locations – such as disk sizes, space occupied, and so on, the PR for tdelibs and tdebase will be merged as they are and the problem with listing numbers will be solved separately.
@MicheleC 👍
Thanks @Chris. On my pc, that writing is not shown in tdepowersave. I checked the code and I think it is because the rate value is null. I think this is because of running inside VM: in device manager I see "time to charge" is 0 for the battery, even when in reality it is not. Something I should take a look at in future if I have time 😄
fa0e4e246c
.