Termostat umożliwiający monitorowanie temperatury wody zasilającej grzejniki

ogarnąłem temat automatyzacja :slight_smile: ponizej kod z esphome i automatyzacja.

esphome:
  name: termostat

esp8266:
  board: esp01_1m

# Enable logging
logger:

# Enable Home Assistant API
api:

ota:
  password: 

wifi:
  ssid: 
  password: 

  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Termostat Fallback Hotspot"
    password: 

captive_portal:

switch: 
  - platform: gpio
    pin: GPIO 0
    name: "RelDół"
    id: "dol"
    #inverted: true
    
  - platform: gpio
    pin: GPIO 2
    name: 'RelGóra'
    id: "gora"
    #inverted: true
  
dallas:
  - pin: GPIO1
    update_interval: 15s
  
sensor:
  - platform: dallas
    address: 0x5601145e9e982728
    name: "Tpodl"
    id: "Tpodloga"
    
  - platform: dallas
    address: 0x2D02099245225228
    name: "Temperature #5"
   # id: "Tbufor"
   
  - platform: dallas
    address: 0x8d082221ed0b6328
    name: "Tgora"
    id: "Tgora"
    
    
climate:
  - platform: thermostat
    name: "Termostat dół"
    sensor: Tpodloga
    min_heating_off_time: 10s
    min_heating_run_time: 10s
    min_idle_time: 20s
    default_mode: heat
    heat_deadband: 0.3
    heat_overrun: 0.2
    default_target_temperature_low: 28 °C
    heat_action:
      - switch.turn_on: dol
    idle_action:
      - switch.turn_off: dol    
    
  - platform: thermostat
    name: "Termostat góra"
    sensor: Tgora
    min_heating_off_time: 10s
    min_heating_run_time: 10s
    min_idle_time: 20s
    default_mode: heat
    heat_deadband: 0.3
    heat_overrun: 0.1
    default_target_temperature_low: 21 °C
    heat_action:
      - switch.turn_on: gora
    idle_action:
      - switch.turn_off: gora   

    
    
    
    
    

Automatyzacja ON:

id: ''
alias: Termostat dół ON
description: ''
trigger:
  - platform: numeric_state
    entity_id: sensor.temperature_5
    above: 34
condition:
  - condition: state
    entity_id: climate.termostat_dol
    attribute: hvac_action
    state: 'off'
action:
  - service: climate.turn_on
    data: {}
    target:
      entity_id: climate.termostat_dol
mode: single

Automatyzacja OFF

id: ''
alias: Termostat dół OFF
description: ''
trigger:
  - platform: numeric_state
    entity_id: sensor.temperature_5
    below: 32.5
condition:
  - condition: state
    entity_id: climate.termostat_dol
    attribute: hvac_action
    state: heating
action:
  - service: climate.turn_off
    data: {}
    target:
      entity_id: climate.termostat_dol
mode: single

To samo dla drugiego termostatu :grin:
Dla pracy “stand allone” automatyzacje można by zrobić w samym esphome :slightly_smiling_face:

1 polubienie