Advertisement
Guest User

Untitled

a guest
Feb 15th, 2020
116
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
YAML 2.30 KB | None | 0 0
  1. ## Lekstugan lampor
  2.  
  3. esphome:
  4.   name: shelly2_03
  5.   platform: ESP8266
  6.   board: esp01_1m
  7.  
  8. wifi:
  9.   manual_ip:
  10.     static_ip: 192.168.21.192
  11.     gateway: 192.168.21.1
  12.     subnet: 255.255.255.0
  13.     dns1: 192.168.21.12
  14.     dns2: 1.1.1.1
  15.   networks:
  16.  # AP02 finentren
  17.   - ssid: !secret ssid
  18.     password: !secret wifipwd
  19.     bssid: F0:9F:C2:34:EB:03
  20.   # AP04 Garaget
  21.   - ssid: !secret ssid
  22.     password: !secret wifipwd
  23.     bssid: FC:EC:DA:81:BA:D1
  24.   # AP01 Hall OV
  25.   - ssid: !secret ssid
  26.     password: !secret wifipwd
  27.     bssid: 80:2A:A8:D4:D3:28
  28.   ap:
  29.     ssid: "Shelly2_03 Fallback Hotspot"
  30.  
  31. captive_portal:
  32. # Enable logging
  33. logger:
  34. # Enable Home Assistant API
  35. api:
  36. ota:
  37. web_server:
  38.   port: 80
  39.  
  40. i2c:
  41.   sda: GPIO12
  42.   scl: GPIO14
  43.  
  44. binary_sensor:
  45.   - platform: gpio
  46.     pin:
  47.       number: GPIO13
  48. #      mode: INPUT_PULLUP
  49. #      inverted: True
  50.     name: "Shelly2 03 Switch 1"
  51.     internal: true
  52.     on_state:
  53.       - switch.toggle: relay1
  54.   - platform: gpio
  55.     pin:
  56.       number: GPIO5
  57. #      mode: INPUT_PULLUP
  58. #      inverted: True
  59.     name: "Shelly2 03 Switch 2"
  60.     internal: true
  61.     on_state:
  62.       - switch.toggle: relay2
  63.   - platform: status
  64.     name: "Shelly2 03 Status"
  65.  
  66. switch:
  67.   - platform: gpio
  68.     name: "Shelly2 03 Relay 1"
  69.     pin: GPIO4
  70.     id: relay1
  71.  
  72.   - platform: gpio
  73.     name: "Shelly2 03 Relay 2"
  74.     pin: GPIO15
  75.     id: relay2
  76.  
  77. sensor:
  78.   - platform: wifi_signal
  79.     name: "Shelly2 03 wifi signal"
  80.     update_interval: 60s
  81.   - platform: ade7953
  82.     voltage:
  83.       name: Shelly2 03 Voltage
  84.     current_a:
  85.       name: Shelly2 03 Current B
  86.     current_b:
  87.       name: Shelly2 03 Current A
  88.     active_power_a:
  89.       name: Shelly2 03 Active Power B
  90.       filters:
  91.         - multiply: -1
  92.     active_power_b:
  93.       name: Shelly2 03 Active Power A
  94.       filters:
  95.         - multiply: -1
  96.     update_interval: 10s
  97.  
  98.   # NTC Temperature
  99.   - platform: ntc
  100.     sensor: temp_resistance_reading
  101.     name: "Shelly2 03 Temperature"
  102.     calibration:
  103.       b_constant: 3350
  104.       reference_resistance: 10kOhm
  105.       reference_temperature: 298.15K
  106.   - platform: resistance
  107.     id: temp_resistance_reading
  108.     sensor: temp_analog_reading
  109.     configuration: DOWNSTREAM
  110.     resistor: 32kOhm
  111.   - platform: adc
  112.     id: temp_analog_reading
  113.     pin: A0
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement