From b16a818cd0918845ea899bb913ce4320a606a510 Mon Sep 17 00:00:00 2001 From: Timmy Keller Date: Thu, 12 Sep 2024 14:01:09 -0500 Subject: add charging state to stdout when ran --- lowbat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lowbat.c') diff --git a/lowbat.c b/lowbat.c index f3855bc..50651a7 100644 --- a/lowbat.c +++ b/lowbat.c @@ -148,7 +148,7 @@ int main() { w_lowbat_crit = w_lowbat = 0; // clear conditions } - printf("\r%d%%", capacity); + printf("\r%s %d%%", discharging ? "Discharging" : "Charging", capacity); fflush(stdout); sleep(PERIOD); } -- cgit v1.2.3