mqtt not yet working

This commit is contained in:
Wolfgang Hottgenroth 2020-11-10 16:23:46 +01:00
parent 00cedd5e6a
commit fa66527d9c

View File

@ -61,7 +61,7 @@ static void messageArrived(MessageData* md)
} }
static void mqttHandler(void *handle) { static void mqttHandler(void *handle) {
MQTTYield(&mqttClient, data.keepAliveInterval); // MQTTYield(&mqttClient, data.keepAliveInterval);
} }
void mqttCommInit(void *handle) { void mqttCommInit(void *handle) {
@ -89,12 +89,12 @@ void mqttCommInit(void *handle) {
int rc = MQTTConnect(&mqttClient, &data); int rc = MQTTConnect(&mqttClient, &data);
logMsg("Connected %d\r\n", rc); logMsg("Connected %d\r\n", rc);
// opts.showtopics = 1; opts.showtopics = 1;
// logMsg("Subscribing to %s\r\n", "hello/wiznet"); logMsg("Subscribing to %s\r\n", "hello/wiznet");
// rc = MQTTSubscribe(&mqttClient, "hello/wiznet", opts.qos, messageArrived); rc = MQTTSubscribe(&mqttClient, "hello/wiznet", opts.qos, messageArrived);
// logMsg("Subscribed %d\r\n", rc); logMsg("Subscribed %d\r\n", rc);
// schAdd(mqttHandler, NULL, 0, 10); schAdd(mqttHandler, NULL, 0, 100);
} }
} }