ESPMegaPRO-v3-SDK/ESPMegaPRO-OS-SDK/lib/ESPMegaPRO/RemoteVariable.hpp

17 lines
401 B
C++
Raw Normal View History

2024-01-16 04:22:41 +00:00
#pragma once
#include <ESPMegaIoT.hpp>
class RemoteVariable
{
public:
RemoteVariable();
~RemoteVariable();
void begin(size_t size, char* topic, ESPMegaIoT* iot);
void subscribe();
char* getValue();
void mqtt_callback(char* topic, char* payload);
private:
ESPMegaIoT* iot;
char* topic;
char* value;
size_t size;
};