MQTT Hub/Gateway

As far as I know everyone using my Home Assistant flow is up and running - if you’re not get in touch - or anyone that wants to try it.

One thing … Some flows got out that have my homey name (homeo) hardcoded in the mqtt nodes - in-particular the bottom 7 on the left hand side must be edited to use your Homey name. see below

e.g. for a Homey called ‘homey’

homie/homeo/+/#
must be changed to
homie/homey/+/#

I have two Homeys - ‘homeo’ and ‘juliet’ … trying for a third :wink:

image

1 Like

Hello, Thanks for making it possible to finally build dashboards for Homey! :blush:
I can’t get this to work with opeenhab.
Have installed broker, client, and hub on Homey. Can anyone share a step by step with settings in the different apps required?

The offline state is a bug in openHab (should be fixed in the next version). When you hit ‘broadcast’ in the app settings, it can get back online.

Once openHab has found your devices, channels for them are created in the Homie MQTT device. From these channels you can create ‘things’. These things can be connected to controls on the dashboard.

Once you’ve created a thing, the Homey device should be controllable, regardless of the offline message.

1 Like

I have tried broadcast, but don’t work… maybe some other settings that I’ve missed. Should it autodetect the homey mqtt?

make sure you have the right version of every app

for homey v2 that means:
latest beta version of the mqtt client app
latest version of the mqtt hub “homie2” branche from github
preferably mosquitto or similar running on your rpi as a broker to lower the load on Homey.

first thing to try when anything breaks, is to restart the mqtt hub app or the mqtt hub service via the settings page.
Debugging can be done using the MQTT client logs, openhab.log and MQTT Explorer

if you need debugging support for Homey v2, feel free to contact me on slack

1 Like

Thanks, I have done everything correctly I think. New to mqtt… I don’t use slack, but thanks for wanting to help, really appreciate it. Think I’ll wait to someone gives a step by step guide with all settings etc.

1 Like

How does the sync work between Homey and Openhab after the first sync? Should that be instantaneously or do you need to do it manually or something else like firing it up again?

I am trying to make a dashboard and tweaked/added some buttons in Homey but these changes do not show up under the binding in OpenHAB. While I have similar buttons with the exact same syntax available from the start. I tried restarting both Homey and my NAS (on which I have the broker & OpenHAB), but no difference. And would rather not do the whole binding thing again, especially since it would not be normal to do this for every change in Homey.

The devices should automatically become available. The app contains a ‘device manager’, which should keep track of added & removed devices. Must admit I did not test this functionality thoroughly (yet).

What happens when you press the ‘broadcast’ button in the app settings? A broadcast will publish the current state of all devices.

If the devices still don’t show up, you could try to disable and re-enable a random device via the app settings. This will trigger the devices initialization process (don’t forget to press broadcast afterwards).

Keep in mind there’s a small bug in openhab regarding the offline status of the MQTT Homie device. See also this conversation of @xAPPO with the developer of MQTT2 within openhab.

Please let me know your findings, so I can adjust the app when needed.

Sorry, should have said that wih my post but I am still on v1 so no settings page for me. I have got no offline issues with the MQTT Homie device, that seems rather solid on my setup.

That explains…the version for 1.5 does not contain the broadcast and is missing the functionality to refresh devices (both are build for the 2.0 app settings).

Installed MQTT Client and Gateway and the private broker in the cloud. everything is working get messages in. Installed MQTTbox for testing on my MAC. To receive the latest MQTT Gateway I have to install it via CLI, right? only have a MAC is it possible to connect or only via Windows command line?

oh see now: CLI client not compatible with v2 of Homey. how you doing this guys

Ok, good to know. Since it were just small tweaks and still fidlling around with my dashboard I just uninstalled and re-installed the MQTT Brokers and let it sync fresh. Now I have the buttons available (for now)…

I’m using a Mac and also using the CLI to install things (Homey v2). The guide i followed to install cli was in Swedish so I don’t have a good link but it should work if you find a guide for it.

1 Like

@Sat2All Did you take a look at this guide: [How To] CLI Install method ?

1 Like
  1. Topic in this example: homie/homey/lampkantoor/onof/set

in my config it looks like: undefined/homey/…

where does the undefined come from? did I mis some configuration?

  1. MQTT-Explorer all comes in auto discover. How should the config look in OpenHAB, doesn’t work so far. So I installed

Bindings: MQTT binding.
Things: Homie MQTT device (this one is offline)
Things: MQTT Broker (online)

No auto discover =. no Items.

Who can help?

edit: MQTT Broker v1.0.4 (on Homey)
MQTT Client v2.2.1
MQTT Hubv2.02
Homey v2.

The ‘undefined’ is a small (known) bug in the settings (fix is on its way).
You can change it in the app settings. type ‘homie’ in the root topic field.
Press ‘broadcast’ afterwards.

1 Like

Can you also help on my second point:

  1. MQTT-Explorer all comes in auto discover. How should the config look in OpenHAB, doesn’t work so far. So I installed

Bindings: MQTT binding.
Things: Homie MQTT device (this one is offline)
Things: MQTT Broker (online)

Try removing the OpenHAB MQTT Device & create a new one using the default settings.

1-MQTT%20Explorer

MQEXPLORER still shows capitals n the names see Badkamer Eetkamer. Think this isn’t following the homie standard?

It shouldn’t. Going to look into that one.

I see you enabled the injection of the device class & zone into the topic. This breaks the Homie convention & will probably break auto discovery in openhab (it’s meant for custom usage in e.g. Node RED, I should probably document this)