Slide 82
Slide 82 text
MESH PUBLISH AND SUBSCRIBE FOR LOCAL MESSAGING
Mesh.publish(“hello-world”,
“I’m meshing!”);
void hello(const char *event,
const char *data)
{
Serial.println(“Device two got it!");
}
void setup()
{
Mesh.subscribe(“hello-world”, hello);
}
void hello(const char *event,
const char *data)
{
Serial.println(“Device one got it!");
}
void setup()
{
Mesh.subscribe(“hello-world”, hello);
}