Read and Write MQTT value - Setpoint temperature

Tags: #<Tag:0x00007f73941fab08>

I continue to integrate my heating system over MQTT.

I have come to an point where I have the following MQTT topic added to HA:

  - platform: mqtt
    name: "Indoor "
    state_topic: "nibe/modbus/47398"
    unit_of_measurement: '°C'

I also have a JSON subtopic (nibe/modbus/47398/json) with some additional information:

    "register": "47398",
    "factor": 10,
    "size": "s16",
    "mode": "R/W",
    "titel": "Room sensor setpoint S1",
    "info": "Sets the room temperature setpoint for the system",
    "unit": "°C",
    "min": "50",
    "max": "300",
    "data": 20.5,
    "raw_data": 20.5,
    "timestamp": 1599769038067,
    "logset": false

The sensor are working fine, I can get the value set in the heating-system. Now I want to be able to set the temperature from HA.
The topic I can send to are: nibe/modbus/47398/set with raw payload e.g. 21.5. In steps of 0.5, max and min values can be “hard-coded”, they don’t change so reading the JSON max and min are not necessary.

I don’t know which path I shall go. But I want to combine the read and write value (like a dimmer slider, I use:
Can you please point me in a direction where I can find some more information how to do this? Saw some:
But I’m not sure it fits this need…

Please advice me… again…! :slight_smile:

Anyone have got some help for me? :slight_smile:

Is there a reason why you didn’t use MQTT HVAC to control your heating system?

1 Like

Ah, of course I shuld use that one… I didn’t know/realize!
After reading it through I don’t find any water-heater states included. Is there a way to “extend”/customize the integration?


Home Assistant is an open-source project so all of its source code is available for inspection/modification. If you are experienced with python, you can create a custom component based on MQTT HVAC.

Thanks, I’m a litte bit intrested about customization + updates…

Is it possible to just extend the MQTT HVAC (just add the extras). And will the updates work well then, except for breaking changes.

I also posted this about costomization of the visible names in the UI.

Hmm, after trying to deal with the MQTT HVAC, I find the modes to be fixed (its a component more suited for air-heater/ac). I have to create “dummy” modes for my machine to work.

But fan speed and temperature (current and commanded) works great!

So the Climate-component may not fit 100%…

How does your heating system differ from what is supported by MQTT HVAC?

I have a water-heater in my system.
And the mode I have are: Auto, Manual, Additive heat only
When Selecting Manual mode, then I can set two topics true or false: Allow heating, Allow additive heating.
So my mode are actually 3 MQTT topics.

For the temperature I use your workaround @123 :slight_smile: