various updates

This commit is contained in:
2024-10-21 00:00:16 -04:00
parent 05534234c7
commit 0c8e81d801
8 changed files with 135 additions and 32 deletions

View File

@@ -5,6 +5,8 @@
- [Door Lock](#door-lock)
- [Philips Hue Lights](#philips-hue-lights)
- [Shelly](#shelly)
- [Relative Humidity Calculator](#relative-humidity-calculator)
- [Font Colors](#font-colors)
## Setup and Configuration
@@ -37,3 +39,32 @@ the range of your home assistant's bluetooth capabilities. Active scanning uses
is quicker to pick up and transmit device information. Note that "gateway mode" is not required,
just enable bluetooth and rpc or select "active" from the configuration menu for the shelly
device.
### Relative Humidity Calculator
<https://www.wikihow.com/Calculate-Humidity>
You can calculate the relative humidity of the outdoor air if warmed to indoor temperatures like so:
```jinja
{% set dew_point = state_attr("weather.forecast_home", "dew_point") %}
{% set air_temp_f = state_attr("climate.ecobee_thermostat", "current_temperature") %}
{% set air_temp = (5/9)*(air_temp_f-32) %}
{% set sat_vap_press = 6.11 * 10**((7.5*air_temp) / (237.3+air_temp)) %}
{% set act_vap_press = 6.11 * 10**((7.5*dew_point) / (237.3+dew_point)) %}
{% set rel_hum = 100*(act_vap_press / sat_vap_press) %}
{{ dew_point }}
{{ air_temp }}
{{ sat_vap_press }}
{{ act_vap_press }}
{{ rel_hum }}
```
### Font Colors
```html
<font color = {{ "green" if state_attr("climate.ecobee_thermostat", "current_humidity") > low_humidity and state_attr("climate.ecobee_thermostat", "current_humidity") < high_humidity else "red" }}>
HVAC Humidity: {{ state_attr("climate.ecobee_thermostat", "current_humidity") }}%
</font>
```