esphome:
  name: garage
esp8266:
  board: d1
# Enable logging
logger:
# Enable Home Assistant API
api:
  password: "Set Password"
ota:
  password: "Set Password"
wifi:
  ssid: "VPNSendling"
  password: "Set Wifi Password"
  # Enable fallback hotspot (captive portal) in case wifi connection fails
  ap:
    ssid: "Garage Fallback Hotspot"
    password: "Set secure Password"
captive_portal:
# DHT11 Sensor
sensor:
  - platform: dht
    pin: D6
    temperature:
      name: "Garage Temperatur"
    humidity:
      name: "Garage Luftfeuchte"
    update_interval: 60s
# Garagentor öffnen mit Wemos Relais
switch:
  - platform: gpio
    pin:
      number: D10
      #inverted: True
    restore_mode: ALWAYS_OFF
    id: relay
    name: "Garagentor"
    icon: "mdi:gate"
    on_turn_on:
    - delay: 800ms
    - switch.turn_off: relay
# Garagentor Kontaktsensor
binary_sensor:
  - platform: gpio
    pin:
      number: D4
      mode: INPUT_PULLUP
      inverted: false
    name: "Garagentor"
    device_class: door
    filters:
      - delayed_on: 10ms
# Garagentor Button am ESP Gehäuse
  - platform: gpio
    pin:
      number: D3
      mode: INPUT_PULLUP
      inverted: True
    name: "Garage Button"
    device_class: presence
    filters:
      - delayed_on: 10ms