sehriyar
(Şəhriyar Balabəyov)
September 23, 2021, 6:15pm
1
Hello. I have one question regarding controlling temprature values in automation. Now I change temprature value in HA in Configuration. for example if I want to turn on heating system above 31 celcius not 35 celcius, I change 35 to 31 from configuration tab. But I would like to control this 35 or 31 celcius degrees in dashboard (main menu). I am open for coding or any other suggestion to reach this goal.
FYI, for this automatization we use MI temprature sensor, aqara relay, selenoid valve.
Just create an input_number helper and use its state in your automation.
1 Like
sehriyar
(Şəhriyar Balabəyov)
October 13, 2021, 7:28pm
3
i create a imput number but i do not use it. can you help me ?
You didn’t give us much to work with, but it would look something like this:
automation:
- id: heating
alias: heating
trigger:
- platform: numeric_state
entity_id: sensor.temperature_current
above: input_number.temperature_target
action:
- service: switch.turn_on
entity_id: switch.heating
Why you would turn on the heating, when it is already warm eludes me though.
123
(Taras)
October 14, 2021, 5:11am
5
Have you considered using the Generic Thermostat integration?
It produces a climate
entity which is displayed by the Thermostat card in the UI.
1 Like
sehriyar
(Şəhriyar Balabəyov)
October 15, 2021, 7:45pm
7
yes of course. which of this you can prefer ? (which you can give advice? )
123
(Taras)
October 15, 2021, 11:10pm
8
Copy-paste this into your configuration.yaml
file:
climate:
- platform: generic_thermostat
name: Thermostat
heater: switch.your_heater_switch
target_sensor: sensor.your_temperature_sensor
min_temp: 15
max_temp: 35
target_temp: 22
min_cycle_duration:
seconds: 15
initial_hvac_mode: "off"
Change the names of the switch and temperature sensor to match the ones you have.
Save the file and restart Home Assistant.
Check Developer Tools > States and you should see a new entity called climate.thermostat
You can add a Thermostat card to your Lovelace UI in order to control climate.thermostat
1 Like
sehriyar
(Şəhriyar Balabəyov)
October 18, 2021, 5:16am
9
thank you wery much for your help ))
1 Like