-->
Page 1 of 2

Looking for a mqtt subscribe example

PostPosted: Tue Apr 21, 2015 3:30 am
by gambituk
Hi all, just wondered if anyone came across an appropriate example to use with the arduino ide of subscribing to mqtt topic and then doing something with the data? I'm thinking of a relay or LED activated by a topic, or even later an oled display. I've seen examples using the alternative methods of programming, but i would like to find something that we can use with this.

Any pointers really appreciated!

Gambituk

Re: Looking for a mqtt subscribe example

PostPosted: Tue Apr 21, 2015 4:24 am
by gerardwr

Re: Looking for a mqtt subscribe example

PostPosted: Tue Apr 21, 2015 5:37 am
by gambituk
Yes, thanks, i had looked at that also, but all the examples seem to be mostly focused on the publish part of the library, i guess i will just have to modify it and post it as a subscribe example. :D

Re: Looking for a mqtt subscribe example

PostPosted: Tue Apr 21, 2015 6:10 am
by CptanPanic
I think in that gist it is all setup, you would just add some processing in the callback method to check to see which of your subscriptions were received.