I am currently fiddling with ebusd. Not the native integration but ebusd via MQTT. I am facing the following situation:
ebusd send the state of the heaters flame with the topic ebusd/bai/Flame
. The result is JSON encoded and looks like this in MQTTExplorer:
{
"0": {"name": "", "value": "off"}
}
I now want to create a binary sensor to read the state of the flame but I cannot get it to work. I have tried the following:
- platform: mqtt
name: "Gastherme Flamme"
state_topic: "ebusd/bai/Flame"
value_template: "{{ value_json['0'].value == 'ok' }}"
and
- platform: mqtt
name: "Gastherme Flamme"
state_topic: "ebusd/bai/Flame"
value_template: "{{ value_json['0']['value'] == 'ok' }}"
But both solutions do not deliver the correct state. Can anyone help me out with the binary sensor?