debug
This commit is contained in:
1 parent
0d359ee997
commit
d2c7ececb4
2 files changed
+2
-4
No files matched your search
@@ -25,7 +25,7 @@
|
|||||||
#define BROKER_ADDRESS "localhost"
|
#define BROKER_ADDRESS "localhost"
|
||||||
#define MQTT_PORT 1883;
|
#define MQTT_PORT 1883;
|
||||||
|
|
||||||
uint debugLevel = INFO | NOTICE | INFO | WARNING | ERROR | ALERT;
|
uint debugLevel = DEBUG | INFO | NOTICE | INFO | WARNING | ERROR | ALERT;
|
||||||
QByteArray toFollow;
|
QByteArray toFollow;
|
||||||
|
|
||||||
//class MqttClient;
|
//class MqttClient;
|
||||||
@@ -37,6 +37,7 @@ Pws2mqtt *pws2mqtt;
|
|||||||
MqttClient *mqttClient;
|
MqttClient *mqttClient;
|
||||||
QHttpServer *httpServer;
|
QHttpServer *httpServer;
|
||||||
|
|
||||||
|
|
||||||
int main(int argc, char *argv[])
|
int main(int argc, char *argv[])
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|||||||
@@ -110,10 +110,8 @@ void Pws2mqtt::listeningHttp()
|
|||||||
if (!port)
|
if (!port)
|
||||||
{
|
{
|
||||||
debug(DEBUGMACRO, "Http Server failed to listen on a port.", ERROR);
|
debug(DEBUGMACRO, "Http Server failed to listen on a port.", ERROR);
|
||||||
//return 0;
|
|
||||||
}
|
}
|
||||||
debug(DEBUGMACRO, "Listening on port " + QString::number(port));
|
debug(DEBUGMACRO, "Listening on port " + QString::number(port));
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void Pws2mqtt::parseData(QList<std::pair<QString, QString>> queryList)
|
void Pws2mqtt::parseData(QList<std::pair<QString, QString>> queryList)
|
||||||
@@ -285,7 +283,6 @@ void Pws2mqtt::parseData(QList<std::pair<QString, QString>> queryList)
|
|||||||
{
|
{
|
||||||
jsonString = jsonString +", " + deviceString + "}}";
|
jsonString = jsonString +", " + deviceString + "}}";
|
||||||
mqttClient->send_message(jsonString);
|
mqttClient->send_message(jsonString);
|
||||||
//debug(DEBUGMACRO, "sent => " + jsonString, DEBUG);
|
|
||||||
}else
|
}else
|
||||||
{
|
{
|
||||||
debug(DEBUGMACRO, "No values to send", DEBUG);
|
debug(DEBUGMACRO, "No values to send", DEBUG);
|
||||||
|
|||||||
Reference in new issue
Block a user