When ventilation actually makes sense?

After my original post got deleted, here is the replacement with corrected code indention.

Ventilation Recommendation

This project provides a set of Home Assistant template blueprints that help you decide when ventilation actually makes sense.

  • Calculate absolute humidity :droplet: based on existing sensor values
  • Estimate the potential humidity improvement :chart_increasing:
  • Get clear ventilation recommendation :vertical_traffic_light:
  • Reduce indoor humidity :chart_decreasing:
  • Avoid unnecessary heat loss :snowflake:
  • For data-driven automations for smart and efficient airing decisions :shuffle_tracks_button:

1. Calculate the Absolute Humidity :droplet:

This one is the most basic sensor. It simply calculates the absolute humidity based on Temperature (°C) and relative Humidity (%).

Can be used for statistics :bar_chart: or as trigger for automation :gear:. The Input values are also available as attributes:

image

Setup

To set up this sensor, you need to do two things:

  1. Import this Blueprint
    Open your Home Assistant instance and show the blueprint import dialog with a specific blueprint pre-filled.
  2. Add one ore multiple sensors to your configuration.yaml (or template.yaml):
template:
  - use_blueprint:
      path: Flo-R1der/absolute-humidity.yaml
      input:
      temperature: #weather-station-or-forecast-or-room-temperature
      relative_humidity: #weather-station-or-forecast-or-room-humidity
    name: Absolute Humidity #outside-or-room-name
    unique_id: absolute_humidity_ #outside-or-room-name

Obviously you need to fill the correct entity-id for each input sensor. You can set up one sensor for each area you want to track (outside, living room, bedroom, bath, …).

Note: You can see the cocking for lunch and dinner, as well as the ventilation having an effect on both: absolute humidity and temperature. Also the absolute humidity outside is always lower then inside. This sensor makes both values comparable!


2. Calculate the Potential Humidity Improvement :chart_increasing:

This sensor compares the inside and outside Temperature (°C) and relative Humidity (%) to calculate the theoretical improvement.

Can be used for statistics :bar_chart: or as trigger for automation :gear:. The Input values are also available as attributes:

This is done in three steps:

  1. Calculates the outside absolute humidity
  2. Calculates the theoretical humidity with the air from outside
  3. Subtracts the calculate humidity from the measured humidity. Result = this sensor value
Setup

To set up this sensor, you need to do two things:

  1. Import this Blueprint
    Open your Home Assistant instance and show the blueprint import dialog with a specific blueprint pre-filled.
  2. Add one ore multiple sensors to your configuration.yaml (or template.yaml):
template:
  - use_blueprint:
      path: Flo-R1der/potential-humidity-improvement.yaml
      input:
        outside_temperature: #weather-station-or-forecast
        outside_humidity: #weather-station-or-forecast
        inside_temperature: #room-temperature
        inside_humidity: #room-humidity
    name: Potential Humidity Improvement #room-name
    unique_id: potential_humidity_improvement_ #room-name

Obviously you need to fill the correct entity-id for each input sensor. You can set up one sensor for each room you want to track (living room, bedroom, bath, …).

NOTE: When ventilation takes place, the potential improvement drops and rises again afterwards.


3. Ventilation Recommendation :vertical_traffic_light:

This sensor compares the inside and outside Temperature (°C) and relative Humidity (%) to calculate the theoretical improvement and directly give an advice if ventilation is recommended or not.

Can be used as trigger for automation :gear: or as an traffic light system :vertical_traffic_light: to inform users via UI or any external lights. The Input values are also available as attributes:

Setup

To set up this sensor, you need to do two things:

  1. Import this Blueprint
    Open your Home Assistant instance and show the blueprint import dialog with a specific blueprint pre-filled.
  2. Add one ore multiple sensors to your configuration.yaml (or template.yaml):
template:
  - use_blueprint:
      path: Flo-R1der/ventilation-recommendation.yaml
      input:
        outside_temperature: #weather-station-or-forecast
        outside_humidity: #weather-station-or-forecast
        inside_temperature: #room-temperature
        inside_humidity: #room-humidity
        minimum_improvement_value: 10 #change-if-required
        threshold_room_humidity: 50 #change-if-required
    name: Ventilation Recommendation #room-name
    unique_id: ventilation_recommendation_ #room-name

Obviously you need to fill the correct entity-id for each input sensor. Adjust the values for minimum_improvement_value and threshold_room_humidity if you like. You can set up one sensor for each room you want to track (living room, bedroom, bath, …).


Tip:
Instead of the fixed numbers in yaml for minimum_improvement_value and threshold_room_humidity, you can also use input_number helpers for more dynamic adjustment of those two input values.

minimum_improvement_value: "{{ states('input_number.min_ventilation_improvement')|int }}"
threshold_room_humidity: "{{ states('input_number.humidity_threshold')|int }}"

:heart: Like My Work?

ko-fi
Part My Smart Home Stuff.

CO2 levels not included ?

I use my own calculations based on the above.
It has a min/max humidity as well as a min/max ppm-co2 level, and calculates the optimum fan speed every 5 minutes based on interpolation.

It also controls the bypass valve of the heat exchanger by comparing inside and outside temperature :stuck_out_tongue:


That explains the small bump in the temperature graph when outside temp is higher then inside temp. I probably still have to tweak that when winter is coming :cold_face:, but it helped keeping the house cool this summer :wink:

Hi aceindy,
honestly i have not installed any CO sensor. I have tested a few values with a IKEA Vindstyrka and only humidity was an issue to me. My ventilation system with is making its own calculations and the sensors above are for tracking and manually opening the windows, when required (could be automated). Here is my example:

When I enter the bathroom, and the presence sensor detects a person, the ventilation recommendation (#3 from above) is checked. If ventilation makes sense, the LED-strip under the washing table gives me a purple sign for 3 sec so I can open the window. Of course I could wait for a fan to evacuate the humidity, but that can take a while after showering and opening a window is much more effective (here I choose effectiveness over automation).

What is your decision logic, when you try to control temperature, humidity and CO (maybe VOC)? I just finished another project Flo-R1der/ESPHome_window-opener where I used this logic:


I actually have 2 automations;
One for humidity; it uses a derivative sensor; if there is a sudden increase of the humidity ( = shower start), the ventilation will be at 100% (no window in my bathroom).
It will just return to the previous set speed once the light turned off and no motion is detected for 30 minutes.
It also sets a toggle helper to indicate the humidity booster is active.

The CO2 automation just checks the CO2 level every 5 minutes, under the condition the humidity booster isn’t active.
If it increases, it will speed up the ventilation, if it decreases it will slow down the ventilation
It just tries to keep it within boundaries set in these variables:

  - variables:
      flow_min_z1: 100
      flow_max_z1: 275
      flow_min_z2: 90
      flow_max_z2: 300
      co2_min: 600
      co2_max: 1100
      co2: |-
        {{ states('sensor.wtw_rs485_highest_measured_co2_concentratie')
           | float(co2_min) }}
      ratiot: |
        {% set r = ((co2 - 650) / 450) %} {{ [[r,0] | max,1] | min }}
      ratio: '{{ ratiot | float ** 2 }}'
      target_z1: '{{ (flow_min_z1 + ratio * (flow_max_z1 - flow_min_z1)) | round(0) }}'
      target_z2: '{{ (flow_min_z2 + ratio * (flow_max_z2 - flow_min_z2)) | round(0) }}'

I actually have 2 zones; each uses its own speed boundaries as they have different volumes.
These values have been tweaked manually over a period of time :wink:

I care about CO₂ and temperatures rather about humidity when considering ventilation. (Bathroom is an exception.) That said, humidity can be an issue and I have humidity sensors, but I don’t need to take the humidity in account there.

In cold weather:

  • I want to accumulate heat
  • ventilation most likely decreases humidity, no matter what. And even if it increases humidity, at 10°C, even if it was 100% humidity outside, it is OK when the walls have at least 20°C.
  • CO₂ usually gets too high quicker than humidity, except in shower.

In hot weather:

  • I want to reduce heat
  • Outside humidity is an issue typically only after rain, when I want to ventilate in order to decrease temperature, but it also brings humid air. Dehumidifier helps.
  • Also, I don’t think it is an issue when done for a short period – walls are hot, because cold air (even humid) will not condense on hot walls.

My ventilation system has a build in heat-exchanger, and I can control the bypass valve for it.

So, in summer time, when the outside temperature drops below the inside temperature, I switch to by-pass, so I can cool my house better :wink:

A few conditions must be met:
Temperature needs to be > 18 degs C
Month must be {{ now().month in [5, 6, 7, 8, 9] }}

Maybe this winter I need to revise this, and reverse the logic keeping an eye on global warming and such :thinking: