summaryrefslogtreecommitdiff
path: root/src/status/battery.c
diff options
context:
space:
mode:
authornorly <ny-git@enpas.org>2022-02-04 16:23:27 +0100
committernorly <ny-git@enpas.org>2022-02-04 16:23:27 +0100
commit5fa4697d8806e85e3313f12a4cd48b0968beed76 (patch)
treefb417d1bc346c678826f467964f4df964cca2bc7 /src/status/battery.c
parent624dbb241fc1cdc04b7c2bf3fb2398c5fd2de7c6 (diff)
battery: Add divider for voltage_nowHEADmaster
Yes, the millions of Watts displayed were in error.
Diffstat (limited to 'src/status/battery.c')
-rw-r--r--src/status/battery.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/status/battery.c b/src/status/battery.c
index 5ce9b04..79d65da 100644
--- a/src/status/battery.c
+++ b/src/status/battery.c
@@ -112,7 +112,7 @@ void status_battery(GlobalData *g, char *batname)
batname, chargePercent);
} else {
snprintf(text, sizeof(text), "%s: %d%% %.1fh %.1fW",
- batname, chargePercent, battTime, (float)voltageNow * (float)currentNow / 1000000.0);
+ batname, chargePercent, battTime, (float)voltageNow / 1000000.0 * (float)currentNow / 1000000.0);
}
line_append_item(g, &s);