initial release

This commit is contained in:
2021-08-04 12:24:08 +02:00
parent fe267a81e2
commit bb9da629fb
12 changed files with 883 additions and 0 deletions

13
mqtt.h Normal file
View File

@ -0,0 +1,13 @@
#ifndef __MQTT_H__
#define __MQTT_H__
#define TOPIC_MAXLEN 255
#define TIC_QOS 0
extern struct mosquitto *mqtt_open(const char *host, int port, int keepalive);
extern void mqtt_close(struct mosquitto *mosq);
extern int mqtt_publish(struct mosquitto *mosq, const char *topic_prefix, const char *topic_suffix, const void *payload, int qos);
extern const char *mqtt_strerror(int err);
#endif