Advertisement
Guest User

Untitled

a guest
May 18th, 2019
160
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 0.78 KB | None | 0 0
  1. substitutions:
  2.   plug_name: esp_bed_light
  3.  esphome:
  4.   name: ${plug_name}
  5.   platform: ESP8266
  6.   board: esp8285
  7. wifi:
  8.   ssid: "######"
  9.   password: "########"
  10. # Enable logging
  11. logger:
  12. # Enable Home Assistant API
  13. api:
  14.   password: '########'
  15. ota:
  16.   password: '############'
  17. # Enable logging
  18. web_server:
  19.   port: 80
  20.  
  21. time:
  22.   - platform: homeassistant
  23.     id: homeassistant_time
  24.    
  25. binary_sensor:
  26.   - platform: gpio
  27.     pin:
  28.       number: GPIO13
  29.       inverted: True
  30.     name: "${plug_name}_button"
  31.     on_press:
  32.       - switch.toggle: relay    
  33.  
  34. switch:
  35.   - platform: gpio
  36.     name: "${plug_name}_Relay"
  37.     pin: GPIO12
  38.     id: relay
  39.    
  40.   - platform: gpio
  41.     name: "${plug_name}_LED_Red"
  42.     pin: GPIO16
  43.     inverted: True
  44.     restore_mode: ALWAYS_OFF
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement