added utci coefficients
This commit is contained in:
11
pws2mqtt.cpp
11
pws2mqtt.cpp
@@ -241,11 +241,11 @@ void Pws2mqtt::parseData(QList<std::pair<QString, QString>> queryList)
|
||||
QString msg = "";
|
||||
static QDateTime timeWind = QDateTime::currentDateTime().addSecs(-600);
|
||||
quint8 windPriority = 1;
|
||||
//static QString msgNotif;
|
||||
|
||||
debug (DEBUGMACRO, name + " : " + QByteArray::number(propertyValue), DEBUG);
|
||||
propertiesValue["vent"] = round(mphTokmh(value.toFloat()));
|
||||
|
||||
debug (DEBUGMACRO, name + " : " + QByteArray::number(propertiesValue["vent"]), DEBUG);
|
||||
|
||||
for (quint8 i=0; i<forceVent.size();i++)
|
||||
{
|
||||
if (propertiesValue["vent"] <= forceVent[i][0].toDouble())
|
||||
@@ -261,10 +261,10 @@ void Pws2mqtt::parseData(QList<std::pair<QString, QString>> queryList)
|
||||
if (name == "windspeedmph")
|
||||
{
|
||||
//propertyList["forcevent"] = msg;
|
||||
propertyList[name] = formatNotifString ("Vent - " + msg, propertyName[name].second , QByteArray::number(propertyValue));
|
||||
propertyList[name] = formatNotifString ("Vent - " + msg, propertyName[name].second , QByteArray::number(propertiesValue["vent"]));
|
||||
}else
|
||||
{
|
||||
propertyList[name] = formatNotifString (propertyName[name].first, propertyName[name].second , QByteArray::number(propertyValue));
|
||||
propertyList[name] = formatNotifString (propertyName[name].first, propertyName[name].second , QByteArray::number(propertiesValue["vent"]));
|
||||
}
|
||||
setPriority(priority, windPriority);
|
||||
|
||||
@@ -672,7 +672,8 @@ void notify(QString notif, QString priority, QString inputPath)
|
||||
curl_easy_setopt(curl, CURLOPT_WRITEDATA, &readBuffer);
|
||||
|
||||
// Exécute la requête
|
||||
res = curl_easy_perform(curl);
|
||||
|
||||
res = curl_easy_perform(curl);
|
||||
|
||||
// Vérifie les erreurs
|
||||
if (res != CURLE_OK)
|
||||
|
||||
Reference in New Issue
Block a user