From cf7dfe0cd17a5ea86d49fc82cb681045a9daad26 Mon Sep 17 00:00:00 2001 From: MaxineMuster <146550015+MaxineMuster@users.noreply.github.com> Date: Wed, 6 Nov 2024 09:12:10 +0100 Subject: [PATCH] try fix negative temperatures in log --- src/driver/drv_ds1820_simple.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/driver/drv_ds1820_simple.c b/src/driver/drv_ds1820_simple.c index 120131102..a94ad92a5 100644 --- a/src/driver/drv_ds1820_simple.c +++ b/src/driver/drv_ds1820_simple.c @@ -445,7 +445,7 @@ void DS1820_OnEverySecond() { dsread=0; lastconv=g_secondsElapsed; CHANNEL_Set(g_cfg.pins.channels[Pin], t, CHANNEL_SET_FLAG_SILENT); - DS1820_LOG(INFO, "Temp=%i.%02i", (int)t/100 , (int)t%100); + DS1820_LOG(INFO, "Temp=%i.%02i", (int)t/100 , frac); } } else if (dsread == 0 && (g_secondsElapsed % ds18_conversionPeriod == 0 || lastconv == 0)) {