I have a Mitsubishi AC unit and I’m using MELCloud integration to control it from Home Assistant. The AC device itself has a flaw that the air it does not spread around the apartment well so the internal thermostat thinks that the desired temperature is already reached even though it’s not. So I would like to control the temperature and other settings based on remote temperature sensors.
In order to define the temperature request for the AC I have created a python script that takes the remote sensor value (as current temperature) and desired temperature as inputs. It calculates the temperature request to be sent to the AC unit.
I have figured out the automation that calls for the script every now and then and sets the request for the AC. And it works. Took awhile to search here at the forum to find out how the “templates” works for getting the current temp as input to the script.
The las part I just cannot copmrehend, even though I would have supposed to find it easily from the documentation. How do I create an input to the lovelace UI?
Currently I have the desired temp hardcoded in the automation. I would like to be able to set the desired temp with a control in lovelace UI. Similar to a thermostat card. It could be an up/down arrow button setup and the number so that when you click up, the number steps up. Or a slider showing the number as well. And then I would like to pass that value to automation as the desired temp.
By searching I found several examples (or various issues) related to input_number, input_boolean, etc. But none of them exactly how to create such to the lovelace UI.