You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
616 B
C
21 lines
616 B
C
#ifndef _MQTT_H_
|
|
#define _MQTT_H_
|
|
|
|
#include "Ethernet/socket.h"
|
|
#include "Internet/MQTT/mqtt_interface.h"
|
|
#include "Internet/MQTT/MQTTClient.h"
|
|
|
|
#define SOCK_MQTT 2
|
|
#define MQTT_BUFFER_SIZE 512 // 2048
|
|
|
|
extern uint8_t mqtt_readBuffer[MQTT_BUFFER_SIZE];
|
|
extern wiz_NetInfo netInfo;
|
|
extern uint8_t MQTT_targetIP[4];
|
|
|
|
void messageArrived(MessageData* md);
|
|
void mqtt_pub(Client* mqtt_client, char * mqtt_topic, char * mqtt_msg, int mqtt_msg_len);
|
|
void send_value(Client* mqtt_client,char* topic, int16_t value);
|
|
void send_value_fl(Client* mqtt_client,char* topic, float value, uint8_t decimal_points);
|
|
|
|
#endif
|