Created
January 25, 2021 19:25
-
-
Save sicknesz/a7e8671dda52f8943d512084740d63e1 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| vapor_deficit: | |
| friendly_name: 'VPD in kilo pascals' | |
| value_template: >- | |
| {% set T = states('sensor.growtent_temp') | float %} | |
| {% set RH = states('sensor.growtent_humidity') | float %} | |
| {% set t = states('input_number.leaf_temperature') | float %} | |
| {% set VPSat = 610.7 * 10 ** (7.5 * t / (t + 237.3)) / 1000 %} | |
| {% set VPAir = (610.7 * 10 ** (7.5 * T / (T + 237.3)) / 1000) * (RH/100) %} | |
| {% set VPD = VPSat - VPAir %} | |
| {{- VPD | round(2) -}} | |
| unit_of_measurement: 'kPa' | |
| icon_template: >- | |
| mdi:gauge |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment