adafruit io mqtt ?

Moderators: grovkillen, Stuntteam, TD-er

Post Reply
Message
Author
nikki81
Normal user
Posts: 23
Joined: 25 Jul 2017, 19:26

adafruit io mqtt ?

#1 Post by nikki81 » 21 Aug 2017, 20:33

Is it possible to us adafruit io mqtt with espeasy ?

Thanks Nikki

code10
New user
Posts: 1
Joined: 01 Sep 2017, 12:09

Re: adafruit io mqtt ?

#2 Post by code10 » 01 Sep 2017, 12:59

Yes it is possible i just got this working myself!

You need to use the OpenHab MQTT protocol and edit the publish template and subscribe templates.

CONFIG PAGE
Name: <yoursensorname>
Protocol: OpenHAB MQTT
Locate Controller: Use Hostname
Controller hostname: io.adafruit.com
controller port: 1883
controller User: <adafruit username>
controller password: <adafruit AIO Key>

Devices
Edit the device
Note down the "Value Name" settings

TOOLS > ADVANCED PAGE
Subscribe Template:
<adafruit username>/feeds/#

Publish Template:
<adafruit username>/feeds/%sysname%%valname%

For me i have a DHT22 (reads both temperature and humidity) so in the device settings value 1 name = temp, and value 2 name = hum
So this creates two feeds, one for temp and one for humidity
And my sensor name is "sensor01"

So for me...
<adafruit username>/feeds/%sysname%%valname%
=
<adafruit username>/feeds/sensor01hum
<adafruit username>/feeds/sensor01temp

The bit after the feeds/... needs to be matched in adafruit.io
So in my example you need a feeds called "sensor01hum" and "sensor01temp"

Note: you could also use the name you have given to the device in the feed name.
%tskname%

<adafruit username>/feeds/%sysname%%tskname%valname%
could look like this...
<adafruit username>/feeds/sensor01dhttemp

flopezvolpe
New user
Posts: 1
Joined: 16 May 2018, 15:30

Re: adafruit io mqtt ?

#3 Post by flopezvolpe » 05 Jun 2018, 17:53

Hello, Thanks for your help. it was very interesting.
i was created dongle switch on io.adafruit, but and all the feeds works great! but i cant turn on/off the sonoff relay from adafruit website. (Locally from the switch:Yes)

have you any sollution for that?
Regards.

Post Reply

Who is online

Users browsing this forum: No registered users and 48 guests