From 4d18a8d9f7f20067bd8b3cfcf8965c6c086a806e Mon Sep 17 00:00:00 2001 From: Daniel TARTAVEL Date: Thu, 28 May 2026 12:03:27 +0200 Subject: [PATCH] temperature alert modified --- src/pws2mqtt.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/pws2mqtt.cpp b/src/pws2mqtt.cpp index 3ad87ba..4ef8e1f 100644 --- a/src/pws2mqtt.cpp +++ b/src/pws2mqtt.cpp @@ -276,19 +276,19 @@ void Pws2mqtt::parseData(QList> queryList) propertyList[name] = formatNotifString(propertyName[name], QByteArray::number(propertyValue)); propertiesValue[name] = propertyValue; debug (DEBUGMACRO, name + " : " + QByteArray::number(propertyValue) + " announced = " + QByteArray::number(announced[name]), DEBUG); - if (propertyValue > 35) + if (qRound(propertyValue) >= 35) { if (announced[name] != 5) { - debug(DEBUGMACRO, "Nofifying external temp > 35°C", DEBUG); + debug(DEBUGMACRO, "Nofifying external temp >= 35°C", DEBUG); notify (propertyList[name], priorityList[5]); announced[name] = 5; } - }else if (propertyValue > 27) + }else if (qRound(propertyValue) >= 27) { if (announced[name] != 4) { - debug(DEBUGMACRO, "Nofifying external temp > 27°C", DEBUG); + debug(DEBUGMACRO, "Nofifying external temp >= 27°C", DEBUG); notify (propertyList[name], priorityList[4]); announced[name] = 4; }