Example node for Yodiwo's Plegma API

Dependencies:   EthernetInterface FXOS8700Q HTTPClient HTTPD MQTTS SDFileSystem YodiwoPlegma mbed-rpc mbed-rtos mbed wolfSSL

Revision:
5:1ef168357347
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/mqtt_helpers.h	Mon Sep 28 08:55:29 2015 +0000
@@ -0,0 +1,21 @@
+#ifndef __MQTT_HELPERS_H__
+#define __MQTT_HELPERS_H__
+
+#include "MQTTClient.h"
+#include "MQTTSocket.h"
+
+//#include "yodiwo_api.h"
+#include <stdlib.h>
+
+#define MAX_MSG_LEN 2500
+#define MAX_TOPIC_LEN 150
+
+
+int mqtt_init(char *hostname, int port, char *certfile, char *nodeKey, char *nodeSecret);
+void on_mqtt_message(MQTT::MessageData &msg);
+
+//typedef int (*portevent_handler_func)(Yodiwo_Plegma_PortEvent_t *event);
+
+int publisher(char *msg, int msg_len, char *msg_type);
+
+#endif /* __MQTT_HELPERS_H__ */