I have two temperature sensors and created a third one using Helper: Combine the state of several sensors, Statistical range. So it gives temperature difference between Sensor 1 and 2.
The idea is to turn Attic Fan when difference above 3C. But it does not fire.
I see the sensor.status_temperature_attic_garage_delta reports 4C
But the Fan is still OFF?
I used this Helper. And it is not working right for my application. As implied it gives Statistical range vs. I need just actual difference.
What would be suitable Helper to find just difference between two numbers (temperature sensors in my case)?
I’m reading about templates, but I’m not ready to venture there yet…
Thank you.
Should you ever change your mind about not willing to “venture there yet”, create a Template Sensor helper, give it a name, then copy-paste this template into its “State template” field:
In the template, replace sensor.temp1 and sensor.temp2 with the entity_ids of your temperature sensors.
Save the new Template Sensor.
If you named it “Temperature Difference”, its entity_id will be sensor.temperature_difference and will be available for use elsewhere in Home Assistant (dashboard card, script, automation, etc). Its value will be automatically recalculated every time the value of either of the two sensors changes.
Privet, Taras, thank you.
I did it by adding this code in config.yaml. Is this correct way? Or I should create this sensor in a separate yaml (still learning)? By the way just to note that by reloading yamls from Dev tools the sensor was not there until HA restart. Expected?