Display status of MQTT Topic in OH3

  • Platform information:
    • Hardware: VM on ESXi
    • OS: CentOS 7.9
    • openHAB version: 3.1 running on docker

I’m new to OH3. I already did some things on OH2 but I’m struggling with OH3 now. I’ve got an ESP8266 with ESPEasy which sends the status of a basement pump via MQTT to my MQTT Mosquitto Broker on my CentOS VM. Status 0 → Ok, no error. Status 1 → Not Ok, error.

I can see the status (0 or 1) with MQTT.fx or on the Linux command line.

[user1@centos ~]$ mosquitto_sub -h localhost -t MicroController/GeneralError/State
0
0

So everything is ok. On OH3 I did the following steps.

  1. Installed MQTT Binding
  2. Added a MQTT system broker connection
  3. Things → Click on + → MQTT Binding → MQTT Broker (Bridge)
  4. Things → Click on + → MQTT Binding → Generic MQTT Thing
  5. And now I’m stuck…

In OH2 there was the Paper UI and I could see the values coming in from my MQTT Topic right the way. How can I display the status of my MQTT topic MicroController/GeneralError/State in OH3 like it was possible in OH2 with Paper UI?

Example of OH2 with Paper UI and Temperature on my balcony.

OH2 Paper UI Temperature Balcony

Thank you very much for your help.

Cheers Manuel

You are on the right track.
After adding the generic MQTT thing, add the respective channels (aligned to your MQTT topic) and then, if needed, items which can be displayed on the UI.

Hello Chris
Thank you very much for pointing me in the right direction. I’ve got it now!

I now see if the status of my pump is 0 (ok) or 1 (not ok). Now I’m going to play around with rules :smiley:

Thank you for your help.

Manuel

Not wanted in OH3, remove. (It’s an OH2 legacy of the embedded broker option)

Hello rossko57
Thank you for your input. I just can delete MQTT system broker connection and everything is still working?

Greetings Manuel

Yes. Your broker Bridge does the work.