get and set config via mqtt messages
This commit is contained in:
@@ -1,12 +1,14 @@
|
||||
#include <mqtt.h>
|
||||
|
||||
#define STACK_DEPTH 8192
|
||||
#define BUFFER_SIZE 2048
|
||||
#define PRIOTITY 2
|
||||
|
||||
MQTTwrapper::MQTTwrapper() : m_config(Config::getInstance()), m_tcp(NetworkClient()), m_client(PubSubClient(m_tcp)), m_loopHandle(NULL)
|
||||
{
|
||||
m_client.setServer(m_config.m_mqttHost.c_str(), m_config.m_mqttPort);
|
||||
m_client.setKeepAlive(15);
|
||||
m_client.setKeepAlive(m_config.m_mqttKeepalive);
|
||||
m_client.setBufferSize(BUFFER_SIZE);
|
||||
getInstance(this);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user