debug
This commit is contained in:
+2
-4
@@ -276,15 +276,13 @@ void Pws2mqtt::parseData(QList<std::pair<QString, QString>> queryList)
|
|||||||
#endif
|
#endif
|
||||||
if (name == "tempf")
|
if (name == "tempf")
|
||||||
{
|
{
|
||||||
static QDateTime timeTemp = QDateTime::currentDateTime().addSecs(-600);
|
|
||||||
propertyValue = qRound(fahrenheitToCelsius(fValue) * 10 ) / 10.0;
|
propertyValue = qRound(fahrenheitToCelsius(fValue) * 10 ) / 10.0;
|
||||||
debug (DEBUGMACRO, "timeTemp = " + timeTemp.time().toString() + " - current :" + QDateTime::currentDateTime().toString() , DEBUG);
|
|
||||||
|
|
||||||
if (compare (propertiesValue[name], propertyValue, 1) and timeTemp < QDateTime::currentDateTime())
|
if (compare (propertiesValue[name], propertyValue, 1)) // and timeTemp < QDateTime::currentDateTime())
|
||||||
{
|
{
|
||||||
//notif += formatNotifString (propertyName[name].first, propertyName[name].second, QByteArray::number(qPow(propertyValue, 1.0)));
|
//notif += formatNotifString (propertyName[name].first, propertyName[name].second, QByteArray::number(qPow(propertyValue, 1.0)));
|
||||||
//debug (DEBUGMACRO, "", DEBUG);
|
//debug (DEBUGMACRO, "", DEBUG);
|
||||||
timeTemp = timeTemp.currentDateTime().addSecs(300);
|
//timeTemp = timeTemp.currentDateTime().addSecs(300);
|
||||||
propertyList[name] = formatNotifString(propertyName[name], QByteArray::number(propertyValue));
|
propertyList[name] = formatNotifString(propertyName[name], QByteArray::number(propertyValue));
|
||||||
propertiesValue[name] = propertyValue;
|
propertiesValue[name] = propertyValue;
|
||||||
if (propertyValue > 35)
|
if (propertyValue > 35)
|
||||||
|
|||||||
Reference in New Issue
Block a user