I know that the particle cloud/console has the google cloud pub/sub integration. I set this up accordingly, and it worked great for sending data, publishing it to a topic.
However, the provided code to receive events sent to the topic doesn’t seem to work, and all the info I find online is about sending data, not receiving.
Is there something more that needs to happen? Do I need to create a subscription with a certain naming convention? To be clear, the integration documentation shows that this code should work (i think):
void setup() {
// Subscribe to the integration response event
Particle.subscribe("hook-response/<topicname>", myHandler, MY_DEVICES);
}
void myHandler(const char *event, const char *data) {
// Handle the integration response
}
Any and all help and advice is appreciated!