12 #ifndef ADAFRUITIO_GROUP_H 13 #define ADAFRUITIO_GROUP_H 18 #include "Adafruit_MQTT.h" 36 void set(
const char *feed,
char *value);
37 void set(
const char *feed,
bool value);
38 void set(
const char *feed, String value);
39 void set(
const char *feed,
int value);
40 void set(
const char *feed,
unsigned int value);
41 void set(
const char *feed,
long value);
42 void set(
const char *feed,
unsigned long value);
43 void set(
const char *feed,
float value);
44 void set(
const char *feed,
double value);
49 void setLocation(
double lat = 0,
double lon = 0,
double ele = 0);
74 Adafruit_MQTT_Subscribe *_sub;
75 Adafruit_MQTT_Publish *_pub;
76 Adafruit_MQTT_Publish *_get_pub;
82 double _lat, _lon, _ele;
85 #endif // ADAFRUITIO_GROUP_H Class for interacting with Adafruit IO.
Definition: AdafruitIO.h:45
bool create()
Creates new Adafruit IO Group. https://io.adafruit.com/api/docs/#create-group.
Definition: AdafruitIO_Group.cpp:454
~AdafruitIO_Group()
Adafruit IO Group destructor.
Definition: AdafruitIO_Group.cpp:42
void setLocation(double lat=0, double lon=0, double ele=0)
Sets up locational metadata.
Definition: AdafruitIO_Group.cpp:414
friend class AdafruitIO_Group
AdafruitIO_Group addition.
Definition: AdafruitIO.h:56
const char * name
Definition: AdafruitIO_Group.h:60
Class that contains MQTT subscription callbacks.
Definition: AdafruitIO_MQTT.h:25
void(* AdafruitIODataCallbackType)(AdafruitIO_Data *data)
Definition: AdafruitIO_Definitions.h:26
AdafruitIO_Data * getFeed(const char *feed)
Obtains data from feed within group.
Definition: AdafruitIO_Group.cpp:244
AdafruitIO_Data * data
Definition: AdafruitIO_Group.h:63
void onMessage(AdafruitIODataCallbackType cb)
Sets up Adafruit IO callback to monitor incoming new data in group.
Definition: AdafruitIO_Group.cpp:277
Class that contains methods for Adafruit IO MQTT callbacks.
Definition: AdafruitIO_Definitions.h:34
bool exists()
Checks if Adafruit IO Group exists. https://io.adafruit.com/api/docs/#get-group.
Definition: AdafruitIO_Group.cpp:436
const char * owner
Definition: AdafruitIO_Group.h:61
void call(AdafruitIO_Data *d)
Adafruit IO Group subscription function callback.
Definition: AdafruitIO_Group.cpp:337
Class for interacting with Adafruit IO Data Records. https://io.adafruit.com/api/docs/#data.
Definition: AdafruitIO_Data.h:30
Class for interacting with Adafruit IO Grouped Feeds https://io.adafruit.com/api/docs/mqtt.html#group-topics.
Definition: AdafruitIO_Group.h:30
bool save()
Updates value of Adafruit IO Group.
Definition: AdafruitIO_Group.cpp:201
void subCallback(char *val, uint16_t len)
Checks for new value within Adafruit IO group.
Definition: AdafruitIO_Group.cpp:365