[BETA] MQTT app Home Assistant Discovery and statestream support

Well I'm pleased as it means we can get ya going :slight_smile:
The instructions are out of date in this area so not your fault
Yes you need to install the driver code but don't manually create an actual device, the app will do that for you. I should also identify this issue in the app

WOO HOO!

2020-06-22 06:37:03.129 pm infoMQTT: ================== Startup complete ==================

app:3212020-06-22 06:37:02.509 pm infoMQTT: Unsubscribing HA events

app:3212020-06-22 06:37:02.505 pm infoMQTT: [2] Total Hubitat endpoints enabled on MQTT

app:3212020-06-22 06:37:02.500 pm infoMQTT: [1] Total Hubitat devices are enabled on MQTT

app:3212020-06-22 06:37:02.321 pm infoMQTT: ==================================================

app:3212020-06-22 06:37:02.313 pm infoMQTT: Initialize exit

app:3212020-06-22 06:37:02.270 pm infoMQTT: Subscribing to 0 individual device topics

app:3212020-06-22 06:37:02.218 pm infoMQTT: Skipping homie MQTT discovery

app:3212020-06-22 06:37:02.206 pm infoMQTT: HE device publishing to MQTT has completed in 0 secs

app:3212020-06-22 06:37:01.408 pm infoMQTT: Resynch MQTT device states and HA discovery topics

app:3212020-06-22 06:37:01.253 pm infoMQTT: Starting HE device publishing to MQTT for 1 HE devices with 1 attributes

app:3212020-06-22 06:36:48.091 pm warnMQTT: Abort is false

app:3212020-06-22 06:36:48.083 pm warnMQTT: restart requested but there's maybe another instance still initializing

app:3212020-06-22 06:36:48.055 pm infoMQTT: MQTT has reconnected, restarting APP

app:3212020-06-22 06:36:48.047 pm infoMQTT: MQTT Status is Connect

app:3212020-06-22 06:36:44.259 pm infoMQTT: Waiting for MQTT connection: false

app:3212020-06-22 06:36:44.035 pm infoMQTT: initialising with App count 0

app:3212020-06-22 06:36:43.803 pm infoMQTT: Hubitat hub name is : Hubitat_MQTT

app:3212020-06-22 06:36:43.758 pm infoMQTT: MQTT child client created

app:3212020-06-22 06:36:39.026 pm infoMQTT: Creating MQTT client child driver

app:3212020-06-22 06:36:39.021 pm infoMQTT: FYI your MQTT child devices are []

app:3212020-06-22 06:36:38.983 pm infoMQTT: MQTT Updated

And that instantly hit my HA broker.

So, at least HE is doing exactly what Shelly is doing

[INFO] found mark on Home Assistant
1592868989: New client connected from 10.0.1.164 as Hubitat_hubitat-mqtt (p2, c1, k60, u'mark').
1592868989: Socket error on client Hubitat_hubitat-mqtt, disconnecting.
1592868989: New connection from 10.0.1.164 on port 1883.
1592868989: New client connected from 10.0.1.164 as Hubitat_hubitat-mqtt (p1, c1, k60, u'mark').

That looks a lot better :slight_smile:
Now the bottom menu in my app allows you to 'publish' an HE device to MQTT - try one - they are published by capability

Actually, I take that back, HE didn't get rejected!

Ahh strange ... but MQTT Explorer remains connected ?? You are using that same username / password in HE ?

You see it likes me !

1 Like

Tell me a sample HE device type you have e.g. switch, dimmer, RGB that you might like to expose to MQTT and HA ?

A non colour dim device is a good one to start

Let's try the Ikea Smart Blind. I connected it directly to HE via Zigbee, and am not using the Ikea hub. It works like a champ on HE. I would love to get it working in HA

You did that deliberately !
It is supported in beta3d but not in beta3c - I added it this week
3d will be out in the next couple of days

1 Like

lmao I had no idea actually!

We can go for a GE Z-Wave Fan Controller

Now you're just goading ! That may not be implemented yet but I will check (it has speeds I assume) ...- you got a bulb to start with or a switch ?

This is the shade device in HA by the way (beta3d)

image

1 Like

Very cool!

No bulbs. Well, I mean I have Wyze bulbs, but HA already directly works with them. Don't even need IFTTT.

The only other Zigbee or Z-wave device I have, is a Keen Smart Vent.

I also have a Z-Wave GE light switch

A nightmare customer !

OK .. I'll send you a link to the beta3d (pre) release by PM and that will work with your blinds.

Please just overwrite the app code and the device code. Don't uninstall either - and then click 'done'

1 Like

Ah man, you didn't have to do that. I can wait until the release.

I re-examined the logs on HA and it looks like HE may have received the boot afterall. The log entries are numbered the same, but have different results, so I'm not sure what happened

[INFO] found mark on Home Assistant
1592868989: New client connected from 10.0.1.164 as Hubitat_hubitat-mqtt (p2, c1, k60, u'mark').
1592868989: Socket error on client Hubitat_hubitat-mqtt, disconnecting.
1592868989: New connection from 10.0.1.164 on port 1883.
1592868989: New client connected from 10.0.1.164 as Hubitat_hubitat-mqtt (p1, c1, k60, u'mark').

Hmm - it looks like it has - this is a user authentication issue I think but I don't understand why MQTT Explorer is remaining connected. I know some people have reported issues with the HA broker when not using the mosquitto based version. I don't think I can help with this. The HA forum might have answers.

The fact MQTT Explorer shows data from HE or Shelly in its topics does not mean they are connected currently as the broker retains this information.

1 Like

@Kevin Picking up from my earlier message, I see this in the logs " HA climate device not implemented yet, no device created"

It's looking like it was a 'next beta' addition then...

Post me that screen grab though and I'll show you how to get it into HE manually

Here we go... Thanks for the help!

there are 4 reported values here

mode
target_temperature_high
target_temperature_low
current_temperature

what do you want to get into HE - just the 'current_temperature or more ?

If you do want more than temperature are the others controllable in HA and what values can mode be set too ?

How does this display in Lovelace as a thermostat - screenshot ?