Hey guys,
I have a device, that is sharing its battery state via MQTT. The problem is, that its value is “100 %”, “99 %” and so on … I implemented it in home assistant like this:
This is working, but in home assistant the history of the sensor is showed like state changes, instead of a numeric value (since in MQTT the value is a string instead of a numeric value).
Somehow this isn’t working. I think the problem is, that the value in MQTT is “100 %” (with % included)… its not just a number without the “%”…
I tried what you said, but this didn’t change anything, I still get this:
Btw.: Is it possible to replace more values with your method? This is an example:
I have a device (also MQTT) that gives different states with numbers from 0 to 3. Is it possible to replace all values to something else: 0 to Auto, 1 to Manuell, 2 to Home, 3 to EOD.